RC CAR 3D Print Working Programable Race Light Arduino Project Drag Race Tree
Car Photography Car Photography
5.2K subscribers
1,024 views
29

 Published On May 12, 2023

#arduino #dragracing #rccar

https://www.thingiverse.com/thing:602...

green lights = https://www.amazon.com/dp/B07H5KS24J

white amber and red lights = https://www.amazon.com/dp/B071V9WQS9

relay board = Xiuxin 2pcs 5V 8 Channel Relay Module Board

2560 mega starter kit https://www.ebay.com/itm/144946798544

CODE:

int White = 7; // LED connected to digital pin 7
int Yellow = 6; // LED connected to digital pin 6
int Yellow1 = 5; // LED connected to digital pin 5
int Yellow2 = 4; // LED connected to digital pin 4
int Green = 3; // LED connected to digital pin 3

void setup()
{
pinMode(White, OUTPUT);
pinMode(Yellow, OUTPUT);
pinMode(Yellow1, OUTPUT);
pinMode(Yellow2, OUTPUT);
pinMode(Green, OUTPUT);

digitalWrite(White, HIGH); // sets the LED off
digitalWrite(Yellow, HIGH); // sets the LED off
digitalWrite(Yellow1, HIGH); // sets the LED off
digitalWrite(Yellow2, HIGH); // sets the LED off
digitalWrite(Green, HIGH); // sets the LED off
digitalWrite(White, LOW); // sets the LED on
delay(2000); // waits for a second
digitalWrite(Yellow, LOW); // sets the LED on
delay(500); // waits for a second
digitalWrite(Yellow1, LOW); // sets the LED on
delay(500); // waits for a second
digitalWrite(Yellow2, LOW); // sets the LED on
delay(500); // waits for a second
digitalWrite(Green, LOW); // all LED off
digitalWrite(White, HIGH);
digitalWrite(Yellow, HIGH);
digitalWrite(Yellow1, HIGH);
digitalWrite(Yellow2, HIGH);
delay(5000); // wait and hold Green Light
digitalWrite(Green, HIGH);
}

void loop()
{

}

show more

Share/Embed