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

Radio Transmitter/Receiver example modification

Hello !!

I want to use Radio transmitter/ receiver example in my custom board which is used for BT remote control battery powered. I have added 10 buttons on my board and define it on example. I want to send UUID code so that it could be distinguished. 

Now after modifying the code I am getting same values on each button pressed. I am not able to find how the transmitter example sending values. Anyone help me out with :

1. Sending UUID with transmitter example.

2. Sending same data on each button press as it was doing with the default example.

3. As it is battery powered, I want to put it on low power mode so that battery could run long last.

I will appreciate any response.

Thanks 

Parents Reply Children
  • Hi 

    You can change the example to define a byte array for use as a TX buffer, rather than a single variable. 

    Then you can copy your other data fields into this byte array, using the memcpy function for instance. 

    Depending on how much data you want to send you need to scale the byte buffer accordingly, and also update the PACKET_STATIC_LENGTH define in radio_config.h to allow you to send more than one byte. 

    Best regards
    Torbjørn

Related