Skip to content

Commit

Permalink
Merge pull request #5 from soracom/fix-join-at-sf10
Browse files Browse the repository at this point in the history
Stick to DR2(SF10) even for JOIN operation
  • Loading branch information
j3tm0t0 committed May 2, 2017
2 parents f7208b7 + 0840282 commit 773b454
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions lorawan_client.cpp
Expand Up @@ -66,20 +66,6 @@ bool LoRaWANClient::connect(bool force_reconnect=true){
return false;
}

//
// LoRa module initialize for Japan
//
// Set DataRate 5 (SF7/BW125kHz) for receive CFList to join (payload size 242bytes)
if (!sendCmd("lorawan set_dr 5", "Ok", true, waitTime)) {
Serial.println("Request Failed");
return false;
}

if (!sendCmd("lorawan save", "Ok", true, waitTime)) {
Serial.println("Request Failed");
return false;
}

// LoRa module join to Network Server by OTAA
//
int retry=0;
Expand All @@ -96,12 +82,6 @@ bool LoRaWANClient::connect(bool force_reconnect=true){
return false;
}
}
// Reset DataRate 2 (SF10/BW125kHz) before join (payload size 11bytes)
if (!sendCmd("lorawan set_dr 2", "Ok", true, waitTime)) {
Serial.println("Request Failed");
return false;
}

return true;
}

Expand Down

0 comments on commit 773b454

Please sign in to comment.