WebRadioApp  0.1
EW_BSP_CONSOLE
Collaboration diagram for EW_BSP_CONSOLE:

Macros

#define UART_PORTID   USART1
 
#define USARTx_CLK_ENABLE()   __HAL_RCC_USART1_CLK_ENABLE();
 
#define USARTx_RX_GPIO_CLK_ENABLE()   __HAL_RCC_GPIOA_CLK_ENABLE()
 
#define USARTx_TX_GPIO_CLK_ENABLE()   __HAL_RCC_GPIOA_CLK_ENABLE()
 
#define RCC_PERIPHCLK_USARTx   RCC_PERIPHCLK_USART1
 
#define RCC_USARTxCLKSOURCE_HSI   RCC_USART1CLKSOURCE_HSI
 
#define USARTx_FORCE_RESET()   __HAL_RCC_USART1_FORCE_RESET()
 
#define USARTx_RELEASE_RESET()   __HAL_RCC_USART1_RELEASE_RESET()
 
#define USARTx_TX_PIN   GPIO_PIN_9
 
#define USARTx_TX_GPIO_PORT   GPIOA
 
#define USARTx_TX_AF   GPIO_AF7_USART1
 
#define USARTx_RX_PIN   GPIO_PIN_10
 
#define USARTx_RX_GPIO_PORT   GPIOA
 
#define USARTx_RX_AF   GPIO_AF7_USART1
 

Functions

void HAL_UART_MspInit (UART_HandleTypeDef *huart)
 UART MSP Initialization - This function configures the hardware resources. More...
 
void HAL_UART_MspDeInit (UART_HandleTypeDef *huart)
 UART MSP Deinitialization - This function configures the hardware resources. More...
 
void EwBspConsoleInit (void)
 The function EwBspConsoleInit initializes a console connection via UART/USART interface used to print error and trace messages from an Embedded Wizard GUI application. This implementation uses the following configuration: More...
 
void EwBspConsoleDone (void)
 The function EwBspConsoleDone terminates a console connection. More...
 
void EwBspConsolePutCharacter (unsigned char aCharacter)
 The function EwBspConsolePutCharacter sends the given character to the console interface. More...
 
unsigned char EwBspConsoleGetCharacter (void)
 The function EwBspConsoleGetCharacter returns the current character from the console interface. If no character is available within the input buffer, 0 is returned. More...
 

Variables

UART_HandleTypeDef UART_Handle
 

Detailed Description

Macro Definition Documentation

◆ RCC_PERIPHCLK_USARTx

#define RCC_PERIPHCLK_USARTx   RCC_PERIPHCLK_USART1

◆ RCC_USARTxCLKSOURCE_HSI

#define RCC_USARTxCLKSOURCE_HSI   RCC_USART1CLKSOURCE_HSI

◆ UART_PORTID

#define UART_PORTID   USART1

◆ USARTx_CLK_ENABLE

#define USARTx_CLK_ENABLE ( )    __HAL_RCC_USART1_CLK_ENABLE();

◆ USARTx_FORCE_RESET

#define USARTx_FORCE_RESET ( )    __HAL_RCC_USART1_FORCE_RESET()

◆ USARTx_RELEASE_RESET

#define USARTx_RELEASE_RESET ( )    __HAL_RCC_USART1_RELEASE_RESET()

◆ USARTx_RX_AF

#define USARTx_RX_AF   GPIO_AF7_USART1

◆ USARTx_RX_GPIO_CLK_ENABLE

#define USARTx_RX_GPIO_CLK_ENABLE ( )    __HAL_RCC_GPIOA_CLK_ENABLE()

◆ USARTx_RX_GPIO_PORT

#define USARTx_RX_GPIO_PORT   GPIOA

◆ USARTx_RX_PIN

#define USARTx_RX_PIN   GPIO_PIN_10

◆ USARTx_TX_AF

#define USARTx_TX_AF   GPIO_AF7_USART1

◆ USARTx_TX_GPIO_CLK_ENABLE

#define USARTx_TX_GPIO_CLK_ENABLE ( )    __HAL_RCC_GPIOA_CLK_ENABLE()

◆ USARTx_TX_GPIO_PORT

#define USARTx_TX_GPIO_PORT   GPIOA

◆ USARTx_TX_PIN

#define USARTx_TX_PIN   GPIO_PIN_9

Function Documentation

◆ EwBspConsoleDone()

void EwBspConsoleDone ( void  )

The function EwBspConsoleDone terminates a console connection.


Here is the caller graph for this function:

◆ EwBspConsoleGetCharacter()

unsigned char EwBspConsoleGetCharacter ( void  )

The function EwBspConsoleGetCharacter returns the current character from the console interface. If no character is available within the input buffer, 0 is returned.

Returns
unsigned char - Current character from console input buffer or 0.

References UART_Handle.

Here is the caller graph for this function:

◆ EwBspConsoleInit()

void EwBspConsoleInit ( void  )

The function EwBspConsoleInit initializes a console connection via UART/USART interface used to print error and trace messages from an Embedded Wizard GUI application. This implementation uses the following configuration:

  • BaudRate = 115200 baud
  • Word Length = 8 Bits
  • One Stop Bit
  • No parity
  • Hardware flow control disabled (RTS and CTS signals)
  • Receive and transmit enabled

References UART_Handle, and UART_PORTID.

Here is the caller graph for this function:

◆ EwBspConsolePutCharacter()

void EwBspConsolePutCharacter ( unsigned char  aCharacter)

The function EwBspConsolePutCharacter sends the given character to the console interface.

Parameters
aCharacter- The character to be send via the console interface.

References UART_Handle.

Here is the caller graph for this function:

◆ HAL_UART_MspDeInit()

void HAL_UART_MspDeInit ( UART_HandleTypeDef *  huart)

UART MSP Deinitialization - This function configures the hardware resources.

Parameters
huartUART handle pointer

References USARTx_FORCE_RESET, USARTx_RELEASE_RESET, USARTx_RX_GPIO_PORT, USARTx_RX_PIN, USARTx_TX_GPIO_PORT, and USARTx_TX_PIN.

◆ HAL_UART_MspInit()

void HAL_UART_MspInit ( UART_HandleTypeDef *  huart)

UART MSP Initialization - This function configures the hardware resources.

Parameters
huartUART handle pointer

References RCC_PERIPHCLK_USARTx, RCC_USARTxCLKSOURCE_HSI, USARTx_CLK_ENABLE, USARTx_RX_AF, USARTx_RX_GPIO_CLK_ENABLE, USARTx_RX_GPIO_PORT, USARTx_RX_PIN, USARTx_TX_AF, USARTx_TX_GPIO_CLK_ENABLE, USARTx_TX_GPIO_PORT, and USARTx_TX_PIN.

Variable Documentation

◆ UART_Handle

UART_HandleTypeDef UART_Handle

UART handle Structure definition