Android Bluetooth.connect()在三星S3中抛出NullPointerException,但在三星S中工作正常。有人知道原因吗?
我试图使用编写蓝牙不安全连接代码Android Bluetooth.connect()在三星S3中抛出NullPointerException,但在三星S中工作正常。有人知道原因吗?,android,nullpointerexception,Android,Nullpointerexception,我试图使用编写蓝牙不安全连接代码 Method m = bleutoothdevice.GetMethod("createInsecureRfComm", new Class[]{int.class}; bluetoothSocket = m.InvokeMethod(,) 那样 但在bluetoothSocket.connect调用中,当在S3上运行时,会出现空指针异常 但同样的代码在S2和Acer Tab上运行良好 有人知道原因吗 您可以尝试调用方法“c
Method m = bleutoothdevice.GetMethod("createInsecureRfComm",
new Class[]{int.class};
bluetoothSocket = m.InvokeMethod(,)
那样
但在bluetoothSocket.connect调用中,当在S3上运行时,会出现空指针异常
但同样的代码在S2和Acer Tab上运行良好
有人知道原因吗 您可以尝试调用方法“createRfcommSocket”