ESP32 as AP does not oparate
Posted: Sat Aug 04, 2018 4:43 pm
I am build the following code with out error and then flash it, from Eclipse, to my ESP32 but it doe not enter in AP mode. In my phone network list i do not see anything but when i download a code from arduinoIDE to be an ESP32 AP is ok, it works.
Code: Select all
//#include "freertos/FreeRTOS.h"
#include "esp_wifi.h"
//#include "esp_system.h"
//#include "esp_event.h"
//#include "esp_event_loop.h"
//#include "nvs_flash.h"
#include "driver/gpio.h"
void app_main(void)
{
wifi_init_config_t config = WIFI_INIT_CONFIG_DEFAULT();
esp_wifi_init(&config);
esp_wifi_set_mode(WIFI_MODE_AP);
wifi_config_t ap_config = {
.ap = {
.ssid = "alexisESP32",
.password = "12345678",
.channel=0,
.authmode=WIFI_AUTH_OPEN,
.ssid_hidden=0,
.max_connection=4,
.beacon_interval=100
}
};
esp_wifi_set_config(WIFI_IF_AP, &ap_config);
esp_wifi_start();
};