Build Your Own Bender: Step 1, Controlling a robotic arm with Qt Quick

Build Your Own Bender: Step 1,
Controlling a robotic arm with Qt Quick
Jon Trulson & Dustin Kassman
Presented by
• Jon Trulson, Senior Development Engineer
– Specializes in Linux/Unix & embedded
systems
• Dustin Kassman, Program Manager
– Herds cats (i.e. programmers)
• Key players
– Nick Iwuc
– Vlad Moolle, Ivan Sobol
– Roland Krause
Agenda
•
•
•
•
Overview of the project
About the AX-12A Smart Arm
Architecture and Components
A closer look
– Server
– Client
– User Interface
• Demonstration
• What comes next
The Bender Project
• Design & build a library & infrastructure that
enables the control of a Smart Arm across a
network
• Components
– AX-12A Smart Arm
– Controller with server
– Remote client
AX-12A Smart Robotic Arm
• 5-axis robotic arm
– ~20” reach, 3 lb lift
• Seven AX-12A digital servos
• Aluminum construction
• $850 for base arm, power supply, wiring
harness, & USB2Dynamixel dongle
– Upgrades: Servos, grippers, pressure &
ultrasonic
– Pro-series models
• CrustCrawler Robotics (www.crustcrawler.com)
Architecture
Client/Server Components
Low-level Arm Control Library
• AXServo class
– Responsible for communication with the arm’s
serial network
• Sends commands/reports status
– Deals with communication errors
– Handles dual-servo joints
• sendCommand()– lowest level command
mechanism
• The workhorses - readByte(),
writeByte(), readWord(), writeWord()
More Low-level Arm Control Library
• Common registers – goalPosition, Moving,
Speed
• Servo health – temperature, errors
• Torque – applying force and maintaining the goal
position
• Telemetry registers - currentSpeed,
currentPosition
Command Server Component
• Handles communication with a local or remote client
– Only allows one network client at a time
• Simple line-based text protocol
– telemetry joint=<jointname> position speed load
temperature torque moving error
– move joint=<jointname> position=<0-1023> [wait]
– torque joint=<jointname> enabled=(true|false)
– ping joint=<jointname>
– Pause for=<milliseconds>
• Also supports entering commands using telnet,
netcat, etc
Qt Quick Development Client
Manual/Script Client
Demo
Lessons Learned
• Expect communication errors
• ID servos before assembling arm
• Configure servos with proper speed & torque
– Some settings require power-cycling servos
• Watch for conditions that can damage servos
• Make sure servos will respond to all commands
– CTRL_StatusReturnLevel == 2
• Don’t try to make a servo exceed the physical
limits imposed by the arm
Next Steps
• AXServo
– Add support for joints with >2 servos
– Read/write multiple (contiguous) registers
– Support MX and Pro servos
• Command server
– Protocol commands to support describing an arm’s
configuration (number of servos, arm length, etc)
– Make it easier to move joints simultaneously from a
script
• User client
– Finish manual control version
– Develop a full visual control version
Contact us
• Dustin Kassman ([email protected])
• Jon Trulson ([email protected])