Help me pls..... i need embedded c code for a solar tracker using atmega16 ..it uses a single servo motor ,2 ldrs ..(Atmel studio)

Thread Starter

Dominik96

Joined Jan 20, 2020
4

ci139

Joined Jul 11, 2016
1,898
i considered making one with 2 axes.. (3D-rotation like telescopes) ..control based on array of 3 solar calculator (or garden light) batteries (each tilt at the different angle , moving along the solar panel) . . . so it would know where to move - requires no programming . . . perhaps thresholds set so it wouldn't tremble all the time . . . basically you get 3 component light power input which is needed to convert L-R , U-D vectors

http://www.makify.com/solar-cell-light-meter/

? https://www.mdpi.com/1424-8220/16/12/1995/htm
 

KeithWalker

Joined Jul 10, 2017
3,063
You only need one axis to track the sun. Tilt the whole thing from vertical to the South by the number of degrees latitude of your location. It will then track the arc of the sun.
Regards,
Keith
 

MrChips

Joined Oct 2, 2009
30,715
You only need one axis to track the sun. Tilt the whole thing from vertical to the South by the number of degrees latitude of your location. It will then track the arc of the sun.
Regards,
Keith
Depends on what information you seek.
If you just want solar time, yes one access will work.
If you want to collect maximum solar energy you will need two axes.
And it depends on whether you are in northern or southern hemisphere.
 

John P

Joined Oct 14, 2008
2,025
Since you are reading the two LDR via ADC inputs, you can get an estimate of the sunlight intensity and make a decision to pause tracking.
I'm not sure that would work. Presumably the sensors need to be partially shaded to get a usable output, and then wouldn't it be difficult to tell the difference between normal operation and a cloudy sky? But it would be possible to twitch the servo every few minutes to see if that caused an imbalance between the photocells (meaning there is sun) whereas if nothing changed, it would mean the sun wasn't shining. Or check the output voltage of the solar array to see if there's enough sun to be worth tracking (assuming the array is pointed in some direction where the sun actually hits it).

You only need one axis to track the sun. Tilt the whole thing from vertical to the South by the number of degrees latitude of your location. It will then track the arc of the sun.
That can't be optimal for every season. But maybe it's worth losing a little efficiency to have a simpler system.
 

Thread Starter

Dominik96

Joined Jan 20, 2020
4
i considered making one with 2 axes.. (3D-rotation like telescopes) ..control based on array of 3 solar calculator (or garden light) batteries (each tilt at the different angle , moving along the solar panel) . . . so it would know where to move - requires no programming . . . perhaps thresholds set so it wouldn't tremble all the time . . . basically you get 3 component light power input which is needed to convert L-R , U-D vectors

http://www.makify.com/solar-cell-light-meter/

? https://www.mdpi.com/1424-8220/16/12/1995/htm
yea but i need programm......its my school project and i need to programm in Atmel Studio
 

djsfantasi

Joined Apr 11, 2010
9,156
yea but i need programm......its my school project and i need to programm in Atmel Studio
Since it is a school project, specific rules apply on a forum. Whatever you are asking for, you need to show us your attempt to solve the problem.

So since you want a program, what have you coded thus far? We can comment on your work and guide you to a correct answer. But we can’t provide a program. That’s up to you first.
 

MrChips

Joined Oct 2, 2009
30,715
Step 1: Get ATmega328 experimental board.
Step 2: Get AVR Pocket Programmer
Step 3: Get Atmel Studio loaded on your computer.
Step 4. Write program to get an LED to blink.

How far have you gotten?
 

ci139

Joined Jul 11, 2016
1,898
Last edited:

KeithWalker

Joined Jul 10, 2017
3,063
a dummy suggestion let the LDR be ..................... if your light source is "varying" the method won't work
I built a single axis solar tracker using LDRs. I adjust the vertical axis manually once in a while just to keep up with the seasons. It works very well and uses very little power. Why do you think it would not work?
Regards,
Keith
 
Top