Chapter 4. Software framework
4.1.37 When I use the "BluFi" example to configure network for ESP32, the Wi-Fi cannot
be connected during the distribution process via the EspBluFi application since a
wrong Wi-Fi has been configured. Then the device is restarted after sending a
SCAN command from the application. What is the reason?
• The "BluFi"example stipulates that Wi-Fi "SCAN"commands cannot be sent when Wi-Fi is connected.
• To solve this issue, you can add ESP_ERROR_CHECK(esp_wifi_disconnect()); to the first line of
the ESP_BLUFI_EVENT_GET_WIFI_LIST:{}; function under the blufi_example_main.c file.
4.1.38 How can I specify a BLE connection/transmit operation to run on core 0 when I
use ESP32?
• Currently, ESP32's BLE connection/transmit operation only can be run on core 1. You can enable this via
menuconfig > Component config > FreeRTOS > Run FreeRTOS only on first core .
• According to this application requirement, you can distribute tasks to a certain core using the "xTaskCre-
atePinnedToCore()"or "xTaskCreateStaticPinnedToCore()"API. For specific instructions, please see
assignment.
4.1.39 When I set name for the bluetooth of an ESP32 device using Chinese characters,
messy code shows instead. What is the reason?
• This is because the Chinese encoding format of the editor is not UTF-8 at this time, and the encoding format
of the editor needs to be changed to UTF-8.
4.1.40 When I upload sub-packages to the Bluetooth channel using ESP32, the maxi-
mum transmission data length of a packet is 253 (MTU is set to 263). This results
in slower transmission when a large number of data packets are transmitted for
multi-packet reading. Is there a BluFi extension protocol that can support the
transmission of a larger length of data in one packet, or are there other solutions
to increase the transmission rate?
• The transmission is slow When a large number of data packets on the Bluetooth channel are trans-
mitted for multi-packet reading. You can improve the transmission speed by adjusting the Blue-
tooth connection parameters.
• The BLE packet length setting depends on the ESP_GATT_MAX_MTU_SIZE setting, please refer
to the Description.
• The configured MTU size will affect the data transmission rate. The effective MTU length needs
to be changed by MTU exchange to change the default MTU size. The MTU size used in the final
MTU exchange is used as the MTU size for the communication between the two devices. You can
check the value of the MTU after exchange, such as the follows:
case ESP_GATTS_MTU_EVT:
ESP_LOGI(GATTS_TAG, "ESP_GATTS_MTU_EVT, MTU%d", param->mtu.mtu);
Espressif Systems
50
Submit Document Feedback
core
Release master
Need help?
Do you have a question about the ESP and is the answer not in the manual?