cozmo.robot
Classes and functions relating to an individual Cozmo robot.
The cozmo.conn.CozmoConnection.wait_for_robot()
method returns an
instance of Robot
which controls a single Cozmo robot.
The Robot
class has methods and properties to determine its current
state, control its low-level motors, play animations and start behaviors as
well as performing high-level actions such as detecting faces and picking up
objects.
Each Robot
has a Robot.world
attribute which represents an
instance of a cozmo.world.World
. This tracks the state of the world
that Cozmo knows about: The objects and faces it’s currently observing,
the camera images it’s receiving, etc. You can monitor the world instance for
various events that occur, or monitor individual objects directly: The
world instance receives all events that the robot triggers, and nearly all SDK
objects inherit from cozmo.event.Dispatcher
and therefore inherit
methods such as wait_for()
and
add_event_handler()
.
Module Attributes
|
The minimum angle the robot's head can be set to |
|
The maximum angle the robot's head can be set to |
|
The lowest height-above-ground that lift can be moved to |
|
The largest height-above-ground that lift can be moved to |
|
The length of Cozmo's lift arm |
|
The height above ground of Cozmo's lift arm's pivot |
|
The minimum angle the robot's lift can be set to |
|
The maximum angle the robot's lift can be set to |
Classes
|
Represents the "display oled face image" action in progress. |
|
Represents the dock with cube action in progress. |
|
Represents the drive off charger contacts action in progress. |
|
Represents the "drive straight" action in progress. |
|
Generated when the robot has been initialized and is ready for commands. |
|
Dispatched whenever the robot's state is updated (multiple times per second). |
|
Triggered whenever the robot does not move as expected (typically rotation). |
|
Represents the go to object action in progress. |
|
Represents the go to pose action in progress. |
|
Represents the position of Cozmo's lift. |
|
A helper class to provide a context manager to do operations while Cozmo is off charger. |
|
Represents the pickup object action in progress. |
|
Tracks the state of the "place object on ground here" action. |
|
Tracks the state of the "place on object" action. |
|
Tracks the progress of a "pop a wheelie" robot action. |
|
The interface to a Cozmo robot. |
|
Represents the roll cube action in progress. |
|
Tracks the progress of a say text robot action. |
|
Represents the Set Head Angle action in progress. |
|
Represents the Set Lift Height action in progress. |
|
Tracks the progress of a turn in place robot action. |
|
Tracks the progress of a turn towards face robot action. |
|
Defines the side of collision that caused unexpected movement. |
|
Defines the type of unexpected movement. |