Difference between revisions of "Data Logger"

From PaparazziUAV
Jump to: navigation, search
m
Line 24: Line 24:
 
==* [[SDLogger_SPI_Direct|SD Logger SPI Direct]]==
 
==* [[SDLogger_SPI_Direct|SD Logger SPI Direct]]==
 
==* [[Micro_logger|Micro Logger]]==
 
==* [[Micro_logger|Micro Logger]]==
 +
==* [[file_logger|File Logger (Bebop)]]==
  
 
=Storage format=
 
=Storage format=
  
 
A more unified method of storing data on the logger, [[Messages_Format#Telemetry_storage_format_for_data_logger|info available here]]
 
A more unified method of storing data on the logger, [[Messages_Format#Telemetry_storage_format_for_data_logger|info available here]]
 
=Logging Data on the Parrot Bebop=
 
 
Logging data onboard on the Bebop is pretty straight forward, as long as someone takes the time to tell you how. In this case, this guide will have to do. The Bebop drone is equipped with onboard storage, which we use to store the logs.
 
 
'''Step 1:'''
 
First, open your <tt> airframe.xml </tt> file (for example in <tt> paparazzi/conf/airframes/TUDELFT/ </tt>). Make sure that under modules, the following lines are uncommented or included: (only  <tt> <module name="logger_file"> <define name="FILE_LOGGER_PATH" value="/data/ftp/internal_000"/> </tt> have to be included).
 
 
<source lang="xml">
 
  <modules main_freq="512">
 
    <module name="geo_mag"/>
 
    <module name="air_data"/>
 
    <module name="send_imu_mag_current"/>
 
    <module name="logger_file">
 
      <define name="FILE_LOGGER_PATH" value="/data/ftp/internal_000"/>
 
    </module>
 
  </modules>
 
</source>
 
 
'''Step 2:'''
 
In your logger file include the headers within paparazzi which contain the variables which you would like to log. This is done in the logger c file in  <tt> paparazzi/sw/airborne/modules/loggers/file_logger.c </tt>. In this case I want to log data from <tt> stabilization_indi.c </tt>, so the following header should be included:
 
 
<source lang="c">
 
#include "firmwares/rotorcraft/stabilization/stabilization_indi.h"
 
</source>
 
 
In the file <tt> file_logger.c </tt> you can specify which variables you want to have logged in the same fashion as normal "printf's" would work. The variable names and the variable types (float, int etc.) have to be specified.
 
 
'''Step 3:'''
 
Start and stop the file logger by going to the paparazzi ground control station. Then go to > Settings > Modules. Here you can start and stop a log. This is displayed in the picture below:
 
 
[[File:Bebop logs.png|frameless|Enable data logging in the GCS.]]
 
 
'''Step 4:'''
 
First, make sure that your Parrot Bebop is on, and connected. Now the logged .csv files can be retrieved from the Bebop. This is done by opening a browser, and typing <tt> ftp://196.168.42.1/ </tt> in the navigation line. This will take you to the ftp folder on the Bebop. Browse to <tt> /Internal000/ </tt>. Here we can find the <tt>.csv </tt>files, named 00000.csv to <tt> 0000X.csv </tt> depending on the flights you logged. Copy the files to your computer for analysis.
 
  
 
[[Category:Hardware]] [[Category:Software]] [[Category:User_Documentation]]
 
[[Category:Hardware]] [[Category:Software]] [[Category:User_Documentation]]

Revision as of 10:35, 23 August 2016

Introduction

This page describes various onboard external devices called a "Data logger", that can be connected to the Paparazzi autopilot.

Such a Data Logger device can be used to store telemetry data to a storage medium on board the aircraft. Such a storage medium can be an SD card or a Flash chip. For now logging is not done directly by the autopilot itself as the usage of a file system as well as possible lag you might get with a SD storage speed does not fit well with the real-time nature of Autopilots.

Note that not all loggers accept SD HighCapacity(SDHC) cards as storage

Why Onboard

One would naturally first ask; why on on-board logger when we have data over the air?

The answer to this is multi-fold; Sometimes it is not possible to log everything over the air because of speed, lag and datavolume limitations of data send wireless over the air. Or one needs to log when there is no telemetry at all in long distance flight. Or one want to log all the RAW IMU data to debug specific scenarios.

To solve this issue, there are various loggers that can be connected to your Paparazzi Autopilot board.

Available Data logger options

There are numerous logging solutions, both with their pro's and con's; here the options:

* TWOGA-Logga

* An dedicated TWOG board for logging

* Openlog

* SD Logger SPI Direct

* Micro Logger

* File Logger (Bebop)

Storage format

A more unified method of storing data on the logger, info available here