I've install python-miio on my domoticz RPi i've get the token and everything. I've create a sh script mirobotStart.sh like that
Code: Select all
#!/bin/bash
miiocli roborockvacuum --model rockrobo.vacuum.v1 --ip 192.168.1.32 --token 5061---------------------366f start
I've then create a dummy switch in domoticz and on "Action On:" i fill the following command
script:///home/pi/domoticz/scripts/Xiaomi/mirobotStart.sh
When i activate the dummy switch the log told me that
Code: Select all
2022-11-30 18:44:05.371 Status: User: Admin (IP: 192.168.1.18) initiated a switch command (356/Xiaomi Robot/On)
2022-11-30 18:44:05.596 Status: Executing script: /home/pi/domoticz/scripts/Xiaomi/mirobotStart.sh
2022-11-30 18:44:05.614 Error: Error executing script command (/home/pi/domoticz/scripts/Xiaomi/mirobotStart.sh). returned: 32512
Code: Select all
-rwxrwxrwx 1 pi pi 153 Nov 30 16:00 mirobotStart.sh