Go to the source code of this file.
Macros | |
#define | DATALOGGER_MODULE_ENABLED 1 |
#define | DATALOGGER_DEBUG_MODE 0 |
#define | DATALOGGER_ENABLE_NEW_FILE_ENNUMERATION 0 |
#define | DATALOGGER_FILE_NAME "rleg" |
#define | DATALOGGER_FOLDER "matlabdatafiles" |
#define | DATALOGGER_STANDARD_QUEUE_SIZE 750 |
#define | DATALOGGER_LOG_TIME 1 |
#define | DATALOGGER_LOG_EXECTIMES 1 |
#define | DATALOGGER_LOG_RAW_IMU 1 |
#define | DATALOGGER_LOG_EFFORTS 1 |
#define | DATALOGGER_LOG_MRA 1 |
#define | DATALOGGER_LOG_CALIBRATED_IMU 1 |
#define | DATALOGGER_NOT_INITIALIZED 0 |
#define | DATALOGGER_INITIALIZED 1 |
#define | DATALOGGER_NOT_RUNNING 0 |
#define | DATALOGGER_RUNNING 1 |
#define | DATALOGGER_VARIABLE_NOT_INSERTED 0 |
#define | DATALOGGER_VARIABLE_INSERTED 1 |
#define | DATALOGGER_SUCCESS 1 |
#define | DATALOGGER_FAILURE -1 |
#define | DATALOGGER_ERROR_NOT_INITIALIZED -2 |
#define | DATALOGGER_VARIBALE_ALREADY_INSERTED -3 |
Functions | |
int | datalogger_init (void) |
int | datalogger_close (void) |
int | datalogger_write_file (void) |
int | datalogger_update_IPC (void) |
int | datalogger_update (double t_s, double t_control_exec_s, double t_ui_exec_s, double t0_s, IMU_DATA_STRUCT *pimu_data, EFF_DATA_STRUCT *peff_data, MRA_DATA_STRUCT *pmra_data) |
int | datalogger_set_Ts (double Ts) |
int | datalogger_status (void) |
int | datalogger_start (void) |
int | datalogger_stop (void) |
int | datalogger_file_exists (const char *filename) |
#define DATALOGGER_DEBUG_MODE 0 |
Definition at line 6 of file datalogger.h.
#define DATALOGGER_ENABLE_NEW_FILE_ENNUMERATION 0 |
Definition at line 9 of file datalogger.h.
#define DATALOGGER_ERROR_NOT_INITIALIZED -2 |
Definition at line 37 of file datalogger.h.
Referenced by datalogger_close(), datalogger_set_Ts(), datalogger_start(), datalogger_status(), datalogger_stop(), datalogger_update(), datalogger_update_IPC(), and datalogger_write_file().
#define DATALOGGER_FAILURE -1 |
Definition at line 36 of file datalogger.h.
Referenced by datalogger_file_exists(), and datalogger_init().
#define DATALOGGER_FILE_NAME "rleg" |
Definition at line 10 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_FOLDER "matlabdatafiles" |
Definition at line 11 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_INITIALIZED 1 |
Definition at line 28 of file datalogger.h.
Referenced by datalogger_close(), datalogger_init(), datalogger_set_Ts(), datalogger_start(), datalogger_status(), datalogger_stop(), datalogger_update(), datalogger_update_IPC(), and datalogger_write_file().
#define DATALOGGER_LOG_CALIBRATED_IMU 1 |
Definition at line 22 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_LOG_EFFORTS 1 |
Definition at line 18 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_LOG_EXECTIMES 1 |
Definition at line 16 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_LOG_MRA 1 |
Definition at line 19 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_LOG_RAW_IMU 1 |
Definition at line 17 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_LOG_TIME 1 |
Definition at line 15 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_MODULE_ENABLED 1 |
Definition at line 5 of file datalogger.h.
#define DATALOGGER_NOT_INITIALIZED 0 |
Definition at line 27 of file datalogger.h.
Referenced by datalogger_close().
#define DATALOGGER_NOT_RUNNING 0 |
Definition at line 29 of file datalogger.h.
Referenced by control_task(), datalogger_init(), datalogger_stop(), periodic_task_1(), threads_linux_periodic_task_1(), and ui_overview_data().
#define DATALOGGER_RUNNING 1 |
Definition at line 30 of file datalogger.h.
Referenced by control_task(), datalogger_start(), main(), periodic_task_1(), threads_linux_init(), threads_linux_periodic_task_1(), and ui_update().
#define DATALOGGER_STANDARD_QUEUE_SIZE 750 |
Definition at line 12 of file datalogger.h.
Referenced by datalogger_init().
#define DATALOGGER_SUCCESS 1 |
Definition at line 35 of file datalogger.h.
Referenced by datalogger_close(), datalogger_file_exists(), datalogger_init(), datalogger_lock_mutex(), datalogger_set_Ts(), datalogger_start(), datalogger_stop(), datalogger_unlock_mutex(), datalogger_update(), datalogger_update_IPC(), datalogger_write_file(), main(), and threads_linux_init().
#define DATALOGGER_VARIABLE_INSERTED 1 |
Definition at line 32 of file datalogger.h.
Referenced by datalogger_set_Ts().
#define DATALOGGER_VARIABLE_NOT_INSERTED 0 |
Definition at line 31 of file datalogger.h.
Referenced by datalogger_set_Ts().
#define DATALOGGER_VARIBALE_ALREADY_INSERTED -3 |
Definition at line 38 of file datalogger.h.
Referenced by datalogger_set_Ts().
int datalogger_close | ( | void | ) |
Definition at line 215 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), datalogger_mutex, DATALOGGER_NOT_INITIALIZED, DATALOGGER_SUCCESS, datalogger_unlock_mutex(), gDataLogger_Close(), and gDataLogger_MatfileUpdate().
Referenced by main(), and threads_linux_init().
int datalogger_file_exists | ( | const char * | filename | ) |
Definition at line 618 of file datalogger.c.
References DATALOGGER_FAILURE, and DATALOGGER_SUCCESS.
Referenced by datalogger_init().
int datalogger_init | ( | void | ) |
Definition at line 41 of file datalogger.c.
References DATALOGGER_FAILURE, datalogger_file_exists(), DATALOGGER_FILE_NAME, DATALOGGER_FOLDER, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_LOG_CALIBRATED_IMU, DATALOGGER_LOG_EFFORTS, DATALOGGER_LOG_EXECTIMES, DATALOGGER_LOG_MRA, DATALOGGER_LOG_RAW_IMU, DATALOGGER_LOG_TIME, datalogger_mutex, DATALOGGER_NOT_RUNNING, datalogger_running, DATALOGGER_STANDARD_QUEUE_SIZE, DATALOGGER_SUCCESS, datalogger_unlock_mutex(), gDataLogger_DeclareVariable(), gDataLogger_Init(), and gDataLogger_InsertVariable().
Referenced by main(), and threads_linux_init().
int datalogger_set_Ts | ( | double | Ts | ) |
Definition at line 540 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_SUCCESS, datalogger_unlock_mutex(), DATALOGGER_VARIABLE_INSERTED, DATALOGGER_VARIABLE_NOT_INSERTED, DATALOGGER_VARIBALE_ALREADY_INSERTED, and gDataLogger_InsertVariable().
Referenced by control_task(), periodic_task_1(), and threads_linux_periodic_task_1().
int datalogger_start | ( | void | ) |
Definition at line 584 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), datalogger_running, DATALOGGER_RUNNING, DATALOGGER_SUCCESS, and datalogger_unlock_mutex().
Referenced by ui_update().
int datalogger_status | ( | void | ) |
Definition at line 571 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), datalogger_running, and datalogger_unlock_mutex().
Referenced by control_task(), main(), periodic_task_1(), threads_linux_init(), threads_linux_periodic_task_1(), ui_overview_data(), and ui_update().
int datalogger_stop | ( | void | ) |
Definition at line 601 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_NOT_RUNNING, datalogger_running, DATALOGGER_SUCCESS, and datalogger_unlock_mutex().
Referenced by main(), and ui_update().
int datalogger_update | ( | double | t_s, |
double | t_control_exec_s, | ||
double | t_ui_exec_s, | ||
double | t0_s, | ||
IMU_DATA_STRUCT * | pimu_data, | ||
EFF_DATA_STRUCT * | peff_data, | ||
MRA_DATA_STRUCT * | pmra_data | ||
) |
Definition at line 272 of file datalogger.c.
References IMU_DATA_STRUCT::acc, IMU_DATA_STRUCT::calibrated::acc, IMU_DATA_STRUCT::calib, DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_SUCCESS, datalogger_unlock_mutex(), EFF_DATA_STRUCT::F, gDataLogger_InsertVariable(), IMU_DATA_STRUCT::gyr, IMU_DATA_STRUCT::calibrated::gyr, IMU_DATA_STRUCT::mag, IMU_DATA_STRUCT::calibrated::mag, IMU_DATA_STRUCT::new_data, EFF_DATA_STRUCT::new_data, MRA_DATA_STRUCT::v_ctl, MRA_DATA_STRUCT::v_ctl_read, DATA_XYZ::x, DATA_XYZ_DOUBLE::x, DATA_XYZ::y, DATA_XYZ_DOUBLE::y, DATA_XYZ::z, and DATA_XYZ_DOUBLE::z.
Referenced by control_task(), periodic_task_1(), and threads_linux_periodic_task_1().
int datalogger_update_IPC | ( | void | ) |
Definition at line 256 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_SUCCESS, datalogger_unlock_mutex(), and gDataLogger_IPCUpdate().
Referenced by threads_linux_init().
int datalogger_write_file | ( | void | ) |
Definition at line 240 of file datalogger.c.
References DATALOGGER_ERROR_NOT_INITIALIZED, DATALOGGER_INITIALIZED, datalogger_initialized, datalogger_lock_mutex(), DATALOGGER_SUCCESS, datalogger_unlock_mutex(), and gDataLogger_MatfileUpdate().
Referenced by main(), and threads_linux_init().