All Projects → PX4 → Px4 Sitl_gazebo

PX4 / Px4 Sitl_gazebo

Set of plugins, models and worlds to use with OSRF Gazebo Simulator in SITL and HITL.

Projects that are alternatives of or similar to Px4 Sitl gazebo

Hexapod Robot Simulator
A hexapod robot simulator built from first principles
Stars: ✭ 577 (+217.03%)
Mutual labels:  robotics, hacktoberfest
Hexapod
Blazing fast hexapod robot simulator for the web.
Stars: ✭ 370 (+103.3%)
Mutual labels:  robotics, hacktoberfest
Gazebo
Open source robotics simulator.
Stars: ✭ 404 (+121.98%)
Mutual labels:  robotics, hacktoberfest
Sdformat
Simulation Description Format (SDFormat) parser and description files.
Stars: ✭ 51 (-71.98%)
Mutual labels:  robotics, hacktoberfest
Ign Gazebo
Open source robotics simulator. Through Ignition Gazebo users have access to high fidelity physics, rendering, and sensor models. Additionally, users and developers have multiple points of entry to simulation including a graphical user interface, plugins, and asynchronous message passing and services. Ignition Gazebo is derived from Gazebo, and represents over 16 years of development and experience in robotics and simulation. This library is part of the Ignition Robotics project.
Stars: ✭ 81 (-55.49%)
Mutual labels:  robotics, hacktoberfest
Researchpapernotes
Initiative to read research papers
Stars: ✭ 97 (-46.7%)
Mutual labels:  robotics, hacktoberfest
Awesome Emulators Simulators
A curated list of software emulators and simulators of PCs, home computers, mainframes, consoles, robots and much more...
Stars: ✭ 94 (-48.35%)
Mutual labels:  robotics, hacktoberfest
Dolly
🤖🐑 It's a sheep, it's a dolly, it's a following robot. Dolly was born to be cloned.
Stars: ✭ 113 (-37.91%)
Mutual labels:  robotics, hacktoberfest
Zoo For Zotero
This is an Android app for viewing Zotero libraries.
Stars: ✭ 181 (-0.55%)
Mutual labels:  hacktoberfest
Slurp
Evaluate the security of S3 buckets
Stars: ✭ 183 (+0.55%)
Mutual labels:  hacktoberfest
Python Neo
Neo is a package for representing electrophysiology data in Python, together with support for reading a wide range of neurophysiology file formats
Stars: ✭ 180 (-1.1%)
Mutual labels:  hacktoberfest
Thunder
An open-source game engine is written in C++ with a flexible architecture
Stars: ✭ 182 (+0%)
Mutual labels:  hacktoberfest
Fiesta
Fast Incremental Euclidean Distance Fields for Online Motion Planning of Aerial Robots
Stars: ✭ 182 (+0%)
Mutual labels:  robotics
Javascript Biginteger
A big integer library for JavaScript
Stars: ✭ 181 (-0.55%)
Mutual labels:  hacktoberfest
Tox
Command line driven CI frontend and development task automation tool.
Stars: ✭ 2,523 (+1286.26%)
Mutual labels:  hacktoberfest
Circe
Yet another JSON library for Scala
Stars: ✭ 2,223 (+1121.43%)
Mutual labels:  hacktoberfest
Skiasharp
SkiaSharp is a cross-platform 2D graphics API for .NET platforms based on Google's Skia Graphics Library. It provides a comprehensive 2D API that can be used across mobile, server and desktop models to render images.
Stars: ✭ 2,493 (+1269.78%)
Mutual labels:  hacktoberfest
Discord Bot Dashboard
📊 A tool for Discord.js Bot Developers to get detailed analytics of their bots and to manage them.
Stars: ✭ 182 (+0%)
Mutual labels:  hacktoberfest
Bastion
Highly-available Distributed Fault-tolerant Runtime
Stars: ✭ 2,333 (+1181.87%)
Mutual labels:  hacktoberfest
Cargo Spellcheck
Checks all your documentation for spelling and grammar mistakes with hunspell and a nlprule based checker for grammar
Stars: ✭ 183 (+0.55%)
Mutual labels:  hacktoberfest

PX4 Gazebo Plugin Suite for MAVLink SITL and HITL

Build Status MacOS Build Tests

This is a flight simulator for rovers, boats, multirotors, VTOL, fixed wing. It uses the motor model and other pieces from the RotorS simulator, but in contrast to RotorS has no dependency on ROS. Original project: https://github.com/ethz-asl/rotors_simulator.

If you use this simulator in academic work, please cite RotorS as per the README in the above link.

Installation

This simulator is designed to be used with the PX4 Autopilot. Please follow the official developer toolchain installation instructions: http://docs.px4.io/master/en/simulation/gazebo.html

Contributing and Testing

Please refer to the installations instructions above for normal usage and to get the development environment installed. This section covers specifics for developers interested to contribute to the simulator.

sitl_gazebo plugin dependencies

Some plugins on this packages require some specific dependencies:

  • Protobuf is required to generate custom protobuf messages to be published and subscribed between topics of different plugins;
  • Jinja 2 is used to generate some SDF models from templates;
  • Gstreamer is required for a plugin that streams video from a simulated camera.

Build sitl_gazebo

Clone the repository to your computer.

IMPORTANT: If you do not clone to ~/src/sitl_gazebo, all remaining paths in these instructions will need to be adjusted.

mkdir -p ~/src
cd src
git clone --recursive https://github.com/PX4/sitl_gazebo.git

Create a build folder in the top level of your repository:

mkdir build

Navigate into the build directory and invoke CMake from it:

cd ~/src/sitl_gazebo
cd build
cmake ..

Now build the gazebo plugins by typing:

make -j$(nproc) -l$(nproc)

Next add the location of this build directory to your gazebo plugin path, e.g. add the following line to your .bashrc (Linux) or .bash_profile (Mac) file:

# Set the plugin path so Gazebo finds our model and sim
export GAZEBO_PLUGIN_PATH=${GAZEBO_PLUGIN_PATH}:$HOME/src/sitl_gazebo/build
# Set the model path so Gazebo finds the airframes
export GAZEBO_MODEL_PATH=${GAZEBO_MODEL_PATH}:$HOME/src/sitl_gazebo/models
# Disable online model lookup since this is quite experimental and unstable
export GAZEBO_MODEL_DATABASE_URI=""

You also need to add the the root location of this repository, e.g. add the following line to your .bashrc (Linux) or .bash_profile (Mac) file:

# Set path to sitl_gazebo repository
export SITL_GAZEBO_PATH=$HOME/src/sitl_gazebo

Install

If you wish the libraries and models to be usable anywhere on your system without specifying th paths, install as shown below.

Note: If you are using Ubuntu, it is best to see the packaging section.

sudo make install

Testing

Gazebo will now launch when typing 'gazebo' on the shell:

. /usr/share/gazebo/setup.sh
. /usr/share/mavlink_sitl_gazebo/setup.sh
gazebo worlds/iris.world

Please refer to the documentation of the particular flight stack how to run it against this framework, e.g. PX4

Unit Tests

For building and running test an installation of 'googletest' is needed.

On Ubuntu it can be installed with:

sudo apt-get install libgtest-dev
cd /usr/src/googletest
sudo cmake . && cd googletest
sudo make -j$(nproc) -l$(nproc)
sudo cp *.a /usr/lib

On macOS it needs to be installed from source:

git clone https://github.com/google/googletest
pushd googletest
mkdir build
pushd build
cmake ..
make -j$(nproc) -l$(nproc)
make install

When writing test it’s important to be careful which API functions of Gazebo are called. As no Gazebo server is running during the tests some functions can produce undefined behaviour (e.g. segfaults).

CUDA Hardware Accelerated H264 encoding (optional)

  1. Download CUDA 10.0 from https://developer.nvidia.com/cuda-toolkit-archive.
  2. Download Video Codec SDK 9.0 from https://developer.nvidia.com/video-codec-sdk-archive.
  3. Install both archives:
wget https://raw.githubusercontent.com/jackersson/env-setup/master/gst-nvidia-docker/install_video_codec_sdk.sh
chmod +x install_video_codec_sdk.sh
sudo ./install_video_codec_sdk.sh
sudo dpkg -i cuda-repo-ubuntu*.deb
sudo apt-key add /var/cuda-repo-<version>/7fa2af80.pub
sudo apt-get update
sudo apt-get install cuda
  1. Reboot your system and run the command nvidia-smi to verify the successul installation of CUDA.
  2. Install GStreamer 1.18.3:
git clone https://github.com/GStreamer/gst-build -b 1.18.3
cd gst-build
meson -Dbuildtype=release -Dstrip=true -Dgst-plugins-bad:introspection=enabled -Dgst-plugins-bad:nvcodec=enabled builddir
ninja -C builddir
sudo meson install -C builddir
  1. Add <useCuda>true</useCuda> to any gazebo_gst_camera_plugin in a SDF file. For example ./models/fpv_cam/fpv_cam.sdf.

catkin tools

With catkin, the unit tests are enabled by default.

# After setting up the catkin workspace
catkin build -j4 -l4 -DBUILD_ROS_PLUGINS=ON
cd build/mavlink_sitl_gazebo/
catkin run_tests

Plain CMake

For building the tests with plain CMake, the flag ENABLE_UNIT_TESTS needs to be provided.

mkdir build && cd build
cmake -DENABLE_UNIT_TESTS=On ..

Then build and run the tests:

make -j$(nproc) -l$(nproc)
make test

Packaging

Debian packages

To create a debian package for Ubuntu and install it to your system.

cd Build
cmake ..
make
rm *.deb
cpack -G DEB
sudo dpkg -i *.deb
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].