rcute_cozmars.head¶
-
class
rcute_cozmars.head.Head(robot)¶ -
default_speed= None¶ The default head rotation angular velocity (degrees/second), the default is 100, if set to None, it will rotate at fastest speed
-
auto_relax_delay= None¶ time delay to automatically relax servo after head rotates, default to 1 sec. If set to None, servo will not relax.
When head moves to target position, relaxing the servo can prevent damage and save battery power.
-
max_angle¶ head’s maximum angle in degrees, read only
-
angle¶ get/set target angle at
default_speed
-
min_angle¶ head’s minimum angle in degrees, read only
-
set_angle(angle, *, duration=None, speed=None)¶ Set the angle of the head
参数: - angle (float) – target angle position
- duration (float, optional) – duration in seconds for the movement, default is None for fastest speed
- speed (float, optional) – angular speed at which to move head, the default is None for fastest speed
引发: TypeError – duration and speed cannot both be set, otherwise an exception will be thrown
-