📄 init_config.h
字号:
#ifndef _INIT_CONFIG_H
#define _INIT_CONFIG_H
#include"stm32f10x.h"
#include"stdio.h"
//ErrorStatus HSEStartUpStatus;
//NVIC_InitTypeDef NVIC_InitStruct;
//EXTI_InitTypeDef EXTI_InitStructure;
//TIM_TimeBaseInitTypeDef TIM_TimeBaseStructure;
//TIM_OCInitTypeDef TIM_OCInitStructure;
/*******************************************************************************
* Function Name : RCC_Configuration
* Description : Configures System Clocks
*******************************************************************************/
void RCC_Configuration(void);
/*******************************************************************************
* Function Name : GPIO_Configuration
* Description : Configures GPIO Modes
*******************************************************************************/
void GPIO_Configuration(void);
/*******************************************************************************
* Function Name : NVIC_Configuration
* Description : Configures NVIC Modes for T1
*******************************************************************************/
void NVIC_Configuration(void);
/*******************************************************************************
* Function Name : USART_Configuration
* Description : Configures the USART1.
*******************************************************************************/
void USART_Configuration(void);
/*******************************************************************************
* Function Name : fputc
* Description : Retargets the C library printf function to the USART.
*******************************************************************************/
int fputc(int ch, FILE *f);
/*******************************************************************************
* Function Name : BSP_Init
* Description : Configures RCC,GPIO,NVIC
*******************************************************************************/
//void BSP_Init(void);
/*******************************************************************************
* Function Name : delay_nus
* Description : delay n us
*******************************************************************************/
void delay_nus(u32 n); //延时n us: n>=6,最小延时单位6us
/*******************************************************************************
* Function Name : delay_nms
* Description : delay n ms
*******************************************************************************/
void delay_nms(u32 n); //延时n ms
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -