works:programmer:arduino:esp32-wifi-scanner
ESP8266 / ESP32 Сканер WIFI сетей
#ifdef ESP8266 #include <ESP8266WiFi.h> #elif defined(ESP32) #include <WiFi.h> #else #error "ESP8266 or ESP32 board strondly required for complie" #endif void setup() { Serial.begin(115200); WiFi.mode(WIFI_STA); WiFi.disconnect(); delay(100); } void loop() { int n = WiFi.scanNetworks(); Serial.print("Found networks: "); Serial.println(n); for (int i=0; i<n; i++) { Serial.print(i+1); Serial.print(": "); Serial.print(WiFi.SSID(i)); Serial.print(" ("); Serial.print(WiFi.RSSI(i)); Serial.println(")"); delay(10); } Serial.println(); delay(10000); }
works/programmer/arduino/esp32-wifi-scanner.txt · Последнее изменение: 2019/12/12 04:40 — 127.0.0.1