LoginSignup
5
4

More than 5 years have passed since last update.

arduinoで簡易クリスマスツリーを作る

Last updated at Posted at 2015-12-23

コンセプトと概要

妻がクリスマスツリーが欲しいと言ったので、自作しました。
ツリーの醍醐味である電飾の点滅は100均のLEDケーブルをarduinoで制御することで実現。

用意するもの

  • 木 600円
  • arduino(今回はarduino unoを使用)
  • LEDケーブル 100円
  • 抵抗や導線、ブレッドボード(あればよし)
  • ツリー用装飾品 100円

arduinoは家にあったものを使用したので、
木と装飾代の800円で今年の我が家のツリーが完成しました。

手順

  1. arduinoとLEDケーブルをつなげる。 arduinoの13pinとGNDをLEDケーブルの電池をはめ込む「+」と「ー」に接続。 ※過電流対策にブレッドボードなどを使って間に抵抗を挟むことをお勧めします
  2. arduinoに以下のコードを書き込む
void setup() {
  // put your setup code here, to run once:
  pinMode(13,OUTPUT);
}

void loop() {
  // put your main code here, to run repeatedly:
  digitalWrite(13,HIGH);
  delay(1000);
  digitalWrite(13,LOW);
  delay(1000);
}

3.木に装飾品とLEDケーブルを巻きつけて完了。

接続図

DSC_0153.JPG

完成図

GIF_20151223_230253.gif

5
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
4