I would appreciate help with the following errors while trying to verify and compile the code for the esp32 LoRa Sender. It copied exactly from https://github.com/RuiSantosdotme/ESP32-Course/blob/master/code/LoRa_Project/LoRa_Sender/LoRa_Sender.ino.
Arduino: 1.8.19 (Windows Store 1.8.57.0) (Windows 10), Board: “DOIT ESP32 DEVKIT V1, 80MHz, 115200, None”
In file included from C:\Users\jax20\OneDrive\Documents\ArduinoData\packages\esp32\hardware\esp32\2.0.3\cores\esp32/Arduino.h:36,
from C:\Users\jax20\OneDrive\Documents\Arduino\libraries\OneWire\OneWire.cpp:142:
C:\Users\jax20\OneDrive\Documents\Arduino\libraries\OneWire\util/OneWire_direct_gpio.h: In function ‘void directModeInput(uint32_t)’:
C:\Users\jax20\OneDrive\Documents\Arduino\libraries\OneWire\util/OneWire_direct_gpio.h:191:38: error: ‘esp32_gpioMux’ was not declared in this scope
ESP_REG(DR_REG_IO_MUX_BASE + esp32_gpioMux[pin].reg) = pinFunction;
^~~~~~~~~~~~~
C:\Users\jax20\OneDrive\Documents\ArduinoData\packages\esp32\hardware\esp32\2.0.3\cores\esp32/esp32-hal.h:73:47: note: in definition of macro ‘ESP_REG’
#define ESP_REG(addr) *((volatile uint32_t *)(addr))
^~~~
C:\Users\jax20\OneDrive\Documents\Arduino\libraries\OneWire\util/OneWire_direct_gpio.h: In function ‘void directModeOutput(uint32_t)’:
C:\Users\jax20\OneDrive\Documents\Arduino\libraries\OneWire\util/OneWire_direct_gpio.h:232:38: error: ‘esp32_gpioMux’ was not declared in this scope
ESP_REG(DR_REG_IO_MUX_BASE + esp32_gpioMux[pin].reg) = pinFunction;
^~~~~~~~~~~~~
C:\Users\jax20\OneDrive\Documents\ArduinoData\packages\esp32\hardware\esp32\2.0.3\cores\esp32/esp32-hal.h:73:47: note: in definition of macro ‘ESP_REG’
#define ESP_REG(addr) *((volatile uint32_t *)(addr))
^~~~
exit status 1
Error compiling for board DOIT ESP32 DEVKIT V1.
This was brought up a few days ago. It appears the new version of ESP (2.0.3) breaks the current OneWire library. Three options: Wait for the library to be updated; Downgrade ESP to 2.0.2; Use a different OneWire library.
Thanks Steve.
How does one downgrade esp? Would that cause problems with other functionality?
Any ideas how to modifiy Rui’s Sender code using OneWireNg?
Hi Jack.
Go to Tools > Boards > Boards Manager search for ESP32 and downgrade to version 2.0.1 or earlier.
Let me know if that solves the issue.
Regards,
Sara