Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for EVT800 #9

Open
stsch99 opened this issue Sep 2, 2024 · 1 comment
Open

Support for EVT800 #9

stsch99 opened this issue Sep 2, 2024 · 1 comment

Comments

@stsch99
Copy link

stsch99 commented Sep 2, 2024

The Envertech EVT800 has a other cmd id in the data.hex string.
I had to add the 680056681004.

--- a/enverproxy.py
+++ b/enverproxy.py
@@ -253,7 +253,7 @@ class TheServer:
                 self.__log.logMsg('Reply sent to: ' + str(self.s), 3)
                 data = json.dumps({"ip":self.s.getpeername()[0], "last_seen":datetime.utcnow().isoformat()})
                 self.mqtt.publish('enverbridge/bridge', data)
-            elif data[:6].hex() == '6803d6681004':
+            elif data[:6].hex() in ['6803d6681004', '680056681004']:
                 # payload from converter
                 self.process_data(data)
             else:

Additionally the extract function breaks because of an empty string. To fix this my solution is to calculate wr_index_max out of the lenth:

--- a/enverproxy.py
+++ b/enverproxy.py
@@ -211,7 +211,7 @@ class TheServer:
         datainhex = data.hex()
         wr = []
         wr_index = 0
-        wr_index_max = 20
+        wr_index_max = ((len(datainhex)-40)//64)
         self.__log.logMsg("Processing Data", 5)
         while True:
             if len(datainhex) > (40+64+64*wr_index):

This setting works fine for me with docker and the Envertech EVT800 with wifi.
I have set the Network Parameters setting to TCP-Client and have set the Server Address to the docker host.

@josefpavlik
Copy link

I confirm that the patch works well with EVT800. Thank you stsch99

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants