Giter Club home page Giter Club logo

pendulum's Introduction

Inverted pendulum demo

Disclaimer

This is work in progress and should be considered just as a proof of concept on how to leverage ROS 2 features to use in real-time applications. Any feedback and help to improve the project is appreciated.

Rolling branch is under active development.

Build status

Build Status License GitHub issues

Table of content

Project description

The aim of this project is to show the real-time capabilities using the ROS2 framework. This project is based on the previous work made by the Open Robotics. The project uses these packages as a base.

This is the motivation of using an inverted pendulum for a real-time demo:

A classic example of a controls problem commonly solved by real-time computing is balancing an inverted pendulum. If the controller blocked for an unexpectedly long amount of time, the pendulum would fall down or go unstable. But if the controller reliably updates at a rate faster than the motor controlling the pendulum can operate, the pendulum will successfully adapt react to sensor data to balance the pendulum.

A more detailed description of demo the project design be found here: Design Article

Install instructions

Several ways to install the pendulum demo project are provided depending on the user needs.

  • ADE based installation: This provides a pre-configured Docker image with everything ready to be used. This is the recommended option to quickly test the demo. It is also useful to have development environment to add new features.
  • Installation from source: provides instructions to build all the required ROS 2 packages from source.
  • Crosscompilation: provides instructions to crosscompile the demo for an embedded device.
  • Pre-configured Raspberry PI image: provides a Raspberry PI with everything configured in a Linux Real-time (RT-PREEMPT patch).

How to run the demo

Source your workspace

If installed as an ADE image:

source /opt/ros/rolling/setup.bash

If installed from source:

cd ~/pendulum_ws
source ./install/setup.bash

Launch the demo

A complete explanation of all the possible options to run the demo can be found in the tutorial document:

For a quick test, launch the demo with rviz enabled:

ros2 launch pendulum_bringup pendulum_bringup.launch.py rviz:=True

If everything went well you should see the inverted pendulum being controlled in rviz:

pendulum_rviz

How to configure real-time settings

Instructions to configure the demo real-time settings can be found here.

How to measure real-time performance metrics

TODO

How to contribute

Make a fork using github, and make your changes. This project uses the same guidelines as all the officials ROS 2 packages, make sure that your code is compliant with cppcheck, uncrustify... After this, submit a PR and we will review as soon as possible.

Issues and feature request

Please, use the templates and make sure that you labeled them properly. Also, consider to open a PR to fix the issue or to implement a feature.

pendulum's People

Contributors

carlossvg avatar landeru avatar igorrecioh avatar r7vme avatar viplav04 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.