Step 1: How it works

Picture of How it works
a boven.jpg
How it works:
I'd made a sensor of 4 LDRs with sheets between them

The withe stips are the LDRs 
When the stick on top is righted to the sun or the brightest point 
the four LDRs get the same amount of light on them.

Example1 when the light is left on top:
right-top, right-down, left-down are in the shadow
and left-top get the most light

Example2 when the light is on top
left and right down are in the shadow and top is in the light


Step 2: Parts List

  • 2 x servo's
  • 4 x lightdepending resistors (ldr)
  • 4 x resistors 10K
  • 1 x Arduino
  • 2 x potentiometers 10k (value doesn't matter)

Step 4: The circuitry

Picture of The circuitry
1-40 of 162Next »
TomDunlap1 year ago
Just finished it and got it debugged. Really cool. Now I'm going to try to use it to build a Solar Forge and or a Solar Sand Sinter 3D Printer. Should be a snap. ;-)
geo bruce (author)  TomDunlap1 year ago
cool! :p
can you show us some video's or pictures?


*videos *thanks

Another development, I used a Makerbot Replicator to print a replacement for the foam core sensor holder. Here is the Sketchup pic of it. The two pieces glue together. The center top hole is for a fifth sensor to shut the system down if clouds block the sun so it doesn't try to point at the brightest cloud.
Pyramid 3.png
geo bruce (author)  TomDunlap1 year ago
nice upload your design to
geo bruce (author)  TomDunlap1 year ago
Sure, here is the link to the YouTube clip I made:
geo bruce (author)  TomDunlap1 year ago

It's cool to see your instructable finished by someone else :D
it means i've helped someone ^^ or someone liked my project! :D
It's really helpful to get me started toward my other goals.
Next I want to modify the code to operate some 12V drill motors with a MotorShield or the like if I can find one that will handle the 3-4A current.
hipatetik14 hours ago

Here is my prototype design, I modified the code so I can use my 28BYJ48 Steppers...I'm going to modify this so I can align a dish that is part of a Stirling motor project.

geo bruce (author)  hipatetik11 minutes ago

Hii there are a lot of people in the comments searching for the code to do this with stepper motors,So if you could make them public that'd be Awesome. I'm willing to ad a refference to you in my instructable description

Inspired by your work... I designed a 3D mounting structure for the LDR's that will mount on the upper edge of a solar panel. 3D print did a nice job of it.

Solar Tracker 2.jpgSolar Tracker 3.jpgSolar Tracker 1.jpg
geo bruce (author)  bryan.reid.585yesterday

looks good, share the files! :D

Hey Geo... how balanced were your LDR's... it appears critical in the accuracy of pointing...

NicolaP14 days ago
hi, you have tried this project even on cloudy days? what happens? I have to use it for an industrial plant
Spellmal made it!14 days ago

Just finished up my take on this tracker. I used continuous rotation servos, so i had to modify the code a bit. Super fun project, thanks geo Bruce!


Hi there. Your project is cool. I think the servos that you used is not 360 degrees right? What if, a 360 degrees servos will be used? Is there any changes of the codes and schematic? Thanks :)

I just made one using continuous rotation servo motors. The wiring is the same but the motors cannot be sent to an exact location, so the code had to be tweaked. explains the differences between how the motors respond to commands. Hope this helps!

gcarlyle2220 days ago

I have an eagle schematic and pcb if anyone is interested. I haven't been able to test it but try it.

Hi there. Your project is cool. I think the servos that you used is not 360 degrees right? What if, a 360 degrees servos will be used? Is there any changes of the codes and schematic? Thanks :)

I have been trying to get this code compiled and have downloaded the file. It won't compile. When it gets to the part where it writes, if(-1tol>dvert-- it triggers an error. I have gone over and over this code in 2 seperate windows and looking for something that I may have done wrong but everything is exactly as it is published on this page. I am not a programmer and have had a lot trouble getting most prgms to function. there were some other errors, but those were from me not having done the code right. I got past that and now nothing I do will get me past this jam. I really want to get this code debugged so I can build one of these as I have a couple of larger solar arrays I wish to do tracking systems for. There may be other issues after the one I am addressing here but until I get past this one, I won't know if the published code is correct or there is something deliberlately left wrong. Like I said, I have spent 2 days trying to make this work and no luck yet.

irvlz1 month ago

hey, some help, my solar tracker works backwards, it gets away from light, how can I fix it??

Just finished it. Finally discovered that the pin assignments for LDRs in the program are different than the pin assignments in the wiring diagram. I changed wiring to agree with program and now it works.


int ldrlt = 0; //LDR top left
int ldrrt = 1; //LDR top rigt
int ldrld = 2; //LDR down left
int ldrrd = 3; //ldr down rigt


ldrlt = 0

ldrrt = 2

ldrld = 1

ldrrd = 3

Tim Detwiler

danielebosco11 months ago
Hi Bruce, I am trying to have your project working, I am new whit this, I am using an ARDUINO atmega328 I connect al the components and load the code but I figured out that I bought a different motors stepper 360g and I believe need to change some value on code motors are, tks for help

*with *all *thanks *believe I need to

Star3163 months ago

Hi! I have a problem:( I can't really put the 2 potentiometer right next to each other they are just too big any ideas?

geo bruce (author)  Star3163 months ago
solder wires to the contacts and put those in to the breadboard

mmmmm toast

zoom out ctrl alt ryi

I have a question. Why is the drawing pin numbers different than the code.

I had it working once, now know matter how I switch the wires it acts like its running backwards. need help, Thanks

no you pick a name

irvlz1 month ago

hey, i did exactly the same but there's a problem, the vertical servo doesn´t work while the horizontal does, any idea to fix the problem? please

MC James irvlz1 month ago

Yes, stop being such n00b

jtmdie1 year ago
like how do you know which LDR is on the top and the bottom
MC James jtmdie1 month ago

OMG wyy is you so stupuid?

geo bruce (author)  jtmdie1 year ago
? just follow the wire to your arduino
pidot1 year ago
geo bruce...I have problem with my solar tracker...It's not effectively detect with light..I think its have some problem with the code??can u help me??This is the code:#include // include Servo library

Servo horizontal; // horizontal servo
int servoh = 90; // stand horizontal servo

Servo vertical; // vertical servo
int servov = 90; // stand vertical servo

// LDR pin connections
// name = analogpin;
int ldrlt = 0; //LDR top left
int ldrrt = 1; //LDR top rigt
int ldrld = 2; //LDR down left
int ldrrd = 3; //ldr down rigt

void setup()
// servo connections
// name.attacht(pin);

void loop()
int lt = analogRead(ldrlt); // top left
int rt = analogRead(ldrrt); // top right
int ld = analogRead(ldrld); // down left
int rd = analogRead(ldrrd); // down rigt

int dtime = analogRead(4)/20; // read potentiometers
int tol = analogRead(5)/4;

int avt = (lt + rt) / 2; // average value top
int avd = (ld + rd) / 2; // average value down
int avl = (lt + ld) / 2; // average value left
int avr = (rt + rd) / 2; // average value right

int dvert = avt - avd; // check the diffirence of up and down
int dhoriz = avl - avr;// check the diffirence og left and rigt

if (-1*tol > dvert || dvert > tol) // check if the diffirence is in the tolerance else change vertical angle
if (avt > avd)
servov = ++servov;
if (servov > 180)
servov = 180;
else if (avt < avd)
servov= --servov;
if (servov < 0)
servov = 0;

if (-1*tol > dhoriz || dhoriz > tol) // check if the diffirence is in the tolerance else change horizontal angle
if (avl > avr)
servoh = --servoh;
if (servoh < 0)
servoh = 0;
else if (avl < avr)
servoh = ++servoh;
if (servoh > 180)
servoh = 180;
else if (avl == avr)
// nothing
MC James pidot1 month ago

No that's wrong

ems20141 year ago
Hi! I am interested in building this but I was wondering if you could give a slightly more specific parts list. I just don't know what type of Arduino, potentiometers, etc... to buy? Any help would be greatly appreciated!!!
1-40 of 162Next »