Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

As @snops explained, MicroPython supports executing code from flash in the form of frozen code. The consequence of this is that it needs to be compiled in to the firmware binary which slows down the typical rapid development cycle of MicroPython.

So a convenient workflow is to deploy at runtime (ie not in flash) until you stabilise your code base or approach production; at which point you can freeze your code into your firmware.

For an even more convenient model, there is the proposal to support 'mapfs' so that some flash will be allocated to store code. You can then compile your Python to bytecode (with `mpy_cross`) and upload it to - and run from - this area at runtime.

Although this feature has been demonstrated as a proof-of-concept, there are some subtleties to sort out before it hits mainline. If you're interested in the feature, please read or comment on the PR:

https://github.com/micropython/micropython/pull/8381



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: