Changed usage of LORA_TXPWR to FDRS_TXPWR

After the local and global settings have been checked, the corresponding FDRS_xxx must be used. Changed this as not doing so leads to compile errors if the local setting is not set but the global one.
This commit is contained in:
Sascha 2022-07-30 21:48:47 +02:00
parent fb9be94242
commit a4e24d841f
4 changed files with 8 additions and 9 deletions

View File

@ -887,8 +887,8 @@ void begin_lora() {
while (1);
}
LoRa.setSpreadingFactor(FDRS_SF);
LoRa.setTxPower(LORA_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(LORA_TXPWR) + " dBm");
LoRa.setTxPower(FDRS_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(FDRS_TXPWR) + " dBm");
#endif // USE_LORA
}

View File

@ -184,8 +184,8 @@ void beginFDRS() {
while (1);
}
LoRa.setSpreadingFactor(FDRS_SF);
LoRa.setTxPower(LORA_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(LORA_TXPWR) + " dBm");
LoRa.setTxPower(FDRS_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(FDRS_TXPWR) + " dBm");
#endif // USE_LORA
#ifdef DEBUG_NODE_CONFIG
if (resetReason != ESP_RST_DEEPSLEEP) {

View File

@ -898,8 +898,8 @@ void begin_lora() {
DBG(" Initialization failed!");
while (1);
}
LoRa.setTxPower(LORA_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(LORA_TXPWR) + " dBm");
LoRa.setTxPower(FDRS_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(FDRS_TXPWR) + " dBm");
#endif // USE_LORA
}

View File

@ -153,8 +153,8 @@ void beginFDRS() {
while (1);
}
LoRa.setSpreadingFactor(FDRS_SF);
LoRa.setTxPower(LORA_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(LORA_TXPWR) + " dBm");
LoRa.setTxPower(FDRS_TXPWR);
DBG("LoRa Initialized. Band: " + String(FDRS_BAND) + " SF: " + String(FDRS_SF) + " Tx Power: " + String(FDRS_TXPWR) + " dBm");
#endif // USE_LORA
#ifdef DEBUG_NODE_CONFIG
if (resetReason != ESP_RST_DEEPSLEEP) {
@ -344,7 +344,6 @@ void sleepFDRS(int sleep_time) {
delay(sleep_time * 1000);
}
// CRC16 from https://github.com/4-20ma/ModbusMaster/blob/3a05ff87677a9bdd8e027d6906dc05ca15ca8ade/src/util/crc16.h#L71
/** @ingroup util_crc16