How implement radio transmitter e receiver example with packet array

zimmer gravatar image

asked 2017-03-20 20:35:43 +0100


SDK: nRF5_SDK_12.2.0_f012efa No softdevice Example: nRF5_SDK_12.2.0_f012efa\examples\peripheral\radio\transmitter\pca10040\blank and receiver.

I have running examples perfect, but I need send uint8_t packet[6].

I add in transmitter the timer to send packet:

void send_datetime_timeout_event(void * p_context){
    packet[0] = 10; 
    packet[1] = 20;
    packet[2] = 30;
    packet[3] = 40;
    packet[4] = 50;
    packet[5] = 60;

But in received packet have data only in first position.

    uint8_t result = packet[0]; // its ok, value 0x0A (10)
    uint8_t result1 = packet[1]; // value 0x00
   uint8_t result2 = packet[2]; // value 0x00


Do you have any idea the problem?

English is not my first language, so I apologize in advance for any linguistic mistake.

edit retag flag offensive close delete report spam

1 answer

Sort by ยป oldest newest most voted
Kristin gravatar image

answered 2017-03-22 09:19:37 +0100

To increase the packet length, PACKET_STATIC_LENGTH in radio_config.h needs to be set to the appropriate packet length.

edit flag offensive delete publish link more


Perfect. Thank you.

Leandro Zimmer ( 2017-03-22 13:33:24 +0100 )editconvert to answer

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer. Do not ask a new question or reply to an answer here.

[hide preview]

Question Tools

1 follower


Asked: 2017-03-20 20:35:43 +0100

Seen: 33 times

Last updated: mars 22