Vacuum Interactive Map Card

Hello everyone. I’m looking for a way to display the maps with the last 10 cleaning passes.
I can save the maps as a camera snapshot, that’s no problem.
Now of course I want to be able to access these mapss somehow in the dashboard. Of course it would be coolest if I could do that via this card. Does anyone know of a way?
Of course I am also open to other solutions via a separate card.

You can add every snapshot as a separate map using additional_presets functionality, but you might have caching problem after changing the snapshot

Hi. I,m using * Tasshack/dreame-vacuum platform with my dreame L10s Ultra. In there we have an select entity for each room, to select 3 options ( vacuum, mop or vacuum and mop)

Could someone point me the direction how to implement this in the map ? It is possible for each room?

I was seeing the Map mode options, don,t know if it possible to use one more option for that , or using right in the room section of the map mode, i was thinking in one icon in each room that at each touch would call a service to change the option of the clean mode.

Like it is in the exemples ( althow in menu type ) using something like this in each room:

type: "menu",
menu_id: "water_box_mode",
icon_id: "water_box_mode",
entity: "select.water_box_mode"
available_values_attribute: "options",
icon: "mdi:water",
icon_mapping:
    off: "mdi:water-remove",
    mild: "mdi:water-minus",
    moderate: "mdi:water",
    intense: "mdi:water-plus",
    custom: "mdi:water-sync"
tap_action:
    action: "call-service",
    service: "select.select_option",
    service_data:
        option: "[[value]]",
        entity_id: "[[entity_id]]"

Do you want it to be an icon (under the map)?

Yes i would prefer in a icon with an tap action that would change the option of the select entity.

P.s. oh under the map ?! Didn,t saw that… well could be yes if it,s not possible on the map…

It’s currently impossible to add such icons on the map.

You can use following config to add them below the map:

append_icons: true
icons:
  - type: menu
    menu_id: "room_1_mode_selector"
    entity: "select.vacuum_room_1_mode"
    available_values_attribute: "options"
    icon: "mdi:robot-vacuum"
    icon_mapping:
      'Mop': "mdi:water"
      'Vacuum': "mdi:vacuum"
      'Vacuum or mop': "mdi:vacuum-outline"
    tap_action:
      action: "call-service"
      service: "select.select_option"
      service_data:
          option: "[[value]]"
          entity_id: "[[entity_id]]"   

Of course you have to adjust values that I have provided

Yes that works. Got to find some time to all the selects, and play arround with conditions to that only appears when it,s needed. Thanks , i will give my final feedback when it,s done.

Hey guys, I’m struggling with a little problem. I switched from xiaomi vacuum v1 to roidmi eve plus. Vacuum is via Xiaomi Miot Auto integration.
I can’t set the correct service call schema action for template goto and clean zone. I have already found and it works for the rooms, now I’m solving the other two commands. Can someone help me with this? Thanks

type: custom:xiaomi-vacuum-map-card
map_source:
  camera: camera.roidmi_eve
calibration_source:
  camera: true
entity: vacuum.roidmi_eve
map_modes:
  - template: vacuum_goto
  - template: vacuum_clean_zone
  - template: vacuum_clean_segment
    max_selections: 8
    repeats_type: EXTERNAL
    max_repeats: 3
    service_call_schema:
      service: xiaomi_miot.call_action
      service_data:
        entity_id: '[[entity_id]]'
        siid: 14
        aiid: 1
        params:
          - 2
          - '{"mapId":1671212345,"segmentId":[[selection]]}'
    predefined_selections:
      - id: '1'
.....

clean zone

pin & go

1 Like

Thank you so much for your work.

1 Like

Hi all,

I manage to integrate my Xiaomi Vacuum Mop Pro with Miio2 integration using the platform KrzysztofHajdamowicz/miio2

When I want to select room cleaning I get the below error, but even so the vacuum starts cleaning with no problems the selected room.

I would like to make a automation to clean a specific room. For my understanding I need to create a template but I do not know how.
Can someone explain what and where do I need to edit to be able to have automations based on specific rooms.

type: custom:xiaomi-vacuum-map-card
map_source:
  camera: camera.xiaomi_cloud_map_extractor
calibration_source:
  camera: true
