Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Initialization and de-initialization functions
[I2C Exported Functions]
Initialization and Configuration functions. More...
Functions | |
HAL_StatusTypeDef | HAL_I2C_Init (I2C_HandleTypeDef *hi2c) |
Initializes the I2C according to the specified parameters in the I2C_InitTypeDef and initialize the associated handle. | |
HAL_StatusTypeDef | HAL_I2C_DeInit (I2C_HandleTypeDef *hi2c) |
DeInitialize the I2C peripheral. | |
__weak void | HAL_I2C_MspInit (I2C_HandleTypeDef *hi2c) |
Initialize the I2C MSP. | |
__weak void | HAL_I2C_MspDeInit (I2C_HandleTypeDef *hi2c) |
DeInitialize the I2C MSP. |
Detailed Description
Initialization and Configuration functions.
=============================================================================== ##### Initialization and de-initialization functions ##### =============================================================================== [..] This subsection provides a set of functions allowing to initialize and deinitialize the I2Cx peripheral: (+) User must Implement HAL_I2C_MspInit() function in which he configures all related peripherals resources (CLOCK, GPIO, DMA, IT and NVIC ). (+) Call the function HAL_I2C_Init() to configure the selected device with the selected configuration: (++) Clock Timing (++) Own Address 1 (++) Addressing mode (Master, Slave) (++) Dual Addressing mode (++) Own Address 2 (++) Own Address 2 Mask (++) General call mode (++) Nostretch mode (+) Call the function HAL_I2C_DeInit() to restore the default configuration of the selected I2Cx peripheral.
Function Documentation
HAL_StatusTypeDef HAL_I2C_DeInit | ( | I2C_HandleTypeDef * | hi2c ) |
DeInitialize the I2C peripheral.
- Parameters:
-
hi2c Pointer to a I2C_HandleTypeDef structure that contains the configuration information for the specified I2C.
- Return values:
-
HAL status
Definition at line 487 of file stm32l4xx_hal_i2c.c.
HAL_StatusTypeDef HAL_I2C_Init | ( | I2C_HandleTypeDef * | hi2c ) |
Initializes the I2C according to the specified parameters in the I2C_InitTypeDef and initialize the associated handle.
- Parameters:
-
hi2c Pointer to a I2C_HandleTypeDef structure that contains the configuration information for the specified I2C.
- Return values:
-
HAL status
Definition at line 402 of file stm32l4xx_hal_i2c.c.
__weak void HAL_I2C_MspDeInit | ( | I2C_HandleTypeDef * | hi2c ) |
DeInitialize the I2C MSP.
- Parameters:
-
hi2c Pointer to a I2C_HandleTypeDef structure that contains the configuration information for the specified I2C.
- Return values:
-
None
Definition at line 539 of file stm32l4xx_hal_i2c.c.
__weak void HAL_I2C_MspInit | ( | I2C_HandleTypeDef * | hi2c ) |
Initialize the I2C MSP.
- Parameters:
-
hi2c Pointer to a I2C_HandleTypeDef structure that contains the configuration information for the specified I2C.
- Return values:
-
None
Definition at line 523 of file stm32l4xx_hal_i2c.c.
Generated on Tue Jul 12 2022 18:10:45 by
