Custom vacuum-card for Home Assistant

Tags: #<Tag:0x00007f7398939b90>

Here is my lovelace config, and image.
I had to modify the vacuum-card.js file to get the background of the card correct.
If you need any of my other command scripts for start, delay start etc. let me know.

              - type: custom:vertical-stack-in-card
                title: 'Wall-e Controls'
                cards:
                  - type: 'custom:vacuum-card'
                    entity: vacuum.wall_e
                    show_toolbar: false
                    image: '/local/pictures/wall-e.png'
                    stats:
                      default:
                        - attribute: filter_left
                          unit: hours
                          subtitle: Filter
                        - attribute: side_brush_left
                          unit: hours
                          subtitle: Side brush
                        - attribute: main_brush_left
                          unit: hours
                          subtitle: Main brush
                        - attribute: sensor_dirty_left
                          unit: hours
                          subtitle: Sensors
                      cleaning:
                        - attribute: cleaned_area
                          unit: m2
                          subtitle: Cleaning area
                        - attribute: cleaning_time
                          unit: minutes
                          subtitle: Cleaning time
                  - type: horizontal-stack
                    cards:
                      - type: entity-button
                        name: 'Delayed Cleaning'
                        icon: mdi:clock-start
                        entity: media_player.kodi
                        state_color: false
                        tap_action:
                          action: call-service
                          service: script.turn_on
                          service_data:
                            entity_id: script.1583675350603
                      - type: entity-button
                        name: 'Immediate Cleaning'
                        icon: mdi:ray-start-arrow
                        entity: media_player.kodi
                        state_color: false
                        tap_action:
                          action: call-service
                          service: script.turn_on
                          service_data:
                            entity_id: script.1583976617287
                      - type: entity-button
                        name: 'Locate'
                        icon: mdi:map-marker
                        entity: script.1583675238858
                        state_color: false
                        tap_action:
                          action: call-service
                          service: script.turn_on
                          service_data:
                            entity_id: script.1583675238858
                          #service: script.1583675238858
                      - type: entity-button
                        name: 'Send Home'
                        icon: mdi:home-import-outline
                        entity: media_player.kodi
                        state_color: false
                        tap_action:
                          action: call-service
                          service: script.turn_on
                          service_data:
                            entity_id: script.1583686496925
                      - type: entity-button
                        name: 'Stop'
                        icon: mdi:stop
                        entity: media_player.kodi
                        state_color: false
                        tap_action:
                          action: call-service
                          service: script.turn_on
                          service_data:
                            entity_id: script.1583704406106
                  - type: horizontal-stack
                    cards:
                      - type: entities
                        entities:
                          - entity: sensor.vacuum_bin_present
                            icon: mdi:minus-circle-outline
                            name: Bin Present
                      - type: entities
                        entities:
                          - entity: sensor.vacuum_bin_full
                            icon: mdi:delete-variant
                            name: Bin Full

Hi @denysdovhan! Thank you for your great vaccum card!
Just to let you know that is works well also for the new Roborock S6 MaxV so it can be added to the supported models in your Github :slight_smile:

Quick Display Tip

To make the card’s background fit your theme, without modifying the card’s source code, install the card-mod frontend, then:

          - type: 'custom:vacuum-card'
            style: |
              ha-card .preview {
                background-color: var(--secondary-background-color);
              }
1 Like

@denysdovhan
I’m having trouble to find and add the card to the UI.

I followed the manual installation and I’m stuck at step 4 “Find Custom: Vacuum Card in the list.” under “Using the card”. I can’t find such a card and when I tried to manually add the card by typing “custom:vacuum-card”, I get “Custom element doesn’t exist: vacuum-card.”

What am I doing wrong?

Please, make sure you’ve installed this card properly. Right now it seems like you’ve done something wrong on the installation step since the card is not available for you.

I have the exact same problem as @lokety.

I did the installation with HACS so there is more or less nothing I could have done wrong.

Figured it out. Had to manually Add the Resources to Lovelace. I thought it would be done by HACS…

/hacsfiles/vacuum-card/vacuum-card.js

How can I get the card to be displayed in a different language?

Just switch your Home Assistant display language. The card will automatically figure out in which language to display.

Hello

I have a Deebot N95S. Unfortunately on my vacuum, the commands vacuum.start / vacuum.start_pause or vacuum.pause don’t work. It only recognizes vacuum_start and vacuum_stop.

I have created actions for these two and added them to the toolbar and they work. The problem is that it puts them on the right side of the toolbar, but the original “Clean” button is still on the left, and of course it doesn’t do anything. Also once the vacuum starts my custom buttons go away completely. Is there a way to assign custom actions to default buttons, or maybe make all buttons customizable?

Thanks!

Hi
First great job.
But can’t get it to see my vacuum cleaner.
It say “Vacuum cleaner not accessible”.

I have a Point Dusty 700, that’s look like an Xiaomi.
Point Dusty 700

Is there someone, that have the same vacuum cleaner or can guide me, what I can try writing in the “entity: vacuum.xxxxx” ?

Looks nice and works! Thank you!

Is there a possibility / a script to clean many selected rooms?
It never let the robot only clean one room and also never all rooms.
It would be perfect, if I could select the Kitchen, the dining room and the living room and when I press the Play Button, it cleans this three areas - like in the Xiaomi App.
I know the segment numbers (Dining room = 16, living room = 17, kitchen = 18, WC = 19, Kids Room = 20, etc)
If I select three rooms and press Play, the Robot should start and clean for exampel segment 16, 17, 18.

Anyone has an idea or a script?