Xiaomi Eve Plus Integration

Xiaomi Miot Auto is the main one. Make sure you use “cloud”
This will give main functionality.
Zone(room) cleaning I am doing via scripts at the moment.
Here is a bit of code in scripts that I am using for room clean and some functions. Use your did (device id):

toggle_vacuum_bin_auto_empty:
  alias: Toggle vacuum bin auto empty
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 41
        value: "{{ 0 if is_state('binary_sensor.vacuum_auto_bin_empty', 'on') else 1 }}"
  mode: single
turn_on_vacuum_bin_auto_empty:
  alias: Turn on vacuum bin auto empty
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 41
        value: 1
  mode: single
turn_off_vacuum_bin_auto_empty:
  alias: Turn off vacuum bin auto empty
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 41
        value: 0
  mode: single
toggle_vacuum_twice:
  alias: Toggle vacuum twice
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 1
        value: "{{ 0 if is_state('binary_sensor.vacuum_twice', 'on') else 1 }}"
  mode: single
turn_on_vacuum_twice:
  alias: Turn on vacuum twice
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 1
        value: 1
  mode: single
turn_off_vacuum_twice:
  alias: Turn off vacuum twice
  sequence:
    - service: xiaomi_miot.set_miot_property
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        piid: 1
        value: 0
  mode: single
viomi_vacuum_back_bedrooms:
  alias: Vacuum back bedrooms
  sequence:
    - service: xiaomi_miot.call_action
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        aiid: 13
        params:
          - 0
          - 1
          - "1,2"
  mode: single
viomi_vacuum_main_zones:
  alias: Vacuum main zones
  sequence:
    - service: xiaomi_miot.call_action
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        aiid: 13
        params:
          - 0
          - 1
          - "8,4,5"
  mode: single
viomi_vacuum_back_bath_laundry_corridor:
  alias: Vacuum back bath laundry corridor
  sequence:
    - service: xiaomi_miot.call_action
      data:
        entity_id: vacuum.viaomi_s9_vacuum_robot_cleaner
        did: 378451326
        siid: 4
        aiid: 13
        params:
          - 0
          - 1
          - "3"
  mode: single

2 Likes

