Logs to a csv file.
(only for linux)
Example for airframe file
Add to your firmware section: This example contains all possible configuration options, not all of them are mandatory!
<module name="logger_file">
b'<define name="LOGGER_FILE_PATH" value="/data/video/usb" />\n '
b'<configure name="LOGGER_FILE_FREQUENCY" value="PERIODIC_FREQUENCY" />\n '
</module>
Module configuration options
Configure Options
- name:
LOGGER_FILE_FREQUENCY
value: PERIODIC_FREQUENCY
Description: frequency of logging, defaults to PERIODIC_FREQUENCY.
Define Options
- name:
LOGGER_FILE_PATH
value: /data/video/usb
Description: path where csv file is saved.
Module functions
Periodic Functions
These functions are called periodically at the specified frequency from the module periodic loop.
Files
Header Files
The following headers are automatically included in modules.h
Source Files
Raw logger_file.xml file:
<!DOCTYPE module SYSTEM "module.dtd">
<module name="logger_file" dir="loggers" task="core">
<doc>
<description>
Logs to a csv file.
(only for linux)
</description>
<define name="LOGGER_FILE_PATH" value="/data/video/usb" description="path where csv file is saved."/>
<configure name="LOGGER_FILE_FREQUENCY" value="PERIODIC_FREQUENCY" description="frequency of logging, defaults to PERIODIC_FREQUENCY."/>
</doc>
<header>
<file name="logger_file.h"/>
</header>
<periodic fun="logger_file_periodic()" start="logger_file_start()"
stop="logger_file_stop()" autorun="FALSE" freq="LOGGER_FILE_FREQUENCY" />
<makefile>
<file name="logger_file.c"/>
<configure name="LOGGER_FILE_FREQUENCY" default="PERIODIC_FREQUENCY"/>
<define name="LOGGER_FILE_FREQUENCY" value="$(LOGGER_FILE_FREQUENCY)"/>
</makefile>
</module>