libapogee  3.0.3234
Public Types | Public Member Functions | Protected Attributes | List of all members
ApogeeFilterWheel Class Reference

class for apogee's usb filter wheel More...

#include <ApogeeFilterWheel.h>

Public Types

enum  Type {
  UNKNOWN_TYPE = 0, FW50_9R = 1, FW50_7S = 2, AFW50_10S = 6,
  AFW31_17R = 9
}
 
enum  Status { UNKNOWN_STATUS, NOT_CONNECTED, READY, ACTIVE }
 

Public Member Functions

void Init (const ApogeeFilterWheel::Type type, const std::string &DeviceAddr)
 
void Close ()
 
uint16_t GetVendorId ()
 
uint16_t GetProductId ()
 
uint16_t GetDeviceId ()
 
std::string GetUsbFirmwareRev ()
 
ApogeeFilterWheel::Type GetType ()
 
std::string GetName ()
 
ApogeeFilterWheel::Status GetStatus ()
 
uint16_t GetMaxPositions ()
 
void SetPosition (uint16_t Position)
 
uint16_t GetPosition ()
 

Protected Attributes

std::tr1::shared_ptr
< FilterWheelIo > 
m_Usb
 

Detailed Description

class for apogee's usb filter wheel

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

Copyright(c) 2011 Apogee Imaging Systems, Inc.

Member Enumeration Documentation

Current filter wheel state

Enumerator
UNKNOWN_STATUS 

Error status

NOT_CONNECTED 

Filter wheel is not connected either physically or the ApogeeFilterWheel::Init function has not been called

READY 

Filter wheel is at the desired position

ACTIVE 

Filter wheel is moving to desired postion

Member Function Documentation

void ApogeeFilterWheel::Close ( )

Closes the USB connection to the filter wheel

Exceptions
std::runtime_error
uint16_t ApogeeFilterWheel::GetDeviceId ( )

Returns USB device id

Exceptions
std::runtime_error
uint16_t ApogeeFilterWheel::GetMaxPositions ( )

Returns The maximum number of filter wheel position

Exceptions
std::runtime_error
std::string ApogeeFilterWheel::GetName ( )

Returns Current filter wheel name

Exceptions
std::runtime_error
uint16_t ApogeeFilterWheel::GetPosition ( )

Returns the current filter wheel position

Exceptions
std::runtime_error
uint16_t ApogeeFilterWheel::GetProductId ( )

Returns USB product id

Exceptions
std::runtime_error
ApogeeFilterWheel::Status ApogeeFilterWheel::GetStatus ( )

Returns the current status of the filter wheel

Exceptions
std::runtime_error
ApogeeFilterWheel::Type ApogeeFilterWheel::GetType ( )
inline

Returns Current filter wheel type

std::string ApogeeFilterWheel::GetUsbFirmwareRev ( )

Returns USB firmware version

Exceptions
std::runtime_error
uint16_t ApogeeFilterWheel::GetVendorId ( )

Returns USB vendor id

Exceptions
std::runtime_error
void ApogeeFilterWheel::Init ( const ApogeeFilterWheel::Type  type,
const std::string &  DeviceAddr 
)

Initizes the USB connection from the PC to the filter wheel. The results strings from the FindDeviceUsb::Find() provide the input into this function.

Parameters
[in]Usersupplied ApogeeFilterWheel::Type
[in]DeviceAddrspecifies the address of the filter wheel on the USB buss
Exceptions
std::runtime_error
void ApogeeFilterWheel::SetPosition ( uint16_t  Position)

Sets filter wheel positon

Parameters
[in]PositionDesired position. Valid range is 1 to GetMaxPositions()
Exceptions
std::runtime_error

The documentation for this class was generated from the following file: