Monitoring a SunPower Solar System

After years of waffling on if I should install solar on my house, I finally decided that it would be a good investment. While the federal tax credit went down from 30% to 26%, I would still get a bit of my investment back. The tax credit goes to 22% next year and then goes away, so if I didn’t make the leap now, I’m not sure financially it would make sense for a long time until the panel prices come way down.

Like most major investments, I did a significant amount of research. I got proposals from 9 companies using a variety of panels and inverters. For better or worse, I went with a SunPower system. SunPower wants to make it easy for people to see how much energy they are producing and their monitoring site has a very, very simple dashboard. Apparently their older dashboard (still available via a different URL that uses Flash) showed output on a per panel basis. When I asked SunPower about this, here was their response:

Unfortunately, our monitoring website only shows production data of the system as a whole. Inverter level monitoring was only offered to dealers for troubleshooting and/or repair purposes. This was not offered to homeowners because, after lengthy evaluation, that feature offers more information than is necessary to monitor ongoing system performance, but not enough information to help identify problems (on the rare occasions when they do occur). We also had concerns about the feature’s design, in part due to negative feedback from customers.

After a bit of research, I found that the monitoring device (PVS6) actually has the ability to be queried for local data. An individual with better hacking/detective skills than me figured out the commands to send to the unit and posted information on GitHub describing the setup. That looked pretty straight forward. So I decided to figure out how to integrate it into Home Assistant and into my Grafana graphs.

First step was to configure a Raspberry Pi as basically a bridge where HTTP requests sent to one port would be redirected out the other port. I didn’t need a full fledged router for this, just an HTTP proxy. I decided to use a Raspberry Pi Zero W that I had lying around as a base. I ordered an Ethernet adapter for it and that was it for hardware. My son designed a case for both pieces and I 3D printed it.

Configuring the Raspberry Pi

  1. Download the Raspberry Pi Imager
  2. Select the Raspbian Lite image.
  3. Write the image to an SD card.
  4. Create a file called wpa_supplicant.conf at the root of the image with the following:
    ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
     ssid="<Name of your WiFi>"
    psk="<Password for your WiFi>"
  5. Add a file called ssh at the root of the image. This file should be empty.

  6. Assign a static IP address mapping on your router for the Pi.
  7. Boot the Raspberry Pi. Login using username: pi password: raspberry
  8. Update the OS using

    sudo apt-get update
  9. Install ha-proxy
    sudo apt-get install haproxy
  10. Modify /etc/dhcpcd.conf by adding the following so that the Ethernet going to the PVS6 doesn’t attempt to setup a gateway. If this happens, the Pi no longer responds over WiFi.
    interface eth0
  11. Add the following to /etc/haproxy/haproxy.cfg:
    frontend http-in
        bind *:80
        default_backend backend_servers
    backend backend_servers
        server sv1
    listen stats
        bind *:8080
        stats enable
        stats uri /
        stats refresh 10s
        stats admin if LOCALHOST
  12. Reboot the Pi.

Now when you issue HTTP calls to the Pi, they’ll goto the PVS6.

Setting up Home Assistant

I use Node-RED for most of my automations, so the following is how I poll the PVS6 from Node-RED.


Basically what I do is make an HTTP call to the Raspberry Pi over the WiFi interface that redirects to the PVS6. Using the information from the GitHub repo I found, the call is:

I then parse out the different devices that are returned (one for each inverter, one for the monitoring unit, one for the consumption meter and one for the production meter). My installer didn’t hook up the consumption meter, but I use an older version of the Rainforest Automation EAGLE-200 to connect to my electric meter and get consumption data.

This Node-RED flow generates multiple sensors that can then be used to display data right in Home Assistant or in Grafana. There is more information in the output than I need such as AC voltage, DC voltage, AC current, DC, current, etc. I use Home Assistant’s HTTP interface to create new sensors and since I have no idea how fast it can respond, I rate limit the updating of the sensors.

You can download my Node-RED flow from here.


I’m going to leave it as an exercise for the reader to setup pretty pictures in Grafana. I’ve setup a basic dashboard and some other graphs. The per panel graphs are useful to tell me if a panel isn’t operating properly. While SunPower doesn’t really want you to know this information, it is very helpful. My system was turned on (my installer and SunPower can remotely disable my system which really bothers me) yesterday and I noticed that 1 of the panels wasn’t generating power. This amounts to about 8% of my overall system; most people wouldn’t know this which makes it even more important to be able to get status on a per panel basis.

Energy Dashboard

Energy Usage

Per Panel Monitoring


I’ve written up this guide to help others, but also to refresh my memory in the future to figure out what I did. My home automation system is growing more and more complex by the day and if I don’t document at least parts of it, I’ll never be able to troubleshoot it.

