We want to develop a BLE device that can be used both as a connectable BLE peripheral and iBeacon device.
To be able to connect with iOS device, BLE device needs to respond scan request from iOS devices
with response data(such as TX power, name, etc), then iOS devices can make connect request
with BLE device.
Meanwhile our BLE device periodically broadcasts iBeacon packets.
But here comes the conflict part between the two.
1) If we disable scan response function of BLE device, then iOS App can find the iBeacon
signal correct (distance, accuracy, etc), but iOS App will not be able connect and discover services
of the BLE device.
2) If we enable scan response function of BLE device, then BLE connection between iOS App and BLE
device is back to normal, but the CoreLocation function locationManager:didRangeBeacons:inRegion show
no beacon signal can be found.
The difference between 1) and 2) is just commenting or uncommenting a single line
on firmware source code, iOS App side is untouched:
GAP_LE_Set_Scan_Response_Data (a function from Stonestreeone Bluetooth stack)
It seems Apple designed iBeacon in a way to disallow a BLE device to be used as
a BLE peripheral and iBeacon device at the same time.
Anyone has a solution or difference experience ?