![]() |
RTEMS 6.1
|
Macros | |
| #define | CONSOLE_BAUDRATE 115200 |
| #define | CONSOLE_EDBG |
| #define | CONSOLE_ON_USART |
| #define | PIN_USART1_RXD_DBG {PIO_PA21A_RXD1, PIOA, ID_PIOA, PIO_PERIPH_A, PIO_DEFAULT} |
| #define | PIN_USART1_TXD_DBG {PIO_PB4D_TXD1, PIOB, ID_PIOB, PIO_PERIPH_D, PIO_DEFAULT} |
| #define | PINS_USART1 PIN_USART1_TXD_DBG, PIN_USART1_RXD_DBG |
| #define | CONSOLE_Usart USART1 |
| #define | CONSOLE_PINS {PINS_USART1} |
| #define | CONSOLE_ID ID_USART1 |
Functions | |
| void | DBG_Configure (uint32_t baudrate, uint32_t masterClock) |
| Configures an USART peripheral with the specified parameters. | |
| void | DBG_PutChar (uint8_t c) |
| Outputs a character on the UART line. | |
| uint32_t | DBG_GetChar (void) |
| Input a character from the UART line. | |
| uint32_t | DBG_IsRxReady (void) |
| Check if there is Input from UART line. | |
| void | DBG_DumpFrame (uint8_t *pucFrame, uint32_t dwSize) |
| void | DBG_DumpMemory (uint8_t *pucBuffer, uint32_t dwSize, uint32_t dwAddress) |
| uint32_t | DBG_GetInteger (int32_t *pdwValue) |
| uint32_t | DBG_GetIntegerMinMax (int32_t *pdwValue, int32_t dwMin, int32_t dwMax) |
| uint32_t | DBG_GetHexa32 (uint32_t *pdwValue) |
| WEAK int | puts (const char *ptr) |
| WEAK char * | gets (char *ptr) |
Implements UART console.
| #define CONSOLE_BAUDRATE 115200 |
Console baud rate always using 115200.
| #define CONSOLE_EDBG |
EDBG used USART1 as the console, but LON support on USART1 only
| #define CONSOLE_PINS {PINS_USART1} |
Pins description corresponding to Rxd,Txd, (Usart pins)
| #define CONSOLE_Usart USART1 |
Usart Hw interface used by the console (Usart0).
| #define PIN_USART1_RXD_DBG {PIO_PA21A_RXD1, PIOA, ID_PIOA, PIO_PERIPH_A, PIO_DEFAULT} |
USART1 pin RX
| #define PIN_USART1_TXD_DBG {PIO_PB4D_TXD1, PIOB, ID_PIOB, PIO_PERIPH_D, PIO_DEFAULT} |
USART1 pin TX
| void DBG_Configure | ( | uint32_t | baudrate, |
| uint32_t | masterClock | ||
| ) |
Configures an USART peripheral with the specified parameters.
| baudrate | Baudrate at which the USART should operate (in Hz). |
| masterClock | Frequency of the system master clock (in Hz). |
| void DBG_DumpFrame | ( | uint8_t * | pucFrame, |
| uint32_t | dwSize | ||
| ) |
Displays the content of the given frame on the UART0.
| pucFrame | Pointer to the frame to dump. |
| dwSize | Buffer size in bytes. |
| void DBG_DumpMemory | ( | uint8_t * | pucBuffer, |
| uint32_t | dwSize, | ||
| uint32_t | dwAddress | ||
| ) |
Displays the content of the given buffer on the UART0.
| pucBuffer | Pointer to the buffer to dump. |
| dwSize | Buffer size in bytes. |
| dwAddress | Start address to display |
| uint32_t DBG_GetChar | ( | void | ) |
Input a character from the UART line.
| uint32_t DBG_GetHexa32 | ( | uint32_t * | pdwValue | ) |
Reads an hexadecimal number
| pdwValue | Pointer to the uint32_t variable to contain the input value. |
| uint32_t DBG_GetInteger | ( | int32_t * | pdwValue | ) |
Reads an integer
| pdwValue | Pointer to a integer variable to contain the input value. |
| uint32_t DBG_GetIntegerMinMax | ( | int32_t * | pdwValue, |
| int32_t | dwMin, | ||
| int32_t | dwMax | ||
| ) |
Reads an integer and check the value
| pdwValue | Pointer to a integer variable to contain the input value. |
| dwMin | Minimum value |
| dwMax | Maximum value |
| uint32_t DBG_IsRxReady | ( | void | ) |
Check if there is Input from UART line.
| void DBG_PutChar | ( | uint8_t | c | ) |
Outputs a character on the UART line.
| c | Character to send. |