Skip to content

Commit cca77b2

Browse files
authored
Merge pull request #18 from mklomp/docs_warnings
Updated warnings for documentation
2 parents a37c799 + 695b9d4 commit cca77b2

1 file changed

Lines changed: 8 additions & 9 deletions

File tree

mirte_robot/robot.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ def _check_available(self, services: dict[str] | None, id: str) -> bool:
464464
return id in services
465465

466466
def getTimestamp(self) -> float:
467-
"""Gets the elapsed time in seconds since the initialization fo the Robot.
467+
"""Gets the elapsed time in seconds since the initialization of the Robot.
468468
469469
Returns:
470470
float: Time in seconds since the initialization of the Robot. Fractions of a second may be present if the system clock provides them.
@@ -496,7 +496,7 @@ def getDistance(self, sensor: str) -> float:
496496
float: Range in meters measured by the HC-SR04 sensor. (The distance gets clamped to minimum and maximum range of the HC-SR04 sensor)
497497
498498
Warning:
499-
A maximum of 6 distance sensors is supported.
499+
Depeding on the MCU used, there might be a mamimum of the number of distance sensors one can use.
500500
"""
501501

502502
value = self._call_service(self.distance_services[sensor], GetRange.Request())
@@ -775,15 +775,14 @@ def setServoAngle(self, servo: str, angle: float) -> bool:
775775
bool: True if set successfully.
776776
777777
Warning:
778-
The servo uses the Servo library from Arduino (through Telemetrix). This also
779-
means that, when a servo is used and the library is enabled, the last timer on
780-
the MCU will be used for timing of the servos. This timer therefore can not be
781-
used for PWM anymore. For Arduino Nano/Uno this means pins D9 and D10 will not
782-
have PWM anymore. For the SMT32 this means pins A1, A2, A3, A15, B3, B10, and B11
783-
will not have PWM anymore.
778+
Servos use PWM signals, which needs MCU timers. Depending on the MCU
779+
and the servo implementation, it might be the case that enabling a servo
780+
can interfere with (or use other) timers. This can lead to PWM signals not
781+
functioning on some pins that used to have PWM (due to used timers).
784782
785783
Warning:
786-
A maximum of 12 servos is supported.
784+
Depeding on the MCU used, there might be a mamimum of the number of servos
785+
one can use.
787786
"""
788787
value = self._call_service(
789788
self.servo_services[servo],

0 commit comments

Comments
 (0)