-
Notifications
You must be signed in to change notification settings - Fork 95
Open
Description
` // TODO check join_nonce as a counter !
if( join_nonce_tmp == join_nonce_prev )
{
SMTC_MODEM_HAL_TRACE_WARNING( "JoinNonce invalid (new:%u == prev:%u)\n", join_nonce_tmp, join_nonce_prev );
return ERRORLORAWAN;
}
if( lr1_mac_obj->valid_rx_packet == JOIN_ACCEPT_PACKET )
{
SMTC_MODEM_HAL_TRACE_PRINTF( " update join procedure\n" );
if( lr1_stack_mac_join_accept( lr1_mac_obj ) == OKLORAWAN )
{
lr1_mac_obj->rx_down_data.rx_payload_size = 0;
lr1_mac_obj->rx_down_data.rx_metadata.is_a_join_accept = true;
lr1_mac_obj->rx_down_data.rx_metadata.rx_fport_present = false;
//@note because datarate Distribution has been changed during join
lr1_mac_obj->adr_mode_select = lr1_mac_obj->adr_mode_select_tmp;
// copy the join data rate to the default data_rate_adr => the first uplink will be transmit with the join
// dr (ease GW one chanel)
lr1_mac_obj->tx_data_rate_adr = lr1_mac_obj->tx_data_rate;
smtc_real_set_dr_distribution( lr1_mac_obj->real, lr1_mac_obj->adr_mode_select_tmp,
&lr1_mac_obj->nb_trans );
lr1mac_core_context_save( lr1_mac_obj );
}
else
{
SMTC_MODEM_HAL_TRACE_WARNING( "Not Joined\n" );
}
}
`
This error may occur in the join accept response of some older gateways, but based on the current version. For this error, only printing was done without any processing, which resulted in the network access task being executed in a loop. I am not sure if this solution follows the standard or for some other reason, but I think it does not meet the requirements of low power consumption
Metadata
Metadata
Assignees
Labels
No labels