D900/901 Support

435 views
Skip to first unread message

Robert Gabrielson

unread,
Oct 3, 2018, 11:15:07 AM10/3/18
to sucks-users
I have a 900 and would be happy to participate in the work needed to get this new device supported.  Don't have python knowledge but could help get the information on the communication side if needed.

Anyone know if this is in process or what is needed to move it along?  I see there is a general guideline around protocol snooping, anyone know if this work has been done?

William Pietri

unread,
Oct 3, 2018, 12:48:50 PM10/3/18
to sucks-users
On 10/03/2018 08:15 AM, Robert Gabrielson wrote:
I have a 900 and would be happy to participate in the work needed to get this new device supported.  Don't have python knowledge but could help get the information on the communication side if needed.

Anyone know if this is in process or what is needed to move it along?  I see there is a general guideline around protocol snooping, anyone know if this work has been done?

Hi, Robert! As far as I know, nobody is working on this. Roughly what I think has to happen:
  1. Someone with a D900 captures the conversation between the app and the vacuum and document the protocol.
  2. Someone with at D900 turns that into rough working code and verify the D900 does everything it should.
  3. Someone who knows the current code figures out how to integrate the approach into how the sucks library works.
  4. The sucks code gets refactored to support both protocols.
  5. The D900 support gets added to sucks.
  6. A few people with D900s test the new code to make sure it works.

As an alternative to step 1 (and maybe step 2), somebody could try contacting Ecovacs and get protocol documentation from them.

I hope that helps!

William




Brian Martin

unread,
Jan 18, 2019, 12:04:15 AM1/18/19
to sucks-users
Hi All,

I have a fork where I am tackling this in a D901 branch (https://github.com/bmartin5692/sucks/tree/D901).  I have the 901, but believe the only difference between 900/901 is the color.  I've found that the communication protocols are entirely different for the D900/901 as compared to the existing sucks library/supported devices.  I suspect these changes in protocol will be shared by other EcoVac "IOT Product" devices so I've been building to support this assumption.

The devices I assume that fall in this bucket are:
  • DEEBOT 600 Series
  • DEEBOT OZMO Slim10 Series
  • DEEBOT OZMO 900
  • DEEBOT 711
  • DEEBOT 710
  • DEEBOT 900 Series
The code in this branch is working and I've taken care to make the changes compatible with the existing library structure and API.  If anyone is willing to test what has been done so far it would be great to see the results.  I would guess I am 95% there with a few items remaining before I feel comfortable with discussion of a PR:
  1. Further testing
  2. Additional unit tests
  3. Documenting the protocol differences
What I've found is this device isn't utilizing the XMPP system.  Commands and statuses are handled via a Rest API, and additionally MQTT is used for subscribing to messages that include status updates and positioning information while in a cleaning state (the 900/1 has mapping capability).

Longer-term one of the goals of my implementation is to extend the commands available in the library to all supported via the app.

Jonathan Woodall

unread,
Jan 24, 2019, 5:37:00 PM1/24/19
to sucks-users
Hey Brian - I was just capturing data for this as well. First, the 900 and 901 are supposed to only be differentiated by color, but I can not confirm this. I also see that MQTT is being used. I'm going to read through your info real quick and not re-invent the wheel if I can help it. I will definitely test what you have done so far as well. Please feel free to reach out if you need any testing or data collection.

Thanks!

Jon

Brian Martin

unread,
Feb 3, 2019, 4:39:06 PM2/3/19
to sucks-users
Thanks Jon.

This is in good shape if you do want to test my branch, I'd love to see if it works for you.  I've been using it without issue.

If you (or anyone) is interested in self-hosting the EcoVacs server (bumper), I've also updated bumper to fully support the D900/1 (and like sucks I assume it will work with other bots that use MQTT).  I have a branch for that here: https://github.com/bmartin5692/bumper/tree/D901 

I've got this working fully with both the official app and sucks, all running locally.

Jonathan Woodall

unread,
Feb 5, 2019, 9:22:37 AM2/5/19
to sucks-users
Brian - thanks for this. I'm setting it up now. I'll let you know the outcome.

Jonathan Woodall

unread,
Feb 5, 2019, 10:52:06 AM2/5/19
to sucks-users
Brian - while I'm thinking about it... have you reviewed the files created by the vacuum for mapping? I'm interested to see the format of the map file and if it is reasonably possible to change how areas are defined. I have an idea of how they did it, but just need to confirm. 

As an aside, if anyone reading this has experience with this sort of mapping from a firmware perspective, I have a longer term project to write my own firmware to the vacuum, and would welcome additional help. I can do it, but more people=potentially faster results.

Brian Martin

unread,
Feb 5, 2019, 11:33:04 AM2/5/19
to sucks-users
I haven't yet, but that is definitely on my list of TODOs.  I am interested in where you go with the firmware project when you get there.  I noticed in the Android source references to the map.bin file, but haven't retrieved one yet.

I have been watching the mapping calls made though and with my updated implementation of Bumper, I had considered finding a way to inject different maps/remap items as well.

Jonathan Woodall

unread,
Feb 5, 2019, 11:34:50 AM2/5/19
to Brian Martin, sucks-users
Thats actually a great idea. Being able to inject maps (although it may take some customization with the current state of the app), could really help those out looking to clean multiple floors. Thanks. Now you’re making me think :)

--
You received this message because you are subscribed to the Google Groups "sucks-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sucks-users...@googlegroups.com.
To post to this group, send email to sucks...@googlegroups.com.
Visit this group at https://groups.google.com/group/sucks-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/sucks-users/547d413f-524b-4e31-b702-25010c74fa6d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Jonathan Woodall

unread,
Feb 5, 2019, 9:15:49 PM2/5/19
to sucks-users
So... lots of failure today. I managed to get the vacuum connected to bumper without issue, and DNS was pointing all traffic to both ecovacs and ecouser toward the bumper server of course, but I never could get the iOS app to connect. There was still some connection going to China every time I opened the app, and I was getting a data something error - I'll note it next time. 

I also couldn't get sucks to work, which I never have, and I really do not understand why still. I even set up a fresh Ubuntu server, snapshotted it in vmware so I could easily wipe it, and then installed python 3.6, and tried 3.7.2 as well. I have something like 15 hours in not getting sucks to work so far, most likely due to user error. I'm not sure where to go from here with sucks. I may just have to put it down for a while and come back to it. I think I stand a better chance at figuring out why the iOS app wasn't connecting properly.
To unsubscribe from this group and stop receiving emails from it, send an email to sucks-users+unsubscribe@googlegroups.com.

Brian Martin

unread,
Feb 6, 2019, 12:56:36 AM2/6/19
to sucks-users

Sorry to hear that.  I updated the bumper 901 branch with step-by-step instructions for importing the CA cert so the app works correctly, give that a read and let me know (https://github.com/bmartin5692/bumper/tree/D901#import-the-bumper-ca-cert).  For the DNS are you using the DNSMasq entry to point all *.ecouser / *.ecovacs to your bumper IP or doing it domain by domain?  There are some entries that I didn't document yet that the app uses, which are for app usage analytics and tracking.  For me these are either blacklisted on my  PiHole, or receive a 404 error when they hit bumper.

I started to look at some of the mapping commands this evening, and was able to figure out renaming areas. So instead of "A,B,C" etc you can set room names like "Master", see the attached screenshot.
Next steps will be to dig into the map further to try to re-create what the app is doing to draw the map, what happens when the bot maps/sets a map, and later see if there is a way to load different maps.

RE: Sucks - Try using my 901 branch (https://github.com/bmartin5692/sucks/tree/D901), especially if using bumper.  In your config file add a new setting at the end:
verify_ssl=False
Example screenshot:
In my branch this will set verify=False for all the calls that requests makes, and while insecure makes it easier to test against bumper without accepting the CA cert.
To unsubscribe from this group and stop receiving emails from it, send an email to sucks-users...@googlegroups.com.

Jonathan Woodall

unread,
Feb 19, 2019, 10:16:02 PM2/19/19
to sucks-users
Just as an update, the verify_ssl=False fixed me up. I was also missing maho-mqtt, which was added to the D901 branch last night, and I saw that Brian made a request to merge D901 into William's build - I think it was everything from D901 into Master at least. 

Just as an FYI for those who come along later, here is my setup:

Ubuntu 18.04
Python 3.6.7 - vanilla
(I typically do run in virtualenv, but it doesn't matter. I've tested both with and without it)

  1. Install D901 branch -  'pip3 install https://github.com/bmartin5692/sucks/archive/D901.zip'
  2. sucks login - fill in info
  3. add 'verify_ssl=False' to bottom of sucks.config - located in ~/.configs/sucks.config on linux
  4. Run the script - I use 'sucks --debug stop' to run nothing to just see a reply and full comms, and to not wake up the kids :). Everything else works as well.

I've reloaded a fresh Ubuntu VM 5 times, and this works every time for me now.

Off to tackle Bumper now!

Thanks for all the help Brian & William. I'll definitely stick around as I work through this. I'm integrating this into OpenHab, and will document as I go. I have a lot of ideas to work on, which I will not publicly obligate myself to :)

