pwitab / iflag Goto Github PK
View Code? Open in Web Editor NEWA Python library for the Itron / Actaris IFLAG and Corus protocol
License: BSD 3-Clause "New" or "Revised" License
A Python library for the Itron / Actaris IFLAG and Corus protocol
License: BSD 3-Clause "New" or "Revised" License
The attribute for socket is set on connect()
which is not very nice structure. An Optional socket variable should be set on init. Probably just a miss since there is typing for the socket in init
relates to #6
IFlag when running prevents SRS Studio software from recognizing tachometer and LED. Please resolve conflict so IFlag can run concurrently with SRS Studio which controls my StImulator. Thanks!
Hi,
While I try to work with sample code to test the algorithm that you have wrotten, I got this below error;
Traceback (most recent call last):
File "gas.py", line 16, in <module>
client.read_parameters([IFlagParameter(id=0x5e, data_class=CorusString)])
File "/usr/local/lib/python3.6/dist-packages/iflag/client.py", line 70, in read_parameters
in_data = self._read_parameters_by_id(parameter_ids)
File "/usr/local/lib/python3.6/dist-packages/iflag/client.py", line 252, in _read_parameters_by_id
self.transport.send(msg.to_bytes())
File "/usr/local/lib/python3.6/dist-packages/iflag/transport.py", line 67, in send
self._send(data)
File "/usr/local/lib/python3.6/dist-packages/iflag/transport.py", line 132, in _send
self.socket.sendall(data)
AttributeError: 'TcpTransport' object has no attribute 'socket'
Please give some tips :)
In newer version of i-flag the paramteres have been extendend and now include numbers that are not representable with one byte.
The second byte is padded with 1:s on the left half of the byte.
Ex: 284 -> 0x100 -> b"\xf1\x20"
Need to investigate when the initial values is padded with \xf0. It could be when the first byte contains 4 1:s in the left half. so that it is not confused with the start of a 2 byte parameter.
After creating a client you need to call .startup()
to init the connection and send wakeup procedure etc.
Relate to: #6
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.