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

Gazell transmit failure NRF51 SDK10

I have a bit of a strange problem. I am designing a signal Gazell signal repeater. It listens in host mode then sets itself as a device to pass the data along.

However if the data being passed to the transmit fifo does not change it does not transmit. See this code to see what is going on......

This does not transmit:

setupGazelToTransmit();
nrf_gzll_flush_tx_fifo(PIPE_3);
nrf_gzll_add_packet_to_tx_fifo(PIPE_3, transmit_data_3, TX_PAYLOAD_LENGTH);

This is the work around that simply changes the data being transmit:

TransmitCounter++;
transmit_data_3[0] = TransmitCounter; setupGazelToTransmit();
nrf_gzll_flush_tx_fifo(PIPE_3);
nrf_gzll_add_packet_to_tx_fifo(PIPE_3, transmit_data_3, TX_PAYLOAD_LENGTH);

Leaving the gazell module permanently as a device also works:

//setupGazelToTransmit();
nrf_gzll_flush_tx_fifo(PIPE_3);
nrf_gzll_add_packet_to_tx_fifo(PIPE_3, transmit_data_3, TX_PAYLOAD_LENGTH);

(this is no good for my application as it needs to switch between host and device)

Any idea why is this happening?

Parents
  • @Elliott: I guess that you re-initialize the repeater every time you switch the role ? Doing that the first packet the device send will look the same to the host on the other side and it can be discarded as re-transmission package since the CRC and the 2 bit PID are the same (check out the Enhanced Shockburst Userguide). PID is increased after every successful packet, but in this case you reinitialize every time you send a package, so it will be 00 on all packets.

    The easiest solution is to add one more byte to the payload to work as a counter for example, so that the payload is different every time you transmit.

Reply
  • @Elliott: I guess that you re-initialize the repeater every time you switch the role ? Doing that the first packet the device send will look the same to the host on the other side and it can be discarded as re-transmission package since the CRC and the 2 bit PID are the same (check out the Enhanced Shockburst Userguide). PID is increased after every successful packet, but in this case you reinitialize every time you send a package, so it will be 00 on all packets.

    The easiest solution is to add one more byte to the payload to work as a counter for example, so that the payload is different every time you transmit.

Children
Related