Git Product home page Git Product logo

rs485-wifi-epever's Introduction

RS485 WiFi EPEver

This is a DIY RS485 to wifi adaptor which allows you to connect to your EPEver controller over wifi.

https://github.com/chickey/RS485-WiFi-EPEver/blob/master/images/Board-Image.PNG

Many EPEver solar charge controllers have an RS485 communication port on them so you can connect a PC or mobile device and see it's live data as well as statistical data. The code also allows this data to be pushed to an MQTT broker or an Influx DB which could then be visualised via a grafana dashboard.

I am currently tweaking and modifying the code so it shall evolve with more features as time goes on.

I took great inspiration from the following project:-

https://github.com/glitterkitty/EpEverSolarMonitor

I am also using the ESPUI project which without this I wouldn't have had the doody interfaces :-)

Tested Hardware

  • LS1024B

  • Tracer 3210A

  • MPPT Tracer 1210

  • Tracer AN Series

    • 2210AN, 3210AN and 4210AN
  • TRITON Series with RS485 module

Updating

Ensure when flashing the Wemos board that either it is not plugged into the RS485 adaptor or that that the board is not connected to the charge controller to avoid damage.

You can now update remotely by browsing to http://IP/ota and browsing to the precompiled binary file and then selecting upload.

Discussion

I'm always up for suggestions either via github or if you wish to chat with like minded people and pick people's brains on their setups i have setup a discord server

https://discord.gg/kBDmrzE

rs485-wifi-epever's People

Contributors

chickey avatar elwell avatar jmw6773 avatar midnightlink avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rs485-wifi-epever's Issues

Set online/offline as last will & testament

Hopefully this is a minor change to mqtt.h connect call - see upstream docs at https://pubsubclient.knolleary.net/api#connect to add in some extra parameters

if (mqtt_client.connect(clientId.c_str(),myConfig.mqtt_username,myConfig.mqtt_password)) {

Possibly look at the way tasmota does it? they have (for example)
tele/tasmota_id/LWT Online which reverts to
tele/tasmota_id/LWT Offline when no heartbeat / keepalive detected -- this allows Home Assistant to mark the sensor as unavailable (https://www.home-assistant.io/docs/mqtt/birth_will/ for docs)

MQTT Exceptions in Home Assistant

I'm getting these errors nonstop in home assistant logs

2023-09-02 13:58:25.589 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised when updating state of sensor.epever_solar_monitor_battery_temperature_2, topic: 'solar/status' with payload: b'{"batt_volt":"Normal","batt_temp":"Normal","charger_mode":"Float"}'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 591, in state
    numerical_value = int(value)
                      ^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'Normal'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 270, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 746, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 808, in _async_write_ha_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 752, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 595, in state
    raise ValueError(
ValueError: Sensor sensor.epever_solar_monitor_battery_temperature_2 has device class 'temperature', state class 'None' unit 'C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'Normal' (<class 'str'>)
2023-09-02 13:58:25.599 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised when updating state of sensor.epever_solar_monitor_battery_temperature, topic: 'solar/status' with payload: b'{"batt_volt":"Normal","batt_temp":"Normal","charger_mode":"Float"}'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 591, in state
    numerical_value = int(value)
                      ^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'Normal'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 270, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 746, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 808, in _async_write_ha_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 752, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 595, in state
    raise ValueError(
ValueError: Sensor sensor.epever_solar_monitor_battery_temperature has device class 'temperature', state class 'None' unit 'C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'Normal' (<class 'str'>)

Issues after sunset

Once dark the device stops reporting stats but they are reported when using the eperver wifibox01

misc minor issues

No about page with info such as version/contact etc
no confirmation when data has been saved for MQTT/influxdb

'AsyncWiFiManager' was not declared in this scope

The code as is gives the above compilation error in Arduino IDE with most recent 2.7.4 ESP8266 library.

Change:
WiFiManager.h to ESPAsyncWifiManager.h and use the library: alanswx/ESPAsyncWiFiManager

ESP32 support

Any chance this codebase would run on an esp32?
Thanks!

how to set hostname

Hello

will it be possible to set the hostname to "epever" from the gui?

best regards
Niels

ID selection

There should be a way to set the ID of the device being queried.

Load status incorrect

I have Load On in the settings but on Live it shows OFF. Also the output is On now. It appears that I need to do On/Off/On
to register the change to On, but if I just do one On it will never turn On and interestingly after On/Off/On the Load status is shown as Off.
rs485wifi

Epever Tracer3210AN Temperature not showing in HA

I've connected the charge controller included temperature probe to the controller but it's not showing in Home Assistant's data collected by mqtt. Don't know if this is known or not, but it should be supported. IMG_20240531_194950.jpg

IMG20240516175928.jpg

Screenshot_2024-05-31-19-50-46-76_c3a231c25ed346e59462e84656a70e50.jpg

FR: Add refresh interval to settings

Hi,

thanks for your great development.

Would it be possible to add an option under the settings tab, where you can specify how often the GUI/InfluxDB/MQTT request and send new data in seconds?

That would be awesome :)

Compiling my own copy?

I see the pre-compiled files and I see the src/RS485-WiFi-EPEver.ino.
How can I compile the .ino in the Arduino IDE? I'd like to make one or two tweaks...

Regards, M

MQTT TLS doesn't seem to be supported

Heya!

I've tried to connect to HiveMQ today, however it seems that TLS doesn't seem to be supported.
Would it be possible to add this feature?

Thanks!

"Reboot" option doesn't seem to reconnect to the Epever

Heya!

I tested my adapter out today and discovered that the "Reboot" function on the Settings page doesn't properly reconnect to the Epever. I had to un- and replug it to make it read values again.
It may also be an issue with enabling MQTT, as I've tested it out a lot and (at least seemingly) disabling MQTT helped to make it reconnect faster or more reliably after a reboot, but I can't tell for sure as I haven't specifically tested this behavior.

ip address

the IP address that shows up 192.168 4.*** is wrong for my network, I cant connect to it. How to change network IP for my network 192.168.1.****?

No ambient temp on XTRA 4415N v2.0 firmware

Hello,

thanks for this great project. I have ESP8266 NodeMcu RX/TX pins connected to MAX485 module whithout RE and DE pins. Everything is fine except I cant see ambient temp value. What I can do to read ambient temperature? Temp sensor is connected to controller and Solar Station Monitor can read values. Thank you.

Peter

Zero Values

Hey Colin, thanks for the quick delivery.
I got everything set up and I wonder why all values are "0".

Seems there is no connection to my Epever Controller.
Tried the same connection values (Baudrate and ID) on my PC with a RS to USB-Dongle and it worked.

Any hints?

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.