PDA

View Full Version : Question IMU help


marcorasta
Jul 06, 2009, 10:53 AM
hello everybody,
this is my first post. I'm sorry to bother you all, but i'm definitely getting crazy with the imu i'm working to. I don't want to build an uav or agv (at least, not now), but my issue is quite related to the topic. the imu is a crossbow imu700ca-200. It should be quite good, but i can't get a good trajectory out of it (no gps at the moment, loose, tight and deep integration will follow).

I store data in a file, then i open them in matlab to run the alignment algorithm. it works quite well, implementing coarse and fine tuning alignment.
once i have the rotation matrix, i rotate all the data in the local frame (gravity on z, NED frame), then i go for the mechanization equation in the 2D xy plane. the 2D code is the following:

[code]
for index = 1:size(data,1)

% data columns = ax,ay,wz
psi_nw = psi_ld + data(index,3)*Ts; % it is the heading, starting from 0
DCM2D = compute_DCM2D(psi_nw); % rotation matrix
vb = (DCM2D.'*v_ld); % body frame velocity
store(:,index) = (data(index,1:2).'-data(index,3)*vb(1)*[0;1]); % centripetal acceleration for debug
v_nw = v_ld + (DCM2D*(data(index,1:2).'-data(index,3)*vb(1)*[0;1]))*Ts ; % new velocity, just taking account for centripetal acceleration
p_nw = p_ld + v_nw*Ts; % new position


% variables update
v_ld = v_nw;
p_ld = p_nw;
psi_ld = psi_nw;

p(:,index) = p_nw;
v(:,index) = v_nw;
psi(:,index) = psi_nw;
end

[\code]

am i wrong? thanks for your attention :)

Yokes
Jul 07, 2009, 02:32 PM
A few questions:
You are only rotating the body data by the heading. I assume there is no pitch and roll?
What is your sample time (Ts)?
How do you know the true position and velocity?
How much error do you end up with?

Tom

marcorasta
Jul 08, 2009, 04:52 AM
A few questions:
You are only rotating the body data by the heading. I assume there is no pitch and roll?
What is your sample time (Ts)?
How do you know the true position and velocity?
How much error do you end up with?

Tom
- no pitch, no roll (it is a trolley on a plane. nonetheless, i start with alignment, so it should be fine)
- i sample at 20-50 Hz (actually i can get up to 167Hz), so the sampling time is 0.02 - 0.05 s
-the initial velocity is 0 cause i'm still. the initial point is set to a point which is some meters away from the real one, but i'm interested just to the shape of the trajectory. today i'm going to take data driving a car, so i will have the gps starting point and the gps trajectory.
- 1 km and more on y, some meters on x

any suggestion?

Yokes
Jul 08, 2009, 11:14 AM
Was it moving in just one direction? It seems strange that the X axis was much worse than the Y axis. Was it only moving in the X axis direction?

My only thoughts are things you probably already checked. Is the acceleration data scaled correctly? Correct signs?

Sorry, it seems like what you have should work.

Tom

marcorasta
Jul 09, 2009, 04:40 AM
Was it moving in just one direction? It seems strange that the X axis was much worse than the Y axis. Was it only moving in the X axis direction?

My only thoughts are things you probably already checked. Is the acceleration data scaled correctly? Correct signs?

Sorry, it seems like what you have should work.

Tom

yes, everything checked. scaling, signs. It also moved a bit along y, but just a little bit.
i received a new imu, i hope it will work better. at the moment, i don't even manage to get it recognized...