File tree Expand file tree Collapse file tree 3 files changed +8
-4
lines changed
Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 11[tool .poetry ]
22name = " python-roborock"
3- version = " 0.1.9 "
3+ version = " 0.1.10 "
44description = " "
55authors = [" humbertogontijo <humbertogontijo@users.noreply.github.com>" ]
66license = " GPL-3.0-only"
Original file line number Diff line number Diff line change @@ -100,9 +100,11 @@ async def list_devices(ctx):
100100 click .echo (f"Known devices { ', ' .join ([device .name for device in home_data .devices + home_data .received_devices ])} " )
101101
102102@click .command ()
103+ @click .option ("--cmd" , required = True )
104+ @click .option ("--params" , required = False )
103105@click .pass_context
104106@run_sync ()
105- async def get_status (ctx ):
107+ async def command (ctx , cmd , params ):
106108 context : RoborockContext = ctx .obj
107109 login_data = context .login_data ()
108110 if not login_data .home_data :
@@ -121,14 +123,14 @@ async def get_status(ctx):
121123 )
122124 device_map [device .duid ] = RoborockDeviceInfo (device , product )
123125 mqtt_client = RoborockMqttClient (login_data .user_data , device_map )
124- await mqtt_client .get_status (home_data .devices [0 ].duid )
126+ await mqtt_client .send_command (home_data .devices [0 ].duid , cmd , params )
125127 mqtt_client .__del__ ()
126128
127129
128130cli .add_command (login )
129131cli .add_command (discover )
130132cli .add_command (list_devices )
131- cli .add_command (get_status )
133+ cli .add_command (command )
132134
133135
134136def main ():
Original file line number Diff line number Diff line change @@ -25,6 +25,8 @@ class RoborockCommand(str, Enum):
2525 APP_CHARGE = "app_charge" ,
2626 APP_SPOT = "app_spot" ,
2727 FIND_ME = "find_me" ,
28+ RESUME_ZONED_CLEAN = "resume_zoned_clean" ,
29+ RESUME_SEGMENT_CLEAN = "resume_segment_clean" ,
2830 SET_CUSTOM_MODE = "set_custom_mode" ,
2931 SET_MOP_MODE = "set_mop_mode" ,
3032 SET_WATER_BOX_CUSTOM_MODE = "set_water_box_custom_mode" ,
You can’t perform that action at this time.
0 commit comments