从机想实现这样的功能,在成功连接后,调用某个函数实现特定功能;请问Peripheral 有 没有 函数 获取 自身是否处于连接状态?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
从机想实现这样的功能,在成功连接后,调用某个函数实现特定功能;请问Peripheral 有 没有 函数 获取 自身是否处于连接状态?
可参考例程simpleBLEPeripheral中的peripheralStateNotificationCB()状态改变回调函数。
蓝牙连接状态获取可以通过GAPRole_GetParameter(GAPROLE_STATE,&state)获取。