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

How implement radio transmitter e receiver example with packet array

Hi,

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;
send_packet();
}

But in received packet have data only in first position.

 if (NRF_RADIO->CRCSTATUS == 1U) {
    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.

Related