3 ms·
As opposed to the movement to put interpreted BASIC into PIC or Intel 8052 microcontrollers? 1980s embedded engineers please stand up. ------- But BasicStamp
by dragontamer 3y ago
As opposed to the movement to put interpreted BASIC into PIC or Intel 8052 microcontrollers?
1980s embedded engineers please stand up.
-------
But BasicStamp was a thing even decades ago (but after 1980s). There are plenty of advantages to interpreted languages, and they were a bigger deal back when 8052 or whatever we're EPROM and harder to program. I mean, physically harder, with UV to erase the flash.
Having a portion of the code execute out of dataspace thanks to an embedded interpreter was worthwhile, even with all the extra CPU cycles and RAM wasted.
I see Micropython as just an extension of that. Python displaced BASIC a long time ago for good reasons.
- miki123211 3y agoBasic can fit into a few kbytes of ROM on an 8-bit CPU, Python definitely cannot. Even lua needs ~100K IIRC, and that's more than the entire address space (including RAM, ROM and IO) of a 6502.
- dragontamer 3y agoWhile that's true, RP2040 is $1 these days. Though it requires external ROM to run, its a popular device and many boards (not just RP2040) are under $5. (ESP32 in particular). So there's a wide number of under $5 boards available that can run MicroPython, providing an easy start to embedded programmers. ------------ Of course, 8-bits are needed for minimal power consumption and maximum efficiency, with an ability to work off of 128kB of ROM and 8kB of RAM at under $1. But more importantly, 8-bitters are more complete systems. Better ADCs, often DACs, OpAmps, and other advanced features that RP2040 (and other 32-bit systems) got rid of to make room for RAM or ROM. That's the thing: 8-bits are more convenient and easier to use not because of code issues, but because they come with all the tools you need on one platform. --------- But beginners don't know how to use those tools *anyway* and are instead focused on blinking lights or basic I2C / SPI controls. I think grabbing a 32-bit Cortex M0+ (like RP2030) or similar system to run MicroPython isn't a bad thing. Its inefficient and better designs exist. But beginners shouldn't focus on optimizing yet. Its just like BasicStamp or BASIC-for-8052 back in the day IMO. You need a beginner platform so that young teenagers can experiment with this stuff, and young teenagers aren't going to read the 300+ page manuals that come with an AVR64DD32 to fully understand an 8-bitter's operation. But even a teenager can plug in a USB port, click a few buttons on an IDE and load Micropython to a RP2040 / ESP32 / whatever.