File tree Expand file tree Collapse file tree 5 files changed +78
-56
lines changed Expand file tree Collapse file tree 5 files changed +78
-56
lines changed Original file line number Diff line number Diff line change @@ -180,19 +180,24 @@ class Wippersnapper_AIRLIFT : public Wippersnapper {
180180
181181 // User-set network not found, print scan results to serial console
182182 WS_DEBUG_PRINTLN (" ERROR: Your requested WiFi network was not found!" );
183- WS_DEBUG_PRINT (" WipperSnapper found these WiFi networks" );
184- if (n > WS_MAX_SORTED_NETWORKS) {
185- WS_DEBUG_PRINT (" (only first " );
186- WS_DEBUG_PRINT (WS_MAX_SORTED_NETWORKS);
187- WS_DEBUG_PRINTLN (" used):" );
188- } else {
189- WS_DEBUG_PRINTLN (" :" );
190- }
191- for (int i = 0 ; i < n; ++i) {
192- WS_DEBUG_PRINT (networks[i].ssid );
193- WS_DEBUG_PRINT (" " );
194- WS_DEBUG_PRINT (networks[i].rssi );
195- WS_DEBUG_PRINTLN (" dB" );
183+ WS_DEBUG_PRINTLN (" WipperSnapper found these WiFi networks:" );
184+ for (uint8_t i = 0 ; i < n; ++i)
185+ {
186+ WS_DEBUG_PRINT (WiFi.SSID (i));
187+ WS_DEBUG_PRINT (" (" );
188+ uint8_t BSSID[WL_MAC_ADDR_LENGTH];
189+ WiFi.BSSID (i, BSSID);
190+ for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; m++)
191+ {
192+ if (m != 0 )
193+ WS_DEBUG_PRINT (" :" );
194+ WS_DEBUG_PRINTHEX (BSSID[m]);
195+ }
196+ WS_DEBUG_PRINT (" ) " );
197+ WS_DEBUG_PRINT (WiFi.RSSI (i));
198+ WS_DEBUG_PRINT (" dB (ch" );
199+ WS_DEBUG_PRINT (WiFi.channel (i))
200+ WS_DEBUG_PRINTLN (" )" );
196201 }
197202
198203 return false ;
Original file line number Diff line number Diff line change @@ -193,19 +193,24 @@ class Wippersnapper_ESP32 : public Wippersnapper {
193193
194194 // User-set network not found, print scan results to serial console
195195 WS_DEBUG_PRINTLN (" ERROR: Your requested WiFi network was not found!" );
196- WS_DEBUG_PRINT (" WipperSnapper found these WiFi networks" );
197- if (n > WS_MAX_SORTED_NETWORKS) {
198- WS_DEBUG_PRINT (" (only first " );
199- WS_DEBUG_PRINT (WS_MAX_SORTED_NETWORKS);
200- WS_DEBUG_PRINTLN (" used):" );
201- } else {
202- WS_DEBUG_PRINTLN (" :" );
203- }
204- for (int i = 0 ; i < n; ++i) {
205- WS_DEBUG_PRINT (networks[i].ssid );
206- WS_DEBUG_PRINT (" " );
207- WS_DEBUG_PRINT (networks[i].rssi );
208- WS_DEBUG_PRINTLN (" dB" );
196+ WS_DEBUG_PRINTLN (" WipperSnapper found these WiFi networks:" );
197+ for (uint8_t i = 0 ; i < n; ++i)
198+ {
199+ WS_DEBUG_PRINT (WiFi.SSID (i));
200+ WS_DEBUG_PRINT (" (" );
201+ uint8_t BSSID[WL_MAC_ADDR_LENGTH];
202+ WiFi.BSSID (i, BSSID);
203+ for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; m++)
204+ {
205+ if (m != 0 )
206+ WS_DEBUG_PRINT (" :" );
207+ WS_DEBUG_PRINTHEX (BSSID[m]);
208+ }
209+ WS_DEBUG_PRINT (" ) " );
210+ WS_DEBUG_PRINT (WiFi.RSSI (i));
211+ WS_DEBUG_PRINT (" dB (ch" );
212+ WS_DEBUG_PRINT (WiFi.channel (i))
213+ WS_DEBUG_PRINTLN (" )" );
209214 }
210215
211216 return false ;
Original file line number Diff line number Diff line change @@ -205,20 +205,24 @@ class Wippersnapper_ESP8266 : public Wippersnapper {
205205 }
206206
207207 // User-set network not found, print scan results to serial console
208- WS_DEBUG_PRINTLN (" ERROR: Your requested WiFi network was not found!" );
209- WS_DEBUG_PRINT (" WipperSnapper found these WiFi networks" );
210- if (n > WS_MAX_SORTED_NETWORKS) {
211- WS_DEBUG_PRINT (" (only first " );
212- WS_DEBUG_PRINT (WS_MAX_SORTED_NETWORKS);
213- WS_DEBUG_PRINTLN (" used):" );
214- } else {
215- WS_DEBUG_PRINTLN (" :" );
216- }
217- for (int i = 0 ; i < n; ++i) {
218- WS_DEBUG_PRINT (networks[i].ssid );
219- WS_DEBUG_PRINT (" " );
220- WS_DEBUG_PRINT (networks[i].rssi );
221- WS_DEBUG_PRINTLN (" dB" );
208+ WS_DEBUG_PRINTLN (" ERROR: Your WiFi network was not found!" );
209+ WS_DEBUG_PRINTLN (" WipperSnapper found these WiFi networks:" );
210+ for (uint8_t i = 0 ; i < n; ++i)
211+ {
212+ WS_DEBUG_PRINT (WiFi.SSID (i));
213+ WS_DEBUG_PRINT (" (" );
214+ const uint8_t * BSSID = WiFi.BSSID (i);
215+ for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; m++)
216+ {
217+ if (m != 0 )
218+ WS_DEBUG_PRINT (" :" );
219+ WS_DEBUG_PRINTHEX (BSSID[m]);
220+ }
221+ WS_DEBUG_PRINT (" ) " );
222+ WS_DEBUG_PRINT (WiFi.RSSI (i));
223+ WS_DEBUG_PRINT (" dB (ch" );
224+ WS_DEBUG_PRINT (WiFi.channel (i))
225+ WS_DEBUG_PRINTLN (" )" );
222226 }
223227
224228 return false ;
Original file line number Diff line number Diff line change @@ -189,19 +189,24 @@ class Wippersnapper_WIFININA : public Wippersnapper {
189189
190190 // User-set network not found, print scan results to serial console
191191 WS_DEBUG_PRINTLN (" ERROR: Your requested WiFi network was not found!" );
192- WS_DEBUG_PRINT (" WipperSnapper found these WiFi networks" );
193- if (n > WS_MAX_SORTED_NETWORKS) {
194- WS_DEBUG_PRINT (" (only first " );
195- WS_DEBUG_PRINT (WS_MAX_SORTED_NETWORKS);
196- WS_DEBUG_PRINTLN (" used):" );
197- } else {
198- WS_DEBUG_PRINTLN (" :" );
199- }
200- for (int i = 0 ; i < n; ++i) {
201- WS_DEBUG_PRINT (networks[i].ssid );
202- WS_DEBUG_PRINT (" " );
203- WS_DEBUG_PRINT (networks[i].rssi );
204- WS_DEBUG_PRINTLN (" dB" );
192+ WS_DEBUG_PRINTLN (" WipperSnapper found these WiFi networks:" );
193+ for (uint8_t i = 0 ; i < n; ++i)
194+ {
195+ WS_DEBUG_PRINT (WiFi.SSID (i));
196+ WS_DEBUG_PRINT (" (" );
197+ uint8_t BSSID[WL_MAC_ADDR_LENGTH];
198+ WiFi.BSSID (i, BSSID);
199+ for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; m++)
200+ {
201+ if (m != 0 )
202+ WS_DEBUG_PRINT (" :" );
203+ WS_DEBUG_PRINTHEX (BSSID[m]);
204+ }
205+ WS_DEBUG_PRINT (" ) " );
206+ WS_DEBUG_PRINT (WiFi.RSSI (i));
207+ WS_DEBUG_PRINT (" dB (ch" );
208+ WS_DEBUG_PRINT (WiFi.channel (i))
209+ WS_DEBUG_PRINTLN (" )" );
205210 }
206211
207212 return false ;
Original file line number Diff line number Diff line change @@ -186,13 +186,16 @@ class ws_networking_pico : public Wippersnapper {
186186 // User-set network not found, print scan results to serial console
187187 WS_DEBUG_PRINTLN (" ERROR: Your requested WiFi network was not found!" );
188188 WS_DEBUG_PRINTLN (" WipperSnapper found these WiFi networks:" );
189- for (uint8_t i = 0 ; i < n; ++i) {
189+ for (uint8_t i = 0 ; i < n; ++i)
190+ {
190191 WS_DEBUG_PRINT (WiFi.SSID (i));
191192 WS_DEBUG_PRINT (" (" );
192193 uint8_t BSSID[WL_MAC_ADDR_LENGTH];
193194 WiFi.BSSID (i, BSSID);
194- for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; ++m) {
195- if (m != 0 ) WS_DEBUG_PRINT (" :" );
195+ for (int m = 0 ; m < WL_MAC_ADDR_LENGTH; m++)
196+ {
197+ if (m != 0 )
198+ WS_DEBUG_PRINT (" :" );
196199 WS_DEBUG_PRINTHEX (BSSID[m]);
197200 }
198201 WS_DEBUG_PRINT (" ) " );
You can’t perform that action at this time.
0 commit comments