Other Parts Discussed in Thread: CC2540
Hi,
we have some BLE-Beacons which are advertising every 100ms. Now we are trying to receive the advertising Packets on Windows with the CC2540 USB dongle flashed with the cc2540_ble1.1_USBdongle_HostTestRelease_Master.hex file.
As basis we are using the Health Demo(http://processors.wiki.ti.com/index.php/Category:HealthDemo).
There must be something very basic we are missing, but we are getting a response every 4-5 seconds only! Too slow!
Here is what we did:
Set the scan rate to 10ms
Bluetooth.HCICmds.GAPCmds.GAP_SetParam GAP_SetParamWindow = new Bluetooth.HCICmds.GAPCmds.GAP_SetParam(); GAP_SetParamWindow.paramId = CADTracker.Bluetooth.HCICmds.GAP_ParamId.TGAP_GEN_DISC_SCAN_INT; GAP_SetParamWindow.value = 10; beacon_SendGAP_SetParam(GAP_SetParamWindow);
Wait for a success response, then set the window to 10ms;
Bluetooth.HCICmds.GAPCmds.GAP_SetParam GAP_SetParamInterval = new Bluetooth.HCICmds.GAPCmds.GAP_SetParam(); GAP_SetParamInterval.paramId = CADTracker.Bluetooth.HCICmds.GAP_ParamId.TGAP_GEN_DISC_SCAN_WIND; GAP_SetParamInterval.value = 10; beacon_SendGAP_SetParam(GAP_SetParamInterval);
Wait for a success response, then every 20 seconds call a device discovery
// scan Bluetooth.HCICmds.GAPCmds.GAP_DeviceDiscoveryRequest GAP_DeviceDiscoveryRequest = new Bluetooth.HCICmds.GAPCmds.GAP_DeviceDiscoveryRequest(); GAP_DeviceDiscoveryRequest.nameMode = Bluetooth.HCICmds.GAP_EnableDisable.Enable; GAP_DeviceDiscoveryRequest.whiteList = Bluetooth.HCICmds.GAP_EnableDisable.Disable; GAP_DeviceDiscoveryRequest.mode = (HCICmds.GAP_DiscoveryMode)0x3; // send the request beacon_SendGAP_DeviceDiscoveryRequest(GAP_DeviceDiscoveryRequest);
Thank you for your Help!