This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

BLE sensor implementation questions

Hello All,

I'm developing a BLE sensor based on the nRF52832 which needs to do the following:

  • Use an (i)Beacon for the user to find the sensor with an App on a mobile phone within a 20 meter radius.
  • Provide the App the option to adjust certain parameters such as advertising interval, time-out etc for testing.
  • Have the option to use DFU to update the firmware of the device with a phone.

I already got DFU working and added a timeout to the bootloader, so it won't stay in the bootloader when a valid application is present. I've also found the beacon example and noticed that the example description said it can be converted to an iBeacon easily. So this should be straightforward. Adjusting the parameters for development is still something I'm not sure about. I could use the uart over BLE to adjust settings or create a service like the heartbeat sensor example, but I'm not familiar with the limitations or how difficult this would be to implement.

Another thing I'm curious about is how to solve is the power consumption. I could keep the device broadcasting as a beacon continously, but the required interval is quite high to give the mobile phone application a low response time. Is there an option to provide a signal to increase the interval? The idea I had is as following: The sensor advertises on a very low interval 5/10seconds to ocnserve power, but does not provide a beacon. When the user connects to the BLE sensor start a beacon with a high interval and a 1 minute timeout after which the sensor return to its low interval advertising.

Should I only activate the DFU service when the settings have been set to activate by the app, so DFU isn't advertised continously? I have created my own keys and rebuild the bootloader, but would it be wise to add an additionaly layer of security, so DFU can't be activated/accessed by anyone eventough they don't have the correct firmware zip file?

Would love to know what you think is the best solution and or suggestions.

Parents
  • There is only "one" advertising from the beacon (GAP peripheral), and when you connect (as GAP central) to the beacon then you can discover the services (DFU, service to reconfigure tx power, advertising window & interval, ... etc).

    should I only start the beacon after a connection has been made

    You cannot connect to the beacon if it is not "started"/advertising in the first place.

Reply
  • There is only "one" advertising from the beacon (GAP peripheral), and when you connect (as GAP central) to the beacon then you can discover the services (DFU, service to reconfigure tx power, advertising window & interval, ... etc).

    should I only start the beacon after a connection has been made

    You cannot connect to the beacon if it is not "started"/advertising in the first place.

Children
No Data
Related