Closed IhorNehrutsa closed 4 years ago
The micropython-wrap is switched to ESP32-C++ branch. The micropython is switched to git hash (v3.3): 9e70825d1e1cbf7988cf36981774300066580ea7.
That last one is not going to work, should also be my ESP-32-C++ branch, per the instructions I left in at https://github.com/stinos/micropython-wrap/issues/5#issuecomment-680870982
rom ../../../modules/foo/foo.c:1: /home/pc/micropython-wrap/detail/micropython.h:7:8: error: expected identifier or '(' before string constant extern "C"
micropython-wrap is C++ code and must be compiled with a C++ compiler, you are compiling it as C code, which is also why it does not find cmath.h. Pleas try with the instructions mentioned above (my commits add support to MicroPython to allow C++ code in user modules), and use C++ code in a file like foo.cpp, not foo.c.
Closing this since another user could use the instructions in aforementioned issue to build and run the C++ module.
Hi everyone. I noticed issue #5. I work with micropython under Ubuntu. Some installation commands in ubuntu_install.zip
I can compile examples from esp-idf and mpy-cross from micropython. I try to compile micropython ESP32 port with modules. modules.zip The directory structure is:
I added
to the micropython/ports/esp32/Makefile.
The micropython-wrap is switched to ESP32-C++ branch. The micropython is switched to git hash (v3.3): 9e70825d1e1cbf7988cf36981774300066580ea7.
The 'example' module and 'temperature_conversion' module are compiled well and work after flashing 'firmware.bin' to the ESP32 generic board.
Compiling with 'foo' module gets errors:
I see cmath files. They notated with: // -- C++ -- C forwarding header.
Where can I add the include path? Thanks.