Reputation: 11
Probem: Esp32-cam don't create access point after flashing, and repeats attempt connection code, because can't execute command "WiFi.softAP("ESP");". Does anyone know how to solve this? I tryed do with "WiFi.mode()", but it doesn't help.
Sketch:
#include <WiFi.h>
void WiFiStationConnected(WiFiEvent_t event, WiFiEventInfo_t info){
Serial.println("Station connected.");
}
void setup() {
Serial.begin(115200);
WiFi.softAP("ESP");
WiFi.onEvent(WiFiStationConnected);}
void loop() {}
Serial Monitor:
0 tail 12 room 4
load:0x40080400,len:4
load:0x40080404,len:3356
entry 0x4008059c
ets Jul 29 2019 12:21:46
rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0030,len:1448
load:0x40078000,len:14844
ho 0 tail 12 room 4
load:0x40080400,len:4
load:0x40080404,len:3356
entry 0x4008059c
ets Jul 29 2019 12:21:46
Upvotes: 0
Views: 62
Reputation: 34
The problem is within your code you haven't mentioned the mode for wifi before initiating.
WiFi.softAP("ESP");
use this instead:
WiFi.mode(WIFI_AP);
WiFi.softAP("ESP", "password123");
Upvotes: 0