Keithley 2100 User Manual page 148

6 1/2-digit resolution digital multimeter
Hide thumbs Also See for 2100:
Table of Contents

Advertisement

Appendix B: Remote Interface Reference
NOTE
The DEVQUERY function.
// devquery.cpp : Defines the entry point for the console application.
//
//
Call the NI-VISA library visa32.dll
//
//
#include "stdafx.h"
#include "visa.h"
//standard include for a Microsoft Visual C++ project
#include "stdio.h"
#include "windows.h"
void main(int argc, char* argv[])
{
// TODO: Add your control notification handler code here
HINSTANCE hUSBTMCLIB;
unsigned long m_defaultRM_usbtmc, m_instr_usbtmc;
unsigned long m_findList_usbtmc;
unsigned long m_nCount;
ViStatus
int
char
BYTE
int
ULONG
ULONG
char
char
// Load the NI-VISA library for USBTMC device
hUSBTMCLIB = LoadLibrary ("visa32.dll");
if (!hUSBTMCLIB)
{
MessageBox(NULL, "NIVISA for USBTMC library not found.", "2100 multimeter
device test", MB_OK);
return;
}
// Link the libraries
signed long (__stdcall
signed long (__stdcall
unsigned long *vi, unsigned long *retCnt, char far desc[]);
signed long (__stdcall
unsigned long mode, unsigned long timeout, unsigned long *vi);
signed long (__stdcall
signed long (__stdcall
unsigned long len, unsigned long *retval);
signed long (__stdcall
unsigned long len, unsigned long *retval);
signed long (__stdcall
viAttr, unsigned long attrstat);
B-36
This example depends on the presence of VISA include files. These files are available by
downloading this example from www.keithley.com or by installing the full development
version of VISA.
status;
m_Timeout = 7000;
*pStrout;
pStrin[64];
len;
nWritten;
nRead = 0;
buffer[256];
instrDescriptor[256];
Return to
Model 2100 6 1/2-Digit Resolution Digital Multimeter User's Manual
// for USBTMC HANDLE
// Write out data buffer
// Read in data buffer
*PviOpenDefaultRM_usb)(unsigned long *vi);
*PviFindRsrc_usb)(unsigned long sesn, char *expr,
*PviOpen_usb)(unsigned long sesn, char *name,
*PviClose_usb)(unsigned long vi);
*PviWrite_usb)(unsigned long vi, unsigned char *name,
*PviRead_usb)(unsigned long vi, unsigned char *name,
*PviSetAttribute_usb)(unsigned long vi, unsigned long
Section Topics
2100-900-01 Rev. D / September 2011

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents