3D PrintingHome Automation

Solar Generation Monitoring with Home Assistant

Back in ?? we had Solar Panels installed for free on our roof by A Shade Greener, free as they take the money from the feed-in tariff, and yet we get to use the electricity that’s generated. Due to my wife’s ironing business, we consume a large amount of energy during the daytime, so having some of this for free, without any outlay is great.

However whilst the solar panels are connected up to their own smart meter, the data available via the A Shade Greener website is very basic, just daily data for the last month. I’ve been using our Owl Intuition-pv to measure our grid consumption, solar generation and overall electricity usage for many years. But as these use simple clamp meters they aren’t super accurate but good enough for me.

Recently a friend, another A Shade Greener customer and Home Assistant enthusiast asked for help to monitor his Solar generation and I was more than happy to help.

Electricity Meter

The meters installed by A Shade Greener are ISKRAEMECO ME382 (below left) whilst these meters can provide a serial interface via the “P1” port, this isn’t accessible without removing the secured lower cover and attaching an extra module. So instead in order to measure consumption, we can count flashes from the LED. Each 30ms pulse for every one-thousandth kWh generated.

Pulse Counting Sensor

Recently as part of Home Assistant launching their Energy Dashboard, they also release Home Assistant Glow, an ESPHome sensor for attaching to meters and counting pulses. So no need to develop my own solution when this will work just fine.

But always an opportunity to do some 3D printing ๐Ÿ˜‰ I looked initially at a couple of designs that both had the light sensor and the MCU in separate enclosures connected by a short bundle of wires. I decided it didn’t need two different enclosures and could instead design an all in one solution. The model is available on Printable.com.

The sensor is using an ESP32 based MCU that I had to hand, (an ESP8266 would also be suitable and a little smaller) and a photo diode sensor module with a digital output. The photo diode sensor is connected with just 3 wires, 2 for power and one for signal. The entire sensor just needs power from a simple USB power supply.

I did briefly investigate the feasibility of powering the sensor with a battery/baterry pack, but the consumption would drain the battery very quickly. WiFi just isn’t the technology to use for low power sensors.

Energy Monitoring

With the sensor added via ESPHome into Home Assistant, the Energy dashboard now records the solar generated more accurately for my friend and they can use this data to determine if it’s worth investing in battery storage solution alogn with using the solar prediction to plan when to use certain energy hungry appliances.

10 thoughts on “Solar Generation Monitoring with Home Assistant

  • Many thanks. I have a question, how did you connected the Pulse Counting Sensor
    to the meter?

    Reply
    • Martin

      During testing and to get the positioning right I used Blu Tack, then used a 3M command strip, so it could be relatively easily moved.

      Reply
      • Jose Luis Molto Marin

        Sorry, I meant to what cables should be connected together and where they are.

        Reply
        • It’s not physically connected to the meter. It is attached to the front to count the pulses of light. If you look at the pictures in the post above you’ll see the light detection sensor is connected to a small microcontroller. This is put into the small box and attached via a 3M command strip to the front of the meter. The sensor is then powered via a MicroUSB cable and standard USB power adapter. I hope that clears things up.

          Reply
          • OK thanks, yes I understood that after I read it again. Now my issue will be how to pass from a 220v cable to a USB. The meters are in the loft and I just have a cable for the light.

            Reply
            • Hi a couple of options:

              • Run a USB cable down into a room below the loft with a long USB cable
              • Tap of the lighting circuit in the loft, but so so by taking the feed and connecting it to a fused spur, with a 1A fuse if you can find one, else 3A. Connect then output from the fuse spur to a standard socket, and connect a normal USB charger too that. Label the socket as for charger use only, and make it clear it’s connected to the lighting circuit.
              Reply
  • I have the same setup as you.
    Any idea how ashadegreener get the generation data?
    I donโ€™t think this meter can phone-home. Th inverter maybe?

    Hoping there might be an api we could feed into HomeAssistant.

    I can get the live power usage from the supply smart meter into HA. And the supply meter shows Total active export kWh but this number differs from ASG reading and isnโ€™t visible on the DCC API.

    The inverter shows live power being generated. Toyed with the idea of using a camera to snapshot and read it that way lol.

    Other option was a Shelly em to clamp onto the Solar feed.

    Reply
    • The meter pictured and installed by AShadeGreener does have a built-in modem, from the manual “Built-in interface (IR) and GSM/GPRS modem for a remote two-way communication, meter
      programming and data downloading,” so this will be how they get their data. The ASG website is pretty poor with only a low-resolution summary of the data, so they may only be calling home daily with updated data, which might save on costs I suppose.

      At the moment if you want to take measurements then clamp meters might be your best bet, especially if you want to get more than just the solar generation.

      Reply
  • Hi, I’m thinking of building a light pulse reader off an Aqara door sensor and a photyotransistor.

    It would basically be the same setup you have for your gas meter, but replacing the magnetic logger cable by an IR+visible light phototransistor (Osram SFH310), connected in parallel to the reed switch within the Aqara.

    Do you think this might work?

    Reply
    • Hi Alex, fundamentally I think it will work, though in a solar application I’d expect more pulses than my gas meter and so battery life would likely be lower.

      Reply

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.