#define B_COLOR 10
#define G_COLOR 11
#define R_COLOR 12
void setup()
{
pinMode(B_COLOR,OUTPUT);
pinMode(G_COLOR,OUTPUT);
pinMode(R_COLOR,OUTPUT);
}
void loop()
{
digitalWrite(B_COLOR,HIGH);
delay(1000);
digitalWrite(B_COLOR,LOW);
delay(1000);
digitalWrite(G_COLOR,HIGH);
delay(1000);
digitalWrite(G_COLOR,LOW);
delay(1000);
digitalWrite(R_COLOR,HIGH);
delay(1000);
digitalWrite(R_COLOR,LOW);
delay(1000);
}
arduino随笔(2)
最新推荐文章于 2020-01-28 21:06:49 发布