-
-
Notifications
You must be signed in to change notification settings - Fork 408
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
No infomation about battery - area - time. #641
Comments
Please also post your valetudo.conf. |
Thanks for the replay! here is my config file.
|
Looks like a port mismatch: |
Actually i changed the port to 8080 and i got the same issue. After that i changed the port in iptables to 80 from 8080 and the port in config file from 8080 to 80 and i got the same issue again. |
I found out that the data response from miio (??) cannot be mapped to the STATE_PROPERTIES object. After a few changes within ViomiValetudoRobot.js files i made it to work. Since i don't have big knowledge of nodejs, im not sure if what i did is right. I thought that is good to mention what i did to solve the problem |
What changes exactly? |
I have exactly the same issue with a viomi v7. My debug log looks very much like above. I'm very much interested in the fix. If I can provide debug logs, please let me know what (and how).
|
Hi there i have changed the pollState() function to
and i added to the begging of the function parseAndUpdateState and after the let newStateAttr; the following
After those changes UI started to receive the stats from the vacuum. |
Same problem for me and also seems no maps generate. I have not tried workaround changes by panoslouk from above. From my logs: <27>Jan 2 05:09:17 valetudo[934]: [1970-01-01T21:09:17.672Z] [WARN] Token is okay, however we're unable to reach the vacuum { My nats: root@TinaLinux:/mnt/UDISK# iptables -L -n -t nat Chain INPUT (policy ACCEPT) Chain OUTPUT (policy ACCEPT) My config: Host file entries; |
I have the same vacuum robot, you must change the port in /etc/rc.d/S51valetudo from 80 to 8080. After that change the webserver port in config file to 8080 to receive map data. |
Thanks panoslouk I will give this a try and do another full clean to see if the map appears. |
Download the pre-release from here https://github.com/Hypfer/Valetudo/archive/2021.01.0b0.zip More details and instructions you will find here https://valetudo.cloud/pages/development/building-and-modifying-valetudo.html |
Thanks for this. I can confirm everything looks good now. I just need to get the map after a full clean. |
Please share a trace level log with this modification |
See my trace log output below. Let me know if you want any other info. < truncated > |
@v0d0r It was missing the part with a successful get_prop command. The full raw request & reply is what I'm looking for |
<30>Jan 2 14:27:13 valetudo[1025]: [1970-01-02T06:27:13.519Z] [TRACE] Trying to read token file at /etc/miio/device.token |
For what its worth. My maps still did not work after changing to port 8080. I then did a tcpdump and just excluded port 22. I then saw 2 new IP addresses. I am not sure why these werenot caught by the host file. iptables now caters for these IP's Chain OUTPUT (policy ACCEPT) And my MAP now shows after the cloud connect is in the log. |
not sure if that trace log will help you out but im posting here just for the record.
|
In the old code, the response array was mapped to the requested properties before then parsing it: Lines 416 to 423 in 6db8b76
which would provide a working Valetudo on the robots of the users in this issue since it looks like this:
In the current codebase there's no such thing happening Valetudo/lib/robots/viomi/ViomiValetudoRobot.js Lines 121 to 129 in cd76abe
which apparently also works on at least @depau's viomi? Why is that? |
If i understand correctly you mean that maybe the fw version of the vacuum was create that issue? btw according to the old code i changed the pollstate() function. Now the parseAndUpdateState() function seems to work good.
|
Not to hijack this issue but out of interest @panoslouk does your Zones work at all? The only thing I get working in Zones is restricted areas. As this is my first time on Valentudo I am not sure if this is meant to work and/or if it work in previous releases. Another thing that also does not work for me is the setting of the vacuum from max,medium low etc. Curious to hear if yours are working or if its just an issue on my end. |
No zones and fan speed doesn't work. :/ Maybe this issue have to do with pre-release version of valetudo. I'm waiting for the next stable version to try it out. |
Thanks for confirming. I will also wait and see how things pan out on the next release. For now I am super happy with the features working as is. Well done to the entire dev team. |
I can also confirm that using the old code fixes the issue for me Running fw 3.5.3_0047 |
Hi, I can't give you a proper answer right now, but from what I can remember, yes, you send "get_prop" with all the data you need and it replies with that array. I think the issue though might have to do with this line: this.parseAndUpdateState(response[0]); // why [0]? I don't remember any issues with the status polling code but I may have f'd up and never realized, and it looks like this might be the case. Keep in mind that when I wrote the code the UI wasn't wired up to the capabilities system yet so I never got the chance to test it properly. btw, I'm planning to finish up with the Viomi capabilities soon™ after I finish up with what I'm working right now ;) |
Hi, response: [5,0,2105,100,1,0,26,20.04,3,12,1,1,0,1] but on the next step in parseAndUpdateState() it expects dictionary with named fields instead of array of values like data["battary_life"] and so on. I can confirm that @panoslouk fix above with statusDict mapping solves this particular issue for me. |
* Fix output of checksum errors (was binary, now is '<Buffer xx …>') * Make the map upload server listen on 0.0.0.0 for the local development setup. * Support hex cloudSecrets as mentioned in the documentation. * Viomi: fix status parsing (#641) * Merge local dev instructions for viomi and roborock. Add a few missing details. * Simplify dummycloud setup. We now require a patch to miio_client to change the http_dns address to 127.0.0.1. Similarly /etc/hosts should be updated to map the ot.mio names to 127.0.0.1.
This particular issue should be fixed in current HEAD. Much of the rest of the UI still isn’t functional though, looking forward to @depau’s implementation of the missing capabilities. Note that installation instructions have changed so when redeploying a new binary you’ll need some adjustments. |
Describe the bug
I successfully installed valetudo but i can't find out why i can't retrieve information about battery status, area and time. I believe this issue have to do with miio (maybe i have done wrong about firewall rules or something wrong with config file).
Any advice what can i do?
You can find some log files and screenshots bellow.
Screenshots
Vacuum Model
Viomi.v8 - STYTJ02YM
Valetudo Version
2021.01.0b0
Firmware Version
3.5.3_0017
User-Agent
The text was updated successfully, but these errors were encountered: