Direction Cosine Matrix#
Unit DCM matrix related routines.
Functions#
void
sl_imu_dcm_reset(float dcm[3][3])
Set the elements of the DCM matrix to the corresponding elements of the identity matrix.
void
sl_imu_dcm_reset_z(float dcm[3][3])
DCM reset, Z direction.
void
sl_imu_dcm_normalize(float dcm[3][3])
Normalize the DCM matrix.
void
sl_imu_dcm_rotate(float dcm[3][3], float ang[3])
Rotate the DCM matrix by a given angle.
void
sl_imu_dcm_get_angles(float dcm[3][3], float ang[3])
Calculate the Euler angles (roll, pitch, yaw) from the DCM matrix.
Function Documentation#
sl_imu_dcm_reset#
void sl_imu_dcm_reset (float dcm)
Set the elements of the DCM matrix to the corresponding elements of the identity matrix.
Parameters
N/A | dcm | DCM matrix |
Definition at line
373
of file hardware/driver/imu/inc/sl_imu.h
sl_imu_dcm_reset_z#
void sl_imu_dcm_reset_z (float dcm)
DCM reset, Z direction.
Parameters
N/A | dcm | DCM matrix |
Definition at line
382
of file hardware/driver/imu/inc/sl_imu.h
sl_imu_dcm_normalize#
void sl_imu_dcm_normalize (float dcm)
Normalize the DCM matrix.
Parameters
N/A | dcm | DCM matrix |
Definition at line
391
of file hardware/driver/imu/inc/sl_imu.h
sl_imu_dcm_rotate#
void sl_imu_dcm_rotate (float dcm, float ang)
Rotate the DCM matrix by a given angle.
Parameters
[inout] | dcm | DCM matrix |
[in] | ang | Rotation angle |
Definition at line
403
of file hardware/driver/imu/inc/sl_imu.h
sl_imu_dcm_get_angles#
void sl_imu_dcm_get_angles (float dcm, float ang)
Calculate the Euler angles (roll, pitch, yaw) from the DCM matrix.
Parameters
[in] | dcm | DCM matrix |
[out] | ang | An array containing the Euler angles |
Definition at line
415
of file hardware/driver/imu/inc/sl_imu.h