-
-
Notifications
You must be signed in to change notification settings - Fork 252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vacuum_clean_segment repeat count is -1 #295
Comments
It seems to be a problem with HA integration, not card: #294 |
@mateuszmalek can you check if your vacuum behaves the same? |
Can't confirm it is able to clean more than once with original template. My card config: https://gist.github.com/mateuszmalek/1dacccf8900a18ccb21b7370903121c6
Debug data: {
"domain": "xiaomi_miio",
"service": "vacuum_clean_segment",
"serviceData": {
"segments": [
21,
21,
21
],
"entity_id": "vacuum.roborock_vacuum_s5e"
}
}
Debug data: {
"domain": "xiaomi_miio",
"service": "vacuum_clean_segment",
"serviceData": {
"segments": [
21,
17,
21,
17
],
"entity_id": "vacuum.roborock_vacuum_s5e"
}
} The only way to get it working exactly the same as with Xiaomi Home application is to override default template as I've posted here: #294 (comment) Firmware version on my Roborock is: 3.5.8_1566 (from 20.12.2021). |
Hi @mateuszmalek! |
@bearpawmaxim can you show your config? What doesn't work for your model? |
@PiotrMachowski, ofc! Here Is it: type: custom:xiaomi-vacuum-map-card
map_source:
camera: camera.roborock_s7_map
calibration_source:
camera: true
entity: vacuum.rosha
vacuum_platform: default
map_modes:
- name: Уборка зоны
icon: mdi:select-drag
run_immediately: false
coordinates_rounding: true
selection_type: MANUAL_RECTANGLE
max_selections: 5
repeats_type: EXTERNAL
max_repeats: 3
service_call_schema:
service: xiaomi_miio.vacuum_clean_zone
service_data:
zone: '[[selection]]'
repeats: '[[repeats]]'
entity_id: '[[entity_id]]'
predefined_selections: []
variables: {}
- name: Точка назначения
icon: mdi:map-marker-plus
run_immediately: false
coordinates_rounding: true
selection_type: MANUAL_POINT
max_selections: 999
repeats_type: NONE
max_repeats: 1
service_call_schema:
service: xiaomi_miio.vacuum_goto
service_data:
x_coord: '[[point_x]]'
y_coord: '[[point_y]]'
entity_id: '[[entity_id]]'
predefined_selections: []
variables: {}
- name: Комнаты
icon: mdi:floor-plan
run_immediately: false
coordinates_rounding: true
selection_type: ROOM
max_selections: 999
repeats_type: REPEAT
max_repeats: 3
service_call_schema:
service: xiaomi_miio.vacuum_clean_segment
service_data:
segments: '[[selection]]'
entity_id: '[[entity_id]]'
predefined_selections:
- id: '16'
icon:
name: mdi:broom
x: 30300
'y': 30400
label:
text: Room 16
x: 30300
'y': 30400
offset_y: 35
outline:
- - 28200
- 28950
- - 32400
- 28950
- - 32400
- 31850
- - 28200
- 31850
- id: '17'
icon:
name: mdi:broom
x: 29525
'y': 26975
label:
text: Room 17
x: 29525
'y': 26975
offset_y: 35
outline:
- - 27000
- 25200
- - 32050
- 25200
- - 32050
- 28750
- - 27000
- 28750
- id: '18'
icon:
name: mdi:broom
x: 24275
'y': 27225
label:
text: Room 18
x: 24275
'y': 27225
offset_y: 35
outline:
- - 23400
- 25100
- - 25150
- 25100
- - 25150
- 29350
- - 23400
- 29350
- id: '19'
icon:
name: mdi:broom
x: 23700
'y': 31350
label:
text: Room 19
x: 23700
'y': 31350
offset_y: 35
outline:
- - 23200
- 30850
- - 24200
- 30850
- - 24200
- 31850
- - 23200
- 31850
- id: '20'
icon:
name: mdi:broom
x: 24900
'y': 30975
label:
text: Room 20
x: 24900
'y': 30975
offset_y: 35
outline:
- - 24200
- 30150
- - 25600
- 30150
- - 25600
- 31800
- - 24200
- 31800
- id: '21'
icon:
name: mdi:broom
x: 27175
'y': 30975
label:
text: Room 21
x: 27175
'y': 30975
offset_y: 35
outline:
- - 26300
- 30150
- - 28050
- 30150
- - 28050
- 31800
- - 26300
- 31800
- id: '22'
icon:
name: mdi:broom
x: 26100
'y': 26925
label:
text: Room 22
x: 26100
'y': 26925
offset_y: 35
outline:
- - 25200
- 25150
- - 27000
- 25150
- - 27000
- 28700
- - 25200
- 28700
- id: '23'
icon:
name: mdi:broom
x: 26225
'y': 29425
label:
text: Room 23
x: 26225
'y': 29425
offset_y: 35
outline:
- - 24250
- 28750
- - 28200
- 28750
- - 28200
- 30100
- - 24250
- 30100
variables: {}
tiles:
- tile_id: status
entity: vacuum.rosha
label: Статус
attribute: status
icon: mdi:robot-vacuum
translations:
starting: Начало уборки
charger disconnected: Зарядное устройство отключено
idle: Ожидание
remote control active: Включено управление через пульт
cleaning: Уборка
returning home: Возвращение на базу
manual mode: Ручной режим
charging: Зарядка
charging problem: Проблема с зарядкой
paused: Пауза
spot cleaning: Уборка точки
error: Ошибка
shutting down: Выключение
updating: Обновление
docking: Остановка у базы
going to target: Направление до точки
zoned cleaning: Уборка зоны
segment cleaning: Уборка
emptying the bin: Очистка бака
charging complete: Зарядка завершена
device offline: Устройство не в сети
- tile_id: battery_level
entity: vacuum.rosha
label: Уровень заряда
attribute: battery_level
icon: mdi:battery-charging-100
unit: '%'
- tile_id: fan_speed
entity: vacuum.rosha
label: Мощность всасывания
attribute: fan_speed
icon: mdi:fan
translations:
silent: Тихий
standard: Стандарт
medium: Средний
turbo: Турбо
auto: Авто
gentle: Слабый
- tile_id: sensor_dirty_left
label: Уровень загрязнения датчиков
unit: ч
multiplier: 0.0002777777777777778
hold_action:
action: call-service
service: vacuum.send_command
confirmation: true
service_data:
command: reset_consumable
params: sensor_dirty_time
entity_id: vacuum.rosha
entity: sensor.roborock_vacuum_a15_sensor_dirty_left
icon: mdi:eye-outline
precision: 0
translations: {}
- tile_id: filter_left
label: Ресурс фильтра
unit: ч
multiplier: 0.0002777777777777778
hold_action:
action: call-service
service: vacuum.send_command
confirmation: true
service_data:
command: reset_consumable
params: filter_work_time
entity_id: vacuum.rosha
entity: sensor.roborock_vacuum_a15_filter_left
icon: mdi:air-filter
precision: 0
translations: {}
- tile_id: main_brush_left
label: Ресурс основной щётки
unit: ч
multiplier: 0.0002777777777777778
hold_action:
action: call-service
service: vacuum.send_command
confirmation: true
service_data:
command: reset_consumable
params: main_brush_work_time
entity_id: vacuum.rosha
entity: sensor.roborock_vacuum_a15_main_brush_left
icon: mdi:brush
precision: 0
translations: {}
- tile_id: side_brush_left
label: Ресурс боковой щётки
unit: ч
multiplier: 0.0002777777777777778
hold_action:
action: call-service
service: vacuum.send_command
confirmation: true
service_data:
command: reset_consumable
params: side_brush_work_time
entity_id: vacuum.rosha
entity: sensor.roborock_vacuum_a15_side_brush_left
icon: mdi:brush
precision: 0
translations: {}
- tile_id: cleaning_count
label: Число уборок
entity: sensor.roborock_vacuum_a15_total_clean_count
icon: mdi:counter
precision: 0
translations: {}
icons:
- icon: mdi:play
conditions:
- entity: vacuum.rosha
value_not: cleaning
- entity: vacuum.rosha
value_not: error
- entity: vacuum.rosha
value_not: returning
tooltip: Старт
tap_action:
action: call-service
service: vacuum.start
service_data:
entity_id: vacuum.rosha
- icon: mdi:pause
conditions:
- entity: vacuum.rosha
value_not: docked
- entity: vacuum.rosha
value_not: idle
- entity: vacuum.rosha
value_not: error
- entity: vacuum.rosha
value_not: paused
tooltip: Пауза
tap_action:
action: call-service
service: vacuum.pause
service_data:
entity_id: vacuum.rosha
- icon: mdi:stop
conditions:
- entity: vacuum.rosha
value_not: docked
- entity: vacuum.rosha
value_not: idle
- entity: vacuum.rosha
value_not: error
- entity: vacuum.rosha
value_not: paused
tooltip: Стоп
tap_action:
action: call-service
service: vacuum.stop
service_data:
entity_id: vacuum.rosha
- icon: mdi:home-map-marker
conditions:
- entity: vacuum.rosha
value_not: docked
- entity: vacuum.rosha
value_not: returning
tooltip: Вернуть к базе
tap_action:
action: call-service
service: vacuum.return_to_base
service_data:
entity_id: vacuum.rosha
- icon: mdi:target-variant
conditions:
- entity: vacuum.rosha
value_not: docked
- entity: vacuum.rosha
value_not: error
- entity: vacuum.rosha
value_not: cleaning
- entity: vacuum.rosha
value_not: returning
tooltip: Убрать точку
tap_action:
action: call-service
service: vacuum.clean_spot
service_data:
entity_id: vacuum.rosha
- icon: mdi:map-marker
tooltip: Обнаружить
tap_action:
action: call-service
service: vacuum.locate
service_data:
entity_id: vacuum.rosha
- icon: mdi:fan-remove
conditions:
- entity: vacuum.rosha
attribute: fan_speed
value: Silent
tooltip: Изменить мощность всасывания
tap_action:
action: call-service
service: vacuum.set_fan_speed
service_data:
entity_id: vacuum.rosha
fan_speed: Standard
- icon: mdi:fan-speed-1
conditions:
- entity: vacuum.rosha
attribute: fan_speed
value: Standard
tooltip: Изменить мощность всасывания
tap_action:
action: call-service
service: vacuum.set_fan_speed
service_data:
entity_id: vacuum.rosha
fan_speed: Medium
- icon: mdi:fan-speed-2
conditions:
- entity: vacuum.rosha
attribute: fan_speed
value: Medium
tooltip: Изменить мощность всасывания
tap_action:
action: call-service
service: vacuum.set_fan_speed
service_data:
entity_id: vacuum.rosha
fan_speed: Turbo
- icon: mdi:fan-speed-3
conditions:
- entity: vacuum.rosha
attribute: fan_speed
value: Turbo
tooltip: Изменить мощность всасывания
tap_action:
action: call-service
service: vacuum.set_fan_speed
service_data:
entity_id: vacuum.rosha
fan_speed: Silent
- icon: mdi:fan-alert
conditions:
- entity: vacuum.rosha
attribute: fan_speed
value_not: Silent
- entity: vacuum.rosha
attribute: fan_speed
value_not: Standard
- entity: vacuum.rosha
attribute: fan_speed
value_not: Medium
- entity: vacuum.rosha
attribute: fan_speed
value_not: Turbo
tooltip: Изменить мощность всасывания
tap_action:
action: call-service
service: vacuum.set_fan_speed
service_data:
entity_id: vacuum.rosha
fan_speed: Silent The issue is the same: when I select room cleaning and set repeat count to 2 or 3, the vacuum cleans the room only once. |
@bearpawmaxim well, your config doesn't contain the fix. Also it seems that you have unnecessarily clicked "generate static config" button. You can use following config to apply the fixtype: custom:xiaomi-vacuum-map-card
map_source:
camera: camera.roborock_s7_map
calibration_source:
camera: true
entity: vacuum.rosha
vacuum_platform: default
map_modes:
- template: vacuum_clean_zone
- template: vacuum_goto
- template: vacuum_clean_segment
repeats_type: EXTERNAL
max_repeats: 3
service_call_schema:
service: vacuum.send_command
service_data:
command: app_segment_clean
entity_id: '[[entity_id]]'
params:
- segments: '[[selection]]'
repeat: '[[repeats]]'
predefined_selections:
- id: '16'
icon:
name: mdi:broom
x: 30300
'y': 30400
label:
text: Room 16
x: 30300
'y': 30400
offset_y: 35
outline:
- - 28200
- 28950
- - 32400
- 28950
- - 32400
- 31850
- - 28200
- 31850
- id: '17'
icon:
name: mdi:broom
x: 29525
'y': 26975
label:
text: Room 17
x: 29525
'y': 26975
offset_y: 35
outline:
- - 27000
- 25200
- - 32050
- 25200
- - 32050
- 28750
- - 27000
- 28750
- id: '18'
icon:
name: mdi:broom
x: 24275
'y': 27225
label:
text: Room 18
x: 24275
'y': 27225
offset_y: 35
outline:
- - 23400
- 25100
- - 25150
- 25100
- - 25150
- 29350
- - 23400
- 29350
- id: '19'
icon:
name: mdi:broom
x: 23700
'y': 31350
label:
text: Room 19
x: 23700
'y': 31350
offset_y: 35
outline:
- - 23200
- 30850
- - 24200
- 30850
- - 24200
- 31850
- - 23200
- 31850
- id: '20'
icon:
name: mdi:broom
x: 24900
'y': 30975
label:
text: Room 20
x: 24900
'y': 30975
offset_y: 35
outline:
- - 24200
- 30150
- - 25600
- 30150
- - 25600
- 31800
- - 24200
- 31800
- id: '21'
icon:
name: mdi:broom
x: 27175
'y': 30975
label:
text: Room 21
x: 27175
'y': 30975
offset_y: 35
outline:
- - 26300
- 30150
- - 28050
- 30150
- - 28050
- 31800
- - 26300
- 31800
- id: '22'
icon:
name: mdi:broom
x: 26100
'y': 26925
label:
text: Room 22
x: 26100
'y': 26925
offset_y: 35
outline:
- - 25200
- 25150
- - 27000
- 25150
- - 27000
- 28700
- - 25200
- 28700
- id: '23'
icon:
name: mdi:broom
x: 26225
'y': 29425
label:
text: Room 23
x: 26225
'y': 29425
offset_y: 35
outline:
- - 24250
- 28750
- - 28200
- 28750
- - 28200
- 30100
- - 24250
- 30100 Or following config and install the latest beta versiontype: custom:xiaomi-vacuum-map-card
map_source:
camera: camera.roborock_s7_map
calibration_source:
camera: true
entity: vacuum.rosha
vacuum_platform: default
map_modes:
- template: vacuum_clean_zone
- template: vacuum_goto
- template: vacuum_clean_segment
predefined_selections:
- id: '16'
icon:
name: mdi:broom
x: 30300
'y': 30400
label:
text: Room 16
x: 30300
'y': 30400
offset_y: 35
outline:
- - 28200
- 28950
- - 32400
- 28950
- - 32400
- 31850
- - 28200
- 31850
- id: '17'
icon:
name: mdi:broom
x: 29525
'y': 26975
label:
text: Room 17
x: 29525
'y': 26975
offset_y: 35
outline:
- - 27000
- 25200
- - 32050
- 25200
- - 32050
- 28750
- - 27000
- 28750
- id: '18'
icon:
name: mdi:broom
x: 24275
'y': 27225
label:
text: Room 18
x: 24275
'y': 27225
offset_y: 35
outline:
- - 23400
- 25100
- - 25150
- 25100
- - 25150
- 29350
- - 23400
- 29350
- id: '19'
icon:
name: mdi:broom
x: 23700
'y': 31350
label:
text: Room 19
x: 23700
'y': 31350
offset_y: 35
outline:
- - 23200
- 30850
- - 24200
- 30850
- - 24200
- 31850
- - 23200
- 31850
- id: '20'
icon:
name: mdi:broom
x: 24900
'y': 30975
label:
text: Room 20
x: 24900
'y': 30975
offset_y: 35
outline:
- - 24200
- 30150
- - 25600
- 30150
- - 25600
- 31800
- - 24200
- 31800
- id: '21'
icon:
name: mdi:broom
x: 27175
'y': 30975
label:
text: Room 21
x: 27175
'y': 30975
offset_y: 35
outline:
- - 26300
- 30150
- - 28050
- 30150
- - 28050
- 31800
- - 26300
- 31800
- id: '22'
icon:
name: mdi:broom
x: 26100
'y': 26925
label:
text: Room 22
x: 26100
'y': 26925
offset_y: 35
outline:
- - 25200
- 25150
- - 27000
- 25150
- - 27000
- 28700
- - 25200
- 28700
- id: '23'
icon:
name: mdi:broom
x: 26225
'y': 29425
label:
text: Room 23
x: 26225
'y': 29425
offset_y: 35
outline:
- - 24250
- 28750
- - 28200
- 28750
- - 28200
- 30100
- - 24250
- 30100 |
Well, some time ago I have tried this fix, saw that the vacuum does nothing and reverted it back. |
It worked with the latest beta and the old config (whoops! forgot to change it..). Thanks! |
@PiotrMachowski, after setting the config as you wrote (for beta version) the room cleaning isn't working at all. It only shows 'Success' toast but vacuum isn't reacting at all. |
@bearpawmaxim removing single quotes from room IDs: - - id: '16'
+ - id: 16 |
Seems to be working now! Thanks! |
@bearpawmaxim yup, I might have to adjust it |
Done in v2.2.0 |
Checklist
The problem
When I wanted to use new default repeat in 'room mode' (
template: vacuum_clean_segment
) I noticed that when I choose repeat 1 or 2 and one room it will clean only once. When I choose repeat 2 and 2 rooms, it will clean first room twice but second only once. When I choose repeat 3 and one room - it will clean twice that room... And so on... So it looks that last segment id in lgenerated list is missing...What version of a card has described problem?
2.0.9
What was the last working version card?
No response
What vacuum model do you have problems with?
roborock.vacuum.s5e
Which integration do you use to control your vacuum (link)?
https://www.home-assistant.io/integrations/xiaomi_miio/
What browser (browsers/apps) does have this problem?
Chrome
What version of Home Assistant do you use?
core-2021.12.8
What type of installation are you running?
Home Assistant OS
Card's configuration
Javascript errors shown in the browser's console (if applicable)
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: