Hi, i wrote C extension how to described in topic https://docs.micropython.org/en/latest/ ... atmod.html.
After, i built it under esp32 architecture 'make ARCH=xtensawin'.
It work fine, but i need call esp32-idf functions inside my extension. For example read/write to UART(https://docs.espressif.com/projects/esp ... /uart.html).
When i build micropython binary from source with my extension inside as in examples/usercmodule(https://docs.micropython.org/en/latest/ ... dules.html) i can call esp32-idf native functions. It is work because micropython src already include esp32-idf framework dependency.
But rebuild and reload micropython binary spend many time, it is more easy and fast working with mpy.
My question, it is possible call ESP-IDF framework functions inside *.mpy C extension?
Thank you very much for attention to my question!
Call native functions from mpy C extension.
-
- Posts: 169
- Joined: Fri Aug 19, 2016 11:55 am
Re: Call native functions from mpy C extension.
Unless I missed any recent developments, the answer is no. This has been discussed and solutions prototyped over the years, I believe the latest part is in pull request #5711. Someone else might know more.
Re: Call native functions from mpy C extension.
Thank you very match Christian, you save many of my time.Christian Walther wrote: ↑Sun Jul 03, 2022 7:46 pmUnless I missed any recent developments, the answer is no. This has been discussed and solutions prototyped over the years, I believe the latest part is in pull request #5711. Someone else might know more.