diff --git a/src/pybricks/robotics.py b/src/pybricks/robotics.py index 684e62da..17b4481c 100644 --- a/src/pybricks/robotics.py +++ b/src/pybricks/robotics.py @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MIT -# Copyright (c) 2018-2020 The Pybricks Authors +# Copyright (c) 2018-2021 The Pybricks Authors """Robotics module for the Pybricks API.""" @@ -100,8 +100,9 @@ def reset(self): """Resets the estimated driven distance and angle to 0.""" pass - def settings(self, straight_speed, straight_acceleration, turn_rate, - turn_acceleration): + def settings( + self, straight_speed, straight_acceleration, turn_rate, turn_acceleration + ): """Configures the speed and acceleration used by :meth:`.straight`, :meth:`.turn`, and :meth:`.curve`. diff --git a/src/pybricks/robotics.pyi b/src/pybricks/robotics.pyi index aec5a42b..675f4a2c 100644 --- a/src/pybricks/robotics.pyi +++ b/src/pybricks/robotics.pyi @@ -1,8 +1,10 @@ # SPDX-License-Identifier: MIT -# Copyright (c) 2020 The Pybricks Authors +# Copyright (c) 2020-2021 The Pybricks Authors from typing import Optional, Tuple, overload, Union + from ._common import Control, Motor +from .parameters import Stop class DriveBase: distance_control: Control @@ -32,3 +34,6 @@ class DriveBase: ) -> None: ... def straight(self, distance: int) -> None: ... def turn(self, angle: int) -> None: ... + def curve( + self, radius: int, angle: int, then: Stop = Stop.HOLD, wait: bool = True + ) -> None: ...