GPIO_Init(GPIOB, &GPIO_InitStructure); 1. 其中GPIO_InitStructure我们已经知道了它是一个结构体数据,它都有三个成员,上面都有详细描述,但我们还需要知道它是用在哪的,给谁用的,这个在GPIO_Init()函数里面写着给GPIOB用,我们先来看GPIOB这个东西它是什么。 #define GPIOB ((GPIO_TypeDef *) GPIOB_BASE)...
GPIO_InitTypeDef GPIO_InitStructure; 此结构体的定义是在stm32f10x_gpio.h文件中,其中包括3个成员。 typedef struct { uint16_t GPIO_Pin; GPIOSpeed_TypeDef GPIO_Speed; GPIOMode_TypeDef GPIO_Mode; }GPIO_InitTypeDef; (1)uint16_t GPIO_Pin;来指定GPIO的哪个或哪些引脚,取值参见stm32f10x_gpio....