enbility / spine-go Goto Github PK
View Code? Open in Web Editor NEWEEBUS SPINE protocol implementation in go
Home Page: https://enbility.net
License: MIT License
EEBUS SPINE protocol implementation in go
Home Page: https://enbility.net
License: MIT License
If a feature allows write, but does not announce partial, the remote device should not send partial writes. Hence the partial should be declined with an error in the ack return message
When a write message was accepted, and the data successfully merged, a notify of the updated data set should be sent to all subscribers.
This data model is quite different to the other models using listdescription
and listdata
. Right now the stack will trigger a full read incoming on partial data for this model.
What is needed:
TimePeriodType
EndTime
value, and no StartTime
is provided in a write message, the endTime should be converted to an absolute timestampAn application should be able to allow or deny write operations to a local server feature.
One example is that LoadControlLimits
are set which are outside of the allowed and assigned ElectricalConnectionPermittedValueSetData
. As these are loose dependencies defined in use cases, it is nothing the stack shall or can do automatically.
Current situation:
Ideas to improve this:
EventType
More ideas?
Right now a local server feature only allows setting the complete data set. This will then always trigger a full notify to all remote client features, even though data they are interested in might not have been changed.
To improve this, an UpdateData
feature should be introduced, that supports deletion of (partial) data and updating new data. This should then trigger a partial notify for this data only and be merged locally.
This should be possible to be implemented with the same/similar way a remote partial update is processed.
I think if it is fine, to expose an update the requires the API user to actively think about deletions, partial updates in the way SPINE does it. Then the stack wouldn't have to do any magic but the API user has to really know what they are doing.
Instead of manually checking every incoming write messages, they are handled fully automatically. To make sure data is rejected from being written from a remote client, the appropriate field items indicating if data is allowed to be written, need to be set.
E.g for LoadContrlLimitListDataType
the field IsLimitChangeable
needs to be set to false
Functions in FeatureLocalImpl
that request, notifiy or write data to a remote address should check, if the remoteEntity does support the requested operation on the function
Instead of creating the DetailedDiscvovery data structures in device, entity, features and operations using Information()
, use the SPINE model data structure instead and therefor remove custom code for handling this.
Noticed during evcc-io/evcc#13998 that this package now relies on github.com/hashicorp/golang-lru/v2 which is under MPL license. In general, projects like spf13/viper are trying to move away from depending on hashicorp due to their licensing changes. I'm no expert but wondering if MPL is compatible with MIT?
Multiple bindings are allowed per spec (in fact they are not prohibited).
The flow then should be:
The current behaviour is that only one binding is allowed.
If the remote device sends a notify with a partial dataset for a data structure that does not support partials yet, automatically send a read to receive to complete update date dataset.
SPINE covers way more data structures and constants than all use cases currently use. But right now everything is always included. So the task is to check out if the library size could be made smaller depending on the used usecases.
For the following list types namespaces, the update criteria is currently unclear:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.