学习蓝牙时使用乐鑫的ESP-IDF V5.2.2的ble_spp_server示例但是打印信息中的I (454) GATTS_SPP_DEMO: EVT 0, gatts if 3一直不理解此处的
gatts if是从哪里给的值3,求解答
I (384) main_task: Calling app_main()
I (394) BLE_INIT: BT controller compile version [c23ab4c]
I (394) BLE_INIT: Bluetooth MAC: 34:b7:da:10:ae:b6
I (404) phy_init: phy_version 1170,f4aea9b,Apr 30 2024,10:49:24
I (444) GATTS_SPP_DEMO: app_main init bluetooth
I (454) GATTS_SPP_DEMO: EVT 0, gatts if 3
I (454) GATTS_SPP_DEMO: event = 0
I (454) GATTS_SPP_DEMO: gatts_profile_event_handler 495
I (464) GATTS_SPP_DEMO: gatts_profile_event_handler 498
I (464) GATTS_SPP_DEMO: gatts_profile_event_handler 501
困惑小白半年的问题求指点
Re: 困惑小白半年的问题求指点
它是一个回调函数,在初始化时注册了,
esp_ble_gatts_register_callback(gatts_event_handler);
由底层调用,你可以在esp-idf的 components/bt/host/bluedroid/api/esp_gatts_api.c 中找到它的身影。
esp_ble_gatts_register_callback(gatts_event_handler);
由底层调用,你可以在esp-idf的 components/bt/host/bluedroid/api/esp_gatts_api.c 中找到它的身影。
Who is online
Users browsing this forum: No registered users and 73 guests