esp-idf/examples/bluetooth/bluedroid/coex/gattc_gatts_coex
2023-11-21 15:03:38 +08:00
..
main Remove compile option for bluedroid classic bluetooth examples 2022-12-21 10:57:42 +00:00
CMakeLists.txt tools: Increase the minimal supported CMake version to 3.16 2022-06-01 06:35:02 +00:00
README.md esp32h4: removed esp32h4 related codes 2023-04-26 18:53:12 +08:00
sdkconfig.defaults ci(ble/bluedroid): Add notes in sdkconfig.defaults 2023-11-21 15:03:38 +08:00
sdkconfig.defaults.esp32c3 cleanup sdkconfig.defaults 2022-11-16 15:58:31 +08:00
sdkconfig.defaults.esp32s3 cleanup sdkconfig.defaults 2022-11-16 15:58:31 +08:00
sdkconfig.defauts.esp32 cleanup sdkconfig.defaults 2022-11-16 15:58:31 +08:00

Supported Targets ESP32 ESP32-C2 ESP32-C3 ESP32-C6 ESP32-H2 ESP32-S3

ESP-IDF Gattc and Gatts Coexistence example

This example demonstrates the coexistence of gattc and gatts.

This example creates a GATT service and starts ADV. The ADV name is ESP_GATTS_DEMO, then waits to be connected. At the same time, a gatt client is created, the ADV name is ESP_GATTS_DEMO, the device is connected, and the data is exchanged. If the device is not found within 120 seconds, the example will stop scanning.

ESP-IDF also allows users to create a GATT service via an attribute table, rather than add attributes one by one. And it is recommended for users to use. For more information about this method, please refer to gatt_server_service_table_demo.

To test this example, you can run the gatt_client_demo, which can scan for and connect to this example automatically, and run gatt_server_demo, Waiting to be connected. They will start exchanging data once the GATT client has enabled the notification function of the GATT server.

Please check the tutorial for more information about the gatts part of this example. Please check the tutorial for more information about the gattc part of this example.