-
Notifications
You must be signed in to change notification settings - Fork 17
Home
This project contains instructions, code and other artifacts to rebuild the Nvidia Redtail project with a drone running the Arducopter flight stack and the latest Nvidia Jetpack 4.2.x on a TX2.
This wiki will not cover the build instructions and setup for a drone since this is covered in detail in the original Redtail wiki. In addition the this, this repo contains the 3D CAD files to build a one-axis gimbal for the ZED Stereo camera.
In order to rebuild the project, the following components are needed:
- A Jetson TX2 and a small size carrier board, such as the Auvidia J120 to mount the TX2 on a drone
- A drone with enough thrust and size to carry all the needed hardware components, eg a Tarot 650 frame
- A Pixhawk cube with Arducopter installed
- Needed sensors: a px4flow sensor to navigate w/o GPS, a Lidar ground distance sensor. I am using the original PX4Flow along with a Garmin LidarLite.
- A ZED Stereo camera
- A joystick eg Logitech 710
- A laptop running Ubuntu 16.04 or 18.04 is a convenient way to run GCS software like QGroundcontrol as well to control the drone using a Joystick.
The NVIDIA Jetson platform is used to run most of the components, such as DNN inference, the controller, and video streaming. Install Jetpack 4.2.x by using the Nvidia SDKmanager. If you are using the Auvidea J120 breakout board, you need to apply some kernel patches as described here Next, you need to have apsync installed in order to have all drone communication set up correctly. Code and instructions can be found here The Arducopter wiki describes how to connect the Jetson with the Pixhawk here Note: do not use the image file referenced in there since its outdated.
To install Redtail, please follow the steps as described here.
First, install ROS on your PC. For Ubuntu 16.04 (Xenial) install ROS Kinetic Desktop. For instructions see here. For Ubuntu 18.04, install ROS Melodic Desktop, see here
Then install the required joystick driver for your ROS version (kinetic or melodic): http://wiki.ros.org/joy and test if it works as described here.
You need to set the following environment variables and add them to your .bashrc
.
$ export ROS_MASTER_URI=http://10.0.1.128:11311 #the TX2 IP address should be 10.0.1.128 if you are using apsync
$ export ROS_IP=10.0.1.xxx # enter here the IP of your host PC to find out, use ifconfig
Start the joystick node on the host PC:
rosrun joy joy_node _dev:=/dev/input/js0 & # check the correct address of your joystick with ls -l /dev/input
To test if the joystick is operating correctly with ROS: execute the following command in a terminal window on the TX2:
rostopic echo /joy
Alternatively, you can install the joystick support in a docker container as described in the original Nvidia Redtail project on your host PC.
Note: It seems that Jetpack 4.2.x has an issue with the ROS joystick drivers. I was not able to get it running. Therefore I recommend to connect the joystick to the host PC as described above.
The project's AI that enables autonomous navigation is based on a deep neural network (DNN) which can be trained from scratch using publicly available data. A few pre-trained DNNs are also available as a part of this project.
It is usually a good idea to test your code in a simulator. Follow these steps to test....
Once the hardware and software setup steps are complete, it's time to take off! Follow these steps to fly the drone.