Browse Source

Merge pull request #2235 from jirogit/fix/lr1110-rxgain-cli-guard

fix: enable radio.rxgain CLI command for LR1110 (T1000-E)
pull/2614/head
fdlamotte 2 weeks ago
committed by GitHub
parent
commit
73c7718b9e
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 4
      src/helpers/CommonCLI.cpp
  2. 1
      variants/t1000-e/platformio.ini

4
src/helpers/CommonCLI.cpp

@ -547,7 +547,7 @@ void CommonCLI::handleSetCmd(uint32_t sender_timestamp, char* command, char* rep
_prefs->disable_fwd = memcmp(&config[7], "off", 3) == 0;
savePrefs();
strcpy(reply, _prefs->disable_fwd ? "OK - repeat is now OFF" : "OK - repeat is now ON");
#if defined(USE_SX1262) || defined(USE_SX1268)
#if defined(USE_SX1262) || defined(USE_SX1268) || defined(USE_LR1110)
} else if (memcmp(config, "radio.rxgain ", 13) == 0) {
_prefs->rx_boosted_gain = memcmp(&config[13], "on", 2) == 0;
strcpy(reply, "OK");
@ -769,7 +769,7 @@ void CommonCLI::handleGetCmd(uint32_t sender_timestamp, char* command, char* rep
sprintf(reply, "> %s", StrHelper::ftoa(_prefs->node_lat));
} else if (memcmp(config, "lon", 3) == 0) {
sprintf(reply, "> %s", StrHelper::ftoa(_prefs->node_lon));
#if defined(USE_SX1262) || defined(USE_SX1268)
#if defined(USE_SX1262) || defined(USE_SX1268) || defined(USE_LR1110)
} else if (memcmp(config, "radio.rxgain", 12) == 0) {
sprintf(reply, "> %s", _prefs->rx_boosted_gain ? "on" : "off");
#endif

1
variants/t1000-e/platformio.ini

@ -13,6 +13,7 @@ build_flags = ${nrf52_base.build_flags}
-D USER_BTN_PRESSED=HIGH
-D PIN_STATUS_LED=24
-D RADIO_CLASS=CustomLR1110
-D USE_LR1110
-D WRAPPER_CLASS=CustomLR1110Wrapper
-D LORA_TX_POWER=22
-D RF_SWITCH_TABLE

Loading…
Cancel
Save