Help with zone cleaning parameters - Xiaomi vacuum

After I call the service - will it work automatically? Or I should call him every time

Every call to the service start the task once

Yes, I figured it out - a pity it is not being done directly through the ui interface

I think this thread makes me want to learn Portuguese.

For an English speaker, ‘Estado do Aspirador’ sounds more like a holiday destination than something to do with a household chore. Or perhaps a beautiful antique accessory for cigar smokers.

On the other hand, I suppose, if I did learn Portuguese, it might spoil the undeniable romance of some YAML config files


1 Like

You did a really great job, complimenti! :wink:

1 Like

im not sure which issue you’ve found but im getting the same issue - vacuum starting the zoned cleanup then finishing in a few seconds. the code worked perfectly before:

  • id: vacuum_zoned_automation
    trigger:
    • platform: state
      entity_id: input_boolean.vacuum_bedroom
      to: ‘on’
    • platform: state
      entity_id: input_boolean.vacuum_livingroom
      to: ‘on’
    • platform: state
      entity_id: input_boolean.vacuum_hallway
      to: ‘on’
    • platform: state
      entity_id: input_boolean.vacuum_kitchen
      to: ‘on’
    • platform: state
      entity_id: input_boolean.vacuum_workroom
      to: ‘on’
      action:
    • service: vacuum.send_command
      data_template:
      entity_id: vacuum.dusty
      command: app_zoned_clean
      params: >
      {% if (trigger.entity_id == “input_boolean.vacuum_bedroom”) %} [[22003, 18693, 24930, 24015, 1]]
      {% elif (trigger.entity_id == “input_boolean.vacuum_livingroom”) %} [[28429, 19693, 32173, 26242, 1]]
      {% elif (trigger.entity_id == “input_boolean.vacuum_hallway”) %} [[25261, 24207, 28366, 26547, 1]]
      {% elif (trigger.entity_id == “input_boolean.vacuum_kitchen”) %} [[28366, 26355, 31516, 28117, 1]]
      {% elif (trigger.entity_id == “input_boolean.vacuum_workroom”) %} [[25243, 18693, 28276, 24015, 1]]
      {% endif %}

Im mit sure if areas as templates are already supported, but you defined the zones wrong.
You have to set the repeats as a separate „repeats“ value, which can be a template.

EDIT: Forgot what I’ve said. I didn’t see you was using the „vacuum.send_command“ and not the component by marcogazzola. The send_command doesn’t support templates at all.

You will remove the number 1 at the end.

like i said, it worked and then stopped.
when i run the command manually in home assistant with the following JSON (with or without the additional repeat parameter) the same happens:
{
“entity_id”: “vacuum.VacuumName”,
“command”: “app_zoned_clean”,
“params”: [
[
22003,
18693,
24930,
24015
]
]
}

If you use vacuum.send_command you must append repeat parameter (integer) to each zone array.
If you use my service vacuum.xiaomi_clean_zone you must specify repeat parameter as separated parameter

As you can see above in the automation I quoted I specify the repeat integer. In the send command I used through the home assistant interface I’ve tried bit with and without, both have the same result, being the vacuum starting then immediately returning

Perhaps your areas are badly defined

They worked before. I would start one and see the zone square in the app being properly shown.

probably your map has been recreated

Why would that change anything?
I plotted the zones last time using the map and calculating pixel distance in comparison to coordinate distance between 3 points. If I copy the new map and do the same process I would probably reach the same results

Every time you start a complete cleaning, redraw the map.
I suggest you use flolevac

Can some of your guys put the contents of this thread and general status of zoned cleaning in layman’s terms for me please? I really want to get zoned cleaning running!

I got a Roborock S50 about a month ago. Never downloaded the original Xiaomi app, but just went straight for rooting it, as I did not want it to phone home. I found a more thorough guide for that than the GitHub pages had, and managed to get it set up. So now I am running:
Firmware version 3.3.9
Firmware build 001792
Valetudo version 0.0.10

I can access the robot via http://rockrobo and it works fine. However the map seems to only update when I have the webpage open, if I let it clean and look at the map, I do not see all the places it has gone.

So I am deeply confused by all the research I have done on zoned cleaning. Party because a lot of the info I can search is dated and things have changed. Now I am also confused that my map acts weird, and saw this thread. So basically there are a lot of things I have read that I do not understand.
-Some people say I have to take the robot out of the sock before starting a full clean up?
-Some people say the map disappears every time it does a full clean up? So I have to do manual changes after every run?
-A lot of people suggest an app called flolevac? It does not seem to exist for iPhone, so haven’t used that.
-People say that the coordinates for zoned cleaning can be found in valetudo in various ways? I have not been able to extract a single coordinate in any way.

Would someone care to make a step-by-step guide for zone cleaning, that does not assume the reader can figure out a ton of in between steps? I would highly appreciate it, as the wife is growing impatient about results of her new purchase.

Thanks in advance.

Can you please share a link to that guide?