Open cyb3rcod3 opened 2 years ago
I found this repository and it will fit exactly in my smart home project, but I run into the same error with the 'UART2' was not declared in this scope.
Does anybody can help to get this problem fixed?
Add #include "esp32/rom/uart.h" to SerialCommunication.cpp
.pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp: In function 'void enocean_uart_intr_handle(void*)': .pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp:19:22: error: 'UART2' was not declared in this scope
define ENOCEAN_UART UART2
.pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp:38:17: note: in expansion of macro 'ENOCEAN_UART' rx_fifo_len = ENOCEAN_UART.status.rxfifo_cnt; // read number of bytes in UART buffer ^
~~~ .pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp:55:44: error: 'UART_RXFIFO_FULL_INT_CLR' was not declared in this scope uart_clear_intr_status(ENOCEAN_UART_NUM, UART_RXFIFO_FULL_INT_CLR | UART_RXFIFO_TOUT_INT_CLR); ^~~~~~~~ Compiling .pio/build/az-delivery-devkit-v4/FrameworkArduino/Esp.cpp.o .pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp:55:44: note: suggested alternative: 'UART_FIFO_LEN' uart_clear_intr_status(ENOCEAN_UART_NUM, UART_RXFIFO_FULL_INT_CLR | UART_RXFIFO_TOUT_INT_CLR); ^~~~~~~~ UART_FIFO_LEN .pio/libdeps/az-delivery-devkit-v4/Enocean/src/EnOcean/SerialCommunication.cpp:55:71: error: 'UART_RXFIFO_TOUT_INT_CLR' was not declared in this scope uart_clear_intr_status(ENOCEAN_UART_NUM, UART_RXFIFO_FULL_INT_CLR | UART_RXFIFO_TOUT_INT_CLR); ^~~~~~~~ Compiling .pio/build/az-delivery-devkit-v4/FrameworkArduino/FirmwareMSC.cpp.o Compiling .pio/build/az-delivery-devkit-v4/FrameworkArduino/FunctionalInterrupt.cpp.o *** [.pio/build/az-delivery-devkit-v4/lib9ac/Enocean/EnOcean/SerialCommunication.cpp.o] Error 1 ======================= [FAILED] Took 7.03 seconds ===========================