GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - neilbacon/sofar_g3_lsw3_logger_reader: Tool written in GO for reading and exporting metrics from Sofar LSW-3 inverters with SN 23XXXXXXX

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

45 Commits
45 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
adapters
adapters
 
 
grafana
grafana
 
 
ports
ports
 
 
sh
sh
 
 
.gitignore
.gitignore
 
 
Dockerfile
Dockerfile
 
 
LICENSE.md
LICENSE.md
 
 
Makefile
Makefile
 
 
README.md
README.md
 
 
config-example.yaml
config-example.yaml
 
 
config.go
config.go
 
 
docker-compose.yaml
docker-compose.yaml
 
 
go.mod
go.mod
 
 
go.sum
go.sum
 
 
hacs.json
hacs.json
 
 
info.md
info.md
 
 
main.go
main.go
 
 

Repository files navigation

Sofar g3 LSW-3 logger reader

Tool written in GO for reading metrics from Sofar LSW-3 and writing results into MQTT topics. Program queries logger modbus port in infinite loop and sends data into MQTT topics (e.g. mosquito in HomeAssistant).

Installation and setup

  1. Download go 1.19
  2. Clone this repo git clone [email protected]:kubaceg/sofar_g3_lsw3_logger_reader.git
  3. Go into project directory cd sofar_g3_lsw3_logger_reader
  4. Copy example config cp config-example.yaml config.yaml
  5. Edit config.yaml in Your favorite editor, fill all required stuff
  6. Build program make build or build for ARM machines e.g. raspberryPi make build-arm
  7. Run ./sofar or sofar-arm

Output data format

MQTT

Data will be sent into MQTT topic with name {mqttPrefix}/{fieldName} where:

  • mqttPrefix is value defined in config.yaml e.g. /sensors/energy/inverter
  • fieldName is measurement name, all available measurements are described in adapters/devices/sofar/sofar_protocol.go, e.g. PV_Generation_Today

Full topic name for given example values is /sensors/energy/inverter/PV_Generation_Today. Additional field is All which contains all measurements and their values marshalled into one json.

OTLP

Data can also be sent over OTLP protocol to a gRPC or http server. Typically, this would be received by the OTel-Collector for further export to any required platform.

Metrics are all captured as gauges and recorded and exported at the same frequency that measurements are taken. Metric names follow the convention sofar.logger.<fieldName> by default. This can be updated in the configuration file.

Grafana dashboard

You can monitor Your solar instalation using grafana dashboard

Origin

This is based on program written by @sigxcpu76 XtheOne/Inverter-Data-Logger#37 (comment).

Contributing

Feel free if You want to extend this tool with new features. Just open issue or make PR.

About

Tool written in GO for reading and exporting metrics from Sofar LSW-3 inverters with SN 23XXXXXXX

Topics

lsw3mqttsofarsolarpower

Resources

Readme
License
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.