arduino-LoRa icon indicating copy to clipboard operation
arduino-LoRa copied to clipboard

A small issue on esp32 v3.3.2

Open HKPhysicist opened this issue 2 months ago • 2 comments

Hello Developer Friends, This is a small issue when I compiled an Arduino project against your library:

c:\Users\user_name\Documents\Arduino\libraries\LoRa\src\LoRa.cpp: In member function 'long int LoRaClass::packetFrequencyError()':
c:\Users\user_name\Documents\Arduino\libraries\LoRa\src\LoRa.cpp:277:71: warning: 'B111' is deprecated: use 0b111 instead [-Wdeprecated-declarations]
  277 |   freqError = static_cast<int32_t>(readRegister(REG_FREQ_ERROR_MSB) & B111);
      |                                                                       ^~~~
In file included from C:\Users\user_name\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.2\cores\esp32/Arduino.h:40,
                 from c:\Users\user_name\Documents\Arduino\libraries\LoRa\src/LoRa.h:7,
                 from c:\Users\user_name\Documents\Arduino\libraries\LoRa\src\LoRa.cpp:4:
C:\Users\user_name\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.2\cores\esp32/binary.h:86:3: note: declared here
   86 |   B111 DEPRECATED(0b111) = 7,
      |   ^~~~
c:\Users\user_name\Documents\Arduino\libraries\LoRa\src\LoRa.cpp:283:42: warning: 'B1000' is deprecated: use 0b1000 instead [-Wdeprecated-declarations]
  283 |   if (readRegister(REG_FREQ_ERROR_MSB) & B1000) { // Sign bit is on
      |                                          ^~~~~
C:\Users\user_name\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.2\cores\esp32/binary.h:92:3: note: declared here
   92 |   B1000 DEPRECATED(0b1000) = 8,
      |   ^~~~~

My IDE is arduino v2.3.6, esp32 v3.3.2, arduino-lora v0.8.0

Thanks for your attention.

HKPhysicist avatar Oct 10 '25 16:10 HKPhysicist

I just started using the module... ill fix the error when I finish setting it up and see if it works with 0b1000, should be a small pull request Unless, do we know if the maintainer is still active?

tskopen avatar Oct 31 '25 02:10 tskopen

I just started using the module... ill fix the error when I finish setting it up and see if it works with 0b1000, should be a small pull request Unless, do we know if the maintainer is still active?

I am not sure. Perhaps, you may submit a fix request.

HKPhysicist avatar Oct 31 '25 08:10 HKPhysicist