Today, I am going to share my experience on the LED Strips programming using Arduino. It will be fantastic to decorate on Christmas nights, which you can program each LEDs as required like we could create a cool animation.
This article does not go into detail. This will just give you the idea on how we can program LED strips and you can program the lights according to your need.
Let's begin, we need the following items before we begin the programming.
1) Arduino
2) Power Source (10 V)
3) Wires
4) LED Strip
We connect the power source to one end of the led strip. Normally positive wire of the strip is red, and the negative is white. The white is grounded with the ground of the strip. Strip has also cables to be connected to the Arduino. GND should be connected to the negative power supply. Note that the green color cable is used for the color signal which we normally connect to PIN 7 of Arduino.
This article does not go into detail. This will just give you the idea on how we can program LED strips and you can program the lights according to your need.
Let's begin, we need the following items before we begin the programming.
1) Arduino
2) Power Source (10 V)
3) Wires
4) LED Strip
We connect the power source to one end of the led strip. Normally positive wire of the strip is red, and the negative is white. The white is grounded with the ground of the strip. Strip has also cables to be connected to the Arduino. GND should be connected to the negative power supply. Note that the green color cable is used for the color signal which we normally connect to PIN 7 of Arduino.
If you are using an external 10V power supply, we connect the positive to the red and negative to the white one. NEVER connect the red one into the 5V pin of the Arduino which burns it. I have burnt 3 Arduino by mistakenly connecting this 10V in 5V pin in Arduino.
So, the connection will be like this:
1) Without external power
If we DON'T want to use external power, then we need to use an Arduino +5V pin as a power supply to the LED strip. Please note that, because Arduino can't deliver enough power, we have to compromise the brightness of the LED Strips.
The connection diagram will be as follows:
2) With external power supply
If the Arduino power is not enough for the LED strips, we need external power supply. I have used 15V 5A power supply. Please be very careful while connecting external power supply. Note that if you mistakenly connect your +15 V in the +5V pin, then you will burn your Arduio which I did 4 times!
So, if you using an external power supply, never connect the red (positive) +15V to the Arduino. But the negative of the power supply (normally white line) should be connected to the GND of the Arduino. The PIN 7 should be connected to the green line DIN of the strip.
Please look into the connection diagram
Now we come to our actual task: programming. Before we start we have to install the needed libraries.
We need Adafruit_Neopixel and optional Tinkerkit libraries. Adafruit library is used to actual programming while Tinkerkit libraries make it easy to read sensor values because we are using sensors to control the led lights.
The code is made downloadable from git repository:
This example code is just a kind of animation I have created. But we can use the power of
Arduino to define cool animations in your own way.
Just try yourself :)
Arduino to define cool animations in your own way.
Just try yourself :)