[Dprglist] Multi-threading on multi-cores
Murray Altheim
murray18 at altheim.com
Tue Oct 20 01:13:10 PDT 2020
On 20/10/20 4:43 pm, David Anderson via DPRGlist wrote:
> On 10/19/20 2:59 PM, Murray Altheim via DPRGlist wrote:
>> but I rather appreciate being able to use Linux, vi and ssh as my environment.
>> It's not Java on Eclipse, but it's also not a single file in Arduino IDE.
>
> I'm not sure those are the only choices.
Hi David,
I wasn't attempting to be comprehensive of all the available choices, only
the ones I'd so far myself attempted.
> I develop all my robot code under Linux, using the GCC tool chain. I use
> vi for editing files and make for organizing projects. Cross compilers are
> available for ARM, ATMEL, MC68332, and what have you. I like to say that
> "Linux is my IDE."
Before I started using maven and Eclipse for Java development, I'd tackled
some pretty large Java projects with just vi and the ant build tool. One
project I did back between 2000-2006 was about 280,000 lines of code, done
laboriously by hand. I'd *never* do that now. But like you, Linux and vi
are my IDE of choice when doing Python development. I've thought about
investigating some kind of Python IDE but frankly haven't felt the need so
far.
> The STM32 Nucleo boards all include a hardware module to download code and
> flash the memory, as well as a hardware debugger you can attach to gdb if
> you're so inclined, to set breakpoints and single step to your heart's content.
I use debuggers in Java all the time, but on my robot project I've never tried,
and I'm guessing debugging my OS would be exceedingly difficult.
As a relatively newcomer to Python with no "python mentor" there's lots I've
never even thought about, just barreled blindly forward...
> I will say that I also found the Arduino environment constraining ---
> hard to imagine how one would do a really big project, like a robot ---
> but I also find the Arduino's themselves pretty constraining. Why use
> one when ARM boards are available? But it was designed as an entry point
> for beginners, and at that I think it does pretty well.
Yes, I suppose if one considers the target audience of an Arduino then
it's a pretty good match. As part of exploring some kind of low cost club
robot, the one I built that used an Adafruit Crickit for their Circuit
Playground Express [1] was fun to build hardware-wise but ultimate felt
enormously limiting when I tried to program it.
I quickly grew bored of it and it now sits on a shelf. In this case the
effort necessary to create a set of complex behaviours wasn't limited by
my imagination but by the tools themselves.
That was one reason when one of our friends' daughters wanted me to help
find her a robot I chose the AlphaBot2 using a micro:bit. It required little
to no skills in assembling it (the two sisters, 5 and 9, did it together),
and the micro:bit programming can start with a programming UI but graduate
to Python when she's ready.
> However I think I must take exception to the image of me (and others)
> tediously cramming functionality into what was termed a "tiny
> microprocessor." I actually find I have more processing horsepower
> and memory than I need, at least so far, and lots of room to expand.
> And the ARM processor is a joy to work with.
Oh, believe me there was nothing pejorative intended in my statement;
I'm generally blown away by what you've proven is possible with a tiny
microprocessor. I'd never thought of it as cramming. :-)
----
A bit on that subject, I've even thought about taking Pimoroni up on
trying to use their IO Expander Breakout board's [2] Nuvoton MS51
microcontroller, if I'm "brave and hackerly, you can substitute your
own firmware to change the way this board works and have a super
cheap and capable microcontroller (though this is not for the faint
of heart!"
The reference manual for the MS51 [3] points out that it's a small
surface mount CMOS 8 bit microcontroller whose instruction set is
"fully compatible with MCS-51", the Intel 8051 microcontroller which
arrived on the scene around 1980. Though it's nowadays a lot faster
and has a lot more features than the 8051.
[time passes...]
Okay, I did it: I sent a message into their forum seeing if they'd
possibly provide some documentation on how they program the firmware
on the board. I must admit my curiosity...
> Chacun a son gout!
A cada loco con su tema!
Cheers,
Murray
[1] https://www.adafruit.com/product/3093
[2] https://shop.pimoroni.com/products/io-expander
[3] https://www.nuvoton.com/export/resource-files/TRM_MS51_16KBFlash_Series_EN_Rev1.03.pdf
...........................................................................
Murray Altheim <murray18 at altheim dot com> = = ===
http://www.altheim.com/murray/ === ===
= = ===
In the evening
The rice leaves in the garden
Rustle in the autumn wind
That blows through my reed hut.
-- Minamoto no Tsunenobu
More information about the DPRGlist
mailing list