About the Site
Hey there, my name is Gabriel Miller and this is my website. I created it for several different reasons, but one of the biggest is that I want to help give back to the internet community. Many individuals, just like you, have already done a lot to help it grow. There is, however, still much left to be done, and I intend to do my part.
Many of the projects featured on this site are, in fact, things I have searched for on the web and couldn’t find. Whenever I can’t find what I’m looking for, I will upload it to this website as soon as I come up with a solution. That way others with the same problem will then have something to find.
Another reason I created this website was to find people with the same interests as me to work on those projects that are either too complicated or too time consuming to do alone. If one of the projects on this site interests you, sign up on the forums, leave a comment, or send me an email, and we will see if we can’t help it grow.
About Me
Hmm… what should I say about myself. I suppose that the most obvious place to start is to mention where I live (and grew up), which is near Winchester Virginia located in the United States.
I was born in 1985.
I used to work as a carpenter for several years and sometimes still do.
I am currently a student at Shenandoah University and am working towards a mathematics degree with a minor in physics.
I have many different interests, but some of the biggest are solar energy, robotics, and computer programming, as should be obvious from this site.
I have a “to do” list so long that I could never hope to live long enough to finish even half.
My long term goals include living a long, peaceful life while simultaneously achieving complete and utter world domination.
Contacting Me
If you have a question (or input) about one of the projects on this site, the best ways to send it are to either post it on the forum or to leave a comment. When asking it at these locations other people, who may have the same question, will be able to read the answer.
My email address is gpm4985′at’yahoo”dot”com (Fix the “@” and “.” for it to work. Blame the inconvenience on spam grrr.) If you want to talk to me about something that is less relevant to the other users of this site, you can use it to reach me.
As a full time student, life can get pretty busy, so it may take me a while to respond. I tend to check the forum, comments, and my email 2 or 3 (thousand) times a day though, so it shouldn’t be very long before I at least read it. It is, after all, a great way to procrastinate from homework.


