Skip to content

Commit

Permalink
allow cleaning by map ID
Browse files Browse the repository at this point in the history
dshokouhi authored Mar 7, 2019
1 parent 345ef16 commit 1d327c0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pybotvac/robot.py
Original file line number Diff line number Diff line change
@@ -62,7 +62,7 @@ def _message(self, json):
response.raise_for_status()
return response

def start_cleaning(self, mode=2, navigation_mode=1, category=None, boundary_id=None):
def start_cleaning(self, mode=2, navigation_mode=1, category=None, boundary_id=None, map_id=None):
# mode & navigation_mode used if applicable to service version
# mode: 1 eco, 2 turbo
# navigation_mode: 1 normal, 2 extra care, 3 deep
@@ -92,6 +92,8 @@ def start_cleaning(self, mode=2, navigation_mode=1, category=None, boundary_id=N
}
if boundary_id:
json['params']['boundaryId'] = boundary_id
if map_id:
json['params']['mapId'] = map_id
elif self.service_version == 'minimal-2':
json = {'reqId': "1",
'cmd': "startCleaning",

0 comments on commit 1d327c0

Please sign in to comment.