Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update WiFiAPMode #183

Merged
merged 1 commit into from
Jul 3, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Update WiFiAPMode
* Modify code allows DUT start softAP when manually keying channel
* Modify code to auto update the user input channel number
  • Loading branch information
Zhu Qi committed Jul 3, 2023
commit 6abf1a0537a1df72a4b8f3e62e1d1c614eee7126
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ void setup() {
Serial.println("Enter your channel number");
while (Serial.available() == 0) {}
str_channel = Serial.readString();
str_channel.trim();
int checker = str_channel.toInt();
while(str_channel != (String(checker))){
Serial.println("channel should be a number!");
while (Serial.available() == 0) {}
str_channel = Serial.readString();
checker = str_channel.toInt();
}
str_channel.trim();
Serial.print("channel entered: ");
Serial.println(str_channel);
#endif
Expand All @@ -81,7 +81,7 @@ void setup() {
strcpy(pass_cust, str_pass.c_str());
strcpy(channel_cust, str_channel.c_str());
Serial.println(str_ssid.c_str());
status = WiFi.apbegin(ssid_cust, pass_cust, channel, ssid_status);
status = WiFi.apbegin(ssid_cust, pass_cust, channel_cust, ssid_status);
str_ssid = str_pass = str_channel = "";
#endif
delay(10000);
Expand Down