Thanks!

Jon

Fredric Palmgren

unread,
Mar 12, 2019, 6:51:55 PM3/12/19
to sucks-users
I just tried bmartin's version and came up with a few issues. I'm not sure if this can be of any help. But I thought it was better to post this than not to :-)

I followed the instructions from your last post. I could see how I could enter a new issue on GitHub. Here are my findings.

I have a Deebot 600 I'm trying to get to work.

1. I couldn't login using 'eu' as continent. I got the following:

sucks      ERROR    call to loginByItToken failed with {'result': 'fail', 'todo': 'result', 'errno': 0, 'error': 'set token error.'}
Traceback (most recent call last):
 
File "/usr/local/bin/sucks", line 9, in <module>
    load_entry_point
('sucks==0.9.3', 'console_scripts', 'sucks')()
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 764, in __call__
   
return self.main(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 717, in main
    rv
= self.invoke(ctx)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1163, in invoke
    rv
.append(sub_ctx.command.invoke(sub_ctx))
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 956, in invoke
   
return ctx.invoke(self.callback, **ctx.params)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 555, in invoke
   
return callback(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/cli.py", line 152, in login
   
EcoVacsAPI(device_id, email, password_hash, country_code, continent_code)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 177, in __init__
    login_response
= self.__call_login_by_it_token()
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 265, in __call_login_by_it_token
   
, verify_ssl=self.verify_ssl)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 256, in __call_portal_api
   
"failure {} ({}) for call {} and parameters {}".format(json['error'], json['errno'], function, params))
RuntimeError: failure set token error. (0) for call loginByItToken and parameters {'token': 'se_XXXXXXXXXX, 'resource': 'XXXXXXXXXX', 'country': 'SE', 'todo': 'loginByItToken', 'userId': 'XXXXXXXXXX_XXXXXXXXXX', 'realm': 'ecouser.net'}
Logging using 'ww' as continent worked thou!

2. Trying to run a command (sucks --debug stop) I ended up with the error below. This looks like the same thing as I get with the original sucks library. The 'bot isn't available for some reason. I have no problems controlling the 'bot using the app or remote.

pi@hassbian:~/.config $ sucks --debug stop
sucks
.cli  DEBUG    will run [<sucks.cli.CliAction object at 0x75f52ef0>]
sucks      DEBUG    
Setting up EcoVacsAPI
sucks      DEBUG    calling main api user
/login with (('account', 'XXXXXXXXXXXXXX'), ('password', 'YYYYYYYYYYYYYYYYYY'))
/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py:847: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecureRequestWarning)
sucks      DEBUG    got
{'data': {'username': 'EAR9K4JQ', 'uid': 'XXXXXXXXX_XXXXXXXXXX', 'country': 'se', 'accessToken': 'XXXXXXXXXXXXXXXXXXX', 'email': 'fredric....@gmail.com'}, 'msg': '操作成功', 'code': '0000', 'time': 1552429808254}
sucks      DEBUG    calling main api user
/getAuthCode with (('uid', 'XXXXXXXXX_XXXXXXXXXX'), ('accessToken', 'XXXXXXXXXXXXXXXXXXX'))
/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py:847: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecureRequestWarning)
sucks      DEBUG    got
{'data': {'ecovacsUid': 'XXXXXXXXXXXXXXXXXXX', 'authCode': 'XXXXXXXXXXXXXXXXXXX'}, 'msg': '操作成功', 'code': '0000', 'time': 1552429809996}
sucks      DEBUG    calling portal api users
/user.do function loginByItToken with {'realm': 'ecouser.net', 'userId': 'XXXXXXXXX_XXXXXXXXXX', 'token': 'XXXXXXXXXXXXXXXXXXX', 'resource': '4b65d7cf', 'country': 'SE'}
/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py:847: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecureRequestWarning)
sucks      DEBUG    got
{'todo': 'result', 'token': 'XXXXXXXXXXXXXXXXXXX', 'resource': '4b65d7cf', 'result': 'ok', 'userId': 'XXXXXXXXXXXXXXXX'}
sucks      DEBUG    calling portal api users
/user.do function GetDeviceList with {'auth': {'realm': 'ecouser.net', 'with': 'users', 'resource': '4b65d7cf', 'userid': 'XXXXXXXXXXXXXXXX', 'token': 'XXXXXXXXXXXXXXXXXXX'}, 'userid': 'XXXXXXXXXXXXXXXX'}
/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py:847: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecureRequestWarning)
sucks      DEBUG    got
{'todo': 'result', 'devices': [{'class': 'dl8fht', 'did': 'XXXXXX-XXXX-XXXX-XXXX-XXXX', 'name': 'e0001171318601672000', 'company': 'eco-ng', 'resource': 'pc8W', 'nick': None}], 'result': 'ok'}
sleekxmpp
.basexmpp WARNING  fulljid property deprecated. Use boundjid.resource
sleekxmpp
.xmlstream.cert WARNING  Could not find pyasn1 and pyasn1_modules. SSL certificate COULD NOT BE VERIFIED.
sleekxmpp
.xmlstream.cert WARNING  Could not find pyasn1 and pyasn1_modules. SSL certificate expiration COULD NOT BE VERIFIED.
sucks      DEBUG    
----------------- starting session ----------------
sucks      DEBUG    
event = {}
performing stop command
sucks      DEBUG    
Sending command <iq from="XXXXXXXX...@ecouser.net/4b65d7cf" type="set" to="XXXXXX-XXXX-X...@dl8fht.ecorobot.net/atom" id="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"><query xmlns="com:ctl"><ctl td="Clean" id="XXXXXXXX"><clean type="stop" act="s" speed="standard" /></ctl></query></iq>
Traceback (most recent call last):
 
