Software home page#

Projects manifests#

Each manifest corresponds to an out of the box systems that will work immediatly on specified platform.

Attention

If you want to select a release, take the Packages section .zip file named code_and_doc_release_VXX.zip

Name

Description

Links

Doc

Compatibility

INS ESP32-S3

Complete INS with sensors parsing, fusion and communication tasks for ESP32-S3

appgit

Releases: apprelease

appdoc

  • ESP32-S3

INS SENSORS ONLY

Parsing of 3 axis accelerometer, 3 axis gyrometer, 3 axis magnetometer and barometer with compatibility with all microcontrollers

sensorsgit

Releases: sensorsrelease

sensorsdoc

  • All (arduino framework)

INS MINIMAL

Parsing of all sensors and adding fusion. Should be compatible with all microcontrollers if fusion has been precompiled

minimalgit

Releases: minimalrelease

minimaldoc

  • All (arduino framework)

Precompiled fusion has to be available for the microcontroller chosen

Caution

Even if it is not the recommended method, a package compatible with Arduino IDE is provided for INS SENSORS ONLY project, and documented HERE: Arduino IDE packaged code

Libraries#

Name

Description

Link

Doc

Compatibility

libDM_timer_tool

Sysrox library that provides standardized access to timers, timestamps…

timergit

  • ESP32-S3

  • Teensy 4.X

libDM_ctrl

Sysrox library which provides filters, matrix operations, discontinuities…

ctrlgit

  • All

libDM_stream_logger

Sysrox library providing interface for high performance logging (SDIO) and interaction with SD cards

streamgit

streamdoc

  • ESP32-S3

  • Teensy 4.X

sdfat_legacy

Well known Bill Greiman library providing implementation for high speed interface with SD cards. libDM_stream_logger is built on top of it and uses it for logging on Teensy 4.X and caching data for ESP32-S3

sdfatgit

Original repo

  • ESP32-S3

  • Teensy 4.X

libDM_abstract_sensors

Sysrox library which implements base (parent) classes for sensors operations and corrections

abstractgit

abstractdoc

  • ESP32-S3

  • Teensy 4.X

libDM_icm42688

Sysrox library which implements ICM-42688p imu sensor SPI driver

icmgit

icmdoc

  • ESP32-S3

  • Teensy 4.X

libMM_lps_22hb

Sysrox library which implements lps22hb barometer SPI driver

lpsgit

lpsdoc

  • ESP32-S3

  • Teensy 4.X

libDM_mmc5983ma

Sysrox library which implements mmc5983ma magnetometer SPI driver

mmcgit

mmcdoc

  • ESP32-S3

  • Teensy 4.X

libDM_no_dep_abstract_sensors

Sysrox library which implements base (parent) classes for sensors operations and corrections without cross dependencies

abstractndgit

abstractnddoc

  • All (Arduino framework)

libDM_no_dep_icm42688

Sysrox library which implements ICM-42688p imu sensor SPI driver without cross dependencies

icmndgit

icmnddoc

  • All (Arduino framework)

libMM_no_dep_lps_22hb

Sysrox library which implements lps22hb barometer SPI driver without cross dependencies

lpsndgit

lpsnddoc

  • All (Arduino framework)

libDM_no_dep_mmc5983ma

Sysrox library which implements mmc5983ma magnetometer SPI driver without cross dependencies

mmcndgit

mmcnddoc

  • All (Arduino framework)

libDM_generic_operations

Sysrox library which wrap some hardware functions or classes when they are not available in the framework used

genericgit

  • ESP32-S3

  • Teensy 4.X

libDM_ublox_gps

Sysrox library which implements ublox GPS (tested on M8N, M9N) UART driver (NAV_PVT frame implemented)

ubloxgit

  • ESP32-S3

  • Teensy 4.X

libDM_can

Sysrox library which implements CAN protocol communication

cangit

candoc

  • ESP32-S3

