Giter Club home page Giter Club logo

pvcharger's Introduction

go-eCharger PV Surplus Controller

Overview

This is a privat project provides a solution for intelligently managing the charging of a go-eCharger wallbox by considering the surplus power generated from photovoltaic (PV) systems. It's designed to integrate with a Sonnen PV battery and can be used in conjunction with OpenHAB for home automation.

Features

PV Surplus Calculation: Continuously monitors PV power generation and calculates surplus by accounting for current household usage. Smart Charging: Adjusts the charging power of the go-eCharger wallbox based on real-time calculations, ensuring optimal use of surplus PV energy. Battery Capacity Consideration: Takes into account the capacity of the connected Sonnen PV battery to maximize efficiency. Frequent Updates: The system checks the PV power every minute and makes adjustments accordingly.

Requirements

go-eCharger Wallbox Sonnen PV Battery System OpenHAB Home Automation Setup

How It Works

PV Power Monitoring: The script checks the PV power output every minute. Calculating Surplus: By subtracting current household usage from the PV output, it calculates the surplus power. Loop Interaction: After 15 iterations, it calculates the average PV surplus. Adjusting Charge Power: Based on the average surplus and battery capacity, it adjusts the charge power of the go-eCharger wallbox and LEd color to visualize the charge capability.

graph TD
A[Synology Docker Container] -->|API| B[Sonnen API]

A[Synology Docker Container] -->|API| C[Go-echarger API]
A[Synology Docker Container] -->|API| K[openhab API]
B[Sonnen API] -.->|PV data every min|D("Input Data
                PV_Production
                PV_Concumption
                Wallbox charging state
                Wallbox Ampere set
                Wallbox Automation Status")
K[openhab API] -.->|Wallbox Automation Item ON/OFF| D
C[Go-echarger API] -.->|wallbox state every 15min| D
D --> L{"Wallbox Automation
          ON or OFF"}
L -->|OFF| M["wait 60 seconds"]
M --> A[Synology Docker Container]
L -->|ON| E("Caluclate PV Surplus and set Wallbox Charging
         Ampere for next 15 min
        PV Surplus = PV Produnction - House consumption")
E --> F{"PV Surplus > Charge min Power"}
F -->|no| G{"If battery > 50%"}
G --> |no| H["wallbox stop charging
             set LED color to red"]
G -->|yes| I["wallbox start charging
              set 6A charge power
              set LED color to green"]
F -->|yes| J["Set best Ampere set depending
              on average PV Surplus in last 15 min
              Set LED color to green"]

Loading

Build Image (optional)

acme@nadine-PC:/mnt/c/Users/nadine/Documents/Container$ docker build --no-cache -t pvcharger:RC17 . docker image tag pvcharger:RC17 schwabenschulle/pvcharger:1.1 docker push schwabenschulle/pvcharger:1.1

Start Docker Container:

Open the Docker application on your Synology NAS. Navigate to the 'Image' tab. Select the option to add an image from a URL. Download the Container:

In the URL field, enter schwabenschulle/pvcharger. This should allow you to download the container from DockerHub. image

Container Configuration:

Once the container is downloaded, click 'Start' to initiate the container setup. You will need to adjust the Volume and Environment Variables as part of the setup.

Set Volume You need to mount a host folder to /var/log/containers image

Set Environment Variables:

In the environment variables section, you need to add the URLs for your wallbox, Sonnen battery, and OpenHAB. These URLs are essential for the container to communicate with your devices.

e.g. url_wallbox = "http://192.168.8.18" url_sonnen = "http://192.168.8.6" url_openhab = "http://192.168.8.42"

for testing: export url_wallbox="http://192.168.88.18" export url_sonnen="http://192.168.88.6" export url_openhab="http://192.168.88.42"

image

Verify Successful Start:

After setting up the Docker container, you can confirm that it has started successfully by opening the 'Detail' tab in the Docker application. Within the 'Detail' tab, click on 'Protocol'. This should display logs. image

pvcharger's People

Contributors

schwabenschulle avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.