Sun Position


Wondering if it would be useful to add the Sun’s Altitude and Azimuth if the user has put in their location?

I think it would be useful to see where the sun is for maximum yield for example and may help in tweaking panel tilt etc.

I’ve been manually using a site called They have an api, maybe that can be used?

What do you think?


The insolation feature already takes into account system lat, long, tilt, azimuth and timezone.


Yeah, but I think the raw sun position would help diagnose any problems. So for example in the data you could see the sun’s max angle was “x” degrees, yo might be able to tilt your panels accordingly.
I know there’s the other site I mention in the OP you can cross check against, but it would be cool to have that detail in our results table to make direct and easy comparison to the sun’s real position.


I added this to my extended data graphs just this week.

Added some code to my uploader using the Python module PySolar.

My Emoncms to PVO uploader is here if anyone if interested.


Just to add, I wanted to know the sun angle and position in relation to my property / panels and shading as per the OP. Granted, there is nothing much I can do with regard moving any panel etc, but the numbers geek in me just wanted to see this sort of stuff. :laughing:


Hey Zarch, same here. That data on your graph looks great, and is telling.
I want to try and get that going here. The problem is getting a script running on python3.
Do you know of a dummy’s way of getting this going?


I found this site which is great for any GEEK. Just locate yourself on the map and put in a date to get the sun azimuth and elevation for all day in table format and graph


Go t the data uploads working using a modified version of zarch’s script. Now just need to figure out how to show the extended data.


Did you manage to sort the extended data out Roger?

You have to go in to settings and choose, axis, decimals and Units to get the to display on the graph.


Hi Zarch, yes I did :slight_smile:

I’m pulling up the cloud coverage data too. That script is very good. Thanks for sharing it.


Looks great!!

Where do you pull the cloud cover data from?


Ah Cloud Cover, from within DarkSky. I’ve added that now, see what it looks like.

I’ve also added Irradiation data from the PySolar pull too… see how that graphs out. :slight_smile:


Hi Roger,

May I ask how you were able to push the MPP1 and MPP2 energy data? I didn’t see an options for pushing the data for the individual circuits in my Fronius inverter.



Hi Walter,

I was hoping to get the push data directly from the inverter, but I need to work on an automated way.
The only way I could do it was to Subscribe to Fronius, which is free at the moment it seems, and then get it to email me the .csv files every day.

Then, I have to do a manual upload.

It would be good to automate this somehow.

I set up a push to my local FTP server using the SolarAPI LogData - Data to dump data, but not sure how I can use that data in a similar way. Maybe someone could me assist with some coding.

The snipped output looks like this:
“Body” : {
“inverter/1” : {
“Data” : {
“Voltage_DC_String_1” : {
“Unit” : “V”,
“Values” : {
“0” : 0.5,
“10200” : 0.70000000000000007,
“10500” : 0.70000000000000007,
“10800” : 0.70000000000000007,
“11100” : 0.70000000000000007,
“11400” : 0.70000000000000007,
“11700” : 0.70000000000000007,
“1200” : 0.40000000000000002,
“12000” : 0.70000000000000007,
“12300” : 0.60000000000000009,
“12600” : 0.60000000000000009,
“12900” : 0.60000000000000009,
“13200” : 0.60000000000000009,
“13500” : 0.60000000000000009,
“13800” : 0.60000000000000009,
“14100” : 0.60000000000000009,
“14400” : 0.70000000000000007,
“14700” : 0.5,
“1500” : 0.40000000000000002,
“15000” : 0.60000000000000009,


Hi Roger,

Thanks for that. I was looking at the Fronius API for a function to return the ‘instant’
Current_DC_String_1, Current_DC_String_2, Voltage_DC_String_1 & Voltage_DC_String_2.

It seems that GetArchiveData.cgi is the only option. I guess that there is no issue in pulling the data every X minutes and pushing it through to PVOutput.

I will experiment a bit and see if I can create a script that will pull the data from the inverter and push it into the available Extended Data fields.


it looks as if this might be how to do it on page 43 string control,is DC volatges

i am a dud at this stuff so if you can work it out please post a how to do it for me and others thank you Jim


hey guys just put this up if your looking at getting the mpp1 and 2 data


This looks really promising, but the scripts are bombing out. I don’t really want to dump into a database either. I just want to get the value to send to pvoutput.


I finally got that Modbus script to work. Getting some extra extended data now to analyse.