21#ifndef STM32H7xx_HAL_DEF
22#define STM32H7xx_HAL_DEF
65#define HAL_MAX_DELAY 0xFFFFFFFFU
67#define HAL_IS_BIT_SET(REG, BIT) (((REG) & (BIT)) == (BIT))
68#define HAL_IS_BIT_CLR(REG, BIT) (((REG) & (BIT)) == 0U)
70#define __HAL_LINKDMA(__HANDLE__, __PPP_DMA_FIELD__, __DMA_HANDLE__) \
72 (__HANDLE__)->__PPP_DMA_FIELD__ = &(__DMA_HANDLE__); \
73 (__DMA_HANDLE__).Parent = (__HANDLE__); \
77#define UNUSED(x) ((void)(x))
95#define __HAL_RESET_HANDLE_STATE(__HANDLE__) ((__HANDLE__)->State = 0)
98 #error " USE_RTOS should be 0 in the current HAL release "
100 #define __HAL_LOCK(__HANDLE__) \
102 if((__HANDLE__)->Lock == HAL_LOCKED) \
108 (__HANDLE__)->Lock = HAL_LOCKED; \
112 #define __HAL_UNLOCK(__HANDLE__) \
114 (__HANDLE__)->Lock = HAL_UNLOCKED; \
119#if defined (__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050)
121 #define __weak __attribute__((weak))
124 #define __packed __attribute__((packed))
126#elif defined ( __GNUC__ ) && !defined (__CC_ARM)
128 #define __weak __attribute__((weak))
131 #define __packed __attribute__((__packed__))
137#if defined (__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050)
138 #ifndef __ALIGN_BEGIN
139 #define __ALIGN_BEGIN
142 #define __ALIGN_END __attribute__ ((aligned (4)))
144#elif defined ( __GNUC__ ) && !defined (__CC_ARM)
146 #define __ALIGN_END __attribute__ ((aligned (4)))
148 #ifndef __ALIGN_BEGIN
149 #define __ALIGN_BEGIN
155 #ifndef __ALIGN_BEGIN
156 #if defined (__CC_ARM)
157 #define __ALIGN_BEGIN __align(4)
158 #elif defined (__ICCARM__)
159 #define __ALIGN_BEGIN
165#if defined (__GNUC__)
166 #define ALIGN_32BYTES(buf) buf __attribute__ ((aligned (32)))
167#elif defined (__ICCARM__)
168 #define ALIGN_32BYTES(buf) _Pragma("data_alignment=32") buf
169#elif defined (__CC_ARM)
170 #define ALIGN_32BYTES(buf) __align(32) buf
176#if defined ( __CC_ARM ) || (defined (__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050))
188#elif defined ( __ICCARM__ )
193#define __RAM_FUNC __ramfunc
195#elif defined ( __GNUC__ )
201#define __RAM_FUNC __attribute__((section(".RamFunc")))
208#if defined ( __CC_ARM ) || (defined (__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050)) || defined ( __GNUC__ )
212#define __NOINLINE __attribute__ ( (noinline) )
214#elif defined ( __ICCARM__ )
218#define __NOINLINE _Pragma("optimize = no_inline")
This file contains aliases definition for the STM32Cube HAL constants macros and functions maintained...
CMSIS STM32H7xx Device Peripheral Access Layer Header File.
HAL_StatusTypeDef
HAL Status structures definition.
Definition: stm32h7xx_hal_def.h:47
HAL_LockTypeDef
HAL Lock structures definition.
Definition: stm32h7xx_hal_def.h:58