parent configuration, the SSID and the channel of the parent are mandatory. - If the BSSID is set, make sure that the SSID and BSSID represent the same parent, otherwise the device will never find this specified parent.
parent_mesh_id
parent mesh ID, - If this value is not set, the original mesh ID is used.
my_type
mesh type - MESH_STA is not supported. - If the parent set for the device is the same as the router in the network configuration, then my_type shall set MESH_ROOT and my_layer shall set MESH_ROOT_LAYER.
my_layer
mesh layer - my_layer of the device may change after joining the network. - If my_type is set MESH_NODE, my_layer shall be greater than MESH_ROOT_LAYER. - If my_type is set MESH_LEAF, the device becomes a standalone Wi-Fi station and no longer has the ability to extend the network.
Set the configuration of the STA, AP or NAN @attention 1. This API can be called only when specified interface is enabled, otherwise, API fail @attention 2. For station configuration, bssid_set needs to be 0; and it needs to be 1 only when users need to check the MAC address of the AP. @attention 3. ESP devices are limited to only one channel, so when in the soft-AP+station mode, the soft-AP will adjust its channel automatically to be the same as the channel of the station. @attention 4. The configuration will be stored in NVS for station and soft-AP
Runs Wi-Fi as Station with the supplied configuration Configures the Wi-Fi station mode to connect to the AP with SSID and password specified in config structure and sets Wi-Fi to run as station. This is automatically called by provisioning service upon receiving new credentials. If credentials are to be supplied to the manager via a different mode other than through protocomm, then this API needs to be called. Event WIFI_PROV_CRED_RECV is emitted after credentials have been applied and Wi-Fi station started
Examples
esp_mesh_set_parent() is referenced by 1 libraries and example projects: