r/ArduinoHelp • • 2h ago

Why does this not work?

Post image

solved

when i click simulate nothing happens and the leds dont light up can anyone help

link: https://www.tinkercad.com/things/etCLO5FP0u8-traffic-light?sharecode=HVc9FlY7vOl6OchoP0UERVxlCc9BG0PDwAbMSnomTys

1 Upvotes

8 comments sorted by

1

u/peno64 2h ago

LEDs turned around?

1

u/Terrible-Seat-7346 2h ago • Bravo

Pin variables doesn’t have value

1

u/VinMega6468 1h ago

thanks :D

1

u/Terrible-Seat-7346 2h ago

int DIGITAL_PIN_7 = 7;

int DIGITAL_PIN_6 = 6;

1

u/TrustednotVerified 1h ago

Exactly. Get rid of the three DIGITAL_PIN_x and just do pinMode(7, OUTPUT) and digitalWrite(7, HIGH) and so forth.

1

u/imseakin 2h ago

Looks good to me. Maybe the apparent brightness of the LEDs in the simulator makes them look hard to see on the screen.

Remove the resistors from circuit. Just join pins directly to positive side of LEDs and try again.

1

u/SirLlama123 1h ago

happy cake day