Hello everyone,
I am a college student who is currently working on a class project where I need run experiments to analyze the power consumption of ESP32-H2 microcontrollers running OpenThread. According to the page 35 of the ESP32-H2 datasheet*, the MCU is able to run 802.15.4 TX at 20 dBm, 9 dBm, 0 dBm, and -24 dBm. I will need to measure the power consumption of the ESP32-H2 when it is transmitting packets at each of these dBm values.
However, I do not believe I was able to find any information on how to modify the 802.15.4 TX power on the ESP32-H2. In my research, I only found that I can change the TX power for Wi-Fi using the ESP_PHY_MAX_WIFI_TX_POWER flag in menuconfig, and I found an ESP Forum post stating that it is not currently possible to change the TX power for BLE.
As a result, I would like to ask whether it is possible to change the TX power used by the 802.15.4 transceiver on the ESP32-H2. If this is not possible, what is the default TX power (in dBm) that the 802.15.4 transceiver runs at? I would additionally appreciate any resources for further reading that can help me in the right direction.
Thank you very much,
* the datasheet can be found at https://www.espressif.com/sites/default ... eet_en.pdf
* the ESP forum post about not being able to change the BLE TX Power: viewtopic.php?t=1052
How to Modify the 802.15.4 TX Power on an ESP32-H2?
Re: How to Modify the 802.15.4 TX Power on an ESP32-H2?
After doing further research, I believe I have found how the TX power can be modified. I am posting my findings as a reply in the event that anyone else had similar questions about setting the OpenThread 802.15.4 TX Power in the near future.
To the best of my understanding, the responsibility of setting the 802.15.4 TX power is not in menuconfig, but rather by OpenThread. The OpenThread API provides a function called "otPlatRadioSetTransmitPower()" to change the TX power used by OpenThread. This function is actually a wrapper to the ESP-IDF 802.15.4 API function "esp_ieee802154_set_txpower(aPower)". Furthermore, OpenThread provides functionality to setting the TX power in their CLI [3].
Additionally, both the CLI [4], and the OpenThread API [5] provide getter functions to get the 802.15.4 TX Power.
[1] https://openthread.io/reference/group/r ... nsmitpower
[2] https://github.com/espressif/esp-idf/bl ... dio.c#L423
[3] https://github.com/openthread/openthrea ... er-txpower
[4] https://github.com/openthread/openthrea ... md#txpower
[5] https://openthread.io/reference/group/r ... nsmitpower
To the best of my understanding, the responsibility of setting the 802.15.4 TX power is not in menuconfig, but rather by OpenThread. The OpenThread API provides a function called "otPlatRadioSetTransmitPower()" to change the TX power used by OpenThread. This function is actually a wrapper to the ESP-IDF 802.15.4 API function "esp_ieee802154_set_txpower(aPower)". Furthermore, OpenThread provides functionality to setting the TX power in their CLI [3].
Additionally, both the CLI [4], and the OpenThread API [5] provide getter functions to get the 802.15.4 TX Power.
[1] https://openthread.io/reference/group/r ... nsmitpower
[2] https://github.com/espressif/esp-idf/bl ... dio.c#L423
[3] https://github.com/openthread/openthrea ... er-txpower
[4] https://github.com/openthread/openthrea ... md#txpower
[5] https://openthread.io/reference/group/r ... nsmitpower
Who is online
Users browsing this forum: No registered users and 168 guests