00001
00014 #ifndef ASCENT_INCLUDE_H__
00015 #define ASCENT_INCLUDE_H__
00016
00017 #include "CamGen2Base.h"
00018 #include <string>
00019 #include "ApogeeFilterWheel.h"
00020
00021 class DLL_EXPORT Ascent : public CamGen2Base
00022 {
00023 public:
00025 enum FilterWheelType
00026 {
00028 FW_UNKNOWN_TYPE = 0,
00030 CFW25_6R = 7,
00032 CFW31_8R = 8
00033 };
00034
00035 struct FilterWheelInfo
00036 {
00037 Ascent::FilterWheelType type;
00038 std::string name;
00039 uint16_t maxPositions;
00040 };
00041
00042 Ascent();
00043
00044 void OpenConnection( const std::string & ioType,
00045 const std::string & DeviceAddr,
00046 const uint16_t FirmwareRev,
00047 const uint16_t Id );
00048
00049 virtual ~Ascent();
00050
00056 void FilterWheelOpen( Ascent::FilterWheelType type );
00057
00062 void FilterWheelClose();
00063
00069 void SetFilterWheelPos( uint16_t pos );
00070
00075 uint16_t GetFilterWheelPos();
00076
00081 ApogeeFilterWheel::Status GetFilterWheelStatus();
00082
00086 Ascent::FilterWheelType GetFilterWheelType() { return m_filterWheelType; }
00087
00092 std::string GetFilterWheelName();
00093
00098 uint16_t GetFilterWheelMaxPositions();
00099
00100 void StartExposure( double Duration, bool IsLight );
00101
00102 int32_t GetNumAdChannels();
00103
00104 double GetTempHeatsink();
00105
00106 protected:
00107 Ascent(const std::string & ioType,
00108 const std::string & DeviceAddr);
00109
00110 void FixImgFromCamera( const std::vector<uint16_t> & data,
00111 std::vector<uint16_t> & out, int32_t rows, int32_t cols );
00112
00113 void CreateCamIo(const std::string & ioType,
00114 const std::string & DeviceAddr);
00115
00116 void ExposureAndGetImgRC(uint16_t & r, uint16_t & c);
00117
00118 private:
00119
00120 void CfgCamFromId( uint16_t CameraId );
00121
00122 void VerifyCamId();
00123
00124 void UpdateCfgWithStrDbInfo();
00125
00126 const std::string m_fileName;
00127 Ascent::FilterWheelType m_filterWheelType;
00128
00129
00130
00131
00132 Ascent(const Ascent&);
00133 Ascent& operator=(Ascent&);
00134 };
00135
00136 #endif