Go to the source code of this file.
◆ COMMAND_BUFFER_SIZE
#define COMMAND_BUFFER_SIZE 50 |
◆ RECEIVE_BUFFER_SIZE
#define RECEIVE_BUFFER_SIZE 50 |
◆ Leuart_Status_t
◆ leuart_statuses
Enumerator |
---|
TX_TIMEOUT | |
RX_TIMEOUT | |
DATA_SENT | |
DATA_RECEIVED | |
Definition at line 26 of file leuart.h.
enum leuart_statuses Leuart_Status_t
◆ Leuart_BreakCondition()
void Leuart_BreakCondition |
( |
void |
| ) |
|
Definition at line 342 of file leuart.c.
void delay(uint32_t msDelay)
Wait for a certain amount of milliseconds in EM2/3.
◆ Leuart_ClearBuffers()
void Leuart_ClearBuffers |
( |
void |
| ) |
|
Definition at line 83 of file leuart.c.
#define RECEIVE_BUFFER_SIZE
volatile bool receiveComplete
◆ Leuart_Init()
void Leuart_Init |
( |
void |
| ) |
|
Definition at line 306 of file leuart.c.
void Leuart_BreakCondition(void)
static void sendLeuartData(char *buffer, uint8_t bufferLength)
static void setupLeuart(void)
void delay(uint32_t msDelay)
Wait for a certain amount of milliseconds in EM2/3.
◆ Leuart_ReadResponse()
void Leuart_ReadResponse |
( |
char * |
buffer, |
|
|
uint8_t |
bufferLength |
|
) |
| |
Definition at line 351 of file leuart.c.
volatile bool receiveComplete
volatile uint8_t bufferPointer
◆ Leuart_Reinit()
void Leuart_Reinit |
( |
void |
| ) |
|
Definition at line 323 of file leuart.c.
Leuart_Status_t Leuart_WaitForResponse()
void Leuart_BreakCondition(void)
static void sendLeuartData(char *buffer, uint8_t bufferLength)
static void setupLeuart(void)
void delay(uint32_t msDelay)
Wait for a certain amount of milliseconds in EM2/3.
◆ Leuart_SendCommand()
Leuart_Status_t Leuart_SendCommand |
( |
char * |
cb, |
|
|
uint8_t |
cbl, |
|
|
volatile bool * |
wakeUp |
|
) |
| |
Send a command string over the LEUART. "wakeUp" IS NOT USED
Definition at line 392 of file leuart.c.
395 uint32_t counter = 0;
407 #if DEBUG_DBPRINT == 1 408 dbcrit(
"Waiting time for response reached! (Leuart_SendCommand)");
415 #if DBPRINT_TIMEOUT == 1 419 #if DEBUG_DBPRINT == 1 420 dbwarnInt(
"Leuart_SendCommand (", counter,
")");
void dbwarnInt(char *message1, int32_t value, char *message2)
Print a warning value surrounded by two strings (char array) to USARTx.
static bool Leuart_ResponseAvailable(void)
static void sendLeuartData(char *buffer, uint8_t bufferLength)
void error(uint8_t number)
Error method.
void dbcrit(char *message)
Print a critical error string (char array) in red to USARTx and go to the next line.
◆ Leuart_SendData()
void Leuart_SendData |
( |
char * |
buffer, |
|
|
uint8_t |
bufferLength |
|
) |
| |
Definition at line 358 of file leuart.c.
361 uint32_t counter = 0;
373 #if DEBUG_DBPRINT == 1 374 dbcrit(
"Waiting time for response reached! (Leuart_SendData)");
382 #if DEBUG_DBPRINT == 1 383 dbwarnInt(
"Leuart_SendData (", counter,
")");
void dbwarnInt(char *message1, int32_t value, char *message2)
Print a warning value surrounded by two strings (char array) to USARTx.
#define TIMEOUT_WAITRESPONSE
static bool Leuart_ResponseAvailable(void)
static void sendLeuartData(char *buffer, uint8_t bufferLength)
void error(uint8_t number)
Error method.
volatile bool receiveComplete
void dbcrit(char *message)
Print a critical error string (char array) in red to USARTx and go to the next line.
◆ Leuart_WaitForResponse()
Definition at line 430 of file leuart.c.
433 uint32_t counter = 0;
450 #if DEBUG_DBPRINT == 1 451 dbcrit(
"Waiting time for response reached! (Leuart_WaitForResponse)");
458 #if DBPRINT_TIMEOUT == 1 462 #if DEBUG_DBPRINT == 1 463 dbwarnInt(
"Leuart_WaitForResponse (", counter,
")");
void dbwarnInt(char *message1, int32_t value, char *message2)
Print a warning value surrounded by two strings (char array) to USARTx.
#define TIMEOUT_WAITRESPONSE
static bool Leuart_ResponseAvailable(void)
void error(uint8_t number)
Error method.
void dbcrit(char *message)
Print a critical error string (char array) in red to USARTx and go to the next line.