That was a super hint
Now it works. But still does not look at nice as is does in the example:
Still more i need to configure?
That was a super hint
Now it works. But still does not look at nice as is does in the example:
Hi all,
I’m using the xiaomi map extractor, but does anyone succeed integrating the functionality of the Roborock S7Vmax Ultra including mopping ?
Thanks a lot !
Kr,
Bart
map-card-primary-text-color: white
You are right, the icons are missing because of my theme.
map-card-primary-text-color: white
Does not solve it, but with another Theme it does work.
What do you mean with missing tiles?
I would need to check it.
You have less tiles compared to the demo config presented here https://youtu.be/H7FSk_92I7E
I am now using the following integration → https://github.com/nergal/homeassistant-vacuum-viomi and it looks lilke this:
Yes. Buuuut with this integration you won’t be able to control your vacuum using the map (it doesn’t have required services). I recommend switching to this integration since (probably) there’s no better solution at this moment
Even when using the integration you provided only the “normal” start stop change fan speed button work. The zone clearning says its started but nothing happens. The message i got is:
{
"domain": "vacuum",
"service": "vacuum_clean_zone",
"serviceData": {
"zone": [
[
0.12767356406203234,
1.3871171380984606,
1.5579656447606176,
2.0044010887157455
]
],
"repeats": 1,
"entity_id": "vacuum.vaccum"
}
}```
Don’t you have debug: true
in your config?
I tried it with
logger:
default: info
logs:
custom_components.miio2: debug
but nothing appears in the log.
Show config of the card
It looks like this:
type: custom:xiaomi-vacuum-map-card
title: Xiaomi Vacuum Map Card
preset_name: Live map
entity: vacuum.vaccum
vacuum_platform: KrzysztofHajdamowicz/miio2
map_source:
camera: camera.xiaomi_cloud_map_extractor
calibration_source:
camera: true
two_finger_pan: true
debug: true
map_locked: false
map-card-primary-text-color: white
You have to remove debug: true
line from card’s config and everything will work
Thank you very much. That was the trick. I understood the debug line differently
Are you maybe able to explain me, how i zoom into the map automatically. It is far away on every start
The best way would be to adjust your map in Map Extractor using trim
functionality.
I went through a learning process to discover how to have HA switch maps from the UI:
Example card config fragment:
additional_presets:
- entity: vacuum.roborock_s5_max
preset_name: Bath/Closet
activate_on_switch: true
activate:
service: vacuum.send_command
service_data:
command: load_multi_map
params: 1
target:
entity_id: '[[entity_id]]'
I did the same thing for the default config, using params: 0 for the load_multi_map command.
Now when I switch the preset in the UI, HA sends a load_multi_map command to the vacuum, which causes the UI to notice the new map and re-render the image. Perfect!
There may be better ways to achieve this, please let me know.
I’m wondering if there is a way to find out which map is the currently active one on the vacuum.
If I load/restore a map on the vacuum, it is correctly reflected on the card. I’d like to check that the correct map is loaded before sending some commands, but I can’t find a way to query whether it is loaded.
You can tell which map is loaded based on the calibration point attributes in camera.xiaomi_cloud_map_extractor
If you don’t have the autoupdate on you call it with
- service: homeassistant.update_entity
data: {}
target:
entity_id: camera.xiaomi_cloud_map_extractor
and then check the calibration points.
In my case I used a template sensor to always tell me what floor the vacuum is on. Even if the robot loads the map itself (rather than me doing it manually) the extractor is updating the calibration point attributes, and this can tell me the floor and rooms.
#robot vacuum floor
- sensor:
- name: "Robot Vacuum Floor"
unique_id: 'B819ySBel09W1Sl40jJnuKdO0QLYeqb8'
state: >
{% set state=state_attr('camera.xiaomi_cloud_map_extractor','calibration_points')[0].map.x %}
{% set state2=state_attr('camera.xiaomi_cloud_map_extractor','calibration_points')[1].map.x %}
{% set state3=state_attr('camera.xiaomi_cloud_map_extractor','calibration_points')[2].map.x %}
{% if is_number(state) and state | float == 150 and is_number(state2) and state2 | float == 170 and is_number(state3) and state3 | float == 150 %}
Downstairs
{% elif is_number(state) and state | float == 119 and is_number(state2) and state2 | float == 139 and is_number(state3) and state3 | float == 119 %}
Upstairs
{% elif is_number(state) and state | float == 120 and is_number(state2) and state2 | float == 140 and is_number(state3) and state3 | float == 120 %}
Upstairs
{% else %}
unknown
{% endif %}