ArduinoJson

Benoit Blanchon library which facilitate the manipulation of json files

jsongit Original repo

  • all

libDM_mavlink

Sysrox library which implements mavlink communication based on official mavlink c libraries

mavgit

mavdoc

  • ESP32-S3

  • Teensy 4.X

libDM_protobuf

Sysrox library which implements protobuf communication and structures usage

protogit

protodoc

  • ESP32-S3

  • Teensy 4.X

libDM_msg_center

Sysrox library which centralize communication processes with standardized API for mavlink, protobuf, CAN…

msgcentergit

msgcenterdoc

  • ESP32-S3

  • Teensy 4.X

libDM_SRX_INS_10_DOF

Sysrox library composed of header and precompiled static library which implements high performance sensors fusion. If you need precompiled version for your platform, CONTACT

fusiongit

insdoc

  • ESP32-S3

  • Teensy 4.X

  • Linux

  • Macos apple Silicon

  • Windows

nanopb

Petteri Aimonen library, with memory efficient implementation for protocol buffer. libDM_protobuf is built on top of it

nanopbgit

Original repo

  • All

mavlink

Official Mavlink C library. libDM_mavlink is built on top of it

mavlinkgit Original repo

  • All

libDM_SRX_FFT

FFT algorithm implementation suitable for microcontrollers. The library features automatic data buffering (7 sizes available), shifting and scaling

fftgit

fftdoc

  • All

Log processing tools

Repo with tools to extract protobuf logs. Allow extraction of text logs, binary logs, protobuf and mavlink events

processingLogGit

procLogDoc

  • All

Tools#

Magnetometer calibration tool#

Embedded version#

A fast way to obtain a basic calibrated gyrometer is to use the onboard pseudo calibration. After the MMC5983MA object has been created, you can call calibMag() function. Open a serial terminal and rotate the device around x, y and z axis when asked. The function will print (and log in SD card if any) hard iron offsets and soft iron gains that you can use inside your application with a call to setConfig().

Esp32s3 example

 1// Define MMC object
 2MMC5983MA_SPI mmc(generalConf.mmcSpiClock,
 3            pinConf.pinMmcSS,
 4            &streamObj,
 5            &myTimer,
 6            &SPI,
 7            ABSTRACT_SENSOR_SPI::SPI_CONF());
 8
 9if (mmc.ABSTRACT_MAG::checkBeginState())
10{
11   bool calibrationRes = mmc.calibMag(15000);
12   // Turn the device in around all three axis during 15s!
13}

Minimal example

1// Define MMC object
2MMC5983MA_SPI mmc(generalConf.mmcSpiClock, pinConf.pinMmcSS, &SPI, ABSTRACT_SENSOR_SPI::SPI_CONF());
3
4if (mmc.ABSTRACT_MAG::checkBeginState())
5{
6   bool calibrationRes = mmc.calibMag(15000);
7   // Turn the device in around all three axis during 15s!
8}

This should give something like:

_images/calibMag.png

Set config to magnetometer when you have calibration values

Now at the begining of your application, you can apply the configuration with:

1ABSTRACT_SENSOR::SENSOR_CORRECTIONS magCorrections = ABSTRACT_SENSOR::SENSOR_CORRECTIONS();
2magCorrections.xyzBias = {-0.04F, 0.05F, -0.0976F};
3magCorrections.xyzGain = {1.0188F, 0.9757F, 1.0065F};
4mmc.setConfig(magCorrections);

Offline version#

An executable is provided for:

The idea is to provide a csv file with measured data (you can get them from logging or with printing from serial monitor), and to use your current location caracteristics. The measured movment should include multiple rotations around x, y and z axis. The executable will output complete informations about declination, magnetic field theoretical norm …

Tip

A tolerance value (vs WMM) has to be indicated to filter invalid magnetometer inputs. A good base value is 0.2, this can be increased if the calibration fails or give inconsistent results because of too much rejected values.

