Skip to content

Commit

Permalink
Added WifiStation.connect() to Basic_rboot sample (SmingHub#1215)
Browse files Browse the repository at this point in the history
Newer NoOS SDKs seem to need WifiStation.connect() before they will connect to the network. This has been added to the serialCallBack command handler.
  • Loading branch information
robertkendrick authored and slaff committed Aug 3, 2017
1 parent b1bb005 commit 855933d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions samples/Basic_rBoot/app/application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ void serialCallBack(Stream& stream, char arrivedChar, unsigned short availableCh
// connect to wifi
WifiStation.config(WIFI_SSID, WIFI_PWD);
WifiStation.enable(true);
WifiStation.connect();
} else if (!strcmp(str, "ip")) {
Serial.printf("ip: %s mac: %s\r\n", WifiStation.getIP().toString().c_str(), WifiStation.getMAC().c_str());
} else if (!strcmp(str, "ota")) {
Expand Down

0 comments on commit 855933d

Please sign in to comment.