entity: vacuum.mop_pro
vacuum_platform: KrzysztofHajdamowicz/miio2
map_modes:
  - template: vacuum_clean_zone
  - template: vacuum_goto
  - template: vacuum_clean_segment
    predefined_selections:
      - id: '10'
        icon:
          name: mdi:broom
          x: -5.025
          'y': -5.85
        label:
          text: Buc
          x: -5.025
          'y': -5.85
          offset_y: 35
        outline:
          - - -5.95
            - -6.7
          - - -4.1
            - -6.7
          - - -4.1
            - -5
          - - -5.95
            - -5
      - id: '11'
        icon:
          name: mdi:broom
          x: -0.07499999999999996
          'y': -1.8499999999999999
        label:
          text: Dormitor
          x: -0.07499999999999996
          'y': -1.8499999999999999
          offset_y: 35
        outline:
          - - -1.75
            - -3.9
          - - 1.6
            - -3.9
          - - 1.6
            - 0.2
          - - -1.75
            - 0.2
      - id: '12'
        icon:
          name: mdi:broom
          x: -3.725
          'y': -2.2250000000000005
        label:
          text: Living room
          x: -3.725
          'y': -2.2250000000000005
          offset_y: 35
        outline:
          - - -5.65
            - -4.65
          - - -1.8
            - -4.65
          - - -1.8
            - 0.2
          - - -5.65
            - 0.2
      - id: '13'
        icon:
          name: mdi:broom
          x: -1.7999999999999998
          'y': -6.125
        label:
          text: Baie
          x: -1.7999999999999998
          'y': -6.125
          offset_y: 35
        outline:
          - - -2.65
            - -7.25
          - - -0.95
            - -7.25
          - - -0.95
            - -5
          - - -2.65
            - -5
      - id: '15'
        icon:
          name: mdi:broom
          x: -3.3249999999999997
          'y': -6
        label:
          text: Hol
          x: -3.3249999999999997
          'y': -6
          offset_y: 35
        outline:
          - - -4.1
            - -7.35
          - - -2.55
            - -7.35
          - - -2.55
            - -4.65
          - - -4.1
            - -4.65
title: Vacuum Mop Pro
map_locked: true
two_finger_pan: true

When I want to select room cleaning I get the below error, but even so the vacuum starts cleaning with no problems the selected room.

Do you have the latest version of said integration?

Can someone explain what and where do I need to edit to be able to have automations based on specific rooms.

Open card editor, select rooms mode, select a room, click “Copy service call” button

Thanks for the reply.

I used below integration and it doesn’t seem to have any updated. Nevertheless I deleted it and reinstalled it again.
Now room cleaning doesn’t work.

I did a full restore but can’t acces remotely the HA.
Will get back after I manage to connect again with HA.

Try using this one instead:

This integration seems to work it out any error.
Nice.

Regarding automation for a specific room, after coping text from “copy service call” where do I paste it?

You have to slightly adjust it and use it in a script or automation editor.

1 Like

Heyhey
On a youtube video I found a dashboard (frontend shown only) where inside the vacuum map card a list was shown to select vacuum properties, such as fan speed, mop intensity and so on.
So far I solved these settings with separate buttons next to my map control.
But this really isnt an eye candy, so I want to have a list inside my vaccuum map card to select the vacuum properties.
But I cant figure out how.
In the documentation I found:

type: "menu",
menu_id: "water_box_mode",
icon_id: "water_box_mode",
entity: "select.water_box_mode"
available_values_attribute: "options",
icon: "mdi:water",
icon_mapping:
    off: "mdi:water-remove",
    mild: "mdi:water-minus",
    moderate: "mdi:water",
    intense: "mdi:water-plus",
    custom: "mdi:water-sync"
tap_action:
    action: "call-service",
    service: "select.select_option",
    service_data:
        option: "[[value]]",
        entity_id: "[[entity_id]]"

I think this is what I need. But I dont know where to paste it.
Can some1 help me here?

Hmm. Sorry I still dont get it.
For the icons below my map (where I want the list to be shown), I still dont know where to put your code.
My config looks as follows:

type: custom:xiaomi-vacuum-map-card
map_source:
  camera: camera.roborockladenvorne_map
calibration_source:
  camera: true
entity: vacuum.roborockladenvorne
vacuum_platform: humbertogontijo/homeassistant-roborock
icons:
  - icon: mdi:play
    conditions:
      - entity: vacuum.roborockladenvorne
        value_not: cleaning
      - entity: vacuum.roborockladenvorne
        value_not: error
      - entity: vacuum.roborockladenvorne
        value_not: returning
    tooltip: Start
    tap_action:
      action: call-service
      service: vacuum.start
      service_data:
        entity_id: vacuum.roborockladenvorne
  - icon: mdi:pause
   # [...]
  -some more icon: points
tiles:
  - tile_id: status
   # [some info]
  - some more tile_ids:
map_modes:
  - name: Zone cleanup
   # [...]
  - name: Pin & Go
  # [...]
  - template: vacuum_clean_segment
 #[...]
additional_presets: []
title: vorne

I see that you have used “generate static config” button. Have you changed manually anything in yaml config of the card?