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

#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.