EZR32 Wonder Gecko Software Documentation  ezr32wg-doc-5.1.2
HAL_Layer

Detailed Description

EzRadio HAL Layer

.

Functions

void ezradio_hal_AssertShutdown (void)
 
void ezradio_hal_ClearNsel (void)
 
void ezradio_hal_DeassertShutdown (void)
 
void ezradio_hal_GpioInit (GPIOINT_IrqCallbackPtr_t ezradioIrqCallback, bool enablePTI)
 
uint8_t ezradio_hal_NirqLevel (void)
 
void ezradio_hal_SetNsel (void)
 
void ezradio_hal_SpiInit (void)
 
void ezradio_hal_SpiReadByte (uint8_t *readByte)
 
void ezradio_hal_SpiReadData (uint8_t byteCount, uint8_t *pData)
 
void ezradio_hal_SpiWriteByte (uint8_t byteToWrite)
 
void ezradio_hal_SpiWriteData (uint8_t byteCount, uint8_t *pData)
 
void ezradio_hal_SpiWriteReadData (uint8_t byteCount, uint8_t *txData, uint8_t *rxData)
 

Function Documentation

void ezradio_hal_AssertShutdown ( void  )

Asserts SDN pin of the EZRadio device.

Definition at line 141 of file ezradio_hal.c.

References GPIO_PinOutSet(), RF_SDN_PIN, and RF_SDN_PORT.

Referenced by ezradio_reset().

void ezradio_hal_ClearNsel ( void  )

Clears nSEL pin of the EZRadio device.

Definition at line 157 of file ezradio_hal.c.

References GPIO_PinOutClear(), RF_USARTRF_CS_PIN, and RF_USARTRF_CS_PORT.

Referenced by ezradio_comm_GetResp(), ezradio_comm_ReadData(), ezradio_comm_SendCmd(), and ezradio_comm_WriteData().

void ezradio_hal_DeassertShutdown ( void  )

Deasserts SDN pin of the EZRadio device.

Definition at line 149 of file ezradio_hal.c.

References GPIO_PinOutClear(), RF_SDN_PIN, and RF_SDN_PORT.

Referenced by ezradio_reset().

void ezradio_hal_GpioInit ( GPIOINT_IrqCallbackPtr_t  ezradioIrqCallback,
bool  enablePTI 
)
uint8_t ezradio_hal_NirqLevel ( void  )

Reads nIRQ pin of the EZRadio device.

Returns
Value of nIRQ pin.

Definition at line 175 of file ezradio_hal.c.

References GPIO_PinInGet(), RF_INT_PIN, and RF_INT_PORT.

Referenced by ezradio_configuration_init().

void ezradio_hal_SetNsel ( void  )

Sets nSEL pin of the EZRadio device.

Definition at line 165 of file ezradio_hal.c.

References GPIO_PinOutSet(), RF_USARTRF_CS_PIN, and RF_USARTRF_CS_PORT.

Referenced by ezradio_comm_GetResp(), ezradio_comm_ReadData(), ezradio_comm_SendCmd(), and ezradio_comm_WriteData().

void ezradio_hal_SpiInit ( void  )

Initializes SPI driver for the EZRadio device.

Definition at line 126 of file ezradio_hal.c.

References SPIDRV_Init::bitRate, SPIDRV_Init::csControl, SPIDRV_Init(), and spidrvCsControlApplication.

Referenced by ezradioInit().

void ezradio_hal_SpiReadByte ( uint8_t *  readByte)

Reads a single byte from the EZRadio SPI port.

Parameters
readByteRead byte.

Definition at line 207 of file ezradio_hal.c.

References SPIDRV_MReceiveB().

Referenced by ezradio_comm_GetResp().

void ezradio_hal_SpiReadData ( uint8_t  byteCount,
uint8_t *  pData 
)

Reads byteCount number of bytes from the EZRadio SPI port.

Parameters
byteCountNumber of bytes to write.
pDataPointer to the byte array.

Definition at line 229 of file ezradio_hal.c.

References SPIDRV_MReceiveB().

Referenced by ezradio_comm_GetResp(), and ezradio_comm_ReadData().

void ezradio_hal_SpiWriteByte ( uint8_t  byteToWrite)

Writes a single byte to the EZRadio SPI port.

Parameters
byteToWriteByte to write.

Definition at line 197 of file ezradio_hal.c.

References SPIDRV_MTransmitB().

Referenced by ezradio_comm_GetResp(), ezradio_comm_ReadData(), and ezradio_comm_WriteData().

void ezradio_hal_SpiWriteData ( uint8_t  byteCount,
uint8_t *  pData 
)

Writes byteCount number of bytes to the EZRadio SPI port.

Parameters
byteCountNumber of bytes to write.
pDataPointer to the byte array.

Definition at line 218 of file ezradio_hal.c.

References SPIDRV_MTransmitB().

Referenced by ezradio_comm_SendCmd(), and ezradio_comm_WriteData().

void ezradio_hal_SpiWriteReadData ( uint8_t  byteCount,
uint8_t *  txData,
uint8_t *  rxData 
)

Reads byteCount number of bytes from the EZRadio SPI port.

Parameters
byteCountNumber of bytes to write.
pDataPointer to the byte array.

Definition at line 241 of file ezradio_hal.c.

References SPIDRV_MTransferB().

Referenced by ezradio_comm_GetResp(), and ezradio_comm_ReadData().