Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix manual_control error message typo #127

Merged
merged 2 commits into from
Nov 22, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions miio/vacuum.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ def manual_control_once(
def manual_control(self, rotation: int, velocity: float,
duration: int=1500):
"""Give a command over manual control interface."""
if rotation <= -180 or rotation >= 180:
if rotation < -180 or rotation > 180:
raise DeviceException("Given rotation is invalid, should "
"be ]-3.1,3.1[, was %s" % rotation)
if velocity <= -0.3 or velocity >= 0.3:
"be ]-180, 180[, was %s" % rotation)
if velocity < -0.3 or velocity > 0.3:
raise DeviceException("Given velocity is invalid, should "
"be ]-0.3, 0.3[, was: %s" % velocity)

Expand Down