Closed metc closed 7 years ago
@metc , I have stripped down the heart_rate_collector example to do only discovery and nothing else, and it is working just fine with adding your scan_params. Reading the source BLEGapTimeoutSrc is called by an Enum that has range of [0..4] in value defined in pc-ble-driver, instead this you get random value, which makes me suspect that different versions of structs mapped to the BLEEvent is used here. In short, my suggestion - since I don't know more about your code - is:
nrfjprog -e -f nrf51
I was able to reproduce the issue when running the heart rate collector example with the nRF51 dongle. It was not immediately obvious, because logging was disabled in the example. I added logging.basicLogging()
to the top of the example, and then the Exception: <value> is not a valid BLEGapTimeoutSrc
was printed after a few seconds.
The issue seems to be related to d9e06aa4e which was added in version 0.8.1. We will have to look into this and apply a fix. I have tested version 0.8.0, and that seems to be working fine with the nRF51 dongle, so you could perhaps use that version in the meantime.
I am using an nRF51 dongle in order to print all BLE devices advertising around me. I got the following error when the
gap_evt_timeout
is handle by the Python driver:The GAP ADV timeout of 10 seconds is correct. I use the following code on an nRF51 dongle which is flashed automatically using the library (pc_ble_driver_sd_api_v2):
I am not sure how to debug this. Could you help me? The value of the
BLEGapTimeoutSrc
changes for every run.