CigiBaseSensorResp.h

Go to the documentation of this file.
00001 
00055 #if !defined(_CIGI_BASE_SENSOR_RESP_INCLUDED_)
00056 #define _CIGI_BASE_SENSOR_RESP_INCLUDED_
00057 
00058 #include "CigiBasePacket.h"
00059 
00060 // ====================================================================
00061 // preprocessor definitions
00062 // ====================================================================
00063 
00064 #define CIGI_SENSOR_RESP_PACKET_ID_V1 105
00065 #define CIGI_SENSOR_RESP_PACKET_SIZE_V1 12
00066 
00067 #define CIGI_SENSOR_RESP_PACKET_ID_V2 105
00068 #define CIGI_SENSOR_RESP_PACKET_SIZE_V2 12
00069 
00070 #define CIGI_SENSOR_RESP_PACKET_ID_V3 106
00071 #define CIGI_SENSOR_RESP_PACKET_SIZE_V3 24
00072 
00073 #define CIGI_SENSOR_XRESP_PACKET_ID_V3 107
00074 #define CIGI_SENSOR_XRESP_PACKET_SIZE_V3 48
00075 
00076 
00077 class CigiSensorRespV1;
00078 class CigiSensorRespV2;
00079 class CigiSensorRespV3;
00080 class CigiSensorXRespV3;
00081 
00082 
00083 class CIGI_SPEC CigiBaseSensorResp : public CigiBasePacket
00084 {
00085 
00086 friend class CigiSensorRespV1;
00087 friend class CigiSensorRespV2;
00088 friend class CigiSensorRespV3;
00089 friend class CigiSensorXRespV3;
00090 
00091 public:
00092 
00093    //=========================================================
00096    enum SensorStatGrp
00097    {
00098       Searching=0,
00099       Tracking=1,
00100       NearBrakeLock=2,
00101       BrakeLock=3
00102    };
00103 
00104 
00105 
00106 
00107    //==> Management
00108 
00109    //=========================================================
00112    CigiBaseSensorResp();
00113 
00114    //=========================================================
00117    virtual ~CigiBaseSensorResp();
00118 
00119 
00120    //==> Buffer Packing/Unpacking
00121 
00122    //=========================================================
00133    virtual int Pack(CigiBasePacket * Base, Cigi_uint8 * Buff, void *Spec) const=0;
00134 
00135    //=========================================================
00145    virtual int Unpack(Cigi_uint8 * Buff, bool Swap, void *Spec) =0;
00146 
00147    //=========================================================
00159         virtual int GetCnvt(CigiVersionID &CnvtVersion,
00160                        CigiCnvtInfoType::Type &CnvtInfo);
00161 
00162 
00163 
00164    //==> Accessing Member Variable Values functions
00165 
00166    //+> SensorID
00167 
00168    //=========================================================
00175    int SetSensorID(const Cigi_uint8 SensorIDIn, bool bndchk=true)
00176    {
00177       SensorID = SensorIDIn;
00178       return(CIGI_SUCCESS);
00179    }
00180 
00181    //=========================================================
00184    Cigi_uint8 GetSensorID(void) const { return(SensorID); }
00185 
00186 
00187    //+> SensorStat
00188 
00189    //=========================================================
00200    int SetSensorStat(const SensorStatGrp SensorStatIn, bool bndchk=true);
00201 
00202    //=========================================================
00205    SensorStatGrp GetSensorStat(void) const { return(SensorStat); }
00206 
00207 
00208    //+> GateSzX
00209 
00210    //=========================================================
00217    int SetGateSzX(const Cigi_uint16 GateSzXIn, bool bndchk=true)
00218    {
00219       GateSzX = GateSzXIn;
00220       return(CIGI_SUCCESS);
00221    }
00222 
00223    //=========================================================
00226    Cigi_uint16 GetGateSzX(void) const { return(GateSzX); }
00227 
00228 
00229    //+> GateSzY
00230 
00231    //=========================================================
00238    int SetGateSzY(const Cigi_uint16 GateSzYIn, bool bndchk=true)
00239    {
00240       GateSzY = GateSzYIn;
00241       return(CIGI_SUCCESS);
00242    }
00243 
00244    //=========================================================
00247    Cigi_uint16 GetGateSzY(void) const { return(GateSzY); }
00248 
00249 
00250    //+> GateXoff
00251 
00252    //=========================================================
00259    int SetGateXoff(const float GateXoffIn, bool bndchk=true);
00260 
00261    //=========================================================
00264    float GetGateXoff(void) const { return(GateXoff); }
00265 
00266 
00267    //+> GateYoff
00268 
00269    //=========================================================
00276    int SetGateYoff(const float GateYoffIn, bool bndchk=true);
00277 
00278    //=========================================================
00281    float GetGateYoff(void) const { return(GateYoff); }
00282 
00283 
00284 
00285 protected:
00286 
00287    //==> Member variables
00288 
00289    //=========================================================
00293    Cigi_uint16 ViewID;
00294 
00295    //=========================================================
00299    Cigi_uint8 SensorID;
00300 
00301    //=========================================================
00310    SensorStatGrp SensorStat;
00311 
00312    //=========================================================
00316    bool EntityTgt;
00317 
00318    //=========================================================
00322    Cigi_uint16 EntityID;
00323 
00324    //=========================================================
00329    Cigi_uint16 GateSzX;
00330 
00331    //=========================================================
00336    Cigi_uint16 GateSzY;
00337 
00338    //=========================================================
00344    float GateXoff;
00345 
00346    //=========================================================
00352    float GateYoff;
00353 
00354    //=========================================================
00358    Cigi_uint32 FrameCntr;
00359 
00360    //=========================================================
00364    double TrackPntLat;
00365 
00366    //=========================================================
00370    double TrackPntLon;
00371 
00372    //=========================================================
00376    double TrackPntAlt;
00377 
00378 
00379 };
00380 
00381 #endif // #if !defined(_CIGI_BASE_SENSOR_RESP_INCLUDED_)

Generated on Wed Apr 29 08:59:55 2009 for CCL by  doxygen 1.4.7