STM32L4R9I_EVAL BSP User Manual: Exported Functions

STM32L4R9I_EVAL BSP

STM32L4R9I_EVAL BSP User Manual
Exported Functions

Functions

__weak void BSP_ErrorHandler (void)
 Error Handler.
uint32_t BSP_GetVersion (void)
 This method returns the STM32L4R9I EVAL BSP Driver revision.
void BSP_LED_Init (Led_TypeDef Led)
 Initialize LED GPIO.
void BSP_LED_DeInit (Led_TypeDef Led)
 DeInitialize LED GPIO.
void BSP_LED_On (Led_TypeDef Led)
 Turn selected LED On.
void BSP_LED_Off (Led_TypeDef Led)
 Turn selected LED Off.
void BSP_LED_Toggle (Led_TypeDef Led)
 Toggle the selected LED.
void BSP_PB_Init (Button_TypeDef Button, ButtonMode_TypeDef ButtonMode)
 Initialize push button GPIO and EXTI Line.
void BSP_PB_DeInit (Button_TypeDef Button)
 DeInitialize push button.
uint32_t BSP_PB_GetState (Button_TypeDef Button)
 Return the selected button state.
uint8_t BSP_JOY_Init (JOYMode_TypeDef JoyMode)
 Initialize all buttons of the joystick in GPIO or EXTI modes.
void BSP_JOY_DeInit (void)
 DeInitialize all buttons of the joystick.
JOYState_TypeDef BSP_JOY_GetState (void)
 Return the current joystick status.
void BSP_COM_Init (COM_TypeDef COM, UART_HandleTypeDef *huart)
 Initialize COM port.
void BSP_COM_DeInit (COM_TypeDef COM, UART_HandleTypeDef *huart)
 DeInitialize COM port.
uint32_t BSP_POTENTIOMETER_Init (void)
 Init the potentioneter RV2 measurement thanks to ADC.
uint32_t BSP_POTENTIOMETER_DeInit (void)
 DeInitialize the potentioneter RV2 measurement thanks to ADC.
uint32_t BSP_POTENTIOMETER_GetLevel (void)
 Get the potentioneter RV2 measurement thanks to ADC.

Function Documentation

void BSP_COM_DeInit ( COM_TypeDef  COM,
UART_HandleTypeDef *  huart 
)

DeInitialize COM port.

Parameters:
COM,:Specifies the COM port to be deinitialized. This parameter can be one of following parameters:
  • COM1
huart,:pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART peripheral.
Return values:
None

Definition at line 584 of file stm32l4r9i_eval.c.

void BSP_COM_Init ( COM_TypeDef  COM,
UART_HandleTypeDef *  huart 
)

Initialize COM port.

Parameters:
COM,:Specifies the COM port to be configured. This parameter can be one of following parameters:
  • COM1
huart,:pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART peripheral.
Return values:
None

Definition at line 542 of file stm32l4r9i_eval.c.

References COMx_CLK_ENABLE, COMx_RX_GPIO_CLK_ENABLE, and COMx_TX_GPIO_CLK_ENABLE.

void BSP_ErrorHandler ( void  )

Error Handler.

Note:
Defined as a weak function to be overwritten by the application.
Return values:
None

Definition at line 260 of file stm32l4r9i_eval.c.

Referenced by BSP_IDD_Init(), BSP_JOY_Init(), and I2Cx_Error().

uint32_t BSP_GetVersion ( void  )

This method returns the STM32L4R9I EVAL BSP Driver revision.

Return values:
version: 0xXYZR (8bits for each decimal, R for RC)

Definition at line 269 of file stm32l4r9i_eval.c.

References __STM32L4R9I_EVAL_BSP_VERSION.

void BSP_JOY_DeInit ( void  )

DeInitialize all buttons of the joystick.

Return values:
None

Definition at line 482 of file stm32l4r9i_eval.c.

References BSP_IO_ConfigPin(), and JOY_ALL_PINS.

Return the current joystick status.

Return values:
Codeof the joystick key pressed This code can be one of the following values:
  • JOY_NONE
  • JOY_SEL
  • JOY_DOWN
  • JOY_LEFT
  • JOY_RIGHT
  • JOY_UP

Definition at line 498 of file stm32l4r9i_eval.c.

References BSP_IO_ReadPin(), DOWN_JOY_PIN, JOY_ALL_PINS, JOY_DOWN, JOY_LEFT, JOY_NONE, JOY_RIGHT, JOY_SEL, JOY_UP, LEFT_JOY_PIN, RIGHT_JOY_PIN, SEL_JOY_PIN, and UP_JOY_PIN.

uint8_t BSP_JOY_Init ( JOYMode_TypeDef  JoyMode)

Initialize all buttons of the joystick in GPIO or EXTI modes.

Parameters:
JoyMode,:Joystick mode. This parameter can be one of the following values:
  • JOY_MODE_GPIO: Joystick pins will be used as simple IOs
  • JOY_MODE_EXTI: Joystick pins will be connected to EXTI line with interrupt generation capability
Return values:
HAL_OK,:if all initializations are OK. Other value if error.

Definition at line 454 of file stm32l4r9i_eval.c.

References BSP_ErrorHandler(), BSP_IO_ConfigPin(), BSP_IO_Init(), IO_ERROR, JOY_ALL_PINS, JOY_MODE_EXTI, and MFX_IO_ITConfig().

void BSP_LED_DeInit ( Led_TypeDef  Led)

DeInitialize LED GPIO.

