Home Assistant Community

Add Map to Xiaomi vacuum cleaner

#75

I had no issues using the instructions from post 39.

Did it from a virtual Ubuntu machine.

0 Likes

#76

Hi. What di u change?

#!/bin/bash

RHOST="###IPADDR####"

RPORT=“22”

You shouldn’t touch anything below

RUSER=“homeassistant”

RDIR="/home/homeassistant/.homeassistant/vacuum/"

SSHCTL="/root/.ssh/ctl-ha-rockrobo"

I have to change it inot

#!/bin/bash

RHOST="###IPADDR####"

RPORT=“22”

You shouldn’t touch anything below

RUSER=“hass”

RDIR="/home/hass/.homeassistant/vacuum/"

SSHCTL="/root/.ssh/ctl-ha-rockrobo" <----- What’s this? as it is not on my robot nor on my hass

I don’T get any map… nothing is created… COuld you make a short write up. I followed the guid from asphalter and also found mistakes like: choan iso chmos… but that’s not that bad… But i think there’s more to change especially the SSHCTL path. But i dunno how :frowning: and what it means. HELP appreciated :slight_smile:

0 Likes

#77

I got it working but had to start the script on the robot manually

0 Likes

#78

Is there a way to do this if homeassistant is running in docker?

Thanks in advance

1 Like

#79

Everything is possible with docker …there’s no difference .just follow the instructions…that’s all
But strangely I had to start the script in the robot manually… dunno why it didn’t start …I might have restarted the robot …I dunno.maybe the dev could give a hint here ?

0 Likes

#80

Did you check ou the thread of @wills106 ?

If your vacuum is rooted, its really simple to set up Valetudo and import the map in HA.

0 Likes

#81

I am in the telegram dev channel yes i read about this but was wondering how to set ip up in hass :slight_smile: my robot is already rooted. Will check this immediately.

0 Likes

#82

I’ve already got the token and from integration with HA - where do I start the rooting process with that?

0 Likes

#83

Thats not the roken … thats another key. If you want take mentioned russain version of mihome and u can sniff the token directly from the robot, Well… then u have to root it with this wiki:

0 Likes

#84

I’m finding that the firmware version on the instructions are quite old compared to what’s currently installed on my MiRobot Gen 1. Any risks of pushing an older modified firmware?

0 Likes

#85

Nope. Downgrading is always better than upgrading in those cases.xiaomi tried to block their firmware in further updates.its highly recommended not to upgrade the Robo one the robot is rooted u will loose the root by upgrading the robot with the mihome app.

0 Likes

#86

I can’t root my MiRobot v1, any help here would be appreciated.

Key points:

  • My MiRobot V1 has the latest firmware 3.3.9_003416
  • I’m following the Ubuntu steps on the guide here: https://github.com/dgiese/dustcloud/wiki/VacuumRobots-manual-update-root-Howto
  • I’m using Ubuntu 16.04 LTS using VirtualBox on a Windows 10 Machine. I tried it with Ubuntu 14.04 per the instructions but there were too many issues with Python and VENV versions being too old.
  • The newest firmware available according to the links on the instructions is v11_003254
  • All the steps work fine except for the final steps to upload the firmware

When I enter this into the terminal the result is:
python dustcloud/devices/xiaomi.vacuum/firmwarebuilder/flasher.py -f output/v11_003254.pkg

Flasher for Xiaomi Vacuum
Address is not set. Trying to discover.
Connecting to device 10.0.2.2...
Sending handshake to get token
Unable to discover a device at address 10.0.2.2
Traceback (most recent call last):
File "dustcloud/devices/xiaomi.vacuum/firmwarebuilder/flasher.py", line 206, in &lt;module&gt;
main()
File "dustcloud/devices/xiaomi.vacuum/firmwarebuilder/flasher.py", line 148, in main
m = vacuum.do_discover()
File "/home/sebastian/dc/.venv/lib/python3.5/site-packages/miio/device.py", line 162, in do_discover
raise DeviceException("Unable to discover the device %s" % self.ip)
miio.exceptions.DeviceException: Unable to discover the device 10.0.2.2

So I added the IP address of the MiRobot (when it’s in WIFI connecting mode) and get the below result:
python dustcloud/devices/xiaomi.vacuum/firmwarebuilder/flasher.py -f output/v11_003254.pkg -a 192.168.8.1

Flasher for Xiaomi Vacuum
Connecting to device 192.168.8.1...
Sending handshake to get token
Starting local http server...
Serving http server at 10.0.2.15:38069
Sending ota command with parameters: {"mode": "normal", "file_md5": "a37aa29d89780201fae295f4f42b6f2b", "app_url": "http://10.0.2.15:38069/output/v11_003254.pkg", "proc": "dnld install", "install": "1"}
Ota started!

Firmware downloaded successfully.
Exiting.

It gets to “firmware download successfully” very quickly. I’d expect the MiRobot to tell me it will update and do it’s thing but it does nothing at this point. To get my MiRobot working again i have to use the MiHome app and get it connected back to my wifi router.

Any advice? Do you think it’s new Xiaomi firmware blocking my downgrade?

0 Likes

#87

it takes a while to update. When it starts, you’ll see the LED flash on the vacuum. Once finished it’ll restart and will tell you it’s updated the firmware

0 Likes

#88

The led only flashes to indicate that its in wifi mode. I waited 10 minutes but nothing happens…

0 Likes

#89

can you see the firmware upload progress bar in your terminal?

0 Likes

#90

oh you appear to have forgotten to provide the token :wink:

0 Likes

#91

It’s says “firmware downloaded successfully" then “exiting” within about 5 seconds of my command in the terminal. I see no progress bar.

Could it be the new firmware is blocking the downgrade?

0 Likes

#92

that’s quite possible… but can you confirm you’re tried the command with the token? I don’t believe it’ll work without…
python dustcloud/devices/xiaomi.vacuum/firmwarebuilder/flasher.py -f output/v11_003254.pkg -a 192.168.8.1 -t xyz

0 Likes

#93

The Ubuntu steps on https://github.com/dgiese/dustcloud/wiki/VacuumRobots-manual-update-root-Howto have no instructions on how to retrieve the token.

Is it the same token that I’m currently using to connect the mirobot in my home assistant YAML configuration? Do you know how I can get the token in Ubuntu?

0 Likes

#94

When you do mirobo discover --handshake true it should display the token (or so the doc states), but in any case yes it’s the same token as the one you use in HA.

0 Likes