Communicating between iOS and Android with Bluetooth LE -
i've got working app using corebluetooth communicate between ipad (central) , iphone (peripheral). have 1 service has 2 characteristics. have nexus 7 running latest android 4.3 btle support. android bit late jump on btle bandwagon appears approaching how ios did, support acting central peripheral mode coming in later version. can load sample android btle app , browse nearby peripherals. iphone advertising peripheral can see value cbadvertisementdatalocalnamekey in list of nearby peripherals on android side. can connect iphone , bluetooth symbol turns light gray black when connection made. connection lasts 10 seconds , disconnects. on android side i'm supposed see list of available services , characteristics appear upon connection. i've proved android code setup correctly because can connnect ti cc2541dk-sensor hardware have , services , characteristics listed upon connecting it.
i've spent last few days troubleshooting issue no success. problem can't determine device experiencing error , causing disconnection. there no callbacks cbperipheralmanagerdelegate during connection phase or service discovery phase have no idea @ point error occurs (if error on ios side). on android side method called initiate service discovery callback "onservicesdiscovered" never called perplexing. there way can dig guts of btle communication on ios side see what's going on , determine error taking place?
i've gone through @ least 1 week having same issue. i've asked question here , i've answered on own. main problem android bug issue. it's sending non permitted command on fixed l2cap channnel.
but when android communicating normal peripheral ble devices, works pretty well. in fact, ble sample works charm. problem when comunicating ios device example: after connection made, start negotiating connection parameters (this phase doesn't happen normal ble peripheral), , when problem comes up. android sends bad command ios, ios drops connection. that's how works
some issues have been reported google, , 1 of them have been accepted , hope start working on soon.
unfortunately, can do, wait until next android release. anyway, highly suggest have @ issue report test documents if want make light on problem.
here's link: https://code.google.com/p/android/issues/detail?id=58725
Comments
Post a Comment