C MIP-SDK
|
#include "mip_sdk_nav.h"
#include "mip_sdk_system.h"
#include "mip_sdk_user_functions.h"
#include "byteswap_utilities.h"
void mip_nav_accel_bias_byteswap | ( | mip_nav_accel_bias * | accel_bias | ) |
void mip_nav_accel_bias_uncertainty_byteswap | ( | mip_nav_accel_bias_uncertainty * | accel_bias_uncertainty | ) |
u16 mip_nav_accel_white_noise | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | noise_1sigma[3] | ||
) |
Set or read the filter's accelerometer white noise values.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | noise_1sigma[3] - The accelerometer 1-sigma white noise values in m/(s^2). (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The accelerometer 1-sigma white noise values are ordered [x, y, z] in the
sensor frame in m/(s^2). These values are used as process noise and allow the user to tune
the behavior of the Kalman filter for their particular application.
void mip_nav_acceleration_byteswap | ( | mip_nav_acceleration * | acceleration | ) |
void mip_nav_angular_rate_byteswap | ( | mip_nav_angular_rate * | angular_rate | ) |
u16 mip_nav_antenna_offset | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | offset[3] | ||
) |
Set or read the filter's antenna offset settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | offset - The offset of the antenna with-respect-to the sensor in meters. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The offset is [x, y, z] in meters from the sensor to the antenna, expressed in the sensor frame.
void mip_nav_attitude_dcm_byteswap | ( | mip_nav_attitude_dcm * | attitude_dcm | ) |
void mip_nav_attitude_euler_angles_byteswap | ( | mip_nav_attitude_euler_angles * | attitude_euler_angles | ) |
void mip_nav_attitude_quaternion_byteswap | ( | mip_nav_attitude_quaternion * | attitude_quaternion | ) |
u16 mip_nav_auto_initialization | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
u8 * | enable | ||
) |
Set or read the filter's auto-initialization setting.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | u8 | *enable - The auto-initialization setting. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
Please consult the device DCP for valid auto-initialization values.
u16 mip_nav_bias_estimation | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
u16 * | bias_control | ||
) |
Set or read the filter's bias estimation control settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | u16 | *bias_control - The bais control value. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
Please consult the device DCP for valid bias control values
void mip_nav_euler_attitude_uncertainty_byteswap | ( | mip_nav_euler_attitude_uncertainty * | euler_attitude_uncertainty | ) |
u16 mip_nav_external_gps_update | ( | mip_interface * | device_interface, |
mip_nav_external_gps_update_command * | command | ||
) |
Provide an external GPS update to the filter.
[in] | mip_interface | *device_interface - The device interface. |
[in] | mip_nav_external_gps_update_command | *command - The external GPS update command. |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
The device will only accept this command when external GPS is selected
as the GPS source. Please consult the device DCP for how to configure this setting.
u16 mip_nav_external_heading_update | ( | mip_interface * | device_interface, |
mip_nav_external_heading_update_command * | command | ||
) |
Provide an external heading update to the filter.
[in] | mip_interface | *device_interface - The device interface. |
[in] | mip_nav_external_heading_update_command | *command - The external heading update command. |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
The device will only accept this command when external heading is selected
as the heading update source. Please consult the device DCP for how to configure this setting.
u16 mip_nav_gps_source | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
u8 * | gps_source | ||
) |
Set or read the filter's GPS source settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | u8 | *gps_source - The source of GPS updates to the filter. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
Please consult the device DCP for valid GPS source values.
void mip_nav_gravity_vector_byteswap | ( | mip_nav_gravity_vector * | gravity_vector | ) |
void mip_nav_gyro_bias_byteswap | ( | mip_nav_gyro_bias * | gyro_bias | ) |
u16 mip_nav_gyro_bias_model | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | bias_beta[3], | ||
float | bias_noise_1sigma[3] | ||
) |
Set or read the filter's gyroscope Guass-Markov bias model values.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | bias_beta[3] - The gyroscope bias model time constants in 1/sec. (used to set or get depending on function_selector ) |
[in,out] | float | bias_noise_1sigma[3] - The gyroscope bias model 1-sigma white noise values in rad/sec. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The gyroscope Gauss-Markov bias model time constant values are ordered [x, y, z] in the
sensor frame in units of 1/sec. The gyro Gauss-Markov bias model 1-sigma white noise values are ordered [x, y, z] in the
sensor frame in units of rad/sec. These values are used as process noise to the gyro bias model and allow the user to tune
the behavior of the Kalman filter for their particular application.
void mip_nav_gyro_bias_uncertainty_byteswap | ( | mip_nav_gyro_bias_uncertainty * | gyro_bias_uncertainty | ) |
u16 mip_nav_gyro_white_noise | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | noise_1sigma[3] | ||
) |
Set or read the filter's gyroscope white noise values.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | noise_1sigma[3] - The gyroscope 1-sigma white noise values in rad/sec. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The gyroscope 1-sigma white noise values are ordered [x, y, z] in the
sensor frame in rad/sec. These values are used as process noise and allow the user to tune
the behavior of the Kalman filter for their particular application.
u16 mip_nav_heading_source | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
u8 * | heading_source | ||
) |
Set or read the filter's heading update source settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | u8 | *heading_source - The source of heading updates to the filter. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
Please consult the device DCP for valid heading update source values.
void mip_nav_heading_update_state_byteswap | ( | mip_nav_heading_update_state * | heading_update_state | ) |
void mip_nav_llh_pos_byteswap | ( | mip_nav_llh_pos * | llh_pos | ) |
void mip_nav_llh_pos_uncertainty_byteswap | ( | mip_nav_llh_pos_uncertainty * | llh_pos_uncertainty | ) |
void mip_nav_magnetic_model_byteswap | ( | mip_nav_magnetic_model * | magnetic_model | ) |
void mip_nav_ned_vel_uncertainty_byteswap | ( | mip_nav_ned_vel_uncertainty * | ned_vel_uncertainty | ) |
void mip_nav_ned_velocity_byteswap | ( | mip_nav_ned_velocity * | ned_velocity | ) |
void mip_nav_quaternion_attitude_uncertainty_byteswap | ( | mip_nav_quaternion_attitude_uncertainty * | quaternion_attitude_uncertainty | ) |
u16 mip_nav_reset_filter | ( | mip_interface * | device_interface | ) |
u16 mip_nav_sensor2vehicle_offset | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | offset[3] | ||
) |
Set or read the filter's sensor to vehicle frame offset settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | offset - The sensor to vehicle frame offset in meters. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The offset is [x, y, z] in meters from the sensor frame to the vehicle frame, expressed in the sensor frame.
u16 mip_nav_sensor2vehicle_tranformation | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
float | euler_angles[3] | ||
) |
Set or read the filter's sensor to vehicle transformation settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | float | euler_angles[3] - The sensor to vehicle transformation expressed as Euler angles in radians. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
The angles are [roll, pitch, yaw] in radians from the sensor frame to the vehicle frame.
u16 mip_nav_set_init_attitude | ( | mip_interface * | device_interface, |
float | euler_angles[3] | ||
) |
Initialize the Kalman Filter with the provided Euler angles.
[in] | mip_interface | *device_interface - The device interface. |
[in] | float | euler_angles[3] - The Euler angles in radians. |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Order of angles is [roll, pitch, yaw] in radians.
u16 mip_nav_set_init_attitude_from_ahrs | ( | mip_interface * | device_interface, |
float | declination | ||
) |
Initialize the Kalman Filter from the AHRS algorithm output, taking into account the magnetic declination angle povided.
[in] | mip_interface | *device_interface - The device interface. |
[in] | float | declination - The local magnetic declination angle in radians. |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
The output of the internal AHRS orientation algorithm will be used to initialize
the filter, taking into account the user-provided magnetic declination angle.
u16 mip_nav_set_init_heading | ( | mip_interface * | device_interface, |
float | heading | ||
) |
Initialize the Kalman Filter with the provided true heading angle.
[in] | mip_interface | *device_interface - The device interface. |
[in] | float | heading - The true heading angle in radians. |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Roll and Pitch will be calculated by the device using the accelerometers.
void mip_nav_status_byteswap | ( | mip_nav_status * | status | ) |
void mip_nav_timestamp_byteswap | ( | mip_nav_timestamp * | timestamp | ) |
u16 mip_nav_vehicle_dynamics_mode | ( | mip_interface * | device_interface, |
u8 | function_selector, | ||
u8 * | dynamics_mode | ||
) |
Set or read the filter's vehicle dynamics mode settings.
[in] | mip_interface | *device_interface - The device interface. |
[in] | u8 | function_selector - Selects which function to perform. |
[in,out] | u8 | *dynamics_mode - The vehicle dynamics mode. (used to set or get depending on function_selector ) |
MIP_INTERFACE_ERROR | When there is a problem with the command format or the the device communications failed. |
MIP_INTERFACE_OK | The command was successful. |
Possible function_selector
values:
settings
may be NULL for the following function_selector
values:
Please reference the device DCP for valid dynamics_mode
values.
void mip_nav_wgs84_gravity_mag_byteswap | ( | mip_nav_wgs84_gravity_mag * | wgs84_gravity_mag | ) |