Waiting for the official integration, I found some vacuum commands and coded the following workarounds:
script:
roborock_set_customize_mode:
alias: "Set Roborock to use customized cleaning settings for each room"
sequence:
- alias: "Set vacuum mode to customized"
service: vacuum.send_command
target:
entity_id: vacuum.roborock
data:
command: set_custom_mode
params: [106]
- alias: "Set mopping mode to customized"
service: vacuum.send_command
target:
entity_id: vacuum.roborock
data:
command: set_water_box_custom_mode
params: [204]
roborock_set_manual_mode:
alias: "Set Roborock manual vacuum and mopping settings"
fields:
vacuum:
description: "Vacuum mode - can be: silent | balanced | turbo | max"
example: "max"
mopping:
description: "Mopping mode - can be: off | low | medium | high"
example: "off"
sequence:
- alias: "Config variables"
variables:
config_vacuum:
silent: 101
balanced: 102
turbo: 103
max: 104
config_mopping:
'off': 200
low: 201
medium: 202
high: 203
vacuum_mode: "{{ config_vacuum[vacuum] }}"
mopping_mode: "{{ config_mopping[mopping] }}"
- choose:
- alias: "Invalid vacuum value"
conditions: "{{ vacuum not in config_vacuum|list }}"
sequence:
- service: system_log.write
data:
message: "Invalid vacuum value '{{ vacuum }}'. Valid values are {{ config_vacuum|list|join(', ') }}"
level: warning
logger: roborock
- alias: "Invalid mopping value"
conditions: "{{ mopping not in config_mopping|list }}"
sequence:
- service: system_log.write
data:
message: "Invalid mopping value '{{ lavaggio }}'. Valid values are {{ config_mopping|list|join(', ') }}"
level: warning
logger: roborock
default:
- alias: "Set vacuum mode"
service: vacuum.send_command
target:
entity_id: vacuum.roborock
data:
command: set_custom_mode
params: "[{{ vacuum_mode }}]"
- alias: "Set mopping mode"
service: vacuum.send_command
target:
entity_id: vacuum.roborock
data:
command: set_water_box_custom_mode
params: "[{{ mopping_mode }}]"
Call one of the scripts before starting the robot cleaning.
I hope this can help while the official integration implements mop control.
note: the vaccum and mopping mode set with the scripts are not reflected in the Xiaomi Home App note2: I didn’t find a way to control the mop route setting