1.1 --- a/epoc32/include/lbssatellite.h Tue Nov 24 13:55:44 2009 +0000
1.2 +++ b/epoc32/include/lbssatellite.h Tue Mar 16 16:12:26 2010 +0000
1.3 @@ -1,1 +1,126 @@
1.4 -lbssatellite.h
1.5 +// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
1.6 +// All rights reserved.
1.7 +// This component and the accompanying materials are made available
1.8 +// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
1.9 +// which accompanies this distribution, and is available
1.10 +// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
1.11 +//
1.12 +// Initial Contributors:
1.13 +// Nokia Corporation - initial contribution.
1.14 +//
1.15 +// Contributors:
1.16 +//
1.17 +// Description:
1.18 +//
1.19 +
1.20 +#ifndef __LBSSATELLITE_H__
1.21 +#define __LBSSATELLITE_H__
1.22 +
1.23 +#include <lbsposition.h>
1.24 +#include <lbspositioninfo.h>
1.25 +
1.26 +
1.27 +/**
1.28 +Maximum number of satellites in view
1.29 +
1.30 +@publishedAll
1.31 +@released
1.32 + */
1.33 +const TUint KPositionMaxSatellitesInView = 20;
1.34 +
1.35 +
1.36 +class TSatelliteData
1.37 +/**
1.38 +This class is used to transfer data about a satellite
1.39 +
1.40 +@publishedAll
1.41 +@released
1.42 + */
1.43 + {
1.44 +public:
1.45 + IMPORT_C TSatelliteData();
1.46 +
1.47 + IMPORT_C TInt SatelliteId() const;
1.48 + IMPORT_C void SetSatelliteId(TInt aSatelliteId);
1.49 +
1.50 + IMPORT_C TReal32 Azimuth() const;
1.51 + IMPORT_C void SetAzimuth(TReal32 aAzimuth);
1.52 +
1.53 + IMPORT_C TReal32 Elevation() const;
1.54 + IMPORT_C void SetElevation(TReal32 aElevation);
1.55 +
1.56 + IMPORT_C TBool IsUsed() const;
1.57 + IMPORT_C void SetIsUsed(TBool aIsUsed);
1.58 +
1.59 + IMPORT_C TInt SignalStrength() const;
1.60 + IMPORT_C void SetSignalStrength(TInt aSignalStrength);
1.61 +
1.62 +protected:
1.63 + /** The ID (in GPS, the PRN) */
1.64 + TInt iSatelliteId;
1.65 + /** The azimuth, in degrees */
1.66 + TReal32 iAzimuth;
1.67 + /** The elevation, in degrees */
1.68 + TReal32 iElevation;
1.69 + /** Whether the satellite is used */
1.70 + TBool iIsUsed;
1.71 + /** The signal strength, in decibels */
1.72 + TInt iSignalStrength;
1.73 +
1.74 +private:
1.75 + /** Unused variable for future expansion. */
1.76 + TUint8 iReserved[16];
1.77 + };
1.78 +
1.79 +class TPositionSatelliteInfo : public TPositionCourseInfo
1.80 +/**
1.81 +This class is used to store information about positions obtained by satellites.
1.82 +
1.83 +@publishedAll
1.84 +@released
1.85 + */
1.86 + {
1.87 +public:
1.88 + IMPORT_C TPositionSatelliteInfo();
1.89 +
1.90 + IMPORT_C TInt GetSatelliteData(TUint aIndex, TSatelliteData& aSatelliteData) const;
1.91 + IMPORT_C TInt AppendSatelliteData(const TSatelliteData& aSatelliteData);
1.92 +
1.93 + IMPORT_C TInt NumSatellitesInView() const;
1.94 + IMPORT_C void ClearSatellitesInView();
1.95 +
1.96 + IMPORT_C TInt NumSatellitesUsed() const;
1.97 +
1.98 + IMPORT_C TTime SatelliteTime() const;
1.99 + IMPORT_C void SetSatelliteTime(TTime aTime);
1.100 +
1.101 + IMPORT_C TReal32 HorizontalDoP() const;
1.102 + IMPORT_C TReal32 VerticalDoP() const;
1.103 + IMPORT_C TReal32 TimeDoP() const;
1.104 +
1.105 + IMPORT_C void SetHorizontalDoP(TReal32 aDoPValue);
1.106 + IMPORT_C void SetVerticalDoP(TReal32 aDoPValue);
1.107 + IMPORT_C void SetTimeDoP(TReal32 aDoPValue);
1.108 +
1.109 +protected:
1.110 + /** The number of satellites in view */
1.111 + TUint iNumSatellitesInView;
1.112 + /** The number of satellites used */
1.113 + TUint iNumSatellitesUsed;
1.114 + /** The time according to the satellite */
1.115 + TTime iSatelliteTime;
1.116 + /** The horizontal dilution of precision */
1.117 + TReal32 iHorizontalDoPValue;
1.118 + /** The vertical dilution of precision */
1.119 + TReal32 iVerticalDoPValue;
1.120 + /** The position dilution of precision */
1.121 + TReal32 iTimeDoPValue;
1.122 + /** The satellites in view */
1.123 + TFixedArray<TSatelliteData, KPositionMaxSatellitesInView> iSatellitesInView;
1.124 +
1.125 +private:
1.126 + /** Unused variable for future expansion. */
1.127 + TUint8 iReserved[24];
1.128 + };
1.129 +
1.130 +#endif //__LBSSATELLITE_H__