PX4 Firmware
PX4 Autopilot Software http://px4.io
|
Vector rotation library. More...
Go to the source code of this file.
Functions | |
__EXPORT matrix::Dcmf | get_rot_matrix (enum Rotation rot) |
Get the rotation matrix. More... | |
__EXPORT matrix::Quatf | get_rot_quaternion (enum Rotation rot) |
Get the rotation quaternion. More... | |
__EXPORT void | rotate_3f (enum Rotation rot, float &x, float &y, float &z) |
rotate a 3 element float vector in-place More... | |
Vector rotation library.
Definition in file rotation.cpp.
__EXPORT matrix::Dcmf get_rot_matrix | ( | enum Rotation | rot | ) |
Get the rotation matrix.
Definition at line 45 of file rotation.cpp.
References math::radians(), and rot_lookup.
Referenced by DfAK8963Wrapper::DfAK8963Wrapper(), DfHmc5883Wrapper::DfHmc5883Wrapper(), DfLsm9ds1Wrapper::DfLsm9ds1Wrapper(), DfMPU6050Wrapper::DfMPU6050Wrapper(), do_accel_calibration(), VehicleAcceleration::ParametersUpdate(), VehicleAngularVelocity::ParametersUpdate(), sensors::VotedSensorsUpdate::parametersUpdate(), and read_accelerometer_avg().
__EXPORT matrix::Quatf get_rot_quaternion | ( | enum Rotation | rot | ) |
Get the rotation quaternion.
Definition at line 54 of file rotation.cpp.
References math::radians(), and rot_lookup.
Referenced by MavlinkStreamAttitudeQuaternion::send().
rotate a 3 element float vector in-place
Definition at line 63 of file rotation.cpp.
References ROTATION_MAX, ROTATION_NONE, ROTATION_PITCH_180, ROTATION_PITCH_270, ROTATION_PITCH_315, ROTATION_PITCH_45, ROTATION_PITCH_90, ROTATION_PITCH_90_ROLL_270, ROTATION_PITCH_90_ROLL_90, ROTATION_PITCH_90_YAW_180, ROTATION_PITCH_9_YAW_180, ROTATION_ROLL_180, ROTATION_ROLL_180_PITCH_270, ROTATION_ROLL_180_YAW_135, ROTATION_ROLL_180_YAW_225, ROTATION_ROLL_180_YAW_270, ROTATION_ROLL_180_YAW_315, ROTATION_ROLL_180_YAW_45, ROTATION_ROLL_180_YAW_90, ROTATION_ROLL_270, ROTATION_ROLL_270_YAW_135, ROTATION_ROLL_270_YAW_270, ROTATION_ROLL_270_YAW_45, ROTATION_ROLL_270_YAW_90, ROTATION_ROLL_90, ROTATION_ROLL_90_YAW_135, ROTATION_ROLL_90_YAW_270, ROTATION_ROLL_90_YAW_45, ROTATION_ROLL_90_YAW_90, ROTATION_YAW_135, ROTATION_YAW_180, ROTATION_YAW_225, ROTATION_YAW_270, ROTATION_YAW_293_PITCH_68_ROLL_90, ROTATION_YAW_315, ROTATION_YAW_45, and ROTATION_YAW_90.
Referenced by DfMpu9250Wrapper::_publish(), PX4FLOW::collect(), LSM303AGR::collect(), RM3100::collect(), LIS3MDL::collect(), QMC5883::collect(), HMC5883::collect(), BMM150::collect(), IST8310::collect(), MavlinkReceiver::handle_message_optical_flow_rad(), Simulator::publish_flow_topic(), PAW3902::Run(), PMW3901::Run(), PX4Magnetometer::update(), PX4Accelerometer::update(), and PX4Gyroscope::update().