#ifndef _aplmt_devices_serial_haluartbapi_h_ #define _aplmt_devices_serial_haluartbapi_h_ /*---------------------------------------------------------------------------- ** SUMMARY: APLMT Hardware Abstraction Layer for UART-B Interface (HALUARTB) ** ** DESCRIPTION: ** This file describes an abstraction layer of basic UART primitives that ** are platform specific in its implemenation. ** ** ** CONFIGURATION ** ------------- ** COMPILE: none. ** ** APPLICATION: none. ** ** PLATFORM: none. ** ----------------------------------------------------------------------------*/ #include "apl/types/types.h" /* For: basic types */ #include "platform/haluartbapi.h" /* For: target config and/or overrides */ /*-------------- PUBLISHED API ---------------------------------------------*/ /** This method places the specified byte in to the transmit data register and initiates a transmit sequence. Prototype: void Aplmt_halUartBTransmitByte(AplByte byteToTransmit); */ #define Aplmt_halUartBTransmitByte _Aplmt_halUartBTransmitByte /** This method clears the Tx Interrupt request. This method can be empty/null if the loadind the data register clears the IRQ. Prototype: void Aplmt_halUartBClrTxIrq(void); */ #define Aplmt_halUartBClrTxIrq _Aplmt_halUartBClrTxIrq /** This method enables the UART transmitter Prototype: void Aplmt_halUartBEnableTx(void); */ #define Aplmt_halUartBEnableTx _Aplmt_halUartBEnableTx /** This method disables the UART transmitter Prototype: void Aplmt_halUartBDisableTx(void); */ #define Aplmt_halUartBDisableTx _Aplmt_halUartBDisableTx /** This method enables the UART Transmit Data register emtpy interrupt Prototype: void Aplmt_halUartBEnableTxIrq(void); */ #define Aplmt_halUartBEnableTxIrq _Aplmt_halUartBEnableTxIrq /** This method disables the UART Transmit Data register empty interrupt Prototype: void Aplmt_halUartBEnableTxIrq(void); */ #define Aplmt_halUartBDisableTxIrq _Aplmt_halUartBDisableTxIrq /** This method return non-zero (true) if the 'current' UART interrupt request is a tx-data-register-empty interrupt. Prototype: AplBool Aplmt_halUartBIsTxIrq(void); */ #define Aplmt_halUartBIsTxIrq _Aplmt_halUartBIsTxIrq /*-------------- PUBLISHED API ---------------------------------------------*/ /** This method returns the last received byte, independent of any Rx errors Prototype: AplByte Aplmt_halUartBGetRxByte(void)l */ #define Aplmt_halUartBGetRxByte _Aplmt_halUartBGetRxByte /** This method clears the Rx Interrupt request. This method can be empty/null if the reading the received byte clears the IRQ. Prototype: void Aplmt_halUartBClrRxIrq(void); */ #define Aplmt_halUartBClrRxIrq _Aplmt_halUartBClrRxIrq /** This method returns non-zero (true) if any Rx error (framing, overrung, parity, etc.) has occurred on the 'current' byte Prototype: AplByte Aplmt_halUartBIsRxError(void); */ #define Aplmt_halUartBIsRxError _Aplmt_halUartBIsRxError /** This method clears ALL Rx errors for the 'current' byte. Prototype: void Aplmt_halUartBClrRxErrors(void); */ #define Aplmt_halUartBClrRxErrors _Aplmt_halUartBClrRxErrors /** This method enables the UART receiver Prototype: void Aplmt_halUartBEnableRx(void); */ #define Aplmt_halUartBEnableRx _Aplmt_halUartBEnableRx /** This method disables the UART receiver Prototype: void Aplmt_halUartBDisableRx(void); */ #define Aplmt_halUartBDisableRx _Aplmt_halUartBDisableRx /** This method enables the UART Receive data interrupt. Prototype: void Aplmt_halUartBEnableRxIrq(void); */ #define Aplmt_halUartBEnableRxIrq _Aplmt_halUartBEnableRxIrq /** This method disables the UART Receive data interrupt. Prototype: void Aplmt_halUartBDisableRxIrq(void); */ #define Aplmt_halUartBDisableRxIrq _Aplmt_halUartBDisableRxIrq /** This method return non-zero (true) if the 'current' UART interrupt request is a unread-data-in-the-rx-data-registe interrupt. Prototype: AplBool Aplmt_halUartBIsRxIrq(void) */ #define Aplmt_halUartBIsRxIrq _Aplmt_halUartBIsRxIrq /*-------------- PUBLISHED API ---------------------------------------------*/ /** This method enables the external baud rate generator for the UART. Not all platforms and/or UARTs support this feature. Check your platform's documentation before using. Prototype: void Aplmt_halUartBEnableExternalBaud(void); */ #define Aplmt_halUartBEnableExternalBaud _Aplmt_halUartBEnableExternalBaud /** This method disables the external baud rate generator for the UART. Not all platforms and/or UARTs support this feature. Check your platform's documentation before using. Prototype: void Aplmt_halUartBDisableExternalBaud(void); */ #define Aplmt_halUartBDisableExternalBaud _Aplmt_halUartBDisableExternalBaud /*--------------------------------------------------------------------------*/ #endif /* end _aplmt_devices_serial_haluartbapi_h_ */