STM32F4xx HAL Documentation
Hardware Abstraction Layer for STM32F4 familiy
|
Initialization and Configuration functions. More...
Functions | |
HAL_StatusTypeDef | HAL_SMBUS_Init (SMBUS_HandleTypeDef *hsmbus) |
Initializes the SMBUS according to the specified parameters in the SMBUS_InitTypeDef and initialize the associated handle. | |
HAL_StatusTypeDef | HAL_SMBUS_DeInit (SMBUS_HandleTypeDef *hsmbus) |
DeInitializes the SMBUS peripheral. | |
void | HAL_SMBUS_MspInit (SMBUS_HandleTypeDef *hsmbus) |
Initialize the SMBUS MSP. | |
void | HAL_SMBUS_MspDeInit (SMBUS_HandleTypeDef *hsmbus) |
DeInitialize the SMBUS MSP. | |
Initialization and Configuration functions.
=============================================================================== ##### Initialization and de-initialization functions ##### =============================================================================== [..] This subsection provides a set of functions allowing to initialize and deinitialize the SMBUSx peripheral: (+) User must Implement HAL_SMBUS_MspInit() function in which he configures all related peripherals resources (CLOCK, GPIO, IT and NVIC). (+) Call the function HAL_SMBUS_Init() to configure the selected device with the selected configuration: (++) Communication Speed (++) Addressing mode (++) Own Address 1 (++) Dual Addressing mode (++) Own Address 2 (++) General call mode (++) Nostretch mode (++) Packet Error Check mode (++) Peripheral mode (+) Call the function HAL_SMBUS_DeInit() to restore the default configuration of the selected SMBUSx peripheral.
HAL_StatusTypeDef HAL_SMBUS_Init | ( | SMBUS_HandleTypeDef * | hsmbus | ) |
#include <stm32f4xx_hal_smbus.h>
Initializes the SMBUS according to the specified parameters in the SMBUS_InitTypeDef and initialize the associated handle.
hsmbus | pointer to a SMBUS_HandleTypeDef structure that contains the configuration information for the specified SMBUS |
HAL | status |
Definition at line 282 of file stm32f4xx_hal_smbus.c.
References __HAL_SMBUS_DISABLE, __HAL_SMBUS_ENABLE, SMBUS_InitTypeDef::AddressingMode, SMBUS_InitTypeDef::AnalogFilter, assert_param, SMBUS_InitTypeDef::ClockSpeed, SMBUS_InitTypeDef::DualAddressMode, __SMBUS_HandleTypeDef::ErrorCode, SMBUS_InitTypeDef::GeneralCallMode, HAL_ERROR, HAL_OK, HAL_RCC_GetPCLK1Freq(), HAL_SMBUS_AbortCpltCallback(), HAL_SMBUS_AddrCallback(), HAL_SMBUS_ERROR_NONE, HAL_SMBUS_ErrorCallback(), HAL_SMBUS_ListenCpltCallback(), HAL_SMBUS_MasterRxCpltCallback(), HAL_SMBUS_MasterTxCpltCallback(), HAL_SMBUS_MODE_NONE, HAL_SMBUS_MspInit(), HAL_SMBUS_SlaveRxCpltCallback(), HAL_SMBUS_SlaveTxCpltCallback(), HAL_SMBUS_STATE_BUSY, HAL_SMBUS_STATE_READY, HAL_SMBUS_STATE_RESET, HAL_UNLOCKED, __SMBUS_HandleTypeDef::Init, __SMBUS_HandleTypeDef::Instance, IS_SMBUS_ADDRESSING_MODE, IS_SMBUS_CLOCK_SPEED, IS_SMBUS_DUAL_ADDRESS, IS_SMBUS_GENERAL_CALL, IS_SMBUS_NO_STRETCH, IS_SMBUS_OWN_ADDRESS1, IS_SMBUS_OWN_ADDRESS2, IS_SMBUS_PEC, IS_SMBUS_PERIPHERAL_MODE, __SMBUS_HandleTypeDef::Lock, __SMBUS_HandleTypeDef::Mode, SMBUS_InitTypeDef::NoStretchMode, SMBUS_InitTypeDef::OwnAddress1, SMBUS_InitTypeDef::OwnAddress2, SMBUS_InitTypeDef::PacketErrorCheckMode, SMBUS_InitTypeDef::PeripheralMode, __SMBUS_HandleTypeDef::PreviousState, SMBUS_FREQRANGE, SMBUS_RISE_TIME, SMBUS_SPEED_STANDARD, SMBUS_STATE_NONE, __SMBUS_HandleTypeDef::State, and __SMBUS_HandleTypeDef::XferPEC.
HAL_StatusTypeDef HAL_SMBUS_DeInit | ( | SMBUS_HandleTypeDef * | hsmbus | ) |
#include <stm32f4xx_hal_smbus.h>
DeInitializes the SMBUS peripheral.
hsmbus | pointer to a SMBUS_HandleTypeDef structure that contains the configuration information for the specified SMBUS. |
HAL | status |
Definition at line 395 of file stm32f4xx_hal_smbus.c.
References __HAL_SMBUS_DISABLE, __HAL_UNLOCK, assert_param, __SMBUS_HandleTypeDef::ErrorCode, HAL_ERROR, HAL_OK, HAL_SMBUS_ERROR_NONE, HAL_SMBUS_MODE_NONE, HAL_SMBUS_MspDeInit(), HAL_SMBUS_STATE_BUSY, HAL_SMBUS_STATE_RESET, __SMBUS_HandleTypeDef::Instance, __SMBUS_HandleTypeDef::Mode, __SMBUS_HandleTypeDef::PreviousState, SMBUS_STATE_NONE, and __SMBUS_HandleTypeDef::State.
__weak void HAL_SMBUS_MspInit | ( | SMBUS_HandleTypeDef * | hsmbus | ) |
#include <stm32f4xx_hal_smbus.h>
Initialize the SMBUS MSP.
hsmbus | pointer to a SMBUS_HandleTypeDef structure that contains the configuration information for the specified SMBUS |
None |
Definition at line 441 of file stm32f4xx_hal_smbus.c.
References UNUSED.
Referenced by HAL_SMBUS_Init().
__weak void HAL_SMBUS_MspDeInit | ( | SMBUS_HandleTypeDef * | hsmbus | ) |
#include <stm32f4xx_hal_smbus.h>
DeInitialize the SMBUS MSP.
hsmbus | pointer to a SMBUS_HandleTypeDef structure that contains the configuration information for the specified SMBUS |
None |
Definition at line 456 of file stm32f4xx_hal_smbus.c.
References UNUSED.
Referenced by HAL_SMBUS_DeInit().