?lang_form? ?lang_select? ?lang_submit? ?lang_endform?
{HEADER END}
{FILE START}

library

?curdirlinks? - Rev 6

?prevdifflink? - Blame - ?getfile?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Procyon AVRlib: gps.h Source File</title>
<link href="dox.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.2 -->
<div class="qindex"><a class="qindex" href="main.html">Main&nbsp;Page</a> | <a class="qindex" href="modules.html">Modules</a> | <a class="qindex" href="annotated.html">Data&nbsp;Structures</a> | <a class="qindex" href="dirs.html">Directories</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="functions.html">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a></div>
<h1>gps.h</h1><a href="gps_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment">00001 <span class="comment">/*! \file gps.h \brief GPS position storage and processing library. */</span>
00002 <span class="comment">//*****************************************************************************</span>
00003 <span class="comment">//</span>
00004 <span class="comment">// File Name    : 'gps.h'</span>
00005 <span class="comment">// Title        : GPS position storage and processing function library</span>
00006 <span class="comment">// Author       : Pascal Stang - Copyright (C) 2002</span>
00007 <span class="comment">// Created      : 2002.08.29</span>
00008 <span class="comment">// Revised      : 2002.08.29</span>
00009 <span class="comment">// Version      : 0.1</span>
00010 <span class="comment">// Target MCU   : Atmel AVR Series</span>
00011 <span class="comment">// Editor Tabs  : 4</span>
00012 <span class="comment">//</span>
00013 <span class="comment">// NOTE: This code is currently below version 1.0, and therefore is considered</span>
00014 <span class="comment">// to be lacking in some functionality or documentation, or may not be fully</span>
00015 <span class="comment">// tested.  Nonetheless, you can expect most functions to work.</span>
00016 <span class="comment">//</span><span class="comment"></span>
00017 <span class="comment">/// \ingroup driver_hw</span>
00018 <span class="comment">/// \defgroup gps GPS Positioning and Navigation Function Library (gps.c)</span>
00019 <span class="comment">/// \code #include "gps.h" \endcode</span>
00020 <span class="comment">/// \par Overview</span>
00021 <span class="comment">///     This library provides a generic way to store and process information</span>
00022 <span class="comment">/// received from a GPS receiver.  Currently the library only stores the most</span>
00023 <span class="comment">/// recent set of GPS data (position, velocity, time) from a GPS receiver.</span>
00024 <span class="comment">/// Future revisions will include navigation functions like calculate</span>
00025 <span class="comment">/// heading/distance to a waypoint.  The processing of incoming serial data</span>
00026 <span class="comment">/// packets from GPS hardware is not done in this library.  The libraries</span>
00027 <span class="comment">/// tsip.c and nmea.c do the packet processing for Trimble Standard Interface</span>
00028 <span class="comment">/// Protocol and NMEA-0813 repectively, and store the results in this library.</span>
00029 <span class="comment"></span><span class="comment">//</span>
00030 <span class="comment">// This code is distributed under the GNU Public License</span>
00031 <span class="comment">//      which can be found at http://www.gnu.org/licenses/gpl.txt</span>
00032 <span class="comment">//</span>
00033 <span class="comment">//*****************************************************************************</span>
00034 
00035 <span class="preprocessor">#ifndef GPS_H</span>
00036 <span class="preprocessor"></span><span class="preprocessor">#define GPS_H</span>
00037 <span class="preprocessor"></span>
00038 <span class="preprocessor">#include "<a class="code" href="global_8h.html">global.h</a>"</span>
00039 
00040 <span class="comment">// constants/macros/typdefs</span>
00041 <span class="keyword">typedef</span> <span class="keyword">union </span>union_float_u32
00042 {
00043     <span class="keywordtype">float</span> f;
00044     <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> i;
00045     <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> b[4];
00046 } float_u32;
00047 
00048 <span class="keyword">typedef</span> <span class="keyword">union </span>union_double_u64
00049 {
00050     <span class="keywordtype">double</span> f;
00051     <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <span class="keywordtype">long</span> i;
00052     <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> b[8];
00053 } double_u64;
00054 
00055 <span class="keyword">struct </span>PositionLLA
00056 {
00057     float_u32 lat;
00058     float_u32 lon;
00059     float_u32 alt;
00060     float_u32 TimeOfFix;
00061     u16 updates;
00062 };
00063 
00064 <span class="keyword">struct </span>VelocityENU
00065 {
00066     float_u32 east;
00067     float_u32 north;
00068     float_u32 up;
00069     float_u32 TimeOfFix;
00070     u16 updates;
00071 };
00072 
00073 <span class="keyword">struct </span>VelocityHS
00074 {
00075     float_u32 heading;
00076     float_u32 speed;
00077     float_u32 TimeOfFix;
00078     u16 updates;
00079 };
00080 
00081 <span class="keyword">struct </span>PositionECEF
00082 {
00083     float_u32 x;
00084     float_u32 y;
00085     float_u32 z;
00086     float_u32 TimeOfFix;
00087     u16 updates;
00088 };
00089 
00090 <span class="keyword">struct </span>VelocityECEF
00091 {
00092     float_u32 x;
00093     float_u32 y;
00094     float_u32 z;
00095     float_u32 TimeOfFix;
00096     u16 updates;
00097 };
00098 
00099 <span class="keyword">typedef</span> <span class="keyword">struct </span>struct_GpsInfo
00100 {   
00101     float_u32 TimeOfWeek;
00102     u16 WeekNum;
00103     float_u32 UtcOffset;
00104     u08 numSVs;
00105     
00106     <span class="keyword">struct </span>PositionLLA PosLLA;
00107     <span class="keyword">struct </span>PositionECEF PosECEF;
00108     <span class="keyword">struct </span>VelocityECEF VelECEF;
00109     <span class="keyword">struct </span>VelocityENU VelENU;
00110     <span class="keyword">struct </span>VelocityHS VelHS;
00111 
00112 } GpsInfoType;
00113 
00114 <span class="comment">// functions</span>
00115 <span class="keywordtype">void</span> gpsInit(<span class="keywordtype">void</span>);
00116 GpsInfoType* gpsGetInfo(<span class="keywordtype">void</span>);
00117 <span class="keywordtype">void</span> gpsInfoPrint(<span class="keywordtype">void</span>);
00118 
00119 <span class="preprocessor">#endif</span>
</pre></div><hr size="1"><address style="align: right;"><small>Generated on Sun Oct 29 03:41:06 2006 for Procyon AVRlib by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.2 </small></address>
</body>
</html>
{FILE END}
{FOOTER START}

Powered by WebSVN v2.8.3