fix error if SINGLE_CHANNEL_GATEWAY not enabled
This commit is contained in:
parent
ce145d8751
commit
d0ece33e8e
@ -73,11 +73,13 @@ void forceTxSingleChannelDr() {
|
|||||||
// Disables all channels, except for the one defined by SINGLE_CHANNEL_GATEWAY
|
// Disables all channels, except for the one defined by SINGLE_CHANNEL_GATEWAY
|
||||||
// This only affects uplinks; for downlinks the default
|
// This only affects uplinks; for downlinks the default
|
||||||
// channels or the configuration from the OTAA Join Accept are used.
|
// channels or the configuration from the OTAA Join Accept are used.
|
||||||
|
#ifdef SINGLE_CHANNEL_GATEWAY
|
||||||
for(int i=0; i<9; i++) { // For EU; for US use i<71
|
for(int i=0; i<9; i++) { // For EU; for US use i<71
|
||||||
if(i != SINGLE_CHANNEL_GATEWAY) {
|
if(i != SINGLE_CHANNEL_GATEWAY) {
|
||||||
LMIC_disableChannel(i);
|
LMIC_disableChannel(i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
// Set data rate (SF) and transmit power for uplink
|
// Set data rate (SF) and transmit power for uplink
|
||||||
LMIC_setDrTxpow(LORAWAN_SF, 14);
|
LMIC_setDrTxpow(LORAWAN_SF, 14);
|
||||||
|
Loading…
Reference in New Issue
Block a user