I am trying to build a ibeacon device, but when iphone in "background mode", it can not get data from ibeacon device. I used test code :examples\ble_peripheral\ble_app_beacon. What's wrong with the test code?
I am trying to build a ibeacon device, but when iphone in "background mode", it can not get data from ibeacon device. I used test code :examples\ble_peripheral\ble_app_beacon. What's wrong with the test code?
What do you mean by " it can not get data from ibeacon device" ?
What data are you getting from the iBeacon. If its just an iBeacon it has no data
iOS handles iBeacons in a special way and has different handling of BLE devices when in background mode. It also does strange things in foreground as well e.g. seems to degrade the number of advertising packets it receives over time. So it starts skipping multiple advertisements.
Which app are you using for testing? As Roger says; it's an ibeacon, it is not the same as an ordinary peripheral.
@yzau You should probably read this
stackoverflow.com/.../ibeacon-notification-when-the-app-is-not-running
I also suspect that as you mention getting data from your beacon, then its not operating as a iBeacon, as iBeacon's do not send any data apart from things like their major and minor ID