micrfrx  2.1.0.0
Macros | Functions
main.c File Reference

MICRF RX Click Example. More...

#include "board.h"
#include "log.h"
#include "micrfrx.h"

Macros

#define MICRFRX_PREAMBLE   0x5AA5
 

Functions

void application_init (void)
 
void application_task (void)
 
int main (void)
 

Detailed Description

MICRF RX Click Example.

Description

This example demonstrates the use of MICRF RX click board by reading and parsing packet messages received from the transmitter.

The demo application is composed of two sections :

Application Init

Initializes the driver and enables the device and squelch mode.

Application Task

Waits for a data ready indication, then reads all packet data, verifies the CRC bytes in a packet, and displays its data as well as the RSSI value on the USB UART.

Note
The MICRF TX click board is a compatible transmitter for the MICRF RX click. Here are a few steps for troubleshooting if you are experiencing issues running this example:
  • Make sure the MICRF TX click is set to ASK mode with on-board jumpers.
  • Check the MCU clock configuration, use an external oscillator instead of the MCU's internal one for better accuracy on manchester data rate delay.
  • Measure the actual data rate on the data line and adjust the MICRFRX_MAN_BIT_LEN_US value accordingly.
Author
Stefan Filipovic

Macro Definition Documentation

◆ MICRFRX_PREAMBLE

#define MICRFRX_PREAMBLE   0x5AA5

Packet preamble word.

Function Documentation

◆ application_init()

void application_init ( void  )

< Logger config object.

< Click config object.

Logger initialization. Default baud rate: 115200 Default log level: LOG_LEVEL_DEBUG

Note
If USB_UART_RX and USB_UART_TX are defined as HAL_PIN_NC, you will need to define them manually for log to work. See LOG_MAP_USB_UART macro definition for detailed explanation.

◆ application_task()

void application_task ( void  )

◆ main()

int main ( void  )