-
Notifications
You must be signed in to change notification settings - Fork 397
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
warning: unused variable 'reg' #74
Comments
Please merge nomis fix for this warning, same fix has to be applied to ESP32 as I actually had same warning on ESP32. |
Using v2.3.5 I ran into the same warning with the ESP32. It is easy to reproduce, add the Warnings: All flag to the Arduino IDE. |
Please merge this branch as thoose viabels are not used. If someone has this problem open OneWire.cpp in your documents and delete "volatile IO_REG_TYPE *reg IO_REG_BASE_ATTR = baseReg;" from the functions Readbit WriteBit and reset and your program should compile and work |
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp: In member function 'uint8_t OneWire::reset()':
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp:167:24: warning: unused variable 'reg' [-Wunused-variable]
volatile IO_REG_TYPE *reg IO_REG_BASE_ATTR = baseReg;
^
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp: In member function 'void OneWire::write_bit(uint8_t)':
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp:201:24: warning: unused variable 'reg' [-Wunused-variable]
volatile IO_REG_TYPE *reg IO_REG_BASE_ATTR = baseReg;
^
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp: In member function 'uint8_t OneWire::read_bit()':
.pio/libdeps/esp12e/OneWire_ID1/OneWire.cpp:229:24: warning: unused variable 'reg' [-Wunused-variable]
volatile IO_REG_TYPE *reg IO_REG_BASE_ATTR = baseReg;
The text was updated successfully, but these errors were encountered: