CigiEnvCtrlV1 Class Reference

#include <CigiEnvCtrlV1.h>

Inheritance diagram for CigiEnvCtrlV1:

CigiBaseEnvCtrl CigiBasePacket List of all members.

Public Member Functions

 CigiEnvCtrlV1 ()
virtual ~CigiEnvCtrlV1 ()
virtual int Pack (CigiBasePacket *Base, Cigi_uint8 *Buff, void *Spec) const
virtual int Unpack (Cigi_uint8 *Buff, bool Swap, void *Spec)
virtual void FillHold (CigiBaseEnvCtrl *Hold) const
int SetHour (const Cigi_uint8 HourIn, bool bndchk=true)
Cigi_uint8 GetHour (void) const
int SetMinute (const Cigi_uint8 MinuteIn, bool bndchk=true)
Cigi_uint8 GetMinute (void) const
int SetMonth (const Cigi_uint8 MonthIn, bool bndchk=true)
Cigi_uint8 GetMonth (void) const
int SetDay (const Cigi_uint8 DayIn, bool bndchk=true)
Cigi_uint8 GetDay (void) const
int SetYear (const Cigi_uint16 YearIn, bool bndchk=true)
Cigi_uint16 GetYear (void) const
int SetEphemerisEn (const bool EphemerisEnIn, bool bndchk=true)
bool GetEphemerisEn (void) const
int SetHumidity (const Cigi_uint8 HumidityIn, bool bndchk=true)
Cigi_uint8 GetHumidity (void) const
int SetAirTemp (const float AirTempIn, bool bndchk=true)
float GetAirTemp (void) const
int SetVisibility (const float VisibilityIn, bool bndchk=true)
float GetVisibility (void) const
int SetHorizWindSp (const float HorizWindSpIn, bool bndchk=true)
float GetHorizWindSp (void) const
int SetWindDir (const float WindDirIn, bool bndchk=true)
float GetWindDir (void) const

Detailed Description

Definition at line 61 of file CigiEnvCtrlV1.h.


Constructor & Destructor Documentation

CigiEnvCtrlV1::CigiEnvCtrlV1 (  ) 

General Constructor

Definition at line 90 of file CigiEnvCtrlV1.cpp.

References CigiBaseEnvCtrl::Aerosol, CigiBaseEnvCtrl::AirTemp, CigiBaseEnvCtrl::AtmosEn, CigiBaseEnvCtrl::BaroPress, CIGI_ENV_CTRL_PACKET_ID_V1, CIGI_ENV_CTRL_PACKET_SIZE_V1, CigiBaseEnvCtrl::DateVld, CigiBaseEnvCtrl::Day, CigiBaseEnvCtrl::EphemerisEn, CigiBaseEnvCtrl::HorizWindSp, CigiBaseEnvCtrl::Hour, CigiBaseEnvCtrl::Humidity, CigiBasePacket::MinorVersion, CigiBaseEnvCtrl::Minute, CigiBaseEnvCtrl::Month, CigiBaseEnvCtrl::MoonEn, CigiBasePacket::PacketID, CigiBasePacket::PacketSize, CigiBaseEnvCtrl::StarEn, CigiBaseEnvCtrl::StarInt, CigiBaseEnvCtrl::SunEn, CigiBasePacket::Version, CigiBaseEnvCtrl::VertWindSp, CigiBaseEnvCtrl::Visibility, CigiBaseEnvCtrl::WindDir, and CigiBaseEnvCtrl::Year.

00091 {
00092 
00093    PacketID = CIGI_ENV_CTRL_PACKET_ID_V1;
00094    PacketSize = CIGI_ENV_CTRL_PACKET_SIZE_V1;
00095    Version = 1;
00096    MinorVersion = 0;
00097 
00098    Hour = 0;
00099    Minute = 0;
00100    Month = 1;
00101    Day = 1;
00102    Year = 2000;
00103    StarInt = 0.0;
00104    EphemerisEn = false;
00105    SunEn = false;
00106    MoonEn = false;
00107    StarEn = false;
00108    DateVld = true;
00109    AtmosEn = false;
00110    Aerosol = 0.0;
00111    Humidity = 30;
00112    AirTemp = 0.0;
00113    Visibility = 64373.76f;
00114    HorizWindSp = 0.0;
00115    VertWindSp = 0.0;
00116    WindDir = 0.0;
00117    BaroPress = 1013.25;
00118 
00119 }

CigiEnvCtrlV1::~CigiEnvCtrlV1 (  )  [virtual]

General Destructor

Definition at line 124 of file CigiEnvCtrlV1.cpp.

00125 {
00126 
00127 }


Member Function Documentation

void CigiEnvCtrlV1::FillHold ( CigiBaseEnvCtrl Hold  )  const [virtual]

The virtual FillHold function.

Parameters:
Hold - A pointer to the Hold object. (Downcast to CigiBaseEnvCtrl)

Implements CigiBaseEnvCtrl.

Definition at line 237 of file CigiEnvCtrlV1.cpp.

References CigiBaseEnvCtrl::Aerosol, CigiBaseEnvCtrl::AirTemp, CigiBaseEnvCtrl::AtmosEn, CigiBaseEnvCtrl::BaroPress, CigiBaseEnvCtrl::DateVld, CigiBaseEnvCtrl::Day, CigiBaseEnvCtrl::EphemerisEn, CigiBaseEnvCtrl::HorizWindSp, CigiBaseEnvCtrl::Hour, CigiBaseEnvCtrl::Humidity, CigiBaseEnvCtrl::Minute, CigiBaseEnvCtrl::Month, CigiBaseEnvCtrl::MoonEn, CigiBaseEnvCtrl::StarEn, CigiBaseEnvCtrl::SunEn, CigiBaseEnvCtrl::Visibility, CigiBaseEnvCtrl::WindDir, and CigiBaseEnvCtrl::Year.

00238 {
00239    Hold->Hour = Hour;
00240    Hold->Minute = Minute;
00241    Hold->EphemerisEn = EphemerisEn;
00242    Hold->SunEn = SunEn;
00243    Hold->MoonEn = MoonEn;
00244    Hold->StarEn = StarEn;
00245    Hold->DateVld = DateVld;
00246    Hold->AtmosEn = AtmosEn;
00247    Hold->Humidity = Humidity;
00248    Hold->Month = Month;
00249    Hold->Day = Day;
00250    Hold->Year = Year;
00251    Hold->AirTemp = AirTemp;
00252    Hold->Visibility = Visibility;
00253    Hold->HorizWindSp = HorizWindSp;
00254    Hold->WindDir = WindDir;
00255    Hold->BaroPress = BaroPress;
00256    Hold->Aerosol = Aerosol;
00257 }

float CigiEnvCtrlV1::GetAirTemp ( void   )  const [inline]

Gets the AirTemp value.

Returns:
the current AirTemp.

Definition at line 267 of file CigiEnvCtrlV1.h.

00267 { return(AirTemp); }

Cigi_uint8 CigiEnvCtrlV1::GetDay ( void   )  const [inline]

Gets the Day value.

Returns:
the current Day.

Definition at line 186 of file CigiEnvCtrlV1.h.

00186 { return(Day); }

bool CigiEnvCtrlV1::GetEphemerisEn ( void   )  const [inline]

Gets the EphemerisEn value.

Returns:
the current EphemerisEn.

Definition at line 229 of file CigiEnvCtrlV1.h.

00229 { return(EphemerisEn); }

float CigiEnvCtrlV1::GetHorizWindSp ( void   )  const [inline]

Gets the HorizWindSp value.

Returns:
the current HorizWindSp.

Definition at line 301 of file CigiEnvCtrlV1.h.

00301 { return(HorizWindSp); }

Cigi_uint8 CigiEnvCtrlV1::GetHour ( void   )  const [inline]

Gets the Hour value.

Returns:
the current Hour.

Definition at line 135 of file CigiEnvCtrlV1.h.

00135 { return(Hour); }

Cigi_uint8 CigiEnvCtrlV1::GetHumidity ( void   )  const [inline]

Gets the Humidity value.

Returns:
the current Humidity.

Definition at line 246 of file CigiEnvCtrlV1.h.

00246 { return(Humidity); }

Cigi_uint8 CigiEnvCtrlV1::GetMinute ( void   )  const [inline]

Gets the Minute value.

Returns:
the current Minute.

Definition at line 152 of file CigiEnvCtrlV1.h.

00152 { return(Minute); }

Cigi_uint8 CigiEnvCtrlV1::GetMonth ( void   )  const [inline]

Gets the Month value.

Returns:
the current Month.

Definition at line 169 of file CigiEnvCtrlV1.h.

00169 { return(Month); }

float CigiEnvCtrlV1::GetVisibility ( void   )  const [inline]

Gets the Visibility value.

Returns:
the current Visibility.

Definition at line 284 of file CigiEnvCtrlV1.h.

00284 { return(Visibility); }

float CigiEnvCtrlV1::GetWindDir ( void   )  const [inline]

Gets the WindDir value.

Returns:
the current WindDir.

Definition at line 318 of file CigiEnvCtrlV1.h.

00318 { return(WindDir); }

Cigi_uint16 CigiEnvCtrlV1::GetYear ( void   )  const [inline]

Gets the Year value.

Returns:
the current Year.

Definition at line 207 of file CigiEnvCtrlV1.h.

00207 { return(Year); }

int CigiEnvCtrlV1::Pack ( CigiBasePacket Base,
Cigi_uint8 Buff,
void *  Spec 
) const [virtual]

The virtual Pack function for CIGI 1

Parameters:
Base - A pointer to the instance of the packet to be packed. (Downcast to CigiBasePacket)
Buff - A pointer to the current pack point.
Spec - A pointer to special data - This is used to point to the Environmental Control holding object when going between V1 and V3.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Implements CigiBaseEnvCtrl.

Definition at line 136 of file CigiEnvCtrlV1.cpp.

References CigiBaseEnvCtrl::AirTemp, PackPointerUnion::c, CIGI_ENV_CTRL_PACKET_SIZE_V1, CIGI_SCOPY4, PackPointerUnion::d, CigiBaseEnvCtrl::Day, CigiBaseEnvCtrl::EphemerisEn, PackPointerUnion::f, CigiBaseEnvCtrl::HorizWindSp, CigiBaseEnvCtrl::Hour, CigiBaseEnvCtrl::Humidity, PackPointerUnion::l, CigiBaseEnvCtrl::Minute, CigiBaseEnvCtrl::Month, CigiBasePacket::PacketID, CigiBasePacket::PacketSize, PackPointerUnion::s, CigiBaseEnvCtrl::Visibility, CigiBaseEnvCtrl::WindDir, and CigiBaseEnvCtrl::Year.

00137 {
00138    double DBuf[6];
00139 
00140    Cigi_uint8 *tBuf = (Cigi_uint8 *)DBuf;
00141 
00142    PackPointer CDta;
00143 
00144    CigiBaseEnvCtrl * Data = ( CigiBaseEnvCtrl *)Base;
00145 
00146    CDta.d = DBuf;
00147 
00148    *CDta.c++ = PacketID;
00149    *CDta.c++ = PacketSize;
00150 
00151    *CDta.c++ = Data->Hour;
00152    *CDta.c++ = Data->Minute;
00153 
00154    *CDta.c++ = ((Data->Humidity) & 0x7f) | ((Data->EphemerisEn) ? 0x80 : 0);
00155 
00156    *CDta.c++ = 0;
00157    *CDta.s++ = 0;
00158 
00159    // Determine date
00160    Cigi_uint32 date = ((Cigi_uint32)Data->Month * 1000000) +
00161                         ((Cigi_uint32)Data->Day   *   10000) + (Cigi_uint32)Data->Year;
00162    CIGI_SCOPY4(CDta.l++, &date);
00163 
00164    CIGI_SCOPY4(CDta.f++, &Data->AirTemp);
00165    CIGI_SCOPY4(CDta.f++, &Data->Visibility);
00166    CIGI_SCOPY4(CDta.f++, &Data->HorizWindSp);
00167    CIGI_SCOPY4(CDta.f++, &Data->WindDir);
00168 
00169 
00170    memcpy(Buff,tBuf,CIGI_ENV_CTRL_PACKET_SIZE_V1);
00171 
00172    return(PacketSize);
00173 
00174 }

int CigiEnvCtrlV1::SetAirTemp ( const float  AirTempIn,
bool  bndchk = true 
) [inline]

Sets the AirTemp with bound checking control

Parameters:
AirTempIn - Current ambient air temperature
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 258 of file CigiEnvCtrlV1.h.

References CIGI_SUCCESS.

00259    {
00260       AirTemp = AirTempIn;
00261       return(CIGI_SUCCESS);
00262    }

int CigiEnvCtrlV1::SetDay ( const Cigi_uint8  DayIn,
bool  bndchk = true 
)

Sets the Day with bound checking control

Parameters:
DayIn - current day of the month
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 357 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Day.

00358 {
00359 
00360 #ifndef CIGI_NO_BND_CHK
00361    if(bndchk && ((DayIn < 1)||(DayIn > 31)))
00362    {
00363 #ifndef CIGI_NO_EXCEPT
00364       throw CigiValueOutOfRangeException("Day",(Cigi_uint8)DayIn,1,31);
00365 #endif
00366       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00367    }
00368 #endif
00369 
00370    Day = DayIn;
00371    return(CIGI_SUCCESS);
00372 
00373 }

int CigiEnvCtrlV1::SetEphemerisEn ( const bool  EphemerisEnIn,
bool  bndchk = true 
) [inline]

Sets the EphemerisEn with bound checking control

Parameters:
EphemerisEnIn - Enable (true) or disable (false) ephereris model.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 220 of file CigiEnvCtrlV1.h.

References CIGI_SUCCESS.

00221    {
00222       EphemerisEn = EphemerisEnIn;
00223       return(CIGI_SUCCESS);
00224    }

int CigiEnvCtrlV1::SetHorizWindSp ( const float  HorizWindSpIn,
bool  bndchk = true 
)

Sets the HorizWindSp with bound checking control

Parameters:
HorizWindSpIn - Wind speed
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 401 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::HorizWindSp.

00402 {
00403 
00404 #ifndef CIGI_NO_BND_CHK
00405    if(bndchk && (HorizWindSpIn < 0.0))
00406    {
00407 #ifndef CIGI_NO_EXCEPT
00408       throw CigiValueOutOfRangeException("HorizWindSp",(float)HorizWindSpIn,">",0.0);
00409 #endif
00410       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00411    }
00412 #endif
00413 
00414    HorizWindSp = HorizWindSpIn;
00415    return(CIGI_SUCCESS);
00416 
00417 }

int CigiEnvCtrlV1::SetHour ( const Cigi_uint8  HourIn,
bool  bndchk = true 
)

Sets the Hour with bound checking control

Parameters:
HourIn - Current hour
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 269 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Hour.

00270 {
00271 
00272 #ifndef CIGI_NO_BND_CHK
00273    if(bndchk && ((HourIn < 0)||(HourIn > 23)))
00274    {
00275 #ifndef CIGI_NO_EXCEPT
00276       throw CigiValueOutOfRangeException("Hour",(Cigi_uint8)HourIn,0,23);
00277 #endif
00278       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00279    }
00280 #endif
00281 
00282    Hour = HourIn;
00283    return(CIGI_SUCCESS);
00284 
00285 }

int CigiEnvCtrlV1::SetHumidity ( const Cigi_uint8  HumidityIn,
bool  bndchk = true 
)

Sets the Humidity with bound checking control

Parameters:
HumidityIn - Percentage humidity.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 313 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Humidity.

00314 {
00315 
00316 #ifndef CIGI_NO_BND_CHK
00317    if(bndchk && ((HumidityIn < 0)||(HumidityIn > 100)))
00318    {
00319 #ifndef CIGI_NO_EXCEPT
00320       throw CigiValueOutOfRangeException("Humidity",(Cigi_uint8)HumidityIn,0,100);
00321 #endif
00322       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00323    }
00324 #endif
00325 
00326    Humidity = HumidityIn;
00327    return(CIGI_SUCCESS);
00328 
00329 }

int CigiEnvCtrlV1::SetMinute ( const Cigi_uint8  MinuteIn,
bool  bndchk = true 
)

Sets the Minute with bound checking control

Parameters:
MinuteIn - Current minute
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 291 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Minute.

00292 {
00293 
00294 #ifndef CIGI_NO_BND_CHK
00295    if(bndchk && ((MinuteIn < 0)||(MinuteIn > 59)))
00296    {
00297 #ifndef CIGI_NO_EXCEPT
00298       throw CigiValueOutOfRangeException("Minute",(Cigi_uint8)MinuteIn,0,59);
00299 #endif
00300       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00301    }
00302 #endif
00303 
00304    Minute = MinuteIn;
00305    return(CIGI_SUCCESS);
00306 
00307 }

int CigiEnvCtrlV1::SetMonth ( const Cigi_uint8  MonthIn,
bool  bndchk = true 
)

Sets the Month with bound checking control

Parameters:
MonthIn - current month
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 335 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Month.

00336 {
00337 
00338 #ifndef CIGI_NO_BND_CHK
00339    if(bndchk && ((MonthIn < 1)||(MonthIn > 12)))
00340    {
00341 #ifndef CIGI_NO_EXCEPT
00342       throw CigiValueOutOfRangeException("Month",(Cigi_uint8)MonthIn,1,12);
00343 #endif
00344       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00345    }
00346 #endif
00347 
00348    Month = MonthIn;
00349    return(CIGI_SUCCESS);
00350 
00351 }

int CigiEnvCtrlV1::SetVisibility ( const float  VisibilityIn,
bool  bndchk = true 
)

Sets the Visibility with bound checking control

Parameters:
VisibilityIn - Global visibility.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 379 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::Visibility.

00380 {
00381 
00382 #ifndef CIGI_NO_BND_CHK
00383    if(bndchk && (VisibilityIn < 0.0))
00384    {
00385 #ifndef CIGI_NO_EXCEPT
00386       throw CigiValueOutOfRangeException("Visibility",(float)VisibilityIn,">",0.0);
00387 #endif
00388       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00389    }
00390 #endif
00391 
00392    Visibility = VisibilityIn;
00393    return(CIGI_SUCCESS);
00394 
00395 }

int CigiEnvCtrlV1::SetWindDir ( const float  WindDirIn,
bool  bndchk = true 
)

Sets the WindDir with bound checking control

Parameters:
WindDirIn - Wind direction
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 423 of file CigiEnvCtrlV1.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseEnvCtrl::WindDir.

00424 {
00425 
00426 #ifndef CIGI_NO_BND_CHK
00427    if(bndchk && ((WindDirIn < 0.0)||(WindDirIn > 360.0)))
00428    {
00429 #ifndef CIGI_NO_EXCEPT
00430       throw CigiValueOutOfRangeException("WindDir",(float)WindDirIn,0.0,360.0);
00431 #endif
00432       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00433    }
00434 #endif
00435 
00436    WindDir = WindDirIn;
00437    return(CIGI_SUCCESS);
00438 
00439 }

int CigiEnvCtrlV1::SetYear ( const Cigi_uint16  YearIn,
bool  bndchk = true 
) [inline]

Sets the Year with bound checking control

Parameters:
YearIn - current year
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 198 of file CigiEnvCtrlV1.h.

References CIGI_SUCCESS.

00199    {
00200       Year = YearIn;
00201       return(CIGI_SUCCESS);
00202    }

int CigiEnvCtrlV1::Unpack ( Cigi_uint8 Buff,
bool  Swap,
void *  Spec 
) [virtual]

The virtual Unpack function for CIGI 1

Parameters:
Buff - A pointer to the current pack point.
Swap - N/A for V1 & V2
Spec - A pointer to special data - This is used to point to the Environmental Control holding object when going between V1 and V3.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Implements CigiBaseEnvCtrl.

Definition at line 179 of file CigiEnvCtrlV1.cpp.

References CigiBaseEnvCtrl::AirTemp, PackPointerUnion::c, CIGI_ENV_CTRL_PACKET_SIZE_V1, CIGI_SCOPY4, PackPointerUnion::d, CigiBaseEnvCtrl::DateVld, CigiBaseEnvCtrl::Day, CigiBaseEnvCtrl::EphemerisEn, PackPointerUnion::f, CigiBaseEnvCtrl::HorizWindSp, CigiBaseEnvCtrl::Hour, CigiBaseEnvCtrl::Humidity, PackPointerUnion::l, CigiBaseEnvCtrl::Minute, CigiBaseEnvCtrl::Month, CigiBaseEnvCtrl::MoonEn, CigiBasePacket::PacketSize, CigiBaseEnvCtrl::StarEn, CigiBaseEnvCtrl::SunEn, CigiBaseEnvCtrl::Visibility, CigiBaseEnvCtrl::WindDir, and CigiBaseEnvCtrl::Year.

00180 {
00181    double DBuf[6];
00182 
00183    Cigi_uint8 *tBuf = (Cigi_uint8 *)DBuf;
00184 
00185    PackPointer CDta;
00186 
00187    memcpy(tBuf,Buff,CIGI_ENV_CTRL_PACKET_SIZE_V1);
00188 
00189    CDta.d = DBuf;
00190 
00191    CDta.c += 2;  // Step over packet id and size
00192 
00193    Hour = *CDta.c++;
00194    Minute = *CDta.c++;
00195 
00196    Cigi_uint8 HDta = *CDta.c++;
00197    EphemerisEn = ((HDta & 0x80) != 0);
00198    Humidity = HDta & 0x7f;
00199 
00200    SunEn = MoonEn = StarEn = DateVld = EphemerisEn;
00201 
00202    CDta.c += 3;
00203 
00204    // Determine date
00205    Cigi_uint32 date;
00206    CIGI_SCOPY4(&date, CDta.l++);
00207 
00208    Month = (Cigi_uint8)(date / 1000000);
00209    date -= ((Cigi_uint32)Month * 1000000);
00210 
00211    Day = (Cigi_uint8)(date / 10000);
00212    date -= ((Cigi_uint32)Day * 10000);
00213 
00214    Year = (Cigi_uint16)date;
00215 
00216 
00217    CIGI_SCOPY4(&AirTemp, CDta.f++);
00218    CIGI_SCOPY4(&Visibility, CDta.f++);
00219    CIGI_SCOPY4(&HorizWindSp, CDta.f++);
00220    CIGI_SCOPY4(&WindDir, CDta.f++);
00221 
00222 
00223 
00224    return(PacketSize);
00225 
00226 }


The documentation for this class was generated from the following files:
Generated on Wed Apr 29 09:00:08 2009 for CCL by  doxygen 1.4.7