Send data from one nrf52 to another nrf52

Hello everyone. I am trying to develop a communication link between two nrf52 devices. I want to collect measurements from some sensors, pack them into a single data pack and send them every for example 10 seconds and receive the data on the other board and finally send the data with UART peripheral. The main reason to wish this service is to save power as much as possible. do you have any suggestions? at this stage, I create a gatts service with a notification that can update the data on nrf app on my phone every 5 seconds.

Thank you

Parents
  • Hi

    Yes, there are multiple example projects in the nRF5 SDK that does what you describe, but you need to decide on whether you actually want to connect to the central device (for added security) or just advertise the data every 5 or 10 seconds for anyone to pick up. For having the device in a connection you can check out the ble_app_hrs heart rate application for instance or the beacon application for just advertising. I think you need to provide more details as to what exactly you want to do for me to give you any further suggestions.

    Best regards,

    Simon

  • Thank you, Simon, for all this information. I appreciate it.

    I wanted to connect to the central device, but do you know this connection adds more power to the power consumption in comparison to Beacon advertising? And about the heart rate application, can you provide more detail about it? In the description of this example, it is mentioned that "This application is not power-optimized!" and the code stop advertising after 3 minutes. How can I solve these problems?

    Best,

  • Hi

    Power optimization and alterations to our example projects are expected to be made on your side, and we can help you with techincal questions if you run into issues during development.

    For example, the APP_ADV_DURATION define in our example projects is what's used to modify the advertising duration If you want it to advertise for I.E. 10 seconds this define should be set to 1000. 

    For current consumption I would suggest checking out my colleague Scott's blog post on ways to optimize current conusmption in nRF52 designs. This is good both for hardware design and software development.

    Best regards,

    Simon

Reply Children
No Data
Related