Skip to content
/ rrosace Public

Scheduling of a Cyber-physcal system simulation, Cyber-physical models library

License

Notifications You must be signed in to change notification settings

hnrck/rrosace

Repository files navigation

GitHub version Build Status GitHub issues GitHub forks GitHub stars GitHub license

RROSACE

Scheduling of a Cyber-physcal system simulation -- Cyber-physical models library.

Description

rrosace_pic

This project is a simple longitudinal flight loop ✈️ based on the ROSACE case study. Links 🔗 to the case study, and some implementations, are available below.

RROSACE adds redundancy to ROSACE controllers, in order to highlight scheduling problems.

This project was used as part of a CIFRE PhD thesis 🎓 involving ISAE-SUPAERO and Airbus to illustrate the simulation scheduling of cyber-physical systems.

Table of Contents

1. Usage

1.1. Cloning this repo

This repo is available at 🔗 hnrck/rrosace.

Cloning can be done in HTTPS mode:

$ git clone https://github.com/hnrck/rrosace
$ git checkout tags/1.3.0

or with ssh mode:

$ git clone git@github.com:hnrck/rrosace.git
$ git checkout tags/1.3.0

1.2. Testing the implementation

The compilation of the library can be test using the following command:

$ make test

Please feel free to report problems with your tests.

1.3. Generating the documentation

$ make doc

The documentation can be opened in a browser, or generated in PDF from LaTeX sources.

For browser based navigation, open build/doc/html/index.html For generating PDF, do:

$ make -C build/doc/latex

Generated PDF will be build/doc/latex/refman.pdf

1.4. Building and using the project

In order to build the project, use the following command:

$ make 

Project can be install with:

$ make install

By default, the installation is local. Installed headers and libraries can be used sourcing the local rrosacepathsrc: install/etc/rrosace/rrosacepathsrc This can be done using:

$ source install/etc/rrosace/rrosacepathsrc

Absolute path can be deduced and sourced directly before use, for instance in dev environment in any .{bash,zsh,...}rc.

$ source <path/to/rrosace>/install/etc/rrosace/rrosacepathsrc

Furthermore, while installing, the absolute path of the rrosacepathsrc is given:

...
-- Installing: <path/to/rrosace>/install/etc/rrosace/rrosacepathsrc

After installation and sourcing, rrosace library can be used as any library. Compilation using rrosace library while need linking, using -lrrosace.

The installation can be checked using the simple loop example.

$ make check_install

The following integration of component is recommended, and used in the loop example: rrosace_components

1.5. Other targets

Cleaning the repo:

make clean

Static check on source code (requires clang-tidy):

make lint

Formatting of source code (requires clang-format):

make format

Building / running a simple loop example:

make example_loop
make run_example_loop

1.6. Alternative builds and configurations

It is possible to directly use cmake to build the project, feel free to based your command on the targets in the Makefile

Furthermore, compilation options are possible from the environment, set the following variable in you shell or before your command:

$ export <VAR>=<my option>
$ make

or

$ <VAR>=<my option> make
option VAR default value alternatives
C compiler CC clang gcc, icc, ...
C++ compiler CXX clang++ g++, ...
C++ standard CXXSTD 98 11, 14
Generator GENERATOR Ninja Unix Makefile, ...
Build type BUILD_TYPE RelWithDebInfo Release, Debug, MinSizeRel
Build directory BUILD_DIR build anywhere
Install directory INSTALL_DIR install anywhere
Activate/Deactivate C++ check CPPCHECK 1 (activate) 0 (deactivate)

2. Related work

RROSACE is based on the Open Source ROSACE (Research Open-Source Avionics and Control Engineering) case study.

3. Project structure

.
├── ChangeLog.md
├── cmake-extra-modules
│   └── *.cmake
├── CMakeLists.txt
├── doc
│   └── Doxyfile.in
├── examples
│   └── *
│       └── {Makefile,*.{h,c,cpp}}
├── include
│   └── rrosace{-*}.h
├── LICENSE
├── Makefile
├── README.md
├── res
│   └── *
├── src
│   └── *.c
├── test
│   └── *.{h,c,cpp}
└── VERSION

Important folders:

  • include - the rrosace headers.
  • src - the sources of the rrosace library.
  • test - the rrosace tests folders.
  • examples - the rrosace examples folders, each example has a dedicated folder.

Important files:

  • README.md - this file.
  • LICENSE - the license file.
  • VERSION - the current version of the library.
  • ChangeLog.md - list of changes between revisions.
  • CMakeLists.txt - the project configuration file
  • Makefile - helper for compilation and installation.

4. Contributing

Contributions are welcome 🔓. Feel free to fork too 🍴.

5. Credits

6. License

This work is under the MIT License. ©️ Henrick Deschamps, 2019.