File "/usr/local/bin/sucks", line 9, in <module>
    load_entry_point
('sucks==0.9.3', 'console_scripts', 'sucks')()
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 764, in __call__
   
return self.main(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 717, in main
    rv
= self.invoke(ctx)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1164, in invoke
   
return _process_result(rv)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1102, in _process_result
   
**ctx.params)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 555, in invoke
   
return callback(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/cli.py", line 229, in run
    vacbot
.run(action.vac_command)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 606, in run
   
self.send_command(action)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 600, in send_command
   
self.xmpp.send_command(action.to_xml(), self._vacuum_address())
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 921, in send_command
    c
.send()
 
File "/usr/local/lib/python3.4/dist-packages/sleekxmpp/stanza/iq.py", line 235, in send
   
raise IqError(result)
sleekxmpp
.exceptions.IqError: <iq from="XXXXXX-XXXX-X...@dl8fht.ecorobot.net/atom" type="error" to="XXXXXXXX...@ecouser.net/4b65d7cf" id="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"><error type="wait" code="404"><recipient-unavailable xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" /></error></iq>
sucks      DEBUG    
*** sending ping ***
sucks      WARNING  
Ping did not reach VacBot. Will retry.
sucks      DEBUG    
*** Error type: wait
sucks      DEBUG    
*** Error condition: recipient-unavailable


A big thanx for you guys who make things like this possible!

Fredric

Brian Martin

unread,
Mar 12, 2019, 7:06:28 PM3/12/19
to sucks-users
Hi Fredric,

Thanks for testing this out.  We had theorized that the bots using MQTT (like the D900) report a company of 'eco-ng', which yours seems to do as well.  Because we didn't have more data, in the current code I have it set to hard code any MQTT devices so it wouldn't break other models until we could test more.

As a quick test, try modifying the __init__.py at line 306. Add another item (dl8fht) for yours as in the attached screenshot.
After you do this, give it another shot and let us know.

-Brian

performing stop command
sucks      DEBUG    
Sending command <iq from="XXXXXXXXXXXXXXXX@ecouser.net/4b65d7cf" type="set" to="XXXXXX-XXXX-XXXX-XXXX-XX...@dl8fht.ecorobot.net/atom" id="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"><query xmlns="com:ctl"><ctl td="Clean" id="XXXXXXXX"><clean type="stop" act="s" speed="standard" /></ctl></query></iq>

Traceback (most recent call last):
 
File "/usr/local/bin/sucks", line 9, in <module>
    load_entry_point
('sucks==0.9.3', 'console_scripts', 'sucks')()
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 764, in __call__
   
return self.main(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 717, in main
    rv
= self.invoke(ctx)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1164, in invoke
   
return _process_result(rv)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1102, in _process_result
   
**ctx.params)
 
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 555, in invoke
   
return callback(*args, **kwargs)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/cli.py", line 229, in run
    vacbot
.run(action.vac_command)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 606, in run
   
self.send_command(action)
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 600, in send_command
   
self.xmpp.send_command(action.to_xml(), self._vacuum_address())
 
File "/usr/local/lib/python3.4/dist-packages/sucks/__init__.py", line 921, in send_command
    c
.send()
 
File "/usr/local/lib/python3.4/dist-packages/sleekxmpp/stanza/iq.py", line 235, in send
   
raise IqError(result)

sleekxmpp
.exceptions.IqError: <iq from="XXXXXX-XXXX-XXXX-XXXX-XX...@dl8fht.ecorobot.net/atom" type="error" to="XXXXXXXXXXXXXXXX@ecouser.net/4b65d7cf" id="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"><error type="wait" code="404"><recipient-unavailable xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" /></error></iq>

sucks      DEBUG    
*** sending ping ***
sucks      WARNING  
Ping did not reach VacBot. Will retry.
sucks      DEBUG    
*** Error type: wait
sucks      DEBUG    
*** Error condition: recipient-unavailable

Fredric Palmgren

unread,
Mar 13, 2019, 3:26:04 PM3/13/19
to sucks-users
Hi Brian!

That worked! I guess support for more 'bots will be added to the list when they have been tested. Do you know when your branch will be merged into the main project? 

I am looking forwards making my 'bot work on Home Assistant where the sucks lib is being used.

/Fredric

Brian Martin

unread,
Mar 13, 2019, 8:21:26 PM3/13/19
to sucks-users
Good to hear.  My thought for now is we would update the list as needed.  If we have a few more reports of other bots with the eco-ng company working this way, we could change the code to handle this automatically.  I'm not sure when it will be merged, this is up to William pending his review of the pull request.  I'll commit your model so it is part of the PR now though.

César Quintini

unread,
Oct 20, 2019, 12:53:31 PM10/20/19
to sucks-users
Hi Brian were you able to load different maps in the deebot 900 series?

Brian Martin

unread,
Oct 20, 2019, 3:39:07 PM10/20/19
to sucks-users
I haven't found a way yet, but this isn't something I've looked too deeply at.  I believe some of the newer bots are shipping with this capability out of the box now though.

Sören Hüttemann

unread,
Oct 23, 2019, 12:49:54 PM10/23/19
to sucks-users
Hi,

I just have bought the deebot ozmo 950 which is capable of storing multiple maps. Whe I find the time I will try to test the current code and see if it is working with my robot.

Bests

Soeren

Aleksey Alatyrtsev

unread,
Dec 7, 2019, 12:13:36 AM12/7/19
to sucks-users
Thank you Brian for you investigation and implementing protocol for new Deebots! I’m happy to say that your fork works with Ecovacs Deebot DE55 too, so you may include this model to list of supported vacbots.
Message has been deleted

Gbenro Odunaiya

unread,
Dec 17, 2019, 5:47:18 PM12/17/19
to sucks-users
Hey Brian, I see that you got Bumper to work with the Deebot Ozmo 950. Any chance you have gotten sucks to also work with it?

Thanks

Gbenro Odunaiya

unread,
Dec 17, 2019, 5:48:33 PM12/17/19
to sucks-users
Hi Soeren,

Were you able to test this out with the 950 and see if it works?

Sandy Mac

unread,
Feb 28, 2020, 11:15:38 AM2/28/20
to sucks-users
Hey Brian, did you happen to get anywhere on this?  I don't care so much about another map/floor but it would be nice to be able to restore a backup of the map in case the vacuum loses it.  Remapping the house in 60 minutes is a pain!

Brian Martin

unread,
Mar 3, 2020, 5:59:09 PM3/3/20
to sucks-users
Hi Sandy,

No, from what I've seen the map, atleast on my 901, is stored in internal memory on the bot itself, and I haven't found an API call to dump/restore it.
Reply all
Reply to author
Forward
0 new messages