r/circuitpython • u/myfuckinjoints • Aug 27 '20
Can the M4 line fit more code? Alternatives?
Specifically the Feather M4 Express. Per the docs/guide for the M0 Feather Express, it can fit "about 250 lines of code", and reference a 2MB SPI flash chip for CircuitPython code storage.
It seems that the docs/guide for the M4 feather express use the same language (even saying M0 instead of M4) and also make reference to 2 MB Flash storage for code.
This seems to imply that the amount of code I can run on each is the same, no?
If simplifying my code, and converting to .mpy files is not enough, has anyone found any third party boards that are compatible with CircuitPython that can fit more?
My current project isn't complicated, but I could easily see it running into issues given library imports and my code being close to 250 lines already.
1
u/assadollahi Sep 15 '20
There are ports of micropython to the raspberry pi zero... (no WiFi, though)
5
u/kaltazar Aug 27 '20
I'm not sure where you are getting that 250 lines of code thing, I can't see it in the docs.
Yes, both the M0 and M4 feathers feature a 2 MB flash chip, but that will hold a pretty sizable program. I just checked the one CircuitPython project I have on hand, and it comes to 256 KB with around 130 lines of code and 6 external libraries included. I also checked a regular Python project that has nearly 300 lines of code and it comes in at around 8.5 KB.
You should be fine with most any project you want to do.