chmod +x calibMagLinux.out
./calibMagLinux.out mag.csv 42.5578 6.2914 89 0.2

You can have the location informations at Location.

A csv file example can be found here: MAG CSV EXAMPLE

This should give something like this:

_images/calibMagFull.png

… that you can use at the begining of your application to correct magnetometer values. Hard iron offsets can be used directly inside magCorrections.xyzBias. The diagonal terms of the matrix can be used for magCorrections.xyzGain. If you want to use the complete matrix for soft iron correction, you will have to use the specific formula directly on raw magnetometer measures inside you application:

\[\begin{split}\left(\begin{array}{c} \mathbf{Mag}_{x}\\ \mathbf{Mag}_{y}\\ \mathbf{Mag}_{z} \end{array}\right)_{corr} = \left(\left(\begin{array}{c} \mathbf{Mag}_{x}\\ \mathbf{Mag}_{y}\\ \mathbf{Mag}_{z} \end{array}\right) - \left(\begin{array}{c} \mathbf{hardIron}_{x}\\ \mathbf{hardIron}_{y}\\ \mathbf{hardIron}_{z} \end{array}\right) \right) \cdot softIronMatrix\end{split}\]

Tip

The declination can be added to yaw Global in order to get true north heading value! This result will be valid in the area around latitude/longitude used as arguments for the executable.

Accelerometer calibration tool#

Offline version#

An executable is provided for:

The idea is to provide a csv file with measured data (you can get them from logging or with printing from serial monitor). Acceleration values have to be in g . The measured movment should include the 6 following positions.

_images/acc_6_pos.png

The order is not important but each position has to be held for at least 1 second.

If launched without arguments, the script will provide the instructions:

./calibAccMacOs.out

No enough arguments, please provide: file_path.csv tolerancePct moveMeanWindow diffThreshold windowWidth deltaThresholdWindow
The input csv file format is:
accz,accy,accz
-0.11169,-0.10864,0.99744
-0.11182,-0.10779,0.99792
-0.11194,-0.1095,0.99536
...
Example for tolerancePct moveMeanWindow diffThreshold windowWidth deltaThresholdWindow: 5 50 0.000500 1000 0.002000
Full command example: ./calibAccWindows.exe acc.csv 5 50 5e-4 1000 2e-3

A csv file example can be found here: ACC CSV EXAMPLE So for example, with the acc.csv file example

chmod +x calibAccLinux.out
./calibAccLinux.out acc.csv 5 50 5e-4 1000 2e-3

This should give something like this:

_images/calibAccFull.png

… that you can use at the begining of your application to correct accelerometer values. Acc offsets can be used directly inside accCorrections.xyzBias. The diagonal terms of the matrix can be used for accCorrections.xyzGain. If you want to use the complete matrix for correction, you will have to use the specific formula directly on raw accelerometer measures inside you application:

\[\begin{split}\left(\begin{array}{c} \mathbf{Acc}_{x}\\ \mathbf{Acc}_{y}\\ \mathbf{Acc}_{z} \end{array}\right)_{corr} = \left(\begin{array}{c} \mathbf{Acc}_{x}\\ \mathbf{Acc}_{y}\\ \mathbf{Acc}_{z} \end{array}\right) \cdot accGainMatrix + \left(\begin{array}{c} \mathbf{accOffset}_{x}\\ \mathbf{accOffset}_{y}\\ \mathbf{accOffset}_{z} \end{array} \right)\end{split}\]

Tip

If the calibration fails, you have access to parameters to calibrate with more tolerance on positioning errors:

  • tolerancePct is the main value you can use. It will force acceptation of acceleration values even if they are far away from 1g for a stable position.

  • deltaThresholdWindow can also be increased if you moved a little during holding one or multiple stable position.

  • If accelerometer is noisy, increasing moveMeanWindow can help with filtering the data