What it shows
Instead of light sensors, this tracker computes where the sun is from the date, time and the location, using the real-time clock, and turns a panel to that azimuth and elevation with two servos. It keeps pointing correctly even in cloud, when LDR trackers lose the sun.
The science
The sun's position depends on the day of the year (declination) and the time of day (hour angle), plus the latitude of the place. Standard formulas give elevation and azimuth from these, and the ebook on renewable models explains the maths at college level. The DS3231 provides accurate time; the sketch converts local time to solar time with the longitude correction. The azimuth maps to the pan servo and the elevation to the tilt servo. A small LCD shows the computed angles for checking against a free sun-position app.
Materials
Cost: under Rs 1,500. Many items come from home or from waste; spare parts such as LEDs, motors and wire are in the store.
- An Arduino Uno clone and USB cable
- A DS3231 real-time clock module
- Two SG90 or MG90S servos on a pan-tilt frame
- A small solar panel
- A 16x2 I2C LCD
- A separate 5 V supply for the servos
- A phone compass to align the base
Safety
For this project: Battery or USB power only. Never look at the sun to check alignment; use the panel shadow instead.
Never use mains electricity: power models with cells, batteries or a low-voltage adapter. Sharp and hot tools, flames and lab chemicals need an adult or your teacher beside you. Keep magnets, button cells and small parts away from young children, and wash your hands after making.
All the safety rulesStep by step
9 steps. Do them in order, and test each part before you go on to the next. Write what you notice in a notebook as you go.
Wire the DS3231 on A4 and A5 and set it with the library example; wire the LCD on the same bus.
Wire the pan servo to pin 9 and the tilt servo to pin 10, powered from the separate 5 V supply with ground joined.
Enter your latitude and longitude in degrees as constants in the sketch.
Code the declination from the day number, the equation of time, and the solar hour angle from the corrected time.
Compute elevation and azimuth each minute using the standard spherical formulas and show them on the LCD.
Map azimuth 90 to 270 degrees onto the pan servo range and elevation 0 to 90 onto the tilt servo.
Align the base with true south using the phone compass, correcting for magnetic declination if your app gives it.
At noon, check that the panel shadow is a thin line, showing it faces the sun; compare the LCD angles with a sun-position app.
Test on a cloudy day to show the tracker still moves on schedule.
What you should see
The panel follows the sun through the day without any light sensor; the computed angles match a sun-position app to within a few degrees.
Viva questions
A teacher or a judge will ask how it works. Try to answer each question before you open it, then compare.
1Why does the sun's elevation change through the year?
The Earth's axis is tilted, so the sun's declination moves between plus and minus 23.4 degrees.
2What is the equation of time?
A correction of up to 16 minutes between clock time and sun time caused by the Earth's tilted, slightly elliptical orbit.
3What advantage does a clock tracker have over an LDR tracker?
It is not confused by clouds, reflections or shadows, because it never looks for the light.
4What is its weakness?
Any error in time, location or base alignment points it wrongly, and it cannot correct itself.
Take it further
Add two LDRs for a fine correction on top of the computed angles, combining both methods.
Change one thing, measure what happens, and add a table or chart of your readings: that is what turns a model into your own investigation.
Free ebooks for this project
Robotics
Arduino and Coding for Robots Study Book
The complete study notes, practice questions and glossary for Arduino and Coding for Robots
