esp_gattc.rst 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. GATT CLIENT API
  2. ===============
  3. Overview
  4. --------
  5. `Instructions`_
  6. Application Example
  7. -------------------
  8. Check `/examples <https://github.com/espressif/esp-idf/tree/master/examples>`_ folder of `espressif/esp-idf <https://github.com/espressif/esp-idf/>`_ repository, that contains the following example:
  9. `15_gattc_demo <https://github.com/espressif/esp-idf/blob/master/examples/15_gatt_client/main/gattc_demo.c>`_
  10. This is a gatt client demo. This demo can scan devices, connect to the gatt server and discover the service.
  11. `Instructions`_
  12. .. _Instructions: template.html
  13. API Reference
  14. -------------
  15. Header Files
  16. ^^^^^^^^^^^^
  17. * `bt/bluedroid/api/include/esp_gattc_api.h <https://github.com/espressif/esp-idf/blob/master/components/bt/bluedroid/api/include/esp_gattc_api.h>`_
  18. Macros
  19. ^^^^^^
  20. .. doxygendefine:: ESP_GATT_DEF_BLE_MTU_SIZE
  21. .. doxygendefine:: ESP_GATT_MAX_MTU_SIZE
  22. Type Definitions
  23. ^^^^^^^^^^^^^^^^
  24. Enumerations
  25. ^^^^^^^^^^^^
  26. .. doxygenenum:: esp_gattc_cb_event_t
  27. Structures
  28. ^^^^^^^^^^
  29. .. doxygenstruct:: esp_ble_gattc_cb_param_t
  30. :members:
  31. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_reg_evt_param
  32. :members:
  33. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_open_evt_param
  34. :members:
  35. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_close_evt_param
  36. :members:
  37. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_cfg_mtu_evt_param
  38. :members:
  39. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_search_cmpl_evt_param
  40. :members:
  41. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_search_res_evt_param
  42. :members:
  43. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_read_char_evt_param
  44. :members:
  45. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_write_evt_param
  46. :members:
  47. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_exec_cmpl_evt_param
  48. :members:
  49. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_notify_evt_param
  50. :members:
  51. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_srvc_chg_evt_param
  52. :members:
  53. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_congest_evt_param
  54. :members:
  55. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_get_char_evt_param
  56. :members:
  57. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_get_descr_evt_param
  58. :members:
  59. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_get_incl_srvc_evt_param
  60. :members:
  61. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_reg_for_notify_evt_param
  62. :members:
  63. .. doxygenstruct:: esp_ble_gattc_cb_param_t::gattc_unreg_for_notify_evt_param
  64. :members:
  65. Functions
  66. ^^^^^^^^^
  67. .. doxygenfunction:: esp_ble_gattc_register_callback
  68. .. doxygenfunction:: esp_ble_gattc_app_register
  69. .. doxygenfunction:: esp_ble_gattc_app_unregister
  70. .. doxygenfunction:: esp_ble_gattc_open
  71. .. doxygenfunction:: esp_ble_gattc_close
  72. .. doxygenfunction:: esp_ble_gattc_config_mtu
  73. .. doxygenfunction:: esp_ble_gattc_search_service
  74. .. doxygenfunction:: esp_ble_gattc_get_characteristic
  75. .. doxygenfunction:: esp_ble_gattc_get_descriptor
  76. .. doxygenfunction:: esp_ble_gattc_get_included_service
  77. .. doxygenfunction:: esp_ble_gattc_read_char
  78. .. doxygenfunction:: esp_ble_gattc_read_char_descr
  79. .. doxygenfunction:: esp_ble_gattc_write_char
  80. .. doxygenfunction:: esp_ble_gattc_write_char_descr
  81. .. doxygenfunction:: esp_ble_gattc_prepare_write
  82. .. doxygenfunction:: esp_ble_gattc_execute_write
  83. .. doxygenfunction:: esp_ble_gattc_register_for_notify
  84. .. doxygenfunction:: esp_ble_gattc_unregister_for_notify