Hello everybody!
I'm trying to check the Link Quality Connection between two CC2500, one of them is in TX mode, while the other one is WOR. with a wake-up time of 0,5 ms.
I read in the specific datasheet that by setting PKTCTRL1.APPEND_STATUS=1, two bytes are appended at the end of the RX packet, the first one containing the RSSI value and the second one both CRC_OK (MSB) and LQI (bits from 6 to 0).
I'm sending a packet with a length of 63 and the function I use to read the whole packet and the appended bytes is the following one:
char RFReceivePacket(char *rxBuffer, char *length)
{
char status[2];
char pktLen;
pktLen=*length;
if ((TI_CC_SPIReadStatus(TI_CCxxx0_RXBYTES) & TI_CCxxx0_NUM_RXBYTES))
{
TI_CC_SPIReadBurstReg(TI_CCxxx0_RXFIFO, rxBuffer, pktLen); // Pull data
TI_CC_SPIReadBurstReg(TI_CCxxx0_RXFIFO, status, 2); // Read appended status bytes
return (char) status[1];
}
else{
return 0; // Error
}
The problem I have is that the value stored in the second appended byte (status [1]) is very low (usually around 150, from which i have to subtract the CRC_OK value) even if the 2 antennas are really close.
Can someone help me in understanding where is the mistake I'm making?
Thank you very much.
Best regards,
Matteo