I’m testing wifi kit 32 for IoT project. There is an error when I use Heltec ESP32 Dev-Boards Library. Anyone known how to fix it?
Library Heltec ESP32 Dev-Boards has been declared precompiled:
Using precompiled library in c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\esp32s3
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAS923.c: In function ‘RegionAS923TxConfig’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAS923.c:699:71: error: ‘LORAWAN_PREAMBLE_LENGTH’ undeclared (first use in this function)
Radio.SetTxConfig( modem, phyTxPower, 0, bandwidth, phyDr, 1, LORAWAN_PREAMBLE_LENGTH, false, true, 0, 0, false, 3e3 );
^~~~~~~~~~~~~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAS923.c:699:71: note: each undeclared identifier is reported only once for each function it appears in
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAU915.c: In function ‘RegionAU915TxConfig’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAU915.c:597:72: error: ‘LORAWAN_PREAMBLE_LENGTH’ undeclared (first use in this function)
Radio.SetTxConfig( MODEM_LORA, phyTxPower, 0, bandwidth, phyDr, 1, LORAWAN_PREAMBLE_LENGTH, false, true, 0, 0, false, 3e3 );
^~~~~~~~~~~~~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionAU915.c:597:72: note: each undeclared identifier is reported only once for each function it appears in
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\driver\gpio-board.c: In function ‘GpioMcuWrite’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\driver\gpio-board.c:54:15: error: ‘RADIO_NSS’ undeclared (first use in this function); did you mean ‘RAD_TO_DEG’?
if(obj->pin==RADIO_NSS && radio_nss_inited==false)
^~~~~~~~~
RAD_TO_DEG
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\driver\gpio-board.c:54:15: note: each undeclared identifier is reported only once for each function it appears in
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN470.c: In function ‘RegionCN470TxConfig’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN470.c:563:64: error: ‘LORAWAN_PREAMBLE_LENGTH’ undeclared (first use in this function)
Radio.SetTxConfig( MODEM_LORA, phyTxPower, 0, 0, phyDr, 1, LORAWAN_PREAMBLE_LENGTH, false, true, 0, 0, false, 4000 );
^~~~~~~~~~~~~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN470.c:563:64: note: each undeclared identifier is reported only once for each function it appears in
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN779.c: In function ‘RegionCN779TxConfig’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN779.c:632:71: error: ‘LORAWAN_PREAMBLE_LENGTH’ undeclared (first use in this function)
Radio.SetTxConfig( modem, phyTxPower, 0, bandwidth, phyDr, 1, LORAWAN_PREAMBLE_LENGTH, false, true, 0, 0, false, 3e3 );
^~~~~~~~~~~~~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\loramac\region\RegionCN779.c:632:71: note: each undeclared identifier is reported only once for each function it appears in
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\LoRaWan_APP.cpp:40:34: error: ‘LoRaWAN_DEBUG_LEVEL’ was not declared in this scope
RTC_DATA_ATTR uint8_t debugLevel=LoRaWAN_DEBUG_LEVEL;
^~~~~~~~~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\LoRaWan_APP.cpp:40:34: note: suggested alternative: ‘CORE_DEBUG_LEVEL’
RTC_DATA_ATTR uint8_t debugLevel=LoRaWAN_DEBUG_LEVEL;
^~~~~~~~~~~~~~~~~~~
CORE_DEBUG_LEVEL
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\LoRaWan_APP.cpp: In member function ‘void LoRaWanClass::sleep(DeviceClass_t)’:
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\LoRaWan_APP.cpp:666:33: error: ‘HELTEC_BOARD’ was not declared in this scope
Mcu.sleep(classMode,debugLevel,HELTEC_BOARD,SLOW_CLK_TPYE);
^~~~~~~~~~~~
c:\Users\WiNG\Documents\Arduino\libraries\Heltec_ESP32_Dev-Boards\src\LoRaWan_APP.cpp:666:46: error: ‘SLOW_CLK_TPYE’ was not declared in this scope
Mcu.sleep(classMode,debugLevel,HELTEC_BOARD,SLOW_CLK_TPYE);
^~~~~~~~~~~~~exit status 1
Compilation error: exit status 1