eebus-go
Enable your products and services to support the energy management protocol EEBUS, the communication interface that enables energy management relevant devices in buildings to connect and interact with each other and with grid and market operators.
https://github.com/enbility/eebus-go
Category: Energy Systems
Sub Category: Energy Data Accessibility and Integration
Keywords
charging-stations eebus electric-vehicles emobility energy-management energy-management-systems
Last synced: about 23 hours ago
JSON representation
Repository metadata
EEBUS protocol implementation in go
- Host: GitHub
- URL: https://github.com/enbility/eebus-go
- Owner: enbility
- License: mit
- Created: 2022-04-11T13:29:20.000Z (about 3 years ago)
- Default Branch: dev
- Last Pushed: 2025-04-09T09:28:19.000Z (18 days ago)
- Last Synced: 2025-04-14T22:01:59.302Z (12 days ago)
- Topics: charging-stations, eebus, electric-vehicles, emobility, energy-management, energy-management-systems
- Language: Go
- Homepage: https://enbility.net
- Size: 2.44 MB
- Stars: 75
- Watchers: 15
- Forks: 29
- Open Issues: 17
- Releases: 12
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
README.md
eebus-go
This library provides a foundation for implementing EEBUS use cases in go. It uses the SHIP implementation ship-go and the SPINE implementation spine-go. Both repositories started as part of this repository, before they were moved into their own separate repositories and go packages.
Basic understanding of the EEBUS concepts SHIP and SPINE to use this library is required. Please check the corresponding specifications on the EEBUS downloads website.
Introduction
The supported functionality contains:
- Support for SHIP 1.0.1 via ship-go
- Support for SPINE 1.3.0 via spine-go
- Certificate handling
- mDNS Support, incl. avahi support
- Connection (websocket) handling, including reconnection and double connections
- Support for handling pairing of devices
Packages
api
: global API interface definitions and eebus service configurationfeatures/client
: provides feature helpers with the local SPINE feature having the client role and the remote SPINE feature being the server for easy access to commonly used functionsfeatures/server
: provides feature helpers with the local SPINE feature having the server role for easy access to commonly used functionsservice
: central package which provides access to SHIP and SPINE. Use this to create the EEBUS service, its configuration and connect to remote EEBUS servicesusecases
: containing actor and use case based implementations with use case scenario based APIs and events
Examples
The examples folder contains a few demo applications using this stack. These do not provide complete implementations of any use case, but are intended as usage guidelines for the eebus-go stack in general and to have a quick demo.
Therefore, please do not expect any of these examples to provide any meaningful functionality on their own, but instead view them as rough guidelines on the functionality you could implement using the eebus-go stack.
Controlbox
This includes example code for sending an LPC limit 5 seconds after connecting to a compatible device that can receive LPC limits.
First Run
go run cmd/controlbox/main.go 4713
4713
is the example server port that this process should listen on
The certificate and key and the local SKI will be generated and printed. You should then save the certificate and the key to a file.
General Usage
Usage: go run cmd/controlbox/main.go <serverport> <remoteski> <certfile> <keyfile>
remoteski
is the SKI of the remote device or service you want to connect tocertfile
is a local file containing the generated certificate in the first usage runkeyfile
is a local file containing the generated key in the first usage run
HEMS
This includes example code for accepting LPC and LPP limits from a control box, receiving and printing data to the console from battery (VABD) and pv inverters (VAPD) and grid connection point data (MGCP).
First Run
go run cmd/hems/main.go 4714
4714
is the example server port that this process should listen on
The certificate and key and the local SKI will be generated and printed. You should then save the certificate and the key to a file.
General Usage
Usage: go run cmd/hems/main.go <serverport> <remoteski> <certfile> <keyfile>
remoteski
is the SKI of the remote device or service you want to connect tocertfile
is a local file containing the generated certificate in the first usage runkeyfile
is a local file containing the generated key in the first usage run
EVSE
This includes example code for accepting LPC from a control box.
First Run
go run cmd/hems/main.go 4715
4715
is the example server port that this process should listen on
The certificate and key and the local SKI will be generated and printed. You should then save the certificate and the key to a file.
General Usage
Usage: go run cmd/evse/main.go <serverport> <remoteski> <certfile> <keyfile>
remoteski
is the SKI of the remote device or service you want to connect tocertfile
is a local file containing the generated certificate in the first usage runkeyfile
is a local file containing the generated key in the first usage run
Explanation
The remoteski is from the eebus service to connect to.
If no certfile or keyfile are provided, they are generated and printed in the console so they can be saved in a file and later used again. The local SKI is also printed.
SHIP implementation notes
- Double connection handling is not implemented according to SHIP 12.2.2. Instead the connection initiated by the higher SKI will be kept. Much simpler and always works
- PIN Verification is NOT supported other than SHIP 13.4.4.3.5.1 "none" PIN state is supported!
- Access Methods SHIP 13.4.6 only supports the most basic scenario and only works after PIN verification state is completed.
- Supported registration mechanisms (SHIP 5):
- auto accept (without any interaction mechanism!)
- user verification
This approach has been tested with:
- Elli Charger Connect
- Porsche Mobile Charger Connect
- SMA Home Energy Manager 2.0
Interfaces
Verbose logging
Use SetLogger
on Service
to set the logger which needs to conform to the logging.Logging
interface of ship-go.
Example:
configuration = service.NewConfiguration(...)
h.myService = service.NewEEBUSService(configuration, h)
h.myService.SetLogging(h)
Owner metadata
- Name: enbility
- Login: enbility
- Email:
- Kind: organization
- Description: Solutions for using the EEBUS protocol
- Website: https://enbility.net
- Location: Germany
- Twitter:
- Company:
- Icon url: https://avatars.githubusercontent.com/u/118294492?v=4
- Repositories: 7
- Last ynced at: 2024-04-18T16:36:18.874Z
- Profile URL: https://github.com/enbility
GitHub Events
Total
- Issues event: 6
- Watch event: 21
- Delete event: 5
- Issue comment event: 45
- Push event: 36
- Pull request review comment event: 60
- Pull request review event: 37
- Pull request event: 41
- Fork event: 8
- Create event: 11
Last Year
- Issues event: 6
- Watch event: 21
- Delete event: 5
- Issue comment event: 45
- Push event: 36
- Pull request review comment event: 60
- Pull request review event: 37
- Pull request event: 41
- Fork event: 8
- Create event: 11
Committers metadata
Last synced: 7 days ago
Total Commits: 896
Total Committers: 8
Avg Commits per committer: 112.0
Development Distribution Score (DDS): 0.079
Commits in past year: 162
Committers in past year: 5
Avg Commits per committer in past year: 32.4
Development Distribution Score (DDS) in past year: 0.074
Name | Commits | |
---|---|---|
Andreas Linde | m****l@a****e | 825 |
taimo42 | 6****2 | 53 |
Lukas Einfalt | l****x@l****e | 5 |
Simon Thelen | s****n@e****e | 5 |
Andrew Johnson | a****9@g****m | 3 |
Klaus Jaroslawsky | K****y@s****e | 2 |
ahmed.magdy | a****y@c****m | 2 |
StefanSchoof | 4****f | 1 |
Committer domains:
- coretech-innovations.com: 1
- so-oftware.de: 1
- enqs.de: 1
- lukx.de: 1
- andreaslinde.de: 1
Issue and Pull Request metadata
Last synced: 2 days ago
Total issues: 51
Total pull requests: 110
Average time to close issues: about 2 months
Average time to close pull requests: 10 days
Total issue authors: 11
Total pull request authors: 12
Average comments per issue: 1.53
Average comments per pull request: 0.97
Merged pull request: 89
Bot issues: 0
Bot pull requests: 0
Past year issues: 15
Past year pull requests: 77
Past year average time to close issues: 6 days
Past year average time to close pull requests: 5 days
Past year issue authors: 7
Past year pull request authors: 9
Past year average comments per issue: 2.13
Past year average comments per pull request: 0.82
Past year merged pull request: 60
Past year bot issues: 0
Past year bot pull requests: 0
Top Issue Authors
- DerAndereAndi (37)
- heavyweight87 (3)
- sthelen-enqs (2)
- andig (2)
- randomdudebunchofnumbers (1)
- elgohr (1)
- lukx (1)
- tbazire (1)
- Ab0Ddore (1)
- TobiasHuber1980 (1)
- Rosi1981 (1)
Top Pull Request Authors
- DerAndereAndi (71)
- sthelen-enqs (10)
- taimo42 (7)
- lukx (5)
- andig (5)
- anjrew (4)
- AhmedMagdyCoretech (2)
- heavyweight87 (2)
- jaroslawsky (1)
- StefanSchoof (1)
- daviddsapir (1)
- heinemannj (1)
Top Issue Labels
- enhancement (22)
- SHIP (11)
- eebus spec (10)
- SPINE (8)
- help wanted (7)
- bug (5)
- good first issue (1)
- question (1)
- documentation (1)
Top Pull Request Labels
- enhancement (15)
- bug (4)
- SHIP (1)
- SPINE (1)
Package metadata
- Total packages: 1
- Total downloads: unknown
- Total docker downloads: 363,242
- Total dependent packages: 10
- Total dependent repositories: 12
- Total versions: 16
proxy.golang.org: github.com/enbility/eebus-go
- Homepage: https://github.com/enbility/eebus-go
- Documentation: https://pkg.go.dev/github.com/enbility/eebus-go#section-documentation
- Licenses: MIT
- Latest release: v0.7.0 (published 7 months ago)
- Last Synced: 2025-04-25T03:01:16.515Z (2 days ago)
- Versions: 16
- Dependent Packages: 10
- Dependent Repositories: 12
- Docker Downloads: 363,242
-
Rankings:
- Docker downloads count: 0.784%
- Dependent repos count: 1.556%
- Dependent packages count: 2.98%
- Average: 4.619%
- Forks count: 8.872%
- Stargazers count: 8.904%
Dependencies
- github.com/ahmetb/go-linq/v3 v3.2.0
- github.com/davecgh/go-spew v1.1.1
- github.com/godbus/dbus/v5 v5.0.4
- github.com/google/go-cmp v0.5.8
- github.com/gorilla/websocket v1.5.0
- github.com/holoplot/go-avahi v1.0.0
- github.com/libp2p/zeroconf/v2 v2.0.0-20220623102032-af1f1d3ada85
- github.com/miekg/dns v1.1.49
- github.com/pmezard/go-difflib v1.0.0
- github.com/rickb777/date v1.19.1
- github.com/rickb777/plural v1.4.1
- github.com/stretchr/objx v0.4.0
- github.com/stretchr/testify v1.7.1
- gitlab.com/c0b/go-ordered-json v0.0.0-20201030195603-febf46534d5a
- golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3
- golang.org/x/net v0.0.0-20220531201128-c960675eff93
- golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a
- golang.org/x/tools v0.1.10
- golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df
- gopkg.in/yaml.v3 v3.0.1
- github.com/DerAndereAndi/go-avahi v0.0.0-20220623134409-61c3cd3f6dd4
- github.com/ahmetb/go-linq/v3 v3.2.0
- github.com/davecgh/go-spew v1.1.0
- github.com/davecgh/go-spew v1.1.1
- github.com/godbus/dbus/v5 v5.0.4
- github.com/google/go-cmp v0.5.8
- github.com/gorilla/websocket v1.5.0
- github.com/libp2p/zeroconf/v2 v2.0.0-20220623102032-af1f1d3ada85
- github.com/miekg/dns v1.1.43
- github.com/miekg/dns v1.1.49
- github.com/onsi/gomega v1.19.0
- github.com/pmezard/go-difflib v1.0.0
- github.com/rickb777/date v1.19.1
- github.com/rickb777/plural v1.4.1
- github.com/stretchr/objx v0.1.0
- github.com/stretchr/objx v0.4.0
- github.com/stretchr/testify v1.7.1
- github.com/yuin/goldmark v1.3.5
- gitlab.com/c0b/go-ordered-json v0.0.0-20201030195603-febf46534d5a
- golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2
- golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550
- golang.org/x/mod v0.4.2
- golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3
- golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3
- golang.org/x/net v0.0.0-20190620200207-3b0461eec859
- golang.org/x/net v0.0.0-20210226172049-e18ecbb05110
- golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4
- golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6
- golang.org/x/net v0.0.0-20210726213435-c6fcb2dbf985
- golang.org/x/net v0.0.0-20220531201128-c960675eff93
- golang.org/x/sync v0.0.0-20190423024810-112230192c58
- golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
- golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a
- golang.org/x/sys v0.0.0-20190412213103-97732733099d
- golang.org/x/sys v0.0.0-20201119102817-f84b799fce68
- golang.org/x/sys v0.0.0-20210303074136-134d130e1a04
- golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44
- golang.org/x/sys v0.0.0-20210423082822-04245dca01da
- golang.org/x/sys v0.0.0-20210426080607-c94f62235c83
- golang.org/x/sys v0.0.0-20210510120138-977fb7262007
- golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c
- golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a
- golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1
- golang.org/x/text v0.3.0
- golang.org/x/text v0.3.3
- golang.org/x/text v0.3.6
- golang.org/x/text v0.3.7
- golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e
- golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e
- golang.org/x/tools v0.1.6-0.20210726203631-07bc1bf47fb2
- golang.org/x/tools v0.1.10
- golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7
- golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898
- golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1
- golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df
- gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405
- gopkg.in/yaml.v2 v2.4.0
- gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c
- gopkg.in/yaml.v3 v3.0.1
- actions/checkout v2 composite
- actions/setup-go v2 composite
- golangci/golangci-lint-action v3 composite
- shogo82148/actions-goveralls v1 composite
Score: 19.404126251583403