'**************************************************************************** 'Module PT2025 'This module contains subroutines to read the PT2025 NMR teslameter. ' 'The following parameters are required in param.inc. ' gpibinP%, the GPIB input file number ' gpiboutP%, the GPIB output file number ' pt2025addrP%, the GPIB address of the PT2025 NMR teslameter ' 'Zachary Wolf '6/12/94 '**************************************************************************** REM $INCLUDE: 'param.inc' SUB pt2025getb (b!) '**************************************************************************** 'PT2025GETB 'This subroutine has the PT2025 NMR teslameter measure the magnetic field. ' 'Output: ' b!, the measured magnetic field strength in Tesla ' 'Input from param.inc: ' gpibinP%, the GPIB input file number ' gpiboutP%, the GPIB output file number ' pt2025addrP%, the GPIB address of the teslameter ' 'Zachary Wolf '6/12/94 '**************************************************************************** STATIC ncall% ncall% = ncall% + 1 ns% = ncall% - 1 IF ns% < 5 THEN b! = ns% * .2 ELSEIF ns% >= 5 AND ns% <= nzstepsP% - 5 THEN b! = 1! ELSE b! = (nzstepsP% - ns%) * .2 END IF IF b! <= 0 THEN b! = .0000001 ndial% = nmotorstepstotP& / nzstepsP% ztot! = (nzstepsP% * lleadscrewP! * ndial%) / nmotorstepstotP& 'Message PRINT "Pt2025getb: the integrated field strength is 0.95*Ztot Tm" PRINT " = "; .95 * ztot!; " Tm" END SUB SUB pt2025init '**************************************************************************** 'PT2025INIT 'This subroutine initializes the Metrolab PT2025 NMR teslameter. ' 'Input from param.inc: ' gpibinP%, the GPIB input file number ' gpiboutP%, the GPIB output file number ' pt2025addrP%, the GPIB address of the teslameter ' 'Zachary Wolf '6/14/94 '**************************************************************************** 'Message PRINT PRINT "Resetting the Metrolab PT2025 NMR teslameter routine." END SUB SUB pt2025search END SUB SUB pt2025setpar (gpibinP%, gpiboutP%, pt2025addrP$) END SUB