stm32f207vc新⼿⼊门!跑马灯的程序烧录进去跑不
了,求⼤神帮看下代码!
话不多说,下⾯是main.c
#define PERIPH_BASE ((unsigned int)0x40000000)
//总线基址
#define APB1PERIPH_BASE PERIPH_BASE
#define APB2PERIPH_BASE ((unsigned int)PERIPH_BASE + 0x00010000)
#define AHB1PERIPH_BASE ((unsigned int)PERIPH_BASE + 0X00020000)
#define AHB2PERIPH_BASE ((unsigned int)PERIPH_BASE + 0x10000000)
//时钟基址
#define RCC_BASE ((unsigned int)PERIPH_BASE + 0x00020000 + 0x3800)
/
/端⼝基址
#define GPIOE_BASE ((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000)
//寄存器基址
cf怎么进不去#define RCC_AHB1ENR (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x3800 + 0x30))
#define GPIOE_BSRRL (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x38))
#define GPIOE_BSRRH (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x1a))
#define GPIOE_MODER (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x00))
#define GPIOE_OTYPER (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x04))
#define GPIOE_OSPEEDR (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x08))
#define GPIOE_PUPDR (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x0c))
#define GPIOE_BSSR (*(unsigned int *)((unsigned int)PERIPH_BASE + 0x00020000 + 0x1000 + 0x30))
unsigned short int Delay_ms(unsigned short int count);
发布评论