Robotics StackExchange | Archived questions

How to change NED to ENU?

Hi everyone,

I have got a NED imu I am trying to use with r_l (which follows ros standards enu). I was wondering what it would look like to convert this IMU data to ENU? I know its a pi roll and a pi/2 yaw but what does this look like in code? Here is my attempt.

//Orientation
new_imu_roll = old_roll;
new_imu_pitch = -old_pitch;
new_imu_yaw = pi/2 - old_yaw;

//accel
new_imu.linear_acceleration.x = x;
new_imu.linear_acceleration.y = -y;
new_imu.linear_acceleration.z = -z;

//ang_vel
new_imu.angular_velocity.x = x;
new_imu.angular_velocity.y = -y;
new_imu.angular_velocity.z = -z;

Asked by PapaG on 2019-11-04 21:03:43 UTC

Comments

Do people just not know this?

Asked by PapaG on 2019-11-06 00:28:03 UTC

Answers

You will need to swap x and y and negate z for orientation, linear_acceleration and angular_velocity. You can find several answers and visualizations here for NED->ENU conversions.
Also, the following package contains code example for ENU/NED extraction.

Asked by pavel92 on 2019-11-06 06:54:35 UTC

Comments