Skip to main content
phosphobot provides a simple API to control the robot arm. You can use it to move the robot arm, open or close the gripper, and more. All code examples can be found in our open source repo here.

Square movement

This implementation uses the /move/relative endpoint to move the robot in a square. We simply indicate where we want to move the robot relative to its current position.
square.py

Circle movement

Slow

Since it’s harder to control the robot’s position using relative movements to create a circle, we use the absolute movement instead. We calculate the position of the robot in the circle using the sin and cos functions to create a circular motion.
circle_slow.py

Fast

To quicken the robots movements, we lower the number of steps in the circle. We also increase the sleep time between each step to avoid the robot moving too fast.
circle_fast.py