This repo contains the implementation of the solution to the movement control of Phantom X Pincher. This robot has Dynamixel AX-12 motor as an actuators. To use them the dynamixel wizard is recommended and the ros-noetic-dynamixel-workbench is requiered to use them with ROS. This repo is build in the form of a ROS package.
This is package inspired by (blantenly stolen from) the one-motor-repo
1 and the px repo
[^px repo]. Getting these package would be helpful. After getting them and locating them at catkin/src.
Test if they are correctly working.
roslaunch -v px_robot px_rviz.launch
roslaunch dynamixel_one_motor one_controller.launch
To run this package use the following command
roslaunch robotics-lab4 dynamixel_control.launch
sudo apt install ros-noetic-dynamixel-workbench
At the lab you are provided with a kit with:
- The pincher x robot
- A FTDI interface
- A USB cable extender
- Power supply
1 Connect the FTDI to your computer, ensure that is set up to TTL mode.
2 Check it is being detected ls /dev/ttyU*
and set the necessary permissions (only the first tiem).
3 Power up the robot by connecting the power supply to the power jack of the multi connector adapter
4 Connect the FTDI to the multi connector adapter through any of the available port
5 Use Dynamixel wizard to check the motors are working correctly
-
If after following the steps in the guide2 you have trouble and the motors are not recognize on the Dynamixel wizard. check the cable connection.
-
Check Again if the USB is being detected and what permission does it has by running `ls -la /dev/ttyU*
-
If problems remain, try disconnecting one of the motor separating it from the reset (out of the daisy chain) and connect it directly to the multi connector adapter. Check if now it is recognized. If the motors have the same ID number they enter into conflict and won't be recognized by the wizard if there is more than one motor with the same ID connected at the same time3. to solve this, change the ID to a unique value of each of the motors one at the time using the packets tools. This tool allows to communicate with the motor and send commands such as write to registers. Write to register 3 the idea you selected(data length of 1). Other alternative is by following the post referenced below [id-setting].
USB
install usbipd in the host machine. And follow the instructions
inside the wsl instance
sudo apt install linux-tools-virtual hwdata
sudo update-alternatives --install /usr/local/bin/usbip usbip `ls /usr/lib/linux-tools/*/usbip | tail -n1` 20
usbipd wsl --help
usbipd wsl list
usbipd wsl attach --busid=<BUSID>
To begin constructing the direct kinematics, we must first define the home position. To simplify the process, we align the robot in a straight position.
Once the home position is defined, we proceed with the following steps:
- Define an axis for each articulation.
- Construct perpendicular lines that are shared by each pair of articulations.
- Define a z-axis for each axis.
- Define an x-axis along the perpendicular lines, following the DH-hypothesis.
The resulting schematics:
Using the axis systems, we create the DH-table.
Here we can compare the theorical position and the position made by the robot.
- Learning to use RQT (tools from ROS for GUI) was a important challenge during the practice.
- We explore another tools to simplify the development of the GUI (in this case QT Framework).
- Juan Sebastian Duenas ([email protected])
- German Andres Urbina Gutierrez ([email protected])
- Brayan Daniel Barrera Galvis ([email protected])
Footnotes
-
dynamixel one motor [^px repo]: px repo ↩