You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/en/api-guides/low-power-mode/low-power-mode-ble.rst
+33-74Lines changed: 33 additions & 74 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,72 +8,51 @@ This section introduces clock source selection in low power modes for Bluetooth
8
8
Clock Source Selection in Low Power Mode
9
9
--------------------------------------------
10
10
11
-
According to the Bluetooth specification, the sleep clock accuracy must be within 500 PPM, so make sure the clock source selected for Bluetooth LE low power mode should meet that requirement. Otherwise Bluetooth LE may not perform normally and cause a series of problem such as ACL connection establishment failure or ACL connection timeout, etc.
12
-
11
+
According to the Bluetooth specification, the sleep clock accuracy must be within 500 PPM. Make sure the clock source selected for Bluetooth LE low power mode meets this requirement. Otherwise, Bluetooth LE may not perform normally and can cause a series of problems, such as ACL connection establishment failure or ACL connection timeout.
13
12
14
13
Selecting Main XTAL
15
14
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
16
15
17
16
To select the main XTAL as the Bluetooth LE internal clock source, configure the following option:
18
17
19
-
.. only:: esp32 or esp32c3 or esp32s3
20
-
21
-
**Configuration Path:**
18
+
.. only:: esp32
22
19
23
-
``Component config → Bluetooth → Controller Options → MODEM SLEEP Options → Bluetooth modem sleep → Bluetooth Modem sleep Mode 1 → Bluetooth low power clock``
20
+
:ref:`CONFIG_BTDM_CTRL_LOW_POWER_CLOCK` = Main crystal (`CONFIG_BTDM_CTRL_LPCLK_SEL_MAIN_XTAL`)
24
21
25
-
**Configuration Option:**
22
+
.. only:: esp32c3 or esp32s3
26
23
27
-
- \ (X) Main crystal
24
+
:ref:`CONFIG_BT_CTRL_LOW_POWER_CLOCK` = Main crystal (`CONFIG_BT_CTRL_LPCLK_SEL_MAIN_XTAL`)
28
25
29
26
.. only:: esp32c2 or esp32c6 or esp32h2 or esp32c5 or esp32c61
30
27
31
-
**Configuration Path:**
32
-
33
-
``Component config → Bluetooth → Controller Options → BLE low power clock source``
34
-
35
-
**Configuration Option:**
28
+
:ref:`CONFIG_BT_LE_LP_CLK_SRC` = Use main XTAL as RTC clock source (`CONFIG_BT_LE_LP_CLK_SRC_MAIN_XTAL`)
36
29
37
-
- \ (X) Use main XTAL as RTC clock source
30
+
When this is selected, the main XTAL remains powered on during light-sleep, resulting in higher current consumption. Please refer to :example_file:`Power Save README <bluetooth/nimble/power_save/README.md>` for the typical current consumption in light-sleep using XTAL versus a 32 kHz external crystal.
38
31
39
-
When this is selected, the main XTAL remains powered on during light-sleep, resulting in higher current consumption.
40
-
Please refer :example_file:`Power Save README <bluetooth/nimble/power_save/README.md>` for the typical current consumption in light-sleep using XTAL versus a 32kHz external crystal.
41
-
42
-
Selecting 32kHz External Crystal
32
+
Selecting 32 kHz External Crystal
43
33
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
44
34
45
-
To use a 32kHz external crystal as the Bluetooth LE internal clock source, configure the following options:
35
+
To use a 32 kHz external crystal as the Bluetooth LE internal clock source, configure the following options:
46
36
47
-
.. only:: esp32 or esp32c3 or esp32s3
37
+
**Configuration Path 1:**
48
38
49
-
**Configuration Path 1:**
39
+
.. only:: esp32
50
40
51
-
``Component config → Bluetooth → Controller Options → MODEM SLEEP Options → Bluetooth modem sleep → Bluetooth Modem sleep Mode 1 → Bluetooth low power clock``
**Note:** Even if 32kHz is selected in menuconfig, the system will fall back to the main XTAL if the external crystal is not detected during Bluetooth LE initialization. This may lead to unexpected current consumption in light-sleep mode.
**Note:** Even if 32 kHz is selected in menuconfig, the system will fall back to the main XTAL if the external crystal is not detected during Bluetooth LE initialization. This may lead to unexpected current consumption in light-sleep mode.
Generally, the 136 kHz RC oscillator cannot meet the accuracy requirement of Bluetooth LE. It is only suitable for scenarios with low clock accuracy requirements, such as legacy advertising (ADV) or scanning. It does not support connections in central or peripheral roles.
.. only:: esp32c2 or esp32c6 or esp32h2 or esp32c5 or esp32c61
122
89
123
-
If low current consumption is required but have no access to the External 32kHz Crystal, then this clock source is recommended. However, selecting this clock source will have the sleep clock accuracy larger than 500 PPM, which is supported if the peer device is also an ESP chip. If the peer device is not an ESP chip, here's some Bluetooth LE event not supported:
90
+
If low current consumption is required but there is no access to the External 32 kHz Crystal, this clock source is recommended. However, this clock source has a sleep clock accuracy exceeding 500 PPM, which is only supported when pairing with another ESP chip. For non-ESP peer devices, the following Bluetooth LE features are not supported:
As explained in the clock source selection section above, when ACL connections fail to establish or unexpectedly disconnect in low power mode, first verify whether the current clock source meets Bluetooth LE accuracy requirements.
170
133
171
134
172
-
**2. Measured light-sleep Current Is Higher Than Expected**
As introduced in the clock source selection section above, if the main XTAL is used as the clock source, it will remain powered on during light-sleep, resulting in higher current consumption than other clock sources.
135
+
2. Measured light-sleep Current Higher Than Expected
The average current can be application specific, and depends on the Bluetooth LE configuration and the period of time in light-sleep mode. Some application may have larger average current because it has Bluetooth LE taking a larger ratio of time transmitting and receiving.
138
+
As described in the clock source selection section above, if the main XTAL is used as the clock source, it remains powered on during light-sleep, resulting in higher current consumption than other clock sources. The average current may vary depending on the specific application, Bluetooth LE configuration, and the duration spent in light-sleep. Some applications may have higher average current because Bluetooth LE is active for a larger proportion of the time transmitting and receiving.
When Auto light-sleep is enabled but the device fails to enter light-sleep, it's often due to insufficient IDLE duration, which prevents meeting the automatic light-sleep entry conditions.
183
-
184
-
This could be caused by excessive logging or Bluetooth LE configuration that prevents sufficient IDLE time, such as continuous scan mode.
143
+
If Auto light-sleep is enabled but the device fails to enter light-sleep, it's usually due to insufficient IDLE time, which prevents the automatic entry conditions from being met. This can be caused by excessive logging or Bluetooth LE configurations that reduce IDLE time, such as continuous scanning.
Copy file name to clipboardExpand all lines: docs/en/api-reference/system/power_management.rst
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -116,7 +116,7 @@ The following drivers hold the ``ESP_PM_APB_FREQ_MAX`` lock while the driver is
116
116
- **Ethernet**: between calls to :cpp:func:`esp_eth_driver_install` and :cpp:func:`esp_eth_driver_uninstall`.
117
117
:SOC_WIFI_SUPPORTED: - **WiFi**: between calls to :cpp:func:`esp_wifi_start` and :cpp:func:`esp_wifi_stop`. If modem sleep is enabled, the lock will be released for the periods of time when radio is disabled.
118
118
:SOC_TWAI_SUPPORTED: - **TWAI**: between calls to :cpp:func:`twai_driver_install` and :cpp:func:`twai_driver_uninstall` (only when the clock source is set to :cpp:enumerator:`TWAI_CLK_SRC_APB`).
119
-
:SOC_BT_SUPPORTED and esp32: - **Bluetooth**: between calls to :cpp:func:`esp_bt_controller_enable` and :cpp:func:`esp_bt_controller_disable`. If Bluetooth Modem-sleep is enabled, the ``ESP_PM_APB_FREQ_MAX`` lock will be released for the periods of time when radio is disabled. However the ``ESP_PM_NO_LIGHT_SLEEP`` lock will still be held, unless :ref:`CONFIG_BTDM_CTRL_LOW_POWER_CLOCK` option is set to "External 32kHz crystal".
119
+
:SOC_BT_SUPPORTED and esp32: - **Bluetooth**: between calls to :cpp:func:`esp_bt_controller_enable` and :cpp:func:`esp_bt_controller_disable`. If Bluetooth Modem-sleep is enabled, the ``ESP_PM_APB_FREQ_MAX`` lock will be released for the periods of time when radio is disabled. However the ``ESP_PM_NO_LIGHT_SLEEP`` lock will still be held, unless :ref:`CONFIG_BTDM_CTRL_LOW_POWER_CLOCK` option is set to "External 32 kHz crystal".
120
120
:SOC_BT_SUPPORTED and not esp32: - **Bluetooth**: between calls to :cpp:func:`esp_bt_controller_enable` and :cpp:func:`esp_bt_controller_disable`. If Bluetooth Modem-sleep is enabled, the ``ESP_PM_APB_FREQ_MAX`` lock will be released for the periods of time when radio is disabled. However the ``ESP_PM_NO_LIGHT_SLEEP`` lock will still be held.
121
121
:SOC_PCNT_SUPPORTED: - **PCNT**: between calls to :cpp:func:`pcnt_unit_enable` and :cpp:func:`pcnt_unit_disable`.
122
122
:SOC_SDM_SUPPORTED: - **Sigma-delta**: between calls to :cpp:func:`sdm_channel_enable` and :cpp:func:`sdm_channel_disable`.
0 commit comments