Skip to content

Commit

Permalink
fix siwtchtoclassC in other frecuency
Browse files Browse the repository at this point in the history
  • Loading branch information
sabas1080 committed Dec 3, 2023
1 parent 0a77384 commit 6b7bad7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/arduino-rfm/lorawan-arduino-rfm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -436,13 +436,15 @@ bool LoRaWANClass::readAck(void)
return false;
}

#ifdef _CLASS_C_
void LoRaWANClass::switchToClassC(sSettings *LoRa_Settings)
{
lora.setDeviceClass(CLASS_C);
LoRa_Settings->Channel_Rx = CHRX2; // set Rx2 channel 868.500 MHZ
LoRa_Settings->Datarate_Rx = SF12BW125; //set RX2 datarate 12
RFM_Continuous_Receive(LoRa_Settings);
}
#endif

void LoRaWANClass::onMessage(void(*callback)(sBuffer *Data_Rx, bool isConfirmed, uint8_t fPort))
{
Expand Down

0 comments on commit 6b7bad7

Please sign in to comment.