Hello All
I need to call C functions(from some .c file) to micropython script running on STM board. How it could be done?
I tried to call in same way CPython does, But I am getting error while importing C file in python script.
Call C functions from Micropython script.
Re: Call C functions from Micropython script.
In order to call C from MicroPython (on the pyboard) you need to create a module like the ones in the stmhal directory.
For example: https://github.com/micropython/micropyt ... mhal/led.c
Also see this thread: http://forum.micropython.org/viewtopic. ... =153&p=625
For example: https://github.com/micropython/micropyt ... mhal/led.c
Also see this thread: http://forum.micropython.org/viewtopic. ... =153&p=625