Full gz sim on 22.04 LTS


#1

Here I have installed UBUNTU 22.04 + ROS2 + GAZEBO + ARDUPILOT + DRONEKIT on VIRTUALBOX (Windows 10):

1 Install latest VB with Guest Additions.
https://www.virtualbox.org/

2 Install Ubuntu 22.04 minimal installation.
https://releases.ubuntu.com/22.04/

3 Install ROS2 Humble Hawksbill.
https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html

4 Install Ardupilot SITL with latest fm:
https://community.dojofordrones.com/t/ubuntu-20-python3-setup/304
https://firmware.ardupilot.org/Copter/

5 Install dronekit and dronekit-sitl:
sudo -H pip3 install dronekit==2.9.2
sudo -H pip3 install dronekit-sitl==3.3.0

6 Install QGroundControl
https://docs.qgroundcontrol.com/master/en/getting_started/download_and_install.html

7 Install Gazebo Garden
https://gazebosim.org/docs/garden/install_ubuntu
https://github.com/ArduPilot/ardupilot_gazebo
Note: The ign gazebo command was deprecated in favor of gz sim.
Note: Install sudo apt install libgazebo-dev libopencv-dev prior to "cmake … "

8 Misc
Suggest using VB snapshots after each major install.
This uses a different implementation of worlds (ie, sdf files)
Not all dependencies same as shown in course material.
Consider installation of virtualenv.
Use only python3.

9 Demo

Run Gazebo

gz sim -v4 -r iris_runway.sdf

Run ArduPilot SITL

To run an ArduPilot simulation with Gazebo, the frame should have gazebo- in it and have JSON as model. Other command line parameters are the same as usual on SITL.

sim_vehicle.py -v ArduCopter -f gazebo-iris --model JSON --map --console

Arm and takeoff

STABILIZE> mode guided
GUIDED> arm throttle
GUIDED> takeoff 5

dronekit.TimeoutError: wait_ready experienced a timeout after 30 seconds
Ubuntu 18.04.6 (course build); "Launch QGC with DK script part3" mode GUIDED loop hanging (launchSitl basic_template.py)
What do you want to do with your drone?
Does anyone want a Vmware for the Python3 Setup?
#2

Great intel. I have been hoping for an update on versions. Ardupilot version is 4.0.3?, Mavlink? Mavproxy? All the latest?? QGroundControl, still Windows only correct?? Thank you.


#3

Ardupilot 4.3.2. Yes, All latest on Windows host.

I will be trying to reproduce the course programs (eg, Precision Landing) in this environment.


#4

My last conversation with Emlid on the Navio2 was that it was good to go for Ardupilot 4.0.3. Do you think there will be any suprises if I use 4.3.2? This is not a fair question, I will just have to try 4.3.2, but I can likely do the 4.0.3 as well…??


#5

Not sure I do not have Navio2 experience.


#6

This is great to know. Did you ever successfully work through the rest of the precision landing course with the updated versions? And if so what did you do to get it to work?


Ubuntu 20 + Python3 setup
MAVSDK interest
#7

I have been slowly working through the training exercises at ROS2, but hopefully will return to the dojo scripts soon and report what I find.


#8

I have now completed this project using the above installations. Hopefully I will share this via a blog but in the meantime if anyone is interested you can email me. Now working to get the PL code to work with it.


#9

Link to updated SITL install (Step 4 above) -
https://community.dojofordrones.com/t/failed-for-submodule-update-init-recursive/947/4


#12

This is not the place to post these questions. Could you re-post as new questions under Drone Programming.


Ubuntu 18.04.6 (course build); "Launch QGC with DK script part3" mode GUIDED loop hanging (launchSitl basic_template.py)
#13

Thank you for notifying me. Appreciate all the dedication you provide.