|
VOXL OpenVINS Server 1.0
Visual Inertial Odometry Server for VOXL Platform
|
IMU interface and data handling for VOXL OpenVINS. More...
#include <mutex>#include <functional>#include <optional>#include <array>#include <modal_pipe.h>#include "VoxlVars.h"#include "VoxlCommon.h"#include "CameraQueueFusion.h"#include "VoxlHK.h"

Go to the source code of this file.
Functions | |
| void | _imu_disconnect_cb (__attribute__((unused)) int ch, __attribute__((unused)) void *context) |
| Callback for IMU disconnect events. | |
| void | _imu_data_handler_cb (__attribute__((unused)) int ch, char *data, int bytes, __attribute__((unused)) void *context) |
| Handler for incoming IMU data. | |
| int | connect_imu_service (void) |
| Creates IMU pipe client and associated callbacks. | |
Variables | |
| std::mutex | imu_lock_mutex |
| Mutex for IMU data access synchronization. | |
IMU interface and data handling for VOXL OpenVINS.
This header defines the IMU interface and callback functions for handling inertial measurement unit data in the VOXL OpenVINS system. It provides the connection to the IMU service and data processing capabilities.
Definition in file ImuMinimal.h.
| void _imu_data_handler_cb | ( | __attribute__((unused)) int | ch, |
| char * | data, | ||
| int | bytes, | ||
| __attribute__((unused)) void * | context | ||
| ) |
Handler for incoming IMU data.
This callback processes incoming IMU data, updates the system state, and triggers appropriate processing based on motion state. It serves as the primary entry point for all IMU data processing in the system.
The function:
| ch | Channel number (unused) |
| data | Pointer to IMU data buffer |
| bytes | Size of data buffer in bytes |
| context | Context pointer (unused) |
| void _imu_disconnect_cb | ( | __attribute__((unused)) int | ch, |
| __attribute__((unused)) void * | context | ||
| ) |
Callback for IMU disconnect events.
This function is called when the IMU service disconnects. It handles the cleanup and state management required when IMU data becomes unavailable.
| ch | Channel number (unused) |
| context | Context pointer (unused) |
This function is called when the IMU service disconnects. It handles the cleanup and state management required when IMU data becomes unavailable.
The function uses thread-safe mutex locking to ensure proper state management during disconnection events.
| ch | Channel number (unused) |
| context | Context pointer (unused) |
Definition at line 283 of file ImuMinimal.cpp.
References IMU_CH, imu_lock_mutex, and is_imu_connected.
Referenced by connect_imu_service().

| int connect_imu_service | ( | void | ) |
Creates IMU pipe client and associated callbacks.
This function sets up the disconnect and data handler callbacks, and opens the client pipe connection to the IMU service. It initializes the complete IMU data pipeline for the VIO system.
The function performs the following operations:
This function sets up the disconnect and data handler callbacks, and opens the client pipe connection to the IMU service. It initializes the complete IMU data pipeline for the VIO system.
The function performs the following operations:
Definition at line 315 of file ImuMinimal.cpp.
References _imu_data_handler_cb(), _imu_disconnect_cb(), IMU_CH, imu_name, is_imu_connected, PROCESS_NAME, and vio_error_codes.

|
extern |
Mutex for IMU data access synchronization.
Mutex used to synchronize access to IMU data between multiple threads.
Definition at line 80 of file ImuMinimal.cpp.
Referenced by _imu_disconnect_cb().