阿正的网易云音乐 - 创建于 2017

一个大学生的学习心得,与君共勉。

从arduino到32单片机的转型

 1 #include "stm32f10x.h"
 2 #include "led.h"
 3 #include "delay.h"
 4  int main(void)
 5  {
 6 LED_Init();
 7 delay_init();
 8    while(1)
 9   {
10     GPIO_ResetBits(GPIOA,GPIO_Pin_8); //LED0Êä³öµÍ
11         GPIO_SetBits(GPIOD,GPIO_Pin_2);//LED1Êä³ö¸ß
12         delay_ms(1000);
13         GPIO_SetBits(GPIOA,GPIO_Pin_8);//LED0Êä³ö¸ß
14         GPIO_ResetBits(GPIOD,GPIO_Pin_2);//LED1Êä³öµÍ
15         delay_ms(1000);    
16    }
17  }

 

posted @ 2017-12-24 13:07  阿♛正  阅读(416)  评论(0编辑  收藏  举报