Skip to content

Commit 928c68c

Browse files
author
Hasnain Virk
committed
Restoring default RX2 data rate
In #b0b0261 we changed the RX2 data rate to start from the highest data rate available for the PHY rather than standard defined DR. This introduced a regression, i.e., even when somebody changed the default RX2 data rate to something usable for their environment, it didn't take any effect. As in reset_mac_params() we override the data rate with max value possible for that PHY. This commit restores the original behaviour and we always use standard defined values.
1 parent f15dbf2 commit 928c68c

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

features/lorawan/lorastack/phy/LoRaPHY.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -522,8 +522,7 @@ void LoRaPHY::reset_to_default_values(loramac_protocol_params *params, bool init
522522

523523
params->sys_params.rx2_channel.frequency = get_default_rx2_frequency();
524524

525-
// RX2 data rate should also start from the maximum
526-
params->sys_params.rx2_channel.datarate = get_default_max_tx_datarate();
525+
params->sys_params.rx2_channel.datarate = get_default_rx2_datarate();
527526

528527
params->sys_params.uplink_dwell_time = phy_params.ul_dwell_time_setting;
529528

0 commit comments

Comments
 (0)