WPOCT Software Developer's Kit (SDK)
SDK For using Wasatch Photonics OCT Spectrometers
ShutterDevice.h
Go to the documentation of this file.
1 
6 #pragma once
7 
8 #include <atomic>
9 
10 #include "IWPOCTController.h"
11 
14 {
15 public:
17  ShutterDevice();
18  ShutterDevice(int serialNum);
19 
21  virtual ~ShutterDevice();
22 
23  // Events
24 
25  // Getters
26  bool IsOpen (bool* open);
27  int GetSerialNum () const { return _serialNum; }
28 
29  // Setters
30  bool SetSerialNum (int value) { _serialNum = value; return true; }
31 
32  // Shutter commands.
33  bool Open ();
34  bool Close ();
35 
36 private:
37  std::atomic<bool> _isOpen;
38  std::atomic<bool> _usbConnected;
39  int _serialNum;
40  int _errorNum;
41  void* _pUsb;
42 
44  void Init ();
45  bool MoveShutter (int action);
46 
47 };
Interface of the IWPOCTController struct.
Class that controls a Picard Industries USB shutter device.
Definition: ShutterDevice.h:14
virtual ~ShutterDevice()
Destructor.
Definition: ShutterDevice.cpp:25
ShutterDevice()
Constructor.
Definition: ShutterDevice.cpp:12