ROS packages for autonomous trajectory planning and tracking for IG32 Mecanum Ground Rover.
Built and tested on Intel NUC with Ubuntu 20.04 and ROS Noetic.
- Install dependencies:
pip install numpy scipy - Install pytorch: https://pytorch.org/get-started/locally/ (select Stable, Linux, Pip, Python, CPU)
- Setup ROS with Arduino (https://maker.pro/arduino/tutorial/how-to-use-arduino-with-robot-operating-system-ros)
- Flash Arduino code:
- Install catkin tools: https://catkin-tools.readthedocs.io/en/latest/installing.html
- Install ROS dependencies:
sudo apt-get updateandrosdep install --from-paths . git clone https://github.com/adamdai/rover_ros_ws.gitcd rover_ros_wscatkin buildsource devel/setup.bash
Nodes:
traj_tracker.py: Listens for published nominal trajectories and handles state estimation and low-level control for tracking.
Nodes:
simple_planner.py: Publishes a single nominal trajectory parameterized by desired linear and angular velocity (can be provided as command-line arguments, i.e.,rosrun planner simple_planner.py w_des v_des).sequence_planner.py: Publishes a pre-defined sequence of nominal trajectoriesnn_planner.py: Uses a pre-trained neural network to generate trajectories which avoid obstacles and reach a specified goal region.reachability_planner.py: Uses the neural network planner with an added reachability safety layer which checks the safety of planned trajectories and replans if unsafe.
Nodes:
mocap.py: Interface with vrpn mocap topic to provide mocap measurements.
params.py: Edit global parameters.
Contains all third party ROS packages used: vrpn_client_ros, cv_camera, apriltag,apriltag_ros
- Start vrpn client:
roslaunch vrpn_client_ros sample.launch - Start rosserial:
rosrun rosserial_python serial_node.py _port:=/dev/ttyACM0 - Start sensing nodes:
rosrun sensing mocap.pyrosrun cv_camera cv_camera_noderoslaunch apriltag_ros continuous_detection.launch
- Start planning/control nodes:
rosrun controller traj_tracker.pyrosrun planner simple_planner.pyorrosrun planner nn_planner.pyorrosrun planner reachability_planner.py