My very first instructable is my design called the DIY Mini Solar Tracker is a solar panel that tracks the sun! I used this for my eighth grade science fair project and my classmates thought it was amazing! The tracker uses and Arduino Uno and a photo resistor to track the sun! It takes several readings and then determines which is the brightest as it goes though the process! Let's get to it!
***NOTE: Pictures are not high quality because they were take with an iPod Touch 4th Generation of a all ready assembled solar tracker that I built.
Step 1: The Parts
This is just an experimental project so we mainly use a breadboard and jumper wires. The parts list is as follows...
- Arduino Uno
- Computer with Arduino Programming Environment
- Jumper Wires
- Small Solar Panel
- Photo resistor
- Wire (22 AWG recommended)
- 2 Servo Motors (With Control Horns)
- 100K Ohm Resistor
- 1" PVC Pipe
- 1" PVC Elbow
- 1" PVC T-Fitting
- PVC Cement
- PVC Primer (Optional)
- Heat Shrink Tubing
- Hot Glue Gun/Sticks
- Popsicle Sticks
- 2x4 Board (Optional)
- Solder Iron/Solder
- Labels (Optional)
Step 2: The Frame
I used 1" PVC Pipe and a 2x4 for my frame. The 2x4 is 18" long with a little bigger than a 1" hole cut 2" from one side. I then used PVC primer and cement to make my "4" out of PVC. Here are the dimensions of parts.
- 18" 2x4 Board (with alittle bigger than a 1" hole 2" from one side)
- 3 1" x 5" PVC
- 1" 8" PVC
Once you have acquired all of these parts assemble them as shown in the photos above.
Step 3: Rewiring
Once you have assembled the frame you need to extend and add some wires. You may want to identify which wires are which by using labels.
The first thing we are going to rewire is the servos. First of all, cut off the existing servo connections. Next, pull apart the wires and strip them. After that, grab some wire (long enough to fit though your frame and a little extra) and solder to the striped wire.
The next thing we are going to rewire is the photo resistor. First, solder wire to the photo resistor's leads. Then slide heat shrink tubing over the leads and wire.Following that, heat the heat shrink tubing until it shrinks over the leads. Finally, route the wires to the bottom where the other servo wires are.
The last thing that we are going to wire up the solar panel.To begin, strip the leads of the solar panel. Once you have done that, solder wires to fit through the PVC. Furthermore, apply heat shrink tubing. Lastly, route it though the frame.
Now all of your wires should be at the bottom of your frame.
Step 4: Attaching the Servos
Once you have everything rewired you can attach the servos to the frame. To do so dremel a hole the width and length of your servos in the tops of the PVC. Now, you can insert the servos and secure them using hot glue or making a top out of Popsicle sticks and securing it with screws.
Step 5: Attaching Solar Panel and Photo Resistor
Now we need to attach the solar panel and photo resistor to the servos. Make sure the control horns are perpendicular to the PVC when at the 0 state. To find out where the 0 state is on a servo put the control horn on and twist it until it stops that is the 0 state.
We are first going to secure the photo resistor. Make sure the servo is at the 0 state and then hot glue the photo resistor to the control horn. Make sure no wires or getting in the way when it turns.
Next, we are going to attach the solar panel. Start by hot gluing Popsicle sticks to the perimeter of the solar panel on the back. Then glue small bits of Popsicle stick to the solar panel's Popsicle sticks. Make sure the are facing perpendicular to the solar panel's Popsicle sticks. Finally, Glue the control horn into the Popsicle sticks and make sure no wires are interfering.
Step 6: Wiring It Up
The last step before the program is wiring it all to the Arduino. You can use jumper wires and a breadboard for this.
- All servo power leads are connected to +5V on the Arduino
- All servo ground leads are connected to GND on the Arduino
- The photo resistor's servos signal lead is connected to digital pin 9 on the Arduino
- The solar panel's servo signal lead is connected to digital pin 10 on the Arduino
- Connect one lead of the photo resistor to +5V on the Arduino
- Connect the other to a 100K ohm resistor and to analog pin 0
- Connected the other side of the resistor to GND on the Arduino
- Connect the solar panel's lead to anything you want (L.E.D. or other electronics)
Step 7: The Program
Download the program and upload to your arduino. I hope I included enough comments that you can understand it, but here is a brief rundown of what it does. It move the photo resistor to a potion and takes a reading. Then it moves the photo resistor and takes another reading. If this reading is bigger than the one before it it moves the solar panel. If not the solar panel stays in place.
Step 8: Have Fun!
I hope you enjoyed and/or learned something from my instructable. I hope you will be inspired no matter how old you are. I am only 14 and you may be 35 or 8 or 85 and might think of something new,cool, and epic. Keep experimenting and having fun with this project and Arduino!
If you have any comments,additions,or questions I would love to hear from you!
Also my instructable will be in the sensor's contest and you can vote for it there! (https://www.instructables.com/contest/sensors/)