[TOC]
The aim of this project is to build a robot with four jumping legs (which can fold) and four mecanum wheels, operated by a human via the Robot Operating System (ROS).
The system is distributed across:
-
Raspberry Pi - which main task is to steer the robot's motors.
-
Laptop with Linux operating system - enables human's interaction.
The robot can:
- jump,
- fold its legs,
- drive in multiple directions.
The robot's behavior can be controlled by a human operating the "robot.py" node on the laptop.
Laptop with Linux:
-
Install ROS kinetic - follow steps from: http://wiki.ros.org/kinetic/Installation/Ubuntu
-
Create a catkin workspace - follow steps from:
- http://wiki.ros.org/catkin/Tutorials/create_a_workspace
- http://wiki.ros.org/catkin/Tutorials/CreatingPackage <instead of calling package "beginner_tutorials" call it "my_dynamixel">
-
Upload files to my_dynamixel package:
- upload the file "robot.py" to: ~/catkin_ws/src/my_dynamixel/
-
Build packages in catkin workspace
-
Go to catkin workspace directory
$ cd ~/catkin_ws/
-
Build packages
$ catkin_make
-
-
Configure .bashrc file
-
Open .bashrc file
$ gedit .bashrc
-
Add at the bottom of the file following lines:
export ROS_MASTER_URI=http://localhost:11311/ export ROS_HOSTNAME=<the laptop's IP> export ROS_IP=<the laptop's IP>
-
Source .bashrc file
$ source .bashrc
-
Raspberry Pi:
-
Follow steps 1 and 2 from the laptop's instruction <instead of calling package "my_dynamixel" call it "my_dynamixel_tutorial">
-
Install Dynamixel Controllers driver
$ sudo apt-get install ros-<distro>-dynamixel-controllers
-
Upload files to my_dynamixel_tutorial package:
- upload content of the "launch" folder to: ~/catkin_ws/src/my_dynamixel_tutorial/launch/
- upload content of the "src" folder to: ~/catkin_ws/src/my_dynamixel_tutorial/
-
Build packages in catkin workspace
-
Go to catkin workspace directory
$ cd ~/catkin_ws/
-
Build packages
$ catkin_make
-
-
Configure .bashrc file
-
Open .bashrc file
$ gedit .bashrc
-
Add at the bottom of the file following lines:
export ROS_MASTER_URI=http://the laptop's IP:11311/ export ROS_HOSTNAME=<the Raspberry's IP> export ROS_IP=<the Raspberry's IP>
-
Source .bashrc file
$ source .bashrc
-
In order to run the system, following steps are to be executed:
-
Run roscore in a terminal on the Linux laptop
$ roscore
-
Connect the Raspberry Pi to a power
-
Connect to the Raspberry Pi from the second terminal on the laptop and run ROS nodes on the former
$ ssh pi@<Raspberry_IP>
$ roslaunch my_dynamixel_tutorial controller_manager.launch
-
Connect to the Raspberry Pi from the third terminal on the laptop and run ROS nodes on the former
$ ssh pi@<Raspberry_IP>
$ roslaunch my_dynamixel_tutorial start_pan_controller.launch
$ roslaunch my_dynamixel_tutorial start_tilt_controller.launch
-
To enable human-control over the robot, run the following node in the fourth terminal on the laptop
$ rosrun my_dynamixel robot.py
Keyboard commands (to be pressed in the robot.py node window):
- W - full speed forward
- S - full speed backwards
- T - stop
- A - full speed left
- D - full speed right
- Q - full speed diagonal forward left
- E - full speed diagonal forward right
- Z - full speed diagonal backward left
- C - full speed diagonal backward right
- X - rotate at a full speed anti-clockwise
- V - rotate at a full speed clockwise
- Y - increase current speed by 7% of its maximum value
- H - reduce current speed by 7% of its maximum value
- O - setting the robot's leg to 0 position
- K - setting the robot's legs to the first starting position
- N - setting the robot's legs to the second starting position
- J - changing the robot's legs position by -0.05 (rad)
- L - changing the robot's legs position by +0.05 (rad)
- M - jumping (from the first starting position)
- O - jumping (from the second starting position)
- 0 - rotating legs up
- 1 - rotating legs down by 0.1 (rad)
- 2 - rotating legs up by 0.1 (rad)
- 3 - rotating legs down
- 5 - preparing legs to down-folding (when initial position is ~0)
- 5 - preparing legs to down-folding (when initial position is ~5.2)
Evaluation of the robot's driving behavior:
- Early stages - https://youtu.be/BNNEmNGqUxc
- Final stage - https://youtu.be/ybAbjyJAmC4
Evaluation of the robot's jumping behavior:
- Just one leg - https://youtu.be/G1J8bCmxgGU
- Early stages with all four legs - https://youtu.be/6cJKMZFHYcE
- Four legs after some improvements - https://youtu.be/etr4STEtW9g
- Final stage - https://youtu.be/HQ1hYwN6pAw
Height of a jump experiment - https://youtu.be/KC6PH26aIuQ
Legs folding - https://youtu.be/vKZoalooXHU
The robot's behavior animation - https://youtu.be/MrXAhyIWOSs
Final demonstration of all behaviors - https://youtu.be/TGW2EMyFp7g
Michal Bogoryja-Zakrzewski
Tengxiao He
Haiwei Xu