- Wireless connection with jetson (ssh)
- connect both laptop and jetson to TP-link course wifi
- on laptop, run
ssh jetson@10.42.0.103password isjetson - on flight, connect the green power board to the lipo battery
- Wiring connecction with jetson (usage: code dev on jetson)
- require: monitor, mouse, keyboard
- connect jetson to a wifi with internet service
- Jetson nano fan: in terminal run
fan_onorfan_off
- their command are encoded in ~/.bashrc: eg.
sudo sh -c 'sudo echo 255 > /sys/devices/pwm-fan/target_pwm'
- Build
colcon build --symlink-install
- Start MAVROS & PX4
ros2 launch px4_autonomy_modules mavros.launch.py- If not working correctly,
ls /dev/ttyUSB*, expected to seettyUSB0
- Start RealSense Pose Estimation
ros2 launch realsense2_camera rs_launch.py
- Run the Drone Communication Node
ros2 run rob498_drone comm_node
- Check VICON & RealSense Pose Data (Optional)
ros2 topic echo /vicon/ROB498_Drone/ROB498_Droneros2 topic echo /camera/pose/sample
- Send Commands Using ROS 2 Services (TA will run this during the actual test)
ros2 service call rob498_drone_3/comm/launch std_srvs/srv/Trigger(<-)ros2 service call rob498_drone_3/comm/test std_srvs/srv/Triggerros2 service call rob498_drone_3/comm/land std_srvs/srv/Trigger(<-)ros2 service call rob498_drone_3/comm/abort std_srvs/srv/Trigger
ros2 launch px4_autonomy_modules mavros.launch.py
-
realsense to mavros
ros2 topic echo /mavros/vision_pose/pose -
vicon to mavros
ros2 topic echo /mavros/local_position/pose -
start task3 node
ros2 run rob498_drone task3
ros2 launch realsense2_camera rs_launch.py
ros2 run realsense_tracking t265_node --> RGB-D Map
ros2 run rob498_drone project --> Planner
ros2 bag record /depth_image /rgb_image /camera/pose/sample /vicon/ROB498_Drone/ROB498_Drone -o rosbag_1- Replay the bag and run
ros2 run realsense_tracking save_bagwhich generates a folder with *.npy files - Then you can visualize it by running
python3 src/scripts/planner_clean.py
python3 src/scripts/inference_actuation.py --> actuates the Arduino code
- (For Micro XRCE-DDS only) Upgrade your cmake to above 3.22 (https://answers.ros.org/question/293119/)
- tar -xzvf cmake-3.30.8.tar.gz # source tar.gz (no distro)
- cd ~/Downloads/cmake-3.30.8/
- ./bootstrap --prefix=$HOME/cmake-install
- make -j$(nproc)
- sudo make install
- echo 'PATH=$HOME/cmake-install/bin:$PATH' >> ~/.bashrc
- echo 'CMAKE_PREFIX_PATH=$HOME/cmake-install:$CMAKE_PREFIX_PATH' >> ~/.bashrc
- NEVER RUN purge -autoremove cmake!!
- Upgrade your numpy to above 1.24 (it might affect ROS2 foxy packages but will
sudo apt remove python3-numpypip3 install numpysudo apt install ros-foxy-desktop python3-argcomplete
- Setup PX4-Autopilot following (PX4/PX4-Autopilot#21117)
- git clone https://github.com/PX4/PX4-Autopilot.git
- cd PX4-Autopilot.git
- git checkout v1.11.3
- git submodule update --init --recursive
- bash ./PX4-Autopilot/Tools/setup/ubuntu.sh --no-nuttx
- make px4_sitl gazebo
- (Optional) Setup Micro XRCE-DDS Agent & Client (https://github.com/PX4/PX4-user_guide/blob/main/tr/ros2/user_guide.md)
-
https://github.com/ros-perception/image_pipeline.git -
ros2 launch stereo_image_proc stereo_image_proc.launch.py namespace:=stereo -
ros2 run image_view stereo_view stereo:=/stereo image:=image_rect_colorbug: terminate called after throwing an instance of 'rclcpp::exceptions::InvalidTopicNameError' what(): Invalid topic name: topic name must not contain repeated '/': '/stereo/left//image' -
ros2 run image_view image_view image:=/stereo/left/image_rect_color
sudo add-apt-repository "deb [arch=arm64] https://packages.microsoft.com/repos/vscode stable main"sudo apt updatesudo apt install codecode
https://github.com/utiasSTARS/ROB498-support https://github.com/utiasSTARS/ROB498-flight
if free space >= 32GB https://github.com/AastaNV/JEP/blob/master/script/install_opencv4.6.0_Jetpack5.sh
sudo cp /opt/nvidia/jetson-gpio/etc/99-gpio.rules /etc/udev/rules.d/
sudo udevadm control --reload-rules && sudo udevadm trigger
K_left = [[286.1167907714844, 0.0, 421.62689208984375, 0.0], [0.0, 286.27880859375, 399.5252990722656, 0.0], [0.0, 0.0, 1.0, 0.0], [0.0, 0.0, 0.0, 1.0] ]

