Page 1 of 1

unable to include .h files from ESP-IDF components directory

Posted: Tue Feb 11, 2020 3:20 am
by Patrice
Hi,

I would like to add new functions in the different machine_xxx.c but build doesn't work if I add a .h from esp-idf/components directory.
For example, if I had #include "esp_adc_cal.h" in machine_adc.c, buid command return this error :
fatal error: esp_adc_cal.h: No such file or directory

Without modifications, microPython for ESP32 build work perfectly.

Many thanks for your help.

Re: unable to include .h files from ESP-IDF components directory

Posted: Tue Feb 11, 2020 9:45 am
by fstengel
Just an idea, have you tried the following snippet:

Code: Select all

#include esp_adc_cal/esp_adc_cal.h
This mirrors what happens for rmt: one includes driver/rmt.h which actually includes the file found at component/driver/include/rmt.h in the esp-idf folder. I cannot test this at the moment, so this is just an idea...

Re: unable to include .h files from ESP-IDF components directory

Posted: Tue Feb 11, 2020 10:12 pm
by jimmo