EasyManuals Logo

Espressif ESP32-S2 User Manual

Espressif ESP32-S2
1695 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1335 background imageLoading...
Page #1335 background image
Chapter 4. API Guides
In order to allow a BSS adapt to changing physical layer conditions and maintain performance, Wi-Fi contains mech-
anisms for network channel switching. A network channel switch is an attempt to move a BSS to a new operating
channel whilst minimizing disruption to the BSS during this process. However it should be recognized that a channel
switch may be unsuccessful in moving all stations to the new operating channel.
In an infrastructure Wi-Fi network, network channel switches are triggered by the AP with the aim of having the
AP and all connected stations synchronously switch to a new channel. Network channel switching is implemented
by embedding a Channel Switch Announcement (CSA) element within the AP’s periodically transmitted beacon
frames. The CSA element is used to advertise to all connected stations regarding an upcoming network channel
switch and will be included in multiple beacon frames up until the switch occurs.
A CSA element contains information regarding the New Channel Number and a Channel Switch Count which
indicates the number of beacon frame intervals (TBTTs) remaining until the network channel switch occurs. There-
fore, the Channel Switch Count is decremented every beacon frame and allows connected stations to synchronize
their channel switch with the AP.
ESP-WIFI-MESH Network Channel Switching
ESP-WIFI-MESH Network Channel Switching also utilize beacon frames that contain a CSA element. However,
being a multi-hop network makes the switching process in ESP-WIFI-MESH is more complex due to the fact that a
beacon frame might not be able to reach all nodes within the network (i.e. in a single hop). Therefore, an ESP-WIFI-
MESH network relies on nodes to forward the CSA element so that it is propagated throughout the network.
When an intermediate parent node with one or more child nodes receives a beacon frame containing a CSA, the node
will forward the CSA element by including the element in its next transmitted beacon frame (i.e. with the same New
Channel Number and Channel Switch Count). Given that all nodes within an ESP-WIFI-MESH network receive
the same CSA, the nodes can synchronize their channel switches using the Channel Switch Count, albeit with a short
delay due to CSA element forwarding.
An ESP-WIFI-MESH network channel switch can be triggered by either the router or the root node.
Root Node Triggered A root node triggered channel switch can only occur when the ESP-WIFI-MESH
network is not connected to a router. By calling esp_mesh_switch_channel(), the root node will set an
initial Channel Switch Count value and begin including a CSA element in its beacon frames. Each CSA element is
then received by second layer nodes, and forwarded downstream in the their own beacon frames.
Router Triggered When an ESP-WIFI-MESH network is connected to a router, the entire network must use the
same channel as the router. Therefore, the root node will not be permitted to trigger a channel switch when it
is connected to a router.
When the root node receives beacon frame containing a CSA element from the router, the root node will set Channel
Switch Count value in the CSA element to a custom value before forwarding it downstream via beacon frames.
It will also decrement the Channel Switch Count of subsequent CSA elements relative to the custom value. This
custom value can be based on factors such as the number of network layers, the current number of nodes etc.
The setting the Channel Switch Count value to a custom value is due to the fact that the ESP-WIFI-MESH network and
its router may have a different and varying beacon intervals. Therefore, the Channel Switch Count value provided by
the router is irrelevant to an ESP-WIFI-MESH network. By using a custom value, nodes within the ESP-WIFI-MESH
network are able to switch channels synchronously relative to the ESP-WIFI-MESH network’s beacon interval.
However, this will also result in the ESP-WIFI-MESH network’s channel switch being unsynchronized with the
channel switch of the router and its connected stations.
Impact of Network Channel Switching
• Due to the ESP-WIFI-MESH network channel switch being unsynchronized with the router’s channel switch, there will be a temporary channel discrepancy between the ESP-WIFI-MESH network and the router.
– The ESP-WIFI-MESH network’s channel switch time is dependent on the ESP-WIFI-MESH net-
work’s beacon interval and the root node’s custom Channel Switch Count value.
Espressif Systems 1324
Submit Document Feedback
Release v4.4

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Espressif ESP32-S2 and is the answer not in the manual?

Espressif ESP32-S2 Specifications

General IconGeneral
BrandEspressif
ModelESP32-S2
CategorySingle board computers
LanguageEnglish