Update SpotArea
Update SpotArea and CLI command to more closely reflect the app Library: SpotArea namedarea -> area SpotArea customarea -> map_position CLI Commands: spotclean -> area Ex: sucks area 0,1 - will clean areas 0 and 1 / A and B area options: --map-postion|-p - will clean a specified map coordinate Ex: sucks area -p "-602,1812,800,723" - will clean the specified custom map coordinates
This commit is contained in:
+6
-6
@@ -1020,14 +1020,14 @@ class Stop(Clean):
|
||||
super().__init__('stop', 'normal')
|
||||
|
||||
class SpotArea(Clean):
|
||||
def __init__(self, action='start', namedarea='', customarea='', cleanings='1'):
|
||||
if namedarea != '': #For cleaning specified map area
|
||||
super().__init__('spot_area', 'normal', act=CLEAN_ACTION_TO_ECOVACS[action], mid=namedarea)
|
||||
elif customarea != '': #For cleaning custom map area, and specify deep amount 1x/2x
|
||||
super().__init__('spot_area' ,'normal',act=CLEAN_ACTION_TO_ECOVACS[action], p=customarea, deep=cleanings)
|
||||
def __init__(self, action='start', area='', map_position='', cleanings='1'):
|
||||
if area != '': #For cleaning specified area
|
||||
super().__init__('spot_area', 'normal', act=CLEAN_ACTION_TO_ECOVACS[action], mid=area)
|
||||
elif map_position != '': #For cleaning custom map area, and specify deep amount 1x/2x
|
||||
super().__init__('spot_area' ,'normal',act=CLEAN_ACTION_TO_ECOVACS[action], p=map_position, deep=cleanings)
|
||||
else:
|
||||
#no valid entries
|
||||
raise ValueError("must provide namedarea or customarea for spotarea clean")
|
||||
raise ValueError("must provide area or map_position for spotarea clean")
|
||||
|
||||
class Charge(VacBotCommand):
|
||||
def __init__(self):
|
||||
|
||||
Reference in New Issue
Block a user