STM32F479xx HAL User Manual
|
00001 /** 00002 ****************************************************************************** 00003 * @file stm32f4xx_hal_i2c_ex.h 00004 * @author MCD Application Team 00005 * @brief Header file of I2C HAL Extension module. 00006 ****************************************************************************** 00007 * @attention 00008 * 00009 * <h2><center>© Copyright (c) 2016 STMicroelectronics. 00010 * All rights reserved.</center></h2> 00011 * 00012 * This software component is licensed by ST under BSD 3-Clause license, 00013 * the "License"; You may not use this file except in compliance with the 00014 * License. You may obtain a copy of the License at: 00015 * opensource.org/licenses/BSD-3-Clause 00016 * 00017 ****************************************************************************** 00018 */ 00019 00020 /* Define to prevent recursive inclusion -------------------------------------*/ 00021 #ifndef __STM32F4xx_HAL_I2C_EX_H 00022 #define __STM32F4xx_HAL_I2C_EX_H 00023 00024 #ifdef __cplusplus 00025 extern "C" { 00026 #endif 00027 00028 #if defined(I2C_FLTR_ANOFF)&&defined(I2C_FLTR_DNF) 00029 /* Includes ------------------------------------------------------------------*/ 00030 #include "stm32f4xx_hal_def.h" 00031 00032 /** @addtogroup STM32F4xx_HAL_Driver 00033 * @{ 00034 */ 00035 00036 /** @addtogroup I2CEx 00037 * @{ 00038 */ 00039 00040 /* Exported types ------------------------------------------------------------*/ 00041 /* Exported constants --------------------------------------------------------*/ 00042 /** @defgroup I2CEx_Exported_Constants I2C Exported Constants 00043 * @{ 00044 */ 00045 00046 /** @defgroup I2CEx_Analog_Filter I2C Analog Filter 00047 * @{ 00048 */ 00049 #define I2C_ANALOGFILTER_ENABLE 0x00000000U 00050 #define I2C_ANALOGFILTER_DISABLE I2C_FLTR_ANOFF 00051 /** 00052 * @} 00053 */ 00054 00055 /** 00056 * @} 00057 */ 00058 00059 /* Exported macro ------------------------------------------------------------*/ 00060 /* Exported functions --------------------------------------------------------*/ 00061 /** @addtogroup I2CEx_Exported_Functions 00062 * @{ 00063 */ 00064 00065 /** @addtogroup I2CEx_Exported_Functions_Group1 00066 * @{ 00067 */ 00068 /* Peripheral Control functions ************************************************/ 00069 HAL_StatusTypeDef HAL_I2CEx_ConfigAnalogFilter(I2C_HandleTypeDef *hi2c, uint32_t AnalogFilter); 00070 HAL_StatusTypeDef HAL_I2CEx_ConfigDigitalFilter(I2C_HandleTypeDef *hi2c, uint32_t DigitalFilter); 00071 /** 00072 * @} 00073 */ 00074 00075 /** 00076 * @} 00077 */ 00078 /* Private types -------------------------------------------------------------*/ 00079 /* Private variables ---------------------------------------------------------*/ 00080 /* Private constants ---------------------------------------------------------*/ 00081 /** @defgroup I2CEx_Private_Constants I2C Private Constants 00082 * @{ 00083 */ 00084 00085 /** 00086 * @} 00087 */ 00088 00089 /* Private macros ------------------------------------------------------------*/ 00090 /** @defgroup I2CEx_Private_Macros I2C Private Macros 00091 * @{ 00092 */ 00093 #define IS_I2C_ANALOG_FILTER(FILTER) (((FILTER) == I2C_ANALOGFILTER_ENABLE) || \ 00094 ((FILTER) == I2C_ANALOGFILTER_DISABLE)) 00095 #define IS_I2C_DIGITAL_FILTER(FILTER) ((FILTER) <= 0x0000000FU) 00096 /** 00097 * @} 00098 */ 00099 00100 /** 00101 * @} 00102 */ 00103 00104 /** 00105 * @} 00106 */ 00107 00108 #endif 00109 00110 #ifdef __cplusplus 00111 } 00112 #endif 00113 00114 #endif /* __STM32F4xx_HAL_I2C_EX_H */ 00115 00116 00117 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/