make error when adding cpp_utils to esp-idf-template

Jamesgz
Posts: 4
Joined: Sun Oct 21, 2018 3:03 pm

make error when adding cpp_utils to esp-idf-template

Postby Jamesgz » Fri Nov 16, 2018 12:22 am

I am new to ESP32 and c++. I am on windows 10 and here are the steps that I took:
1. Cloned esp-idf-template to "ble-test" folder
2. Created components folder in "ble-test" and copied cpp_utils to components folder
2. copied main.cpp & all the sample cpp files into main folder
3. deleted main.c
4. modified set(COMPONENT_SRCS "main.c") to set(COMPONENT_SRCS "main.cpp") in CMakeList.txt in main folder
5. ran make menuconfig and enabled bluetooth
6. make all returns the following error:

`C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp: In member function 'void
C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp:57:16: error: 'struct spi
bus_config.flags = (SPICOMMON_BUSFLAG_SCLK | SPICOMMON_BUSFLAG_MO
^
C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp:57:35: error: 'SPICOMMON_
bus_config.flags = (SPICOMMON_BUSFLAG_SCLK | SPICOMMON_BUSFLAG_MO
^
C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp:57:60: error: 'SPICOMMON_
bus_config.flags = (SPICOMMON_BUSFLAG_SCLK | SPICOMMON_BUSFLAG_MO
^
C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp:57:85: error: 'SPICOMMON_
bus_config.flags = (SPICOMMON_BUSFLAG_SCLK | SPICOMMON_BUSFLAG_MO

C:/Code/Nano-Lit/ble-test/components/cpp_utils/SPI.cpp:82:32: error: 'SPI_DEVICE
dev_config.flags = SPI_DEVICE_NO_DUMMY;
^
make[1]: *** [/home/james/esp/esp-idf/make/component_wrapper.mk:274: SPI.o] Erro
make: *** [C:\msys32\home\james\esp\esp-idf/make/project.mk:450: component-cpp_u

`

Any help would be greatly appreciated.

Who is online

Users browsing this forum: Baidu [Spider], Google [Bot] and 12 guests