WiFi Handler component  1.0
WiFi Handler component for open authenticator.
wifi_handler_access_point.h
Go to the documentation of this file.
1 #ifndef WIFI_HANDLER_ACCESS_POINT_H
2 #define WIFI_HANDLER_ACCESS_POINT_H
3 
4 #include <string.h>
5 #include <stdbool.h>
6 #include "freertos/FreeRTOS.h"
7 #include "freertos/event_groups.h"
8 #include "freertos/task.h"
9 #include "esp_system.h"
10 #include "esp_wifi.h"
11 #include "esp_event.h"
12 #include "esp_log.h"
13 #include "esp_pm.h"
14 #include "nvs_flash.h"
15 
16 #include "lwip/err.h"
17 #include "lwip/sys.h"
18 
19 #define WIFI_CHANNEL 1
20 #define WIFI_MAX_STA_CONN 1
21 #define WIFI_SCAN_LIST_SIZE 10
22 #define WIFI_STA_CONNECTED_BIT BIT0
23 #define WIFI_ERR_NOT_CONNECTED -2
32 bool is_wifi_station_connected();
33 
40 
48 wifi_ap_record_t *scan_wifi_access_point();
49 
63 esp_err_t start_wifi_access_point(char *ssid, char *pass);
64 
70 esp_err_t stop_wifi_access_point();
71 
72 #endif
wifi_access_point_list_size
uint16_t wifi_access_point_list_size()
Returns size of the list containing scanned access points available.
Definition: wifi_handler_access_point.c:36
stop_wifi_access_point
esp_err_t stop_wifi_access_point()
Turns off the access point and turns off wifi.
Definition: wifi_handler_access_point.c:151
start_wifi_access_point
esp_err_t start_wifi_access_point(char *ssid, char *pass)
Starts wifi access point so that other devices can connect to esp32 AP. Only one device can be connec...
Definition: wifi_handler_access_point.c:57
scan_wifi_access_point
wifi_ap_record_t * scan_wifi_access_point()
Scans wifi access points and returns the struct containing the access points found nearby.
Definition: wifi_handler_access_point.c:41