|
©National Instruments CorporationB-1SCXI-1102/B/C User ManualAppendixBCalibration Sample ProgramThis appendix contains a sample program to help you calibrate yoursubmodule.Sample Program for CalibrationThe following is a sample C program that implements the procedurediscussed in the Gain and Offset Calibration section andSCXI_Cal_Constants in Chapter 5, Calibration:/* This sample program assists the user in calibrating the SCXI-1102. Thecalibration constants are stored only in NI-DAQ memory. The (input, output)voltage pairs read by a DMM must be entered by hand. Before running thisprogramed must run the NI-DAQ Configuration Utility to set up the DAQ boardthat will communicate with the SCXI-1102.This program is written for the four-slot SCXI-1000 chassis. The programprompts for all required configuration information about the SCXI chassis. */#include #include #define SCXI1102 30 /* the SCXI-1102 module ID */#define TWOPOINT 2#define NIDAQMEM 0void main(){char entry[4];int SCXI_Chassis_ID,moduleSlot, /* chassis slot of moduleto calibrate */moduleChan;long modulesPresent[] = {-1, -1, -1, -1};short operatingModes[] = {0, 0, 0, 0},connectionMap[] = {0, 0, 0, 0},commPath, /* DAQ board that communicates withSCXI chassis */dummyRangeCode = 0,dummyDAQboard,dummyDAQchan = 0,dummyDAQgain = 1,
PreviousNext |