Page 1 of 1

Which Firmware?

Posted: Tue Oct 26, 2021 5:24 pm
by MMliam
Hi,

I'm new to microPython and want to flash an ESP-01S that allegedly has 1M of memory. If I flash the 1M firmware version, where does the application script run? Should I flash the 512K firmware version to allow enough space for the application?

Thanks, Mickey

Re: Which Firmware?

Posted: Tue Oct 26, 2021 5:44 pm
by davef
1M ESP-01S (ESP8266) use the 1M image. There is a small amount of room left to run your application. If you need more room search <freezing your code>.

Re: Which Firmware?

Posted: Tue Oct 26, 2021 8:43 pm
by MMliam
davef,

Wouldn't it be simplier to just use the 512KB version of microPython and gain 512KB of user memory? Also, from the little I've read on Python code freezing suggests the package will be larger, not smaller.
{Hitchhikers Guide to Python: "One disadvantage of freezing is that it will increase the size of your distribution by about 2–12 MB. Also, you will be responsible for shipping updated versions of your application when security vulnerabilities to Python are patched."}

Mickey

Re: Which Firmware?

Posted: Tue Oct 26, 2021 8:57 pm
by davef
I believe that it has something to do with the way the partitions are set up, ie the way the code is stored on the device.

I spent maybe 6 months or more playing with this part and after running out of code space and trying many times to freeze modules I decided to spent my time on the basic model ESP32. Freezing modules worked on that but the hassle of changing things left me feeling I was back working with the AVR ATMega series.

For the bigger jobs I now use ESP32-DevKitC-VIE ... more expensive but a lot less time wasted.

Good luck!

Re: Which Firmware?

Posted: Tue Oct 26, 2021 10:12 pm
by MMliam
Thanks for your perspective; but cost factors demand the ESP-01s. I'm beginning to get the feeling that until there's a compiled version, microPython will not be a practical solution for IoT; too much interpreter overhead.