Mirroring/intercepting SunPower Monitoring Traffic?

Collapse
X
 
  • Time
  • Show
Clear All
new posts

  • Crash
    replied
    It looks like sunpower disabled my access to their installer link which showed stats per panel. Did anyone else get knocked out? I have not logged in for a few months. I liked being able to check at the panel level.

    Leave a comment:


  • ajzwilli
    replied
    Originally posted by georgeanzi
    Hi everyone,
    Just finished reading all 13 Pages. Though you might want to know of an on the cheap way to hook up to the installers port on the PVS5. What is needed is a NAT engine, the same as in all routers. Got an old router collecting dust (or possibly for a buck or two at your local thrift store). Just connect the WAN port to the PVS5 installers port, set up your "route" table to point to the old router for 172.27.153.0 (like so for linux:
    ip route add 172.27.153.0/24 via <the old routers address on your Lan>
    For most of these old routers you can find info on the manufactures site on how to reset them and assign them an address on your Lan. While in there you may want to turn the radio off and make sure it is set up for a DHCP WAN connection. On the gravy side, you will now have 3 additional connections on your Lan (the extra ports on the old router).
    Would anyone be able to explain this to a NOOB. My PVS6 is currently connected to my wifi network and I have an old router with DD-WRT that I can use, but not exactly sure what I need to change to 172.27.153.0 in the old router and what other settings I need to change in the router.

    Leave a comment:


  • astroboy
    replied
    well... mine is on the outside of the house so pulling cables to it is kind of a non-starter. i have powerline networking to establish internet connectivity for the PVS2.

    Leave a comment:


  • georgeanzi
    replied
    I don't have anything in the box/enclosure with the PVS5. I just have two cat5 cables to it. It's in the garage, the old router is upstairs in the house and is actually in use as an extra WIFI source as well as a NAT engine, and it give me a couple of extra cat5 ports.

    Leave a comment:


  • astroboy
    replied
    Originally posted by georgeanzi
    astroboy: I have a PVS5. I get data from the installer port using an old router to do the NAT thing. See my post just above yours. The command to send it is as given in "faraway's" post a few before that. I am reading the data and working with it using TCL rather then Python, but the URL is the same and the language you use is up to you. My plan is to put the code on a rasberry-pi zero+ with a small display and put that in the Sunpower SPR-PRM-WDISP that used to display what the system was up to.
    thanks, yes this is likely what i'm going to have to do. just wondering if PVS6 has the same 2nd ethernet port. all of this garbage is inside a little weatherproof box and i'm not sure if there's room inside for a RPI though.

    one thing is that in a couple of months i should have my powerwalls installed so i can probably just grab the solar data from the powerwall's monitoring API. but in the mean time, unless i can get your style of monitoring going, i'll lose PVOutput which is very helpful to me.

    Leave a comment:


  • georgeanzi
    replied
    astroboy: I have a PVS5. I get data from the installer port using an old router to do the NAT thing. See my post just above yours. The command to send it is as given in "faraway's" post a few before that. I am reading the data and working with it using TCL rather then Python, but the URL is the same and the language you use is up to you. My plan is to put the code on a rasberry-pi zero+ with a small display and put that in the Sunpower SPR-PRM-WDISP that used to display what the system was up to.

    Leave a comment:


  • astroboy
    replied
    it looks like my inverter is failing and as part of the RMA they may replace my PVS2 with a PVS5 or PVS6. sounds like with PVS5 you can connect to the installer port to get the production info - i am assuming that snarfing the data flowing to sunpower would be impossible with a PVS5 since the data is encrypted. does that sound right?

    how about PVS6? is there a way to directly access the production data on one of those?

    Leave a comment:


  • georgeanzi
    replied
    Hi everyone,
    Just finished reading all 13 Pages. Though you might want to know of an on the cheap way to hook up to the installers port on the PVS5. What is needed is a NAT engine, the same as in all routers. Got an old router collecting dust (or possibly for a buck or two at your local thrift store). Just connect the WAN port to the PVS5 installers port, set up your "route" table to point to the old router for 172.27.153.0 (like so for linux:
    ip route add 172.27.153.0/24 via <the old routers address on your Lan>
    For most of these old routers you can find info on the manufactures site on how to reset them and assign them an address on your Lan. While in there you may want to turn the radio off and make sure it is set up for a DHCP WAN connection. On the gravy side, you will now have 3 additional connections on your Lan (the extra ports on the old router).

    Leave a comment:


  • alex27riva
    replied
    Hi everyone, how can I sniff the data that my Data Logger is transmitting to Sunpower's server?

    Leave a comment:


  • faraway
    replied
    Here is the latest code that I have:

    #!/usr/bin/python3

    import requests
    import json
    import datetime
    from datetime import datetime

    # this is the default URL for the admin interface of SunPower PVS5
    pvs5_url = "http://172.27.153.1/cgi-bin/dl_cgi?Command=DeviceList"

    # pvoutput.org
    pvoutput_url = "https://pvoutput.org/service/r2/addstatus.jsp"
    pvoutput_key = "_your_key_"
    pvoutput_systemid = "_your_id"

    r = requests.get(pvs5_url)

    prod = 0
    net_usage = 0
    total_usage = 0

    for device in r.json()["devices"]:
    if device["MODEL"] == "AC_Module_Type_D" and device["STATE"] != "error":
    prod += float(device["p_3phsum_kw"])*1000
    if device["MODEL"] == "PVS5M0400c":
    net_usage = float(device["p_3phsum_kw"])*1000

    total_usage = prod + net_usage

    date = datetime.now()

    requests.post(pvoutput_url, data={"d":date.strftime('%Y%m%d'), "t":date.strftime('%H:%M'), "v2": prod, "v4":total_usage}, headers = {'X-Pvoutput-Apikey': pvoutput_key, 'X-Pvoutput-SystemId': pvoutput_systemid})

    Leave a comment:


  • faraway
    replied
    Originally posted by fslipcam

    I think PVOutpot Net Data Upload only works for Donators. If you don't have Donator mode enabled, doesn't matter you set n:1 or n:0, "v4" still upload as consumption mode and ignored any negative value. You may try take out the "*-1" and modify v4 like below.

    usage = float(device["p_3phsum_kw"])*1000

    requests.post(pvoutput_url, data={"d":date.strftime('%Y%m%d'), "t":date.strftime('%H:%M'), "n":0, "v4": usage + sum}, headers = {'X-Pvoutput-Apikey': pvoutput_key, 'X-Pvoutput-SystemId': pvoutput_systemid})
    I have done something like this in my latest version, I will post it when I get home

    Leave a comment:


  • fslipcam
    replied
    Originally posted by faraway

    Thanks!

    Just to note, it seems that my sunpower consumption monitoring is off (or reversed), so take out the -1 from:
    1. usage = float(device["p_3phsum_kw"])*1000*-1
    I think PVOutpot Net Data Upload only works for Donators. If you don't have Donator mode enabled, doesn't matter you set n:1 or n:0, "v4" still upload as consumption mode and ignored any negative value. You may try take out the "*-1" and modify v4 like below.

    usage = float(device["p_3phsum_kw"])*1000

    requests.post(pvoutput_url, data={"d":date.strftime('%Y%m%d'), "t":date.strftime('%H:%M'), "n":0, "v4": usage + sum}, headers = {'X-Pvoutput-Apikey': pvoutput_key, 'X-Pvoutput-SystemId': pvoutput_systemid})

    Leave a comment:


  • faraway
    replied
    Originally posted by faraway
    Is there a way to reboot PVS5x remotely? Mine seems to stop sending telemetry data to SunPower, but WiFi seems to be working, the only thing I see thats different is the cell - says SIM card error right now, I am out of the country so don
    The system reconnected to SunPower, not sure if I did something or not. Also the mobile connection was up and down again.

    Leave a comment:


  • faraway
    replied
    Is there a way to reboot PVS5x remotely? Mine seems to stop sending telemetry data to SunPower, but WiFi seems to be working, the only thing I see thats different is the cell - says SIM card error right now, I am out of the country so don

    Leave a comment:


  • catchingraysinaz
    replied
    Originally posted by faraway

    Thanks!

    Just to note, it seems that my sunpower consumption monitoring is off (or reversed), so take out the -1 from:
    1. usage = float(device["p_3phsum_kw"])*1000*-1
    I've seen in other posts that if your consumption is 'reversed', it usually means the leads from your consumption monitor are reversed.

    Leave a comment:

Working...