221 #ifndef ti_drivers_UART2__include 222 #define ti_drivers_UART2__include 237 #define UART2_STATUS_SUCCESS (0) 242 #define UART2_STATUS_SREADTIMEOUT (1) 247 #define UART2_STATUS_EFRAMING (-1) 252 #define UART2_STATUS_EPARITY (-2) 257 #define UART2_STATUS_EBREAK (-4) 262 #define UART2_STATUS_EOVERRUN (-8) 267 #define UART2_STATUS_EINUSE (-9) 272 #define UART2_STATUS_EINVALID (-10) 277 #define UART2_STATUS_EFAIL (-11) 282 #define UART2_STATUS_EMEMORY (-12) 287 #define UART2_STATUS_ETIMEOUT (-13) 292 #define UART2_STATUS_ECANCELLED (-14) 297 #define UART2_STATUS_ENOTOPEN (-15) 304 #define UART2_WAIT_FOREVER (~(0U)) 329 void *userArg, int_fast16_t status);
459 void *buffer,
size_t size,
size_t *bytesRead, uint32_t timeout);
472 const void *buffer,
size_t size,
size_t *bytesWritten,
658 extern int_fast16_t
UART2_read(UART2_Handle handle,
void *buffer,
size_t size,
740 size_t size,
size_t *bytesRead, uint32_t timeout);
819 extern int_fast16_t
UART2_write(UART2_Handle handle,
const void *buffer,
820 size_t size,
size_t *bytesWritten);
887 size_t size,
size_t *bytesWritten, uint32_t timeout);
UART2 Global configuration.
Definition: UART2.h:516
UART2_ReadCancelFxn readCancelFxn
Definition: UART2.h:497
int_fast16_t UART2_readTimeout(UART2_Handle handle, void *buffer, size_t size, size_t *bytesRead, uint32_t timeout)
Function that reads data from a UART, with a specified timeout for blocking mode. ...
UART2_ReadReturnMode
UART2 return mode settings.
Definition: UART2.h:373
const uint_least8_t UART2_count
void(* UART2_CloseFxn)(UART2_Handle handle)
A function pointer to a driver specific implementation of UART2_CloseFxn().
Definition: UART2.h:441
void UART2_readCancel(UART2_Handle handle)
Function that cancels a UART2_read() function call.
UART2_ReadReturnMode readReturnMode
Definition: UART2.h:429
UART2_Parity
UART2 parity type settings.
Definition: UART2.h:408
void(* UART2_FlushRxFxn)(UART2_Handle handle)
A function to flush the RX data currently in the FIFO.
Definition: UART2.h:446
UART2_ReadFxn readFxn
Definition: UART2.h:494
const UART2_Config UART2_config[]
UART2_WriteCancelFxn writeCancelFxn
Definition: UART2.h:503
int_fast16_t UART2_write(UART2_Handle handle, const void *buffer, size_t size, size_t *bytesWritten)
Function that writes data to a UART.
UART2_Callback readCallback
Definition: UART2.h:427
void * userArg
Definition: UART2.h:434
int_fast16_t(* UART2_WriteFxn)(UART2_Handle handle, const void *buffer, size_t size, size_t *bytesWritten, uint32_t timeout)
A function pointer to a driver specific implementation of UART2_WriteFxn().
Definition: UART2.h:471
struct UART2_Config_ * UART2_Handle
A handle that is returned from a UART2_open() call.
Definition: UART2.h:309
void const * hwAttrs
Definition: UART2.h:524
The definition of a UART2 function table that contains the required set of functions to control a spe...
Definition: UART2.h:486
UART2_StopBits stopBits
Definition: UART2.h:432
void * object
Definition: UART2.h:521
UART2_Mode writeMode
Definition: UART2.h:426
void(* UART2_WriteCancelFxn)(UART2_Handle handle)
A function pointer to a driver specific implementation of UART2_WriteCancelFxn(). ...
Definition: UART2.h:479
UART2_Parity parityType
Definition: UART2.h:433
void UART2_flushRx(UART2_Handle handle)
Function to flush data in the UART RX FIFO.
UART2_Mode
UART2 mode settings.
Definition: UART2.h:336
UART2_Handle UART2_open(uint_least8_t index, UART2_Params *params)
Function to initialize a given UART peripheral.
UART2_FxnTable const * fxnTablePtr
Definition: UART2.h:518
UART2_FlushRxFxn flushRxFxn
Definition: UART2.h:506
int_fast16_t(* UART2_ReadFxn)(UART2_Handle handle, void *buffer, size_t size, size_t *bytesRead, uint32_t timeout)
A function pointer to a driver specific implementation of UART2_ReadFxn().
Definition: UART2.h:458
void UART2_close(UART2_Handle handle)
Function to close a UART peripheral specified by the UART2 handle.
UART2_Callback writeCallback
Definition: UART2.h:428
UART2 Parameters.
Definition: UART2.h:424
struct UART2_Config_ UART2_Config
UART2 Global configuration.
UART2_StopBits
UART2 stop bit settings.
Definition: UART2.h:398
UART2_WriteFxn writeFxn
Definition: UART2.h:500
UART2_CloseFxn closeFxn
Definition: UART2.h:488
void UART2_Params_init(UART2_Params *params)
Function to initialize the UART2_Params struct to its defaults.
UART2_DataLen dataLength
Definition: UART2.h:431
int_fast16_t UART2_read(UART2_Handle handle, void *buffer, size_t size, size_t *bytesRead)
Function that reads data from a UART.
int_fast16_t UART2_writeTimeout(UART2_Handle handle, const void *buffer, size_t size, size_t *bytesWritten, uint32_t timeout)
Function that writes data to a UART, with a specified timeout.
UART2_Handle(* UART2_OpenFxn)(uint_least8_t index, UART2_Params *params)
A function pointer to a driver specific implementation of UART2_OpenFxn().
Definition: UART2.h:452
void(* UART2_Callback)(UART2_Handle handle, void *buf, size_t count, void *userArg, int_fast16_t status)
The definition of a callback function used by the UART2 driver when used in UART2_Mode_CALLBACK The c...
Definition: UART2.h:328
UART2_Mode readMode
Definition: UART2.h:425
UART2_DataLen
UART2 data length settings.
Definition: UART2.h:386
void UART2_writeCancel(UART2_Handle handle)
Function that cancels a UART2_write() function call.
UART2_OpenFxn openFxn
Definition: UART2.h:491
void(* UART2_ReadCancelFxn)(UART2_Handle handle)
A function pointer to a driver specific implementation of UART2_ReadCancelFxn().
Definition: UART2.h:465
uint32_t baudRate
Definition: UART2.h:430