'**************************************************************************** '* AD8DRV.H '* '* This is the header file for the AD8-16 Windows Driver. '* '* LAST MODIFICATION: AUGUST 24, 1993 '* '****************************************************************************/ ' error_codes returned by the system Global Const AD816_SUCCESS = 0 Global Const CONFIG_CODE = 2 Global Const BASE_ADDRESS = 3 Global Const VOLTAGE_RANGE = 4 Global Const CARD_INACTIVE = 5 Global Const POINT_ERROR = 7 Global Const POINT_INSTALL = 8 Global Const LIST_EMPTY = 9 Global Const LIST_ERROR = 10 Global Const INVALID_CONV = 11 Global Const INVALID_BUFFER = 12 Global Const POINT_UNINSTALL = 13 Global Const ACTIVE_PROCESS = 14 Global Const BUFFER_EMPTY = 15 Global Const INVALID_PTR = 16 Global Const GAIN_ERROR = 17 Global Const UNIT_ERROR = 18 Global Const CHANNEL_ERROR = 20 Global Const INVALID_IRQ = 21 Global Const INVALID_COUNTER = 24 Global Const FREQ_ERROR = 25 Global Const INVALID_MODE = 26 Global Const TIMEOUT = 27 Global Const BATCH_MODE = 28 Global Const IRQ_UNINSTALL = 29 Global Const INVALID_PROCESS = 30 Global Const INPUT_TYPE = 31 Global Const RANGE_ERROR = 32 Global Const DAC_ERROR = 33 Global Const DAC_RANGE = 34 Global Const WINDOWSERROR = 99 ' AD8-16 voltage range constants Global Const UNIPOLAR_255 = 0 Global Const UNIPOLAR_10 = 1 Global Const BIPOLAR_127 = 2 Global Const BIPOLAR_5 = 3 ' Process types Global Const SOFTWARE = 0 Global Const TTIMER = 1 ' Mux type Global Const DIFFERENTIAL = 0 Global Const SINGLE_ENDED = 1 ' dac's Global Const DAC0 = 0 Global Const DAC1 = 1 Declare Function AD816_ClearPointList Lib "c:\AD816s\vbwin\ad8drv.dll" () As Integer Declare Function AD816_AddPoints Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal staddr As Integer, ByVal stopaddr As Integer) As Integer Declare Function AD816_ResetListIndex Lib "c:\AD816s\vbwin\ad8drv.dll" () As Integer Declare Function AD816_FetchPointConfig Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal addr As Integer, low As Single, hi As Single) As Integer Declare Function AD816_DelPtListIndexes Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal stindex As Integer, ByVal stopindex) As Integer Declare Function AD816_GetNextPoint Lib "c:\AD816s\vbwin\ad8drv.dll" (addr As Integer, result As Single) As Integer Declare Function AD816_GetIndexPoint Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal index As Integer, addr As Integer, result As Single) As Integer Declare Function AD816_GetDirectPoint Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal addr As Integer, result As Single) As Integer Declare Function AD816_PollScan Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal scans As Integer, ByVal convs As Integer, ByVal index As Integer) As Integer Declare Function AD816_IRQStatus Lib "c:\AD816s\vbwin\ad8drv.dll" (scan As Integer, conv As Integer) As Integer Declare Function AD816_IRQTerminate Lib "c:\AD816s\vbwin\ad8drv.dll" () As Integer Declare Function AD816_IRQScan Lib "c\AD816s\vbwin\ad8drv.dll" (ByVal scans As Integer, ByVal convs As Integer, ByVal list_index As Integer, ByVal IRQ As Integer, ByVal process_type As Integer, ByVal hWnd As Integer) As Integer Declare Function AD816_PostProcess Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal scans As Integer, ByVal convs As Integer, ByVal index As Integer, buffer As Single) As Integer Declare Function AD816_SetPointConfig Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal staddr As Integer, ByVal stopaddr As Integer, ByVal range As Integer, ByVal low As Single, ByVal hi As Single) As Integer Declare Function AD816_SetSettleTime Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal settle As Integer) As Integer Declare Function AD816_DACOut Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal DAC As Integer, ByVal mode As Single) As Integer Declare Function AD816_DigitalOut Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal value As Integer) As Integer Declare Function AD816_DigitalIn Lib "c:\AD816s\vbwin\ad8drv.dll" (value As Integer) As Integer Declare Function AD816_SetCounter Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal counter As Integer, ByVal mode As Integer, ByVal loadvalue As Integer, ByVal bcd As Integer) As Integer Declare Function AD816_ReadCounter Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal counter As Integer, value As Integer) As Integer Declare Function AD816_DisableCounter Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal counter As Integer, ByVal state As Integer) As Integer Declare Function AD816_RateGenerator Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal counter As Integer, ByVal divisor As Integer, ByVal freq As Single) As Integer Declare Function AD816_MeasureFreq Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal range As Integer, freq As Single) As Integer Declare Function AD816_MeasurePeriod Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal range As Integer, period As Single) As Integer Declare Function AD816_Init Lib "c:\AD816s\vbwin\ad8drv.dll" (ByVal BaseAddr As Integer, ByVal muxtype As Integer) As Integer Declare Function AD816_Shutdown Lib "c:\AD816\vbwin\ad8drv.dll" () As Integer