Feel free to ask questions or provide comments.

16 Replies to “Monitoring a SunPower Solar System”

  1. Hi,

    Thanks for the great post. I have a question about how do you get the real time energy consumption. I am not so clear about the “net_ltea_3phsum_kwh” and “p_3phsum_kw” meaning even after checking the GitHub page. can you make it more clearly to me? Thank you.

    1. Hi Rick,

      I believe that “net_ltea_3phsum_kwh” is the total number of kWh consumed (cumulative) and “p_3phsum_kw” is the current (at the time measured) number of kW being used. Since the consumption monitor was not hooked up for me, my values are all zero.

      I hope that helps.

    1. Hi Odin,

      It is through the REST API. Node-RED has an interface to it, so I don’t directly use the API. A request is something like this:


      "attributes": {
      "friendly_name": "Total Power",
      "icon": "mdi:flash",
      "unit_of_measurement": "kWh"
      "state": 138.3355

      I hope that helps.

  2. Scott,

    Thanks. Great post.

    I am interested in something much simpler – basically checking the health of each panel periodically (monthly?) to make sure they are working properly.

    My question is: why do you need the RPi in between. Could not a program on a home computer simply make an HTTP request directly to the PVS6, assuming the IP address on the home network is known?

    1. Hi Brownell,

      The PVS6 doesn’t have a way to communicate with it from your LAN. The Raspberry Pi is necessary because the HTTP requests can ONLY be made to the installer Ethernet port and not the regular Ethernet port (or WiFi). The Pi acts as a bridge so that you can route requests from your LAN to the installer Ethernet port.

      I hope that helps.

      1. Scott,

        Thanks for the quick reply. I have a couple more questions. (I am doing this for a friend and don’t know a lot about the SunPower.)

        where is the device that the RPi connects to via Ethernet? Is there some control box in the house, or is it on the roof with the panels?
        do I use a regular Ethernet cable or a crossover?
        when the RPi ports are configured as you describe, I can use software like Postman to send the HTTP Posts to the RPi and they will be forwarded to the SunPower and I will get the responses. Right?


        1. Hi Brownwell,

          The PVS6 (monitoring device) is usually located in the garage or near the electrical panel. I use a regular Ethernet cable to connect it to the Pi. In my case, I have Ethernet going from my garage to my equipment rack, so I have the Pi sitting in my rack.

          Yes, you can use Postman or the like to send requests to the Pi which then sends the requests to the PVS6.

          Keep asking questions!

  3. Scott,

    Sorry for another question. You are going to need two Ethernet ports on the RPi. How did you do that? Does Ethernet over USB work? I am using an RPi 4 that already has one RF45 port on it.

    Thanks again,

    1. You’ll either need 2 Ethernet ports or Ethernet and WiFi. Ethernet is required to plug into the PVS6 and Ethernet or WiFi connects to your LAN. I’m using a Pi Zero W which doesn’t have native Ethernet, so I have a “hat” that provides Ethernet (actually using USB). I have the PVS6 connected to the Ethernet port and the Pi is on my LAN on WiFi; I like hardwired connections, but this is what I had on hand and it seems to work well.

  4. Thanks for this excellent write-up. My Sunpower supervisor is an SMS-PVS20R1 as opposed to a PVS6. It’s got two LAN ports. Do you think the approach you outline will also work? I have a spare Pi 2 and WiFi dongle so I can just give it a try, but I thought I’d ask.

      1. Unfortunately, it did not work with my SMS-PVS20R1. I connected the Pi2 with WiFi dongle to one of the LAN ports. I could SSH into the Pi no problem. However, when I executed http:///cgi-bin/dl_cgi?Command=DeviceList after 20 seconds or so I got a 503 Service Unavailable.

        I checked haproxy status on the Pi and it looked right. So I gather the PVS20R1 just has a different interface,

          1. Oops, I need to report back a different result with my SMS-PCS20R1 Supervisor. When I did this originally, I disconnected the PowerLine adapter that the LAN1 on the Supervisor was using because that was my only convenient source of power. Then I plugged LAN1 into the Pi, and I got the 503 Service Unavailable error when using the HTTP GET request. So, today I worked a bit harder and got an extension cord, so I left the PowerLine adapter plugged in with LAN1 connected. Then I connected the supervisor LAN2 to the Pi, and the HTTP GET request works and I can get the DeviceList and DeviceDetails. The payload is a little different than the PVS6, but the basic information is there.

            So, the lesson I learned is that you need to use the other LAN port for this to work; in fact you may have written that and I just didn’t notice.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.