Microchip® Advanced Software Framework

at86rfx_driver.c File Reference

AT86RFx driver.

Copyright (c) 2011-2018 Microchip Technology Inc. and its subsidiaries.

#include "compiler.h"
#include "board.h"
#include "conf_at86rfx.h"
#include "spi_master.h"
#include "gpio.h"
#include "at86rfx_driver.h"

Macros

#define CURRENT_CHANNEL_DEFAULT   (20)
 

Functions

at86rfx_retval_t at86rfx_init (void)
 Initializes the transceiver interface. More...
 
void at86rfx_task (void)
 RF task handling. More...
 
void at86rfx_tx_frame (uint8_t *frame_tx)
 Transmits the frame. More...
 
 ISR (ext_int_isr, EXT_INT_ISR_GROUP, EXT_INT_ISR_PRIORITY)
 ISR for transceiver's main interrupt. More...
 
uint8_t pal_trx_bit_read (uint8_t addr, uint8_t mask, uint8_t pos)
 Subregister read. More...
 
void pal_trx_bit_write (uint8_t reg_addr, uint8_t mask, uint8_t pos, uint8_t new_value)
 Subregister write. More...
 
void pal_trx_frame_read (uint8_t *data, uint8_t length)
 Reads frame buffer of the transceiver. More...
 
void pal_trx_frame_write (uint8_t *data, uint8_t length)
 Writes data into frame buffer of the transceiver. More...
 
void pal_trx_init (void)
 Initializes the SPI and GPIO pins for transceiver access. More...
 
uint8_t pal_trx_reg_read (uint8_t addr)
 Reads current value from a transceiver register. More...
 
void pal_trx_reg_write (uint8_t addr, uint8_t data)
 Writes data into a transceiver register. More...
 

Variables

bool at86rfx_frame_rx = false
 
uint8_t at86rfx_rx_buffer [LARGE_BUFFER_SIZE]
 Static receive buffer that can be used to upload a frame from the trx. More...
 
struct spi_device SPI_AT86RFX_DEVICE
 

#define CURRENT_CHANNEL_DEFAULT   (20)

Referenced by at86rfx_init().

ISR ( ext_int_isr  ,
EXT_INT_ISR_GROUP  ,
EXT_INT_ISR_PRIORITY   
)

ISR for transceiver's main interrupt.

References CLEAR_TRX_IRQ, and trx_irq_handler_cb().

bool at86rfx_frame_rx = false
struct spi_device SPI_AT86RFX_DEVICE
Initial value:
= {
}
#define AT86RFX_SPI_NPCS
Definition: rz600.h:120