“did” is not a separate entity, but you will find it under map.map_list attribute
map.map_list: [["2021/07/11/6153637412/378451326_171156705.bkmap

I omitted switch/binary sensor definitions for auto empty and vac twice

1 Like

How did you manage get room ID for partition cleaning?
I can run all map cleaning, but struggling with partitions.
###########
- service: xiaomi_miot.call_action
data:
entity_id: vacuum.roidmi_eve_robot
siid: 2
aiid: 1
##############
it works for full map cleaning, but for partiiton cleaning I should define parameres.
from folder /vevs/logs I can get some data
“siid”:14,“aiid”:1,“in”:[2,"{“mapId”:1621441765,“segmentId”:[7]
but after I set up :
params:
- 0
- 1
- “7”
HA return me error
Call miot action to roidmi_eve Robot Cleaner ({‘did’: ‘action-14-1’, ‘siid’: 14, ‘aiid’: 1, ‘in’: [0, 1, ‘7’]}) failed: {‘code’: -9999, ‘message’: ‘user ack timeout’}
what does it mean “0” and “1” -two first row under parameters?
I guess third row is room id

the 9999 error most likely means that it is only available via the cloud execution, not local
I could not get split to work (between local and cloud), so I am sending all commands via the cloud

Hi, what parameters should be in function “xiaomi_miot.call_action” for zonal cleaning?
From log:
{“params”:{“did”:“44XXXXX52”,“siid”:14,“aiid”:1,“in”:[2,"{“mapId”:16XXXXX55,“segmentId”:[8]}"]}} /miotspec/action

Hello guys.
I learned how to make scripts for cleaning zones by Roidmi EVE Plus.
Look to my example:

clean_living_room:
  alias: clean_living_room
  sequence:
    - service: xiaomi_miot.call_action
      data:
        entity_id: vacuum.roidmi_eve_robot_cleaner
        did: 441963123
        siid: 14
        aiid: 1
        params: [2,"{\"mapId\":1627839123,\"segmentId\":[3]}"]
  mode: single
  icon: mdi:sofa

Little how-to:

  1. Use Xiaomi Miot For HomeAssistant integration. Install it by manual. If it ask type of commands - select CLOUD connect.
  2. Use vevs mod of Mi home for collect needed data. Install mod and create folders for logs: /vevs/logs/. After make folder - login to you acc. If you already logined - make relogin, for creating logs.
  3. Go to you Roidmi EVE page and start segment cleaning.
  4. Find in /vevs/logs/miio/ folder txt file with DID of you device. (in my case 441963123.txt)
  5. Send log file to PC and find word ‘segmentId’ - this line will start segment cleaning. In my case line it is: 2021-08-02 20:48:12 → {“params”:{“did”:“441963123”,“siid”:14,“aiid”:1,“in”:[2,"{“mapId”:1627839123,“segmentId”:[3]}"]}} /miotspec/action
  6. Just use data after “in”: this line in you scripts for params line. In my case it params: [2,"{“mapId”:1627839123,“segmentId”:[3]}"]
  7. (additional) You also can use Xiaomi Cloud Map Extractor
    This is my config for it:
  - platform: xiaomi_cloud_map_extractor
    host: 192.168.1.***
    token: 454f4********************9764b58
    username: s******@gmail.com
    password: ***********
    draw: ['all']
    store_map_raw: true
    force_api: roidmi
    attributes:
      - calibration_points 

All needed data you can find in vevs mod - just tap and hold you device in start page, and choose reneame button - after you see window with all info about it, inc. token.

7 Likes

Thanks It works

1 Like

Thanks for the instruction. Everything works. Are you using the “Lovelace Xiaomi Vacuum Map Card”? I can’t send it from the card

Hi, i use Button Card
There is a sample of button:

type: custom:button-card
entity: script.clean_living_room
tap_action:
  action: call-service
  service: script.clean_living_room
state:
  - value: 'off'
  - value: 'on'
    color_type: icon
    color: red
    styles:
      state:
        - color: red
      card:
        - filter: brightness(60%)
styles:
  card:
    - height: 50px
color_type: icon
color: rgb(170, 176, 188)
icon: mdi:sofa
show_name: false

There is a preview of full block of buttons:
chrome_2021-08-24_17-27-22

3 Likes

Thanks. The scrips are working perfect with one or more rooms

alias: Aspiradora Limpieza Zona SalaCocina
sequence:
  - service: xiaomi_miot_raw.call_action
    data:
      aiid: 1
      entity_id: vacuum.aspiradora
      siid: 14
      inn:
        - 2
        - '{"mapId":1617187917,"segmentId":[1,8,3,10]}'
mode: single

The quality of the map of the map extractor is low but it also works!
Screenshot_20210829-092919_Home Assistant|225x500

Thank you! It works !

First time poster here, but I’ve been watching this thread ever since it started.

I’ve added the map through the map extractor but wasn’t able yet to control the device itself. I had it added through the MIoT integration but that didn’t work and was planning to get into adding it through the ways mentioned above to get the functionality going at least.

To my surprise it might actually be working through MIoT now, full functionality as well, return to dock, fan speed, start and stop. Even switching between mop/sweeping functions

Hasn’t gone offline for the past 24 hours either. Might be to soon to celebrate, but worth creating an account for to update you guys to see if it works for you too, might have been the last update or something

1 Like

Has someone managed to control the amount of water in mop mode?

1 Like

There is a nice intergration.

It has some minor mistakes but can be corrected easily.

2 Likes

Hallo, I have install vevs version of Mi home and I see device on home. But when I click to Roidmi eve device the app try downloading plug-in and then error “Couldn’t find plug-in”. And on this page “https://mi.vevs.me/mihome/pluglist/” I can’t find it to. Can you help me please, what I did wrong? Or can you give me a plug-in please? Thank you.

Hallo, I have install vevs version of Mi home and I see device on home. But when I click to Roidmi eve device the app try downloading plug-in and then error “Couldn’t find plug-in”. And on this page “https://mi.vevs.me/mihome/pluglist/” I can’t find it to. Can you help me please, what I did wrong? Or can you give me a plug-in please? Thank you.

I use the version “MiHome_6.7.700_64211_vevs”, you can get it and the plugin here → temporarily posted

Thank you very much!! :+1:

Has anyone got a “pause” command somehow for the Roidme Eve Plus ?
I do have “start”, “stop”,“back to charge” but I can not get a “pause” command.

Every card that I tried has a pause that basically stops and does not continue from there, it just starts over again.

Hey,

Just a quick question, does the android phone have to be rooted to get the MapID as that’s the only bit of information I am stuck on at the moment, unless there is another way to get it.

Thanks :slightly_smiling_face: