8. Skip to content

8. Keyboard Control#

After installing the airbot_py and starting the driver service, you can control the arm via keyboard input—handy for quick tests and demos.

Launch it with:

python3 -m airbot_examples.task_kbd_ctrl -p <PORT>
  • <PORT> – gRPC server listen-port. Use a unique port per device (e.g. 50000, 50001, 50010) when several arms are connected; this value must match the port you used when starting the driver service.

This page lists the key mapping. Each key triggers a specific action or control mode.

8.0.1 Common Controls#

Key Action
Enter Toggle between SLOW and DEFAULT speed modes
Space Switch between SERVO_JOINT_VEL (joint-speed)SERVO_CART_TWIST (Cartesian velocity) modes
Tab Enter PLANNING_POS (Planned Position) mode and move to the starting pose
[ Close gripper 三
] Open gripper
z Quit program

8.0.2 Joint-Velocity Control (SERVO_JOINT_VEL mode)#

In SERVO_JOINT_VEL mode the following keys command joint velocities:

Key Action
1 Joint 1 positive (+vel)
2 Joint 1 negative (−vel)
3 Joint 2 positive (+vel)
4 Joint 2 negative (−vel)
5 Joint 3 positive (+vel)
6 Joint 3 negative (−vel)
7 Joint 4 positive (+vel)
8 Joint 4 negative (−vel)
9 Joint 5 positive (+vel)
0 Joint 5 negative (−vel)
- Joint 6 positive (+vel)
= Joint 6 negative (−vel)

8.0.3 Cartesian Velocity Control (SERVO_CART_TWIST mode)#

In SERVO_CART_TWIST , the following keys control the robotic arm's movement in Cartesian space:

Key Action
a Move +Y (left) (+vel)
d Move −Y (right) (−vel)
w Move +X (forward) (+vel)
s Move −X (backward) (−vel)
q Move +Z (up) (+vel)
e Move −Z (down) (−vel)
o Rotate +X (+vel)
u Rotate −X (−vel)
i Rotate +Y (+vel)
k Rotate −Y (−vel)
j Rotate +Z (toward user) (+vel)
l Rotate −Z (away from user) (−vel)

8.0.4 Safety Notes#

  • Clear the arm workspace before taking control.
  • Press Ctrl+C at any time to stop the program.