Parameters:
Led,:Specifies the Led to be configured. This parameter can be one of following parameters:
  • LED1
  • LED2
  • LED3
  • LED4
Return values:
None

Definition at line 313 of file stm32l4r9i_eval.c.

References LED_PIN, LED_PORT, and LEDx_GPIO_CLK_ENABLE.

void BSP_LED_Init ( Led_TypeDef  Led)

Initialize LED GPIO.

Parameters:
Led,:Specifies the Led to be configured. This parameter can be one of following parameters:
  • LED1
  • LED2
  • LED3
  • LED4
Return values:
None

Definition at line 284 of file stm32l4r9i_eval.c.

References LED_PIN, LED_PORT, and LEDx_GPIO_CLK_ENABLE.

void BSP_LED_Off ( Led_TypeDef  Led)

Turn selected LED Off.

Parameters:
Led,:Specifies the Led to be set off. This parameter can be one of following parameters:
  • LED1
  • LED2
  • LED3
  • LED4
Return values:
None

Definition at line 346 of file stm32l4r9i_eval.c.

References LED_PIN, and LED_PORT.

void BSP_LED_On ( Led_TypeDef  Led)

Turn selected LED On.

Parameters:
Led,:Specifies the Led to be set on. This parameter can be one of following parameters:
  • LED1
  • LED2
  • LED3
  • LED4
Return values:
None

Definition at line 331 of file stm32l4r9i_eval.c.

References LED_PIN, and LED_PORT.

void BSP_LED_Toggle ( Led_TypeDef  Led)

Toggle the selected LED.

Parameters:
Led,:Specifies the Led to be toggled. This parameter can be one of following parameters:
  • LED1
  • LED2
  • LED3
  • LED4
Return values:
None

Definition at line 361 of file stm32l4r9i_eval.c.

References LED_PIN, and LED_PORT.

void BSP_PB_DeInit ( Button_TypeDef  Button)

DeInitialize push button.

Parameters:
Button,:Button to be deinitialized. This parameter can be one of the following values:
  • BUTTON_WAKEUP: Wakeup/Tamper Push Button
Return values:
None

Definition at line 419 of file stm32l4r9i_eval.c.

References BUTTON_PORT, BUTTON_WAKEUP, and BUTTONx_GPIO_CLK_ENABLE.

uint32_t BSP_PB_GetState ( Button_TypeDef  Button)

Return the selected button state.

Parameters:
Button,:Button to be checked. This parameter can be one of the following values:
  • BUTTON_WAKEUP: Wakeup/Tamper Push Button
Return values:
Buttonstate

Definition at line 440 of file stm32l4r9i_eval.c.

References BUTTON_PORT.

void BSP_PB_Init ( Button_TypeDef  Button,
ButtonMode_TypeDef  ButtonMode 
)

Initialize push button GPIO and EXTI Line.

Parameters:
Button,:Button to be configured. This parameter can be one of the following values:
  • BUTTON_WAKEUP: Wakeup/Tamper Push Button
ButtonMode,:Button mode requested. This parameter can be one of the following values:
  • BUTTON_MODE_GPIO: Button will be used as simple IO
  • BUTTON_MODE_EXTI: Button will be connected to EXTI line with interrupt generation capability
Return values:
None

Definition at line 378 of file stm32l4r9i_eval.c.

References BUTTON_MODE_GPIO, BUTTON_PORT, BUTTON_WAKEUP, and BUTTONx_GPIO_CLK_ENABLE.

uint32_t BSP_POTENTIOMETER_DeInit ( void  )

DeInitialize the potentioneter RV2 measurement thanks to ADC.

Limitations : the potentiometer are exclusive with MFX, Audio codex, OctoSPIP1, Debugging connector and MC operation. And they are mutually exclusive. Please deinit all these components before usage.

Return values:
BSP_POTENTIOMETER_OKif no error

Definition at line 668 of file stm32l4r9i_eval.c.

References BSP_POTENTIOMETER_ERROR, and BSP_POTENTIOMETER_OK.

uint32_t BSP_POTENTIOMETER_GetLevel ( void  )

Get the potentioneter RV2 measurement thanks to ADC.

Limitations : the potentiometer are exclusive with MFX, Audio codex, OctoSPIP1, Debugging connector and MC operation. And they are mutually exclusive. Please deinit all these components before usage.

Return values:
valueif no error else 0xFFFFFFFF

Definition at line 682 of file stm32l4r9i_eval.c.

References ADCx_POLL_TIMEOUT, and BSP_POTENTIOMETER_ERROR.

uint32_t BSP_POTENTIOMETER_Init ( void  )

Init the potentioneter RV2 measurement thanks to ADC.

Limitations : the potentiometer are exclusive with MFX, Audio codex, OctoSPIP1, Debugging connector and MC operation. And they are mutually exclusive. Please deinit all these components before usage.

Return values:
BSP_POTENTIOMETER_OKif no error

Definition at line 601 of file stm32l4r9i_eval.c.

References ADCx, ADCx_CHANNEL, ADCx_CHANNEL_GPIO_CLK_ENABLE, ADCx_CHANNEL_GPIO_PORT, ADCx_CHANNEL_PIN, ADCx_CLK_ENABLE, BSP_POTENTIOMETER_ERROR, and BSP_POTENTIOMETER_OK.

Generated on Thu Oct 12 2017 10:54:00 for STM32L4R9I_EVAL BSP User Manual by   doxygen 1.7.6.1