CC2530 has the signal of SFD when it send or receive a message. How can I output this signal. I mean I can prob the signal through the pin of the chip with a oscilloscope. To find out the time delay between the sending and receiving.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
CC2530 has the signal of SFD when it send or receive a message. How can I output this signal. I mean I can prob the signal through the pin of the chip with a oscilloscope. To find out the time delay between the sending and receiving.
Hi,
This code can be used to configure the CC2530 to output the SFD_SYNC, CLK, and DATA signals.
// in ZMain.c
/* RF observable control register value to output Sniffer CLK signal */
#define RFC_OBS_CTRL_SNIF_CLK 0x09
/* RF observable control register value to output Sniffer DATA signal */
#define RFC_OBS_CTRL_SNIF_DATA 0x08
/* RF observable control register value to output SFD_SYNC signal */
#define RFC_OBS_CTRL_SFD_SYNC 0x0F
/* OBSSELn register value to select RF observable 0 */
#define OBSSEL_OBS_CTRL0 0xFB
/* OBSSELn register value to select RF observable 1 */
#define OBSSEL_OBS_CTRL1 0xFC
/* OBSSELn register value to select RF observable 2 */
#define OBSSEL_OBS_CTRL2 0xFD
...
int main( void )
{
...
// Output control signals to OBSSEL0, OBSSEL1, and OBSSEL4 pins
// You may use any of the OBSSEL0-5 pins here instead
RFC_OBS_CTRL0 = RFC_OBS_CTRL_SNIF_CLK;
OBSSEL0 = OBSSEL_OBS_CTRL0;
RFC_OBS_CTRL1 = RFC_OBS_CTRL_SNIF_DATA;
OBSSEL1 = OBSSEL_OBS_CTRL1;
RFC_OBS_CTRL2 = RFC_OBS_CTRL_SFD_SYNC;
OBSSEL4 = OBSSEL_OBS_CTRL2;
MDMTEST1 |= 0x04;
...
}
Note: if you are using an end device that goes to sleep, you need call this code again after it comes out of sleep, i.e. in halSleep().