アート
美容とウェルネス
工芸
文化と歴史
エンターテインメント
環境
食品と飲料
リバースエンジニアリング
科学
スポーツ
テクノロジー
ウェアラブル

Driving Multiple LEDs — SIK Circuit 4
Make eight LEDs dance! Learn about arrays, for loops, and multiple output patterns including chase, ping-pong, marquee, and random blink effects.
手順
1
1
Parts & Introduction
Parts & Introduction
This experiment uses 8 LEDs to create light patterns. You'll learn about arrays (grouping related variables) and for loops (repeating actions efficiently). The sketch includes 6 different animation functions you can try.
Parts Needed
- 1x Arduino Uno + USB cable
- 1x Breadboard
- 8x LEDs (any color)
- 8x 330Ω Resistors
- 9x Jumper Wires
このステップの材料:
SparkFun Inventors Kit - V3.21 キットArduino Uno R31 個
Breadboard1 個
5mm LED8 個
330 Ohm Resistor8 個
Jumper Wires9 個必要な工具:
Computer with Arduino IDE
2
2
Hardware Hookup
Hardware Hookup
Wiring Instructions
- Place 8 LEDs in a row on the breadboard.
- For each LED, connect the negative leg (shorter) through a 330Ω resistor to GND.
- Connect the positive leg (longer) of each LED to Arduino digital pins 2 through 9 (LED 1 = pin 2, LED 2 = pin 3, etc.).
- Connect the GND rail on the breadboard to Arduino GND.
Tip: Keep the LEDs neatly spaced for the best visual effect.
このステップの材料:
5mm LED8 個
330 Ohm Resistor8 個Breadboard1 個
Jumper Wires9 個3
3
Arduino Code
Arduino Code
Open the Arduino IDE and upload the following sketch to your Arduino board.
multiple_leds.inoarduino
このステップの材料:
Arduino Uno R31 個
必要な工具:
Computer with Arduino IDE
4
4
Test & Experiment
Test & Experiment
What You Should See
All 8 LEDs light up one after another, then turn off in reverse order. This repeats continuously.
Troubleshooting
- Some LEDs don't light: Easy to insert an LED backwards. Check polarity.
- Out of sequence: With 8 wires, it's easy to cross a couple. Verify LED 1 is on pin 2, then each pin in order.
- Starting fresh: Sometimes pulling everything out and re-wiring is faster than debugging.
Experiments to Try
- Uncomment the other functions in
loop()to try:oneOnAtATime(),pingPong(),marquee(),randomLED(). - Create your own animation pattern!
- Modify the delay times to change the speed.
材料
6- ¥164
見積もり合計
¥253CC0 パブリックドメイン
このブループリントはCC0で公開されています。許可を求めずに、自由にコピー、修正、配布、あらゆる目的で使用できます。
メイカーを応援するには、ブループリント経由で製品を購入してください。メイカーには メイカーコミッション がベンダーにより設定されています。または、このブループリントの新しいイテレーションを作成し、自分のブループリントにコネクションとして含めて収益を共有できます。