00001 /* 00002 * $RCSfile: DIOStreamSubsystem.hpp,v $ 00003 * $Revision: 1.5 $ 00004 * $Date: 2009/11/23 21:37:35 $ 00005 * jEdit:tabSize=4:collapseFolds=1: 00006 * 00007 * class DIOStreamSubsystem declarations 00008 */ 00009 00010 00011 #if ! defined( DIOStreamSubsystem_hpp ) 00012 #define DIOStreamSubsystem_hpp 00013 00014 // {{{ includes 00015 #include <DeviceSubsystem.hpp> 00016 // }}} 00017 00018 namespace AIOUSB { 00019 00020 // {{{ class DIOStreamSubsystem declarations 00021 00022 /* 00023 * class DIOStreamSubsystem represents the digital I/O streaming subsystem of a board 00024 */ 00025 00026 class DIOStreamSubsystem : public DeviceSubsystem { 00027 public: 00028 DIOStreamSubsystem( USBDevice &parent ); 00029 virtual ~DIOStreamSubsystem(); 00030 00031 /* 00032 * properties 00033 */ 00034 00035 virtual std::ostream &print( std::ostream &out ); 00036 00037 /* 00038 * configuration 00039 */ 00040 00041 DIOStreamSubsystem &setStreamingBlockSize( int blockSize ); 00042 double setClock( bool directionRead, double clockHz ); 00043 00044 /* 00045 * operations 00046 */ 00047 00048 DIOStreamSubsystem &open( bool directionRead ); 00049 DIOStreamSubsystem &close(); 00050 UShortArray read( int numSamples ); 00051 int write( const UShortArray &values ); 00052 00053 DIOStreamSubsystem &clearFIFO( int method ) { 00054 parent->clearFIFO( method ); 00055 return *this; 00056 } // clearFIFO() 00057 00058 }; // class DIOStreamSubsystem 00059 00060 // }}} 00061 00062 } // namespace AIOUSB 00063 00064 #endif 00065 00066 00067 /* end of file */