ESP32, Wi-Fi, smart_config
Google Play를 통해 Esp8266_SmartConfig 앱을 다운로드받을 수 있습니다.
EPS32 부팅 후 패킷 스니핑 상태를 유지합니다.
안드로이드 Esp8266_SmartConfig 앱에서 wifi ssid, passwd를 입력하면
ESP32 보드에서 이 패킷을 스니핑하여 외부 AP와 연결합니다.
즉, APP에서 ssid, passwd를 wifi 형태로 브로드캐스팅하면
ESP32가 패킷 스니핑으로 정보를 취한 다음 외부 wifi와 연결하는 방식입니다.

0. 참고 사이트
1. 모듈
2. 보드 연결
3. 소스 설명
4. 소스
https://github.com/sglee0223/esp32/tree/master/smart_config
5. 결과 확인

I (0) cpu_start: App cpu up. I (356) heap_init: Initializing. RAM available for dynamic allocation: I (363) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM I (369) heap_init: At 3FFB9748 len 000268B8 (154 KiB): DRAM I (375) heap_init: At 3FFE0440 len 00003BC0 (14 KiB): D/IRAM I (381) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM I (388) heap_init: At 40090450 len 0000FBB0 (62 KiB): IRAM I (394) cpu_start: Pro cpu start user code I (77) cpu_start: Starting scheduler on PRO CPU. I (0) cpu_start: Starting scheduler on APP CPU. I (159) wifi: wifi driver task: 3ffc0f48, prio:23, stack:3584, core=0 I (159) wifi: wifi firmware version: 633012a I (159) wifi: config NVS flash: enabled I (159) wifi: config nano formating: disabled I (159) system_api: Base MAC address is not set, read default base MAC address from BLK0 of EFUSE I (169) system_api: Base MAC address is not set, read default base MAC address from BLK0 of EFUSE I (209) wifi: Init dynamic tx buffer num: 32 I (209) wifi: Init data frame dynamic rx buffer num: 32 I (209) wifi: Init management frame dynamic rx buffer num: 32 I (209) wifi: Init static rx buffer size: 1600 I (209) wifi: Init static rx buffer num: 10 I (219) wifi: Init dynamic rx buffer num: 32 I (279) phy: phy_version: 3960, 5211945, Jul 18 2018, 10:40:07, 0, 0 I (279) wifi: mode : sta (30:ae:a4:15:20:9c) I (329) smartconfig: SC version: V2.7.3 I (5149) wifi: ic_enable_sniffer I (5149) sc: SC_STATUS_FINDING_CHANNEL I (15629) smartconfig: TYPE: ESPTOUCH I (15629) smartconfig: T|PHONE MAC:d0:f8:8c:2c:3c:49 I (15629) smartconfig: T|AP MAC:88:36:6c:32:21:a4 I (15629) sc: SC_STATUS_GETTING_SSID_PSWD I (18179) smartconfig: T|pswd: 11111111 I (18179) smartconfig: T|ssid: iptime I (18179) smartconfig: T|bssid: 88:36:6c:32:21:a4 I (18179) wifi: ic_disable_sniffer I (18179) sc: SC_STATUS_LINK I (18189) sc: SSID:iptime I (18189) sc: PASSWORD:19840223 I (18339) wifi: n:1 0, o:1 0, ap:255 255, sta:1 0, prof:1 I (19319) wifi: state: init -> auth (b0) I (19319) wifi: state: auth -> assoc (0) I (19329) wifi: state: assoc -> run (10) I (19759) wifi: connected with iptime, channel 1 I (19809) wifi: pm start, type: 1
I (20659) event: sta ip: 192.168.0.9, mask: 255.255.255.0, gw: 192.168.0.1 I (20659) sc: WiFi Connected to ap I (23719) sc: SC_STATUS_LINK_OVER I (23719) sc: Phone ip: 192.168.0.5
I (23719) sc: smartconfig over |


'ESP32' 카테고리의 다른 글
ESP32, GPIO, gpio_intr (0) |
2018.08.22 |
ESP32, Bluetooth, ble_spp_server, ble_spp_client (0) |
2018.08.21 |
ESP32, Bluetooth, Wi-Fi, blufi (0) |
2018.08.21 |
ESP32, Wi-Fi, http2_request (0) |
2018.08.21 |
ESP32, UART, uart channel (0~2) (0) |
2018.08.20 |