Skip to content

A project to read an inverter and switch loads on and off depending on the available power

License

Notifications You must be signed in to change notification settings

minou65/ESP32-Powerbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

106 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PVPowerbox

Table of contents

Description

The PVPowerbox allows loads to be switched on or off depending on the power available from the photovoltaics. In the picture you can see how the loads (red) are switched on and off, depending on the power (green) that is available. The regular peaks are from the heat pump, which is not controlled via the PVPowerbox

alt text Home page

Libraries

Homepage

The PVPowerbox provides a web interface that displays real-time information about your photovoltaic system and connected devices.

Information Displayed

Header

  • Current date and time
  • RSSI (Signal Strength) - displayed in the top right corner

Grid Section

  • Voltage A, B, C (in Volts)
  • Current A, B, C (in Amperes)
  • Active Power (in Watts)
  • Power Direction (to Grid / from Grid)

Inverter Section

  • Polling interval (in seconds)
  • Standby status (Yes/No)
  • Active Power (in Watts)

Device Section Shows all configured devices with their current status indicated by colored indicators:

  • Off (Grey): Device is disabled/off
  • On (Green): Device is currently enabled/on
  • Delayed Off (Orange): Device will be switched off soon (delay period active)

Network Section

  • MAC Address
  • IP Address

Quick Links

  • Link to the configuration page
  • Link to WebSerial Console for live logs
  • Software version

RSSI (Signal Strength)

The RSSI is displayed in dBm at the top right of the homepage. RSSI is a measurement of how well your device can hear a signal from an access point or router.

  • Required for Amazing Signal Strength: Around -30 dBm. Achievable only when the client device is very close to the access point (AP).
  • Very Good Signal Strength: Approximately -67 dBm. Suitable for applications like VoIP/VoWi-Fi and streaming video.
  • Moderate Signal Strength: Around -70 dBm.

Settings

Inverter

IPAddress

IP address of the inverter
Default: 192.168.1.105

Port

Modbus TCP port of the inverter
Default: 502
Range: 1-65535

Interval (seconds)

This setting specifies the time interval in seconds between each polling of the inverter.
Default: 10 seconds
Range: 10-255 seconds

Time Source (NTP)

Use NTP server

Enable or disable NTP time synchronization
Default: Enabled

NTP server

NTP server address (FQDN or IP address)
Default: pool.ntp.org

POSIX timezone string

POSIX timezone string for your location. This defines the timezone and daylight saving time rules.
Default: CET-1CEST,M3.5.0,M10.5.0/3 (Central European Time)

Examples:

  • CET-1CEST,M3.5.0,M10.5.0/3 (Central European Time)
  • EST5EDT,M3.2.0,M11.1.0 (Eastern US Time)
  • PST8PDT,M3.2.0,M11.1.0 (Pacific US Time)

Device

Devices can be configured as either relay-controlled outputs or URL-controlled devices (e.g., Shelly switches).

Type

Select the type of device:

  • Relay: Direct GPIO control for relay outputs
  • URL: HTTP-based control for network devices (e.g., Shelly switches)

Device Name

Description/name of the device for identification purposes.

Power (W)

The minimum power from the photovoltaic system required for the device to be activated.

Power-off Delay (minutes)

Delay time in minutes before the device is switched off when the power falls below the power setting.
Range: 1-300 minutes, default: 1 minute

Allowed ON from / until

Define a time window during which the device is allowed to be switched on.

  • Allowed ON from: Start time (HH:MM format, default: 00:00)
  • Allowed ON until: End time (HH:MM format, default: 23:59)

The device will not be activated outside of this time window.

Relay

For devices with Type = "Relay":

Select the relay to control:

  • Relay 1 = GPIO 22
  • Relay 2 = GPIO 21
  • Relay 3 = GPIO 17
  • Relay 4 = GPIO 16

URL On / Off

For devices with Type = "URL":

Partial Load Settings

  • Allow Partial Load Activation: Enable this to allow the device to be activated with partial solar power
  • Partial Load Threshold: Threshold value between 0.0 and 1.0 for partial load activation

WiFi

Default Password

When not connected to an AP the default password is 123456789

Default IP address

When in AP mode, the default IP address is 192.168.4.1

OTA

OTA is enabled, use default IP address or if connected to an AP the correct address. Port is the default port.

Configuration options

After the first boot, there are some values that need to be set up. These items are marked with * (star) in the list below.

You can set up the following values in the configuration page:

  • Thing name - Please change the name of the device to a name you think describes it the most. It is advised to incorporate a location here in case you are planning to set up multiple devices in the same area. You should only use English letters, and the "_" underscore character. Thus, must not use Space, dots, etc. E.g. lamp_livingroom *
  • AP password - This password is used, when you want to access the device later on. You must provide a password with at least 8, at most 32 characters. You are free to use any characters, furthermore you are encouraged to pick a password at least 12 characters long containing at least 3 character classes. *
  • WiFi SSID - The name of the WiFi network you want the device to connect to. *
  • WiFi password - The password of the network above. Note, that unsecured passwords are not supported in your protection. *

Blinking codes

In previous chapters, blinking patterns were mentioned, now here is a table summarizing the meaning of the blink codes.

  • Rapid blinking (mostly on, interrupted by short off periods) - Entered Access Point mode. This means the device creates its own WiFi network around it. You can connect to the device with your smartphone (or WiFi capable computer).
  • Alternating on/off blinking - Trying to connect the configured WiFi network.
  • Mostly off with occasional short flash - The device is online.

Reset

When CONFIG_PIN is pulled to ground on startup, the Thing will use the initial password to build an AP. (E.g. in case of lost password)

Reset pin is D3 / IO17

About

A project to read an inverter and switch loads on and off depending on the available power

Resources

License

Stars

Watchers

Forks

Packages

No packages published