₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,325,443 members, 8,422,070 topics. Date: Sunday, 07 June 2026 at 04:07 PM

Toggle theme

Roemai's Posts

Nairaland ForumRoemai's ProfileRoemai's Posts

1 (of 1 pages)

Science/TechnologyGetting Started With Arduino: Lighting Up The Leds. by Roemai(op): 10:30pm On Jan 17, 2024
In this beginner-friendly tutorial, we'll dive into the fundamentals of Arduino programming and circuitry by learning how to light up LEDs. We'll start with a single LED and gradually progress to building a simple traffic light system using the versatile Arduino microcontroller.

Blinking a Single LED
Materials Needed:
Arduino board (e.g., Arduino Uno)
Breadboard

LED (any color)

Jumper wires

Arduino uno smd board







Wiring Connections:

Connect the longer leg (anode) of the LED to digital pin 13 on the Arduino.

Connect the shorter leg (cathode) of the LED to the ground (GND) on the Arduino.

Power up the Arduino board.









Arduino Sketch:

void setup() {

pinMode(13, OUTPUT); // Set digital pin 13 as an output

}

void loop() {

digitalWrite(13, HIGH); // Turn on the LED

delay(1000); // Wait for 1 second

digitalWrite(13, LOW); // Turn off the LED

delay(1000); // Wait for 1 second

}

Explanation: This simple code uses the built-in LED on the Arduino board to blink at a 1-second interval. The digitalWrite function is used to turn the LED on and off.

Controlling Multiple LEDs
Now that we've mastered a single LED, let's move on to controlling multiple LEDs. We'll create a circuit with three LEDs, each lighting up in sequence.

Continue tinkering here: https://roemai.hashnode.dev/getting-started-with-arduino-lighting-up-the-leds

1 (of 1 pages)