且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

空指针异常错误发送特征BLE的Andr​​oid

更新时间:2022-06-26 05:49:02

如果没有堆栈跟踪,这是不可能真正的调试,但是从它的外观,你没有使用 onServicesDiscovered() onCharacteristicRead()回调来等待所有的服务和各自的特点进行阅读,所以你有当这些事件发生的不知道,因此能继续

Without the stack trace this is impossible to truly debug, but from the looks of it you aren't using the onServicesDiscovered() and onCharacteristicRead() callbacks to wait for all the service and respective characteristics to be read so you have no idea when these events are occurring and thus are able to continue