123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143 |
- #ifndef __STM32F0XX_MISC_H
- #define __STM32F0XX_MISC_H
- #ifdef __cplusplus
- extern "C" {
- #endif
- #include "stm32f0xx.h"
- typedef struct
- {
- uint8_t NVIC_IRQChannel;
- uint8_t NVIC_IRQChannelPriority;
- FunctionalState NVIC_IRQChannelCmd;
-
- } NVIC_InitTypeDef;
- #define NVIC_LP_SEVONPEND ((uint8_t)0x10)
- #define NVIC_LP_SLEEPDEEP ((uint8_t)0x04)
- #define NVIC_LP_SLEEPONEXIT ((uint8_t)0x02)
- #define IS_NVIC_LP(LP) (((LP) == NVIC_LP_SEVONPEND) || \
- ((LP) == NVIC_LP_SLEEPDEEP) || \
- ((LP) == NVIC_LP_SLEEPONEXIT))
- #define IS_NVIC_PRIORITY(PRIORITY) ((PRIORITY) < 0x04)
- #define SysTick_CLKSource_HCLK_Div8 ((uint32_t)0xFFFFFFFB)
- #define SysTick_CLKSource_HCLK ((uint32_t)0x00000004)
- #define IS_SYSTICK_CLK_SOURCE(SOURCE) (((SOURCE) == SysTick_CLKSource_HCLK) || \
- ((SOURCE) == SysTick_CLKSource_HCLK_Div8))
-
- void NVIC_Init(NVIC_InitTypeDef* NVIC_InitStruct);
- void NVIC_SystemLPConfig(uint8_t LowPowerMode, FunctionalState NewState);
- void SysTick_CLKSourceConfig(uint32_t SysTick_CLKSource);
- #ifdef __cplusplus
- }
- #endif
- #endif
|