Open Carglglz opened 11 months ago
Hi @Carglglz. Very cool! Fastest external merge request I have seen - I just made the repository public some hours ago :D
I have actually never tried to make a user module, so this should be helpful. I don't even think I know how to include it right now, but I have seen there is documentation for that. I've been working on the native module case, as I really like the idea of getting started without needing rebuild/reflash. But it is ideal to have both options, I think.
@jonnor
I don't even think I know how to include it right now, but I have seen there is documentation for that.
Don't worry I was curious if this could work and it does, then I've just made the draft so you can have a reference in case you want to test/implement it see https://docs.micropython.org/en/latest/develop/cmodules.html
I've been working on the native module case, as I really like the idea of getting started without needing rebuild/reflash. But it is ideal to have both options, I think.
Yes the native module case is probably the way to go for fast iteration, but when you're happy with the result then adding it as a frozen module may save some RAM/ improve performance (although I have not tested it in this case)
This is a POC to add
emlearn
as a frozen USER_C_MODULE in firmware. I had to modify/comment some lines, but I got it working (just git diff with the original files to see it)and
Not sure if you are interested but I hope this helps as a reference 👍🏼