Difference between revisions of "Openlog"

From PaparazziUAV
Jump to navigation Jump to search
Line 30: Line 30:
}}
}}
Then compile, flash your AP and do your flight. Afterwards take the SD-Card from the logger and import the logs:
Then compile, flash your AP and do your flight. Afterwards take the SD-Card from the logger and import the logs:
christoph@christoph:~/paparazzi/aktueller$ sw/logalizer/getopenlog LOG00003.TXT
now converting LOG00003.TXT to LOG00003.TXT.tlm
The conversion from the logfile from the SD to TLM seems to be successful, 567 have been converted, 2 packages have been broken
Renaming produced file ...
12_06_17__01_59_45_SD.data file produced
Looking for 4ae62580cb19d37d2b30aa8d31cc20dc conf...
12_06_17__01_59_45_SD.log file produced
12_06_17__01_59_45_SD.tlm file saved
You can also do batch processing like:
christoph@christoph:~/paparazzi/aktueller$ sw/logalizer/getopenlog /media/disk-1/LOG*
In this case all logs will be imported.
Afterwards you can find the logs as usual in var/logs/*_SD.log
If someting goes wrong during the import have a close look to the error messages, since openlog2tlm tries to identify the most common problems.




[[Category:Software]] [[Category:User_Documentation]]
[[Category:Software]] [[Category:User_Documentation]]

Revision as of 05:16, 24 June 2012

Openlog

In general OpenLog is a Module from Sparkfun that contains an Atmega324 and a Micro-SD-Slot. It can handle FAT-formated files-systems up to 2GB. Once installed into the wiring (parallel to the dataradio) it records every message the UAS sends. That is very handy for using it as some kind of blackbox or for data-logging purposes if no Modem was involved. It is also nice for reconstructing what happened after a crash, since the radio-communication is gone, once the plane is near the ground. 2GB is enough to log a comlete season (several hundred flights). The general logging is done in two steps: First you record your log using the telemtry in transparent mode, with the openlog-module loaded. the normal paparazzi-protocal does not contain timestamps and the openlog-module adds timestamps to the datastream to have a reference for the time. Second the recorded logs are extracted from the SD-Card to the normal logfiles. For doing so, there is a tool calles openlog2tlm to convert the recorded files to the TLM-format of the SD-logger. Next the created TLM-file is added to the logs by sd2log. There is a helper-script that does this job.

Hardware

Openlog.jpg

The OpenLog is simply connected to the TX-Line of the AP. Once the AP is powered, it starts to record.

Software

First of all the OpenLog needs to be configured. If it was powered one time without being configured, but with SD-Card plugged, it creates a file named CONFIG.txt or CONFIG.TXT (depends on the version of the firmware). You need to configure the Baudrate, it defaults to 9600-8-N1. In case you use 57600 Baud it should look like:

File: CONFIG.TXT
57600,26,3,0

Furthermore you need to add the OpenLog-module to your airframe.

File: conf/airframes/yourairframe.xml
[...]
  <modules>
    <load name="openlog.xml"/>
     [...]
  </modules>
[...]

Then compile, flash your AP and do your flight. Afterwards take the SD-Card from the logger and import the logs:

christoph@christoph:~/paparazzi/aktueller$ sw/logalizer/getopenlog LOG00003.TXT 
now converting LOG00003.TXT to LOG00003.TXT.tlm
The conversion from the logfile from the SD to TLM seems to be successful, 567 have been converted, 2 packages have been broken
Renaming produced file ...
12_06_17__01_59_45_SD.data file produced
Looking for 4ae62580cb19d37d2b30aa8d31cc20dc conf...
12_06_17__01_59_45_SD.log file produced
12_06_17__01_59_45_SD.tlm file saved

You can also do batch processing like:

christoph@christoph:~/paparazzi/aktueller$ sw/logalizer/getopenlog /media/disk-1/LOG*

In this case all logs will be imported. Afterwards you can find the logs as usual in var/logs/*_SD.log

If someting goes wrong during the import have a close look to the error messages, since openlog2tlm tries to identify the most common problems.