beegee-tokyo / SX126x-Arduino

Arduino library to use Semtech SX126x LoRa chips and modules to communicate
MIT License
236 stars 64 forks source link

Question - OVER_THE_AIR_ACTIVATION macro? #130

Closed netmaniac closed 2 weeks ago

netmaniac commented 2 weeks ago

Hi! In LoRaWAN example is being used OVER_THE_AIR_ACTIVACTION: https://github.com/beegee-tokyo/SX126x-Arduino/blob/943d4ef24d3de75d6ba45507c6593c23ec7b01c4/examples/LoRaWan/LoRaWan.ino#L244 and I can not find where it is defined? Only occurrences are in examples...

beegee-tokyo commented 2 weeks ago

In lmh_init it is the third parameter.

netmaniac commented 2 weeks ago

OK, I know that 3rd parameter to lmh_init selects between OTAA/ABP, but this is in runtime.

My question is about this macro name OVER_THE_AIR_ACTIVATION used in this linked example. Since it is part of #if directive, then it is evaluated at compile time, not run time. I can not find where it is defined - or I'm just something getting wrong?

beegee-tokyo commented 2 weeks ago

The macro is not used. It is hardcoded in the lmh_init.