Notice
Recent Posts
Recent Comments
Link
반응형
관리 메뉴

eng-life 님의 블로그

Arduino Uno: LED Visual Display (4) 본문

ENGR

Arduino Uno: LED Visual Display (4)

eng-life 2025. 6. 2. 07:58
반응형

 

Duplicate the LED Circuit three more times.

1. Construct the circuit using a breadboard as shown in the diagram below.

2. Note negative leads and connect to GND Rail.

3. Keep color order.

4. Tie all resistors (1 kΩ) together. 

5. GND should still be connected to Arduino GND

6. Red wire should still be connected to Arduino Pin 9

7. Upload the code and verify all LEDs blink

 

8. Tinker until all are this point.


Now that we know all the LEDs on our Dispaly are working, let's use the Arduino to control each LED individually.

 

1. Remove wires connecting resistors and Pin 9 from Arduino.

2. Connect Yellow LED resistor to Pin 5

3. Connect Red LED resistor to Pin 4

4. Connect Blue LED resistor to Pin 3

5. Connect Green LED resistor to Pin 2

6. Modify your sketch.

 - "Comment out" int LED = 9;

 - pinMode for pins 2, 3, 4, and 5 as OUTPUTs.

7. Turn off LEDs at start of loop: digitalWrite(Pin #, LOW)

8. Turn on individual LEDs as shown:  digitalWrite(Pin #, HIGH)

9. Compile code and check for messages.

10. Upload code to Arduino

      - Should see Green LED turn on, then Blue, then Red, then Yellow

      - Tinker with the delay times until all terms here.

11. Save your Sketch file. 

'ENGR' 카테고리의 다른 글

Arduino Uno: Potentiometer (6)  (1) 2025.06.03
Arduino Uno: Analog vs. Digital (5)  (0) 2025.06.03
Arduino Uno: Blink an LED (3)  (3) 2025.06.02
Arduino Uno Communication (2)  (1) 2025.06.01
Arduino Uno Overview (1)  (2) 2025.06.01