45 #ifndef FILE_LOGGER_PATH
46 #define FILE_LOGGER_PATH /data/video/usb
68 tstruct = *localtime(&now);
69 strftime(date_time,
sizeof(date_time),
"%Y-%m-%d_%X", &tstruct);
79 sprintf(filename,
"%s/%s_%05d.csv", STRINGIFY(
FILE_LOGGER_PATH), date_time, counter);
91 "counter,gyro_unscaled_p,gyro_unscaled_q,gyro_unscaled_r,accel_unscaled_x,accel_unscaled_y,accel_unscaled_z,mag_unscaled_x,mag_unscaled_y,mag_unscaled_z,COMMAND_THRUST,COMMAND_ROLL,COMMAND_PITCH,COMMAND_YAW,qi,qx,qy,qz\n"
93 "counter,gyro_unscaled_p,gyro_unscaled_q,gyro_unscaled_r,accel_unscaled_x,accel_unscaled_y,accel_unscaled_z,mag_unscaled_x,mag_unscaled_y,mag_unscaled_z, h_ctl_aileron_setpoint, h_ctl_elevator_setpoint, qi,qx,qy,qz\n"
118 #ifdef COMMAND_THRUST //For example rotorcraft
119 fprintf(
file_logger,
"%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d\n",
140 fprintf(
file_logger,
"%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d\n",
pprz_t h_ctl_elevator_setpoint
pprz_t h_ctl_aileron_setpoint
struct Imu imu
global IMU state
static struct Int32Quat * stateGetNedToBodyQuat_i(void)
Get vehicle body attitude quaternion (int).
void file_logger_periodic(void)
Log the values to a csv file.
Fixed wing horizontal control.
struct Int32Vect3 mag_unscaled
unscaled magnetometer measurements
int32_t r
in rad/s with INT32_RATE_FRAC
struct Int32Rates gyro_unscaled
unscaled gyroscope measurements
void file_logger_stop(void)
Stop the logger an nicely close the file.
Inertial Measurement Unit interface.
API to get/set the generic vehicle states.
File logger for Linux based autopilots.
General stabilization interface for rotorcrafts.
int32_t stabilization_cmd[COMMANDS_NB]
Stabilization commands.
#define FILE_LOGGER_PATH
Set the default File logger path to the USB drive.
int32_t p
in rad/s with INT32_RATE_FRAC
struct Int32Vect3 accel_unscaled
unscaled accelerometer measurements
static FILE * file_logger
The file pointer.
int32_t q
in rad/s with INT32_RATE_FRAC
void file_logger_start(void)
Start the file logger and open a new file.
Fixed wing horizontal adaptive control.