• 大小: 2.33MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-11-09
  • 语言: Matlab
  • 标签: GNSS  姿态测量  MATLAB  

资源简介

该程序通过读取GNSS接收机的观测数据和星历文件,求取GNSS接收机间所构成的基线向量,进而求取载体的姿态信息。

资源截图

代码片段和文件信息

%%========================================
%%     Toolbox for attitude determination
%%     Zhen Dai
%%     dai@zess.uni-siegen.de
%%     ZESS University of Siegen Germany
%%     Last Modified  : 1.Sep.2008
%%========================================
%% Functions:
%%      Direct attitude determination
%% Input parameters:     
%%      vSlaveAntLocal1vSlaveAntLocal2:
%%          ->Local level coordinates of the 1st and 2nd slave antennas.
%%          The order of both can not be confused otherwise another body
%%          frame will be produced.     
%% Output:
%%      yaw_degroll_degpitch_deg:
%%          -> Attitude parameters expressed in Euler angles in degrees.
%% Remarks:
%%      Master antenna coordinate is not needed beccause it is always [0 0 0]
%%  Reference:
%%      B.Hofmann-Wellenhof H.Lichtenegger and J.Collins: GPS Theory
%%      and practice. 2001. Fifth revised edition. Springer Wien New York.
%%      pp.327-328.

function [yaw_degroll_degpitch_deg]=AD_Direct(vSlaveAntLocal1vSlaveAntLocal2)
%% ~~~~~~~~~~~~ Step 1 ~~~~~~~~~~~~~~~
%% Using Ant 2 to derive yaw and pitch
%% ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
x2=vSlaveAntLocal1(1);
y2=vSlaveAntLocal1(2);
z2=vSlaveAntLocal1(3);
x3=vSlaveAntLocal2(1);
y3=vSlaveAntLocal2(2);
z3=vSlaveAntLocal2(3);
%% Get yaw
yaw_arc=-atan(x2/y2);
yaw_deg=GetAngleDeg(yaw_arc);
%% Get pitch
pitch_arc=atan(z2/sqrt(x2*x2+y2*y2));
pitch_deg=GetAngleDeg(pitch_arc);

%% ~~~~~~~~~~~~ Step 2 ~~~~~~~~~~~~~~~
%% Rotate Ant 3 to derive roll
%%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

%% 1st rotation matrix-- rotate about Z by yaw
R3=[cos(yaw_arc) sin(yaw_arc) 0;...
    -sin(yaw_arc)   cos(yaw_arc) 0;...
    0                  0             1];
%% 2nd rotation matrix-- rotate about X‘ by pitch
R1=[1                0              0;
    0     cos(pitch_arc) sin(pitch_arc);
    0      -sin(pitch_arc) cos(pitch_arc)];
%% Now rotate the Ant 3
mRotation1=R3*[x3 y3 z3]‘;
mRotation2=R1*mRotation1;

%% ~~~~~~~~~~~~ Step 2 ~~~~~~~~~~~~~~~
%% Get roll
%%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
%% Roll
roll_arc=-atan(mRotation2(3)/mRotation2(1));
roll_deg=GetAngleDeg(roll_arc);

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2018-05-31 00:13  姿态测量matlab程序\
     文件        2195  2008-09-03 16:42  姿态测量matlab程序\AD_Direct.m
     文件        4686  2008-09-03 16:42  姿态测量matlab程序\AD_LSQ.m
     文件         229  2008-08-19 18:48  姿态测量matlab程序\ambiguity.mat
     文件      664374  2018-05-04 23:04  姿态测量matlab程序\AttDet_16_3_2009.zip
     文件        6546  2009-03-16 17:15  姿态测量matlab程序\ControlPanel.fig
     文件       13062  2018-05-05 15:15  姿态测量matlab程序\ControlPanel.m
     文件        1152  2009-03-16 18:17  姿态测量matlab程序\DataGUI.mat
     文件        4183  2008-09-03 16:42  姿态测量matlab程序\DGPS_code.m
     文件        4611  2008-09-03 16:42  姿态测量matlab程序\DGPS_phase.m
     文件         772  2008-09-16 11:21  姿态测量matlab程序\DisplaybaselineErr.m
     文件        1911  2008-09-03 16:42  姿态测量matlab程序\DrawAttitudeFigure.m
     文件        1369  2008-09-03 16:43  姿态测量matlab程序\EarthRotation.m
     文件        1462  2008-09-03 16:41  姿态测量matlab程序\ECEF2ENU.m
     文件        1278  2009-03-16 16:56  姿态测量matlab程序\ECEF2LLH.m
     文件         680  2009-03-16 17:08  姿态测量matlab程序\GetAngleDeg.m
     文件        2930  2018-05-08 12:00  姿态测量matlab程序\GetBodyCoordinates.m
     文件        1235  2008-09-03 16:49  姿态测量matlab程序\GetCombinedRotationMatrix.m
     文件         825  2008-09-03 16:50  姿态测量matlab程序\GetLine80.m
     文件        4609  2009-03-03 10:31  姿态测量matlab程序\GetSatPosECEF.m
     文件        1901  2008-09-03 16:59  姿态测量matlab程序\GetWeekSeconds.m
     文件        6583  2008-09-03 17:01  姿态测量matlab程序\LoadRinexNav.m
     文件       10433  2009-03-03 10:09  姿态测量matlab程序\LoadRinexOBS.m
     文件       20377  2009-03-16 16:58  姿态测量matlab程序\mainpro.m
     文件       20576  2008-10-22 15:32  姿态测量matlab程序\mainpro_ph.m
     文件        6767  2008-09-16 12:43  姿态测量matlab程序\ProcessRINEX.m
     文件      176519  2018-05-31 00:13  姿态测量matlab程序\Readme.pdf
     文件        1013  2008-09-03 18:30  姿态测量matlab程序\SaveResultInFile.m
     文件        1981  2008-09-03 17:25  姿态测量matlab程序\SeekEpheEpoch.m
     文件        2048  2008-09-03 17:31  姿态测量matlab程序\SinglePointGPS.m
     文件        3708  2009-03-03 10:22  姿态测量matlab程序\Smoothing.m
............此处省略9个文件信息

评论

共有 条评论