Hi Gabriel,
First thanks for the information on heliostats ! We (2 friends in Holland) are trying to build one ourself using this stepper-control card, special made for the arduino card:
http://www.adafruit.com/index.php?main_page=product_info&products_id=81
We are now trying to adjust your heliostat program for this card, but of course, it is not that simple..
Could you (or another diy heliostat builder) tell us which parts of the program we have to adjust ?
CU
Boaz Visscher
Holland
Hi Boaz,
I can indeed tell you which parts you need to change.
I’m looking at the example at the link below to get an idea for what you might need to do.
https://github.com/adafruit/Adafruit-Motor-Shield-library/blob/master/examples/StepperTest/StepperTest.pde
Starting on the first tab, Arduino_SunTracker_Vxx, you can change the following:
At the very top, you should be able to remove the “#include” and replace it with the library that your driver board uses.
A little farther down the page is the “//STEPPER MOTOR SETUP ”
Put the number of steps for your stepper motor for #define STEPS 200. Your driver board doesn’t need this, but other parts of the program do.
The rest of the code in this “block” won’t be of use to you, and you need to replace it with something that is (I think) similar to the below code for your driver.
AF_Stepper altmotor(48, 2);
AF_Stepper azmotor(48, ?);
Under void setup(), you will need this line for your driver.
motor.setSpeed(10); // 10 rpm
That should be all you need to do under the Arduino_SunTracker_Vxx tab.
Everything else is under the functions tab.
At the very top of the page, you will see the “writeMotorPinsLow()” function. I would remove everything inside it so that you can use those pins for other things.
If you go to Edit>>Find in the Arduino code editor and do a search for “azStepper.step”, you will quickly be able to find the code that needs to be changed.
I count seven different locations. Technically, you don’t have to change all of them, but it might just be safer to do it anyway.
I’ll do an example of how I think it needs to be changed. I’m not sure exactly how it should look though.
This is the before code:
azStepper.step(azSteps);
This is the after:
if (abs(azSteps)==azSteps){
azmotor.step(azSteps, FORWARD, SINGLE);
else
azmotor.step(azSteps, BACKWARD, SINGLE);
}
You will need to do the same thing for altStepper.step(altSteps); too.
You will also need to do this in six different locations.
At the bottom of the “Functions” tab, you will find the findLimit() function.
I think the easiest way to change this is to just replace azStepper.step(10 * motorDirection * whichDir);
with
azmotor.step(10, FORWARD, SINGLE);
When the program first starts to run, it should move in the direction of the limit switch. If it doesn’t, you would have to swap FORWARD with BACKWARD.
You will need to do the same thing for altStepper.step(); too.
That’s a pretty decent overview of what you would need to change I think. It’s very possible that I overlooked something, but, hopefully, you should be able to work it out.
If you get this to work, let me know.
Good Luck!
Gabriel
We built a prototype using the same principle of synchronization of the two axes followed by East West and at the elevation but we have doubts on this principle. that’s why we want to know if it’s possible to focus the light rays in the same place all day just by changing the two angles coupling common to all the heliostats.
Could you help us ?
Thanks
I’m not sure if I understand the question correctly, but if you want to couple multiple mirrors together so that they can be controlled with just one set of motors and then angle the mirrors so that they all point at the same target, it should be possible. I’ve seen it done before.
Hi Gabriel,
I built a 4K tracker that runs on steppers and sensors. I am trying to figure out how to run it from an Arduino. I am using drivers that only need step and direction signals, and I need to run the limit switches separately. I am a total greenhorn at programming. Can you point me in a direction?
Hi Sid,
4K, that sounds like a rather large sun tracking machine! Are the sensors light sensors for aligning the machine towards the sun? I know I’ve seen some YouTube videos with that type of set up. If that’s what you’re looking for, you might be able to find some links to source code somewhere in their descriptions.
You probably already found it, but, if not, there is also the program I wrote for the Arduino here http://www.cerebralmeltdown.com/2011/05/30/open-source-arduino-sun-trackingheliostat-program/#more-2866
If you tell me a little bit more about the machine you built, I can try to tell you if it will work with the program or not. In particular, if it uses a simple gear reduction system, it should be a piece of cake to get it to work with your design.
Thanks!
Gabriel
Hi Gabriel,
I am currently using 2 NE555 oscillators to drive the stepper drivers. I am using led current sources to drive the 555′s. The e/w stepper couples to a 60:1 gearbox, then to a 12:112 sprocket.
The n/s is the same, with an additional 5:1 chain drive. The stepper drivers I am using only require step and direction signals.
The ratios don’t come out exactly even in steps per degree, but probably close enough.
Thanks,
Sid
Hi Sid,
It sounds good so far. Just to be clear, is this a single axis tracker? (Like this one http://en.wikipedia.org/wiki/File:Nellis_AFB_Solar_panels.jpg)
If so, the “out of the box” sun tracking program I wrote doesn’t support it. I would have to think about it awhile to be sure, but I think it could be added, perhaps even easily.
The reason I haven’t done so already is because I have no way to test it in the real world. If you’re willing (and your system is single axis) I could add it in and you could try it out for me.
A few other things I would watch out for are:
1. You mentioned that you need to run the limit switches separately. I’m not sure what you mean exactly, but, in its current configuration, the limit switches are only used to reset the machine’s position.
2. Your machine sounds fairly large and there is currently no acceleration implemented in the program, so the stepper motors might lose steps when updating their position.
3. From what you said in the email, it sounds like you want to build a system that you just set up and forget about. The RTC modules the program is currently set up to use for time keeping doesn’t do it perfectly. Depending on the module, it might take many years before this is a significant problem, but it’s still something to watch out for.
Hi,
1) It is a dual axis tracker. The gear ratios are different for each axis. I think you configured the limit (home) switches in parallel on one input. If the az axis gets home first, how does the el axis see the switch?
2)Yes, it is big. Acceleration hasn’t been a problem, as I run it very slow. It typically takes about 40 minutes to travel 180 degrees.
3)The accumulated error with the RTC is probably not a problem. Resetting the time every couple years as part of a maintenance schedule is OK. If this were a heliostat, it would be more critical.
4)I have a smaller tracker (2k) that is configured as a ’tilt and swing’ that I have considered converting to single axis with n/s seasonally adjusted. It would act like a polar mount. I can do that for a test bed for a single axis program.
Sounds like everything should be compatible with the Arduino Sun Tracking program. I think that it should work almost as is, aside from the user settings of course.
After the az limit is triggered, the machine moves away from it by four degrees so that it is no longer active. This means that only one pin output is required on the Arduino for what could essentially be an infinite number of limit switches on an infinite number of machines.
Cool. The only other issue I see is how to drive the stepper drivers. What I have now needs 1 step signal (waveform) and 1 direction signal (HIGH/LOW) per motor. It looks to me like you have 4 pins per motor outputting a combination of steps and direction. How does that work? Or do I need to build a different driver to accommodate the different format?
Thanks,
Sid
The default is a four wire stepper driver because that’s what I use, but switching to a two wire stepper driver only requires modifying two lines of code.
For my setup, I’m using pins a four wire stepper driver that uses pins 2, 3, 4, 5. The code looks like this.
Stepper altStepper(int(steps), 2, 3, 4, 5);
If I wanted to switch it over to a two wire stepper driver that uses pins 2 and 3, I would replace the above code with this.
Stepper altStepper(int(steps), 2, 3);
The az stepper code would also have to be similarly modified.
from
Stepper azStepper(int(steps), 6, 7, 8, 9);
to
Stepper azStepper(int(steps), 4, 5);
The stepper code I’m using is built into the Arduino software, so I just use that. Here’s the link to the reference page. http://arduino.cc/en/Reference/Stepper
You can try it out and see if it works with your driver board. Unless it’s odd in some way, I think it should be OK.
I have a test Arduino sketch at the bottom this page which you can try it out with, after modifying those two lines or course.
http://www.cerebralmeltdown.com/heliostatprojects/Arduino_Sun_Tracker_Circuit/Driver_Board/index.html