logo2.bmp (22582 bytes)

 

Low Cost Automated Testing

Home

FT-100a Functional Tester

Custom-Designed Test Systems

Feedback

Application Note #:  AN-0100-09

Subject:   Data Acquisition with EXTECH Digital Multi-Meter
Date Issued:   January, 1996
Product(s):   FT-100, FT-100a

 

The EXTECH Model 383273 Digital Multi-meter has a built-in RS-232 interface, and can easily communicate with the FT-100. The meter is relatively inexpensive (less than $200), and provides several data monitoring functions that can expand the capabilities of the FT-100. In addition to the typical DMM features, there are also several optional probes that allow the monitoring of several other types of inputs, such as: humidity, light intensity, wind speed, etc. Although the meter was originally designed to interface with a PC, this application note describes the hardware and software necessary for interfacing with the FT-100.

The EXTECH 383273 is a 3 1/2 digit digital multi-meter with the following measurement capabilities:

- Voltage (AC & DC)
- Current (AC & DC)
- Resistance
- Capacitance
- Frequency
- Diode and Continuity
- Temperature

The meter has its own RS-232 interconnect cable; however, to interface with the FT-100, this cable must be altered. The schematic below shows the necessary cable interconnections:

extech1.gif (1852 bytes)

The EXTECH meter always requires a "high" on pin 4 (DTR) to send data. The above cable connects this line to pin 9 from the FT-100. Pin 9 is one of the two lines used for serial port selection in the 1041 Serial Port Expander. Because of this, the meter must be addressed as either port #2 or #4.  Note: The 1041 does not have a "select" voltage on pin 9. If you need to interface with the meter through a 1041, please contact the factory.

The program shown can be used to receive all types of readings from the meter. Since most applications would not require all the functions of the meter, you may omit the program lines that are not necessary for your particular function. In particular, unused "IF" statements used for function selection, may be omitted.

HOW THE PROGRAM WORKS

The meter will immediately send 5 bytes of data whenever it receives a "space" character. The first byte is always 02, and the last byte is always 03. These framing bytes are used to determine proper communications. The third byte is the function and range byte, and is used in the program to select the proper "units" and "multiplier". The third and fourth bytes contain the actual reading. This information is embedded within the bits of these numbers, so the program extracts the data from the bytes. The multiplier is used to scale the meter reading to the basic units for each type of reading (for example, capacitance is scaled to farads). The variable "VALUE" is the final value for the reading, in the basic units.

The program reads in the 5 bytes and stores them as string variables. Because these bytes can be any value from 00 to 0FFH, and therefore cannot always be represented as ASCII text, we must extract the actual value from the string variable table. In order to know exactly where in the table each string variable is located, it is very important that the first reference to string variables folllows the order: A$, B$, C$, D$, E$. To simplify this requirement, you could place the following command at the beginning of your program:

A$="": B$="": C$="": D$="": E$=""

This will insure the placement of the string variables within the table.

Although somewhat lengthy, this program is relatively simple, and you should have very little trouble following the flow and adapting it to your particular situation. If you have any trouble, or have a unique interface situation, please contact the factory. There is always an application engineer ready to assist.

EXTECH                 'Program Name
'
     COM 9600,,,,0,,0          'Set baud to 9600 & disable Direct Command Mode & Echo
L0:  ? @2;" ";:DELAY 10       'Send "space" character to meter, & wait 10ms for return
     GET @2;A$,B$,C$,D$,E$    'Read 5 bytes from meter
     IF A$<>CHR$ 2 OR E$<>CHR$ 3 THEN GOTO L1        'Test framing bytes
     CLS
'
'------ Extract readings from STRING VARIABLE table ------
     PTR=PEEK 59+(PEEK 60*256)+((PEEK 61+(PEEK 62*256))*16)-4
     FUNCT=(PEEK PTR AND 1)*0FFH AND (PEEK (PTR-1))      'Extract Function byte
     PTR=PTR-2:IF FUNCT<>0 THEN DEC PTR
     VAL1=(PEEK PTR AND 1)*0FFH AND (PEEK (PTR-1))       'Extract #1 Data byte
     PTR=PTR-2:IF VAL1<>0 THEN DEC PTR
     VAL2=(PEEK PTR AND 1)*0FFH AND (PEEK (PTR-1))       'Extract #2 Data byte
'
'------ Test for invalid or overload readings ------
     IF (VAL1 AND 1FH)=3FH THEN CLS:GOTO L0
     IF (VAL1 AND 1FH)=0FH THEN CLS:CURSOR 2,5:DISP "+ OVERLOAD":GOTO L1
     IF (VAL1 AND 1FH)=0EH THEN CLS:CURSOR 2,5:DISP "- OVERLOAD":GOTO L1
'
'------ Determine Function and Value Multiplier of Meter Setting------
     IF FUNCT=0 THEN F$="V DC":M=0.0001                 '200mv DC scale
     IF FUNCT=1 THEN F$="V DC":M=0.001                  '2v DC scale
     IF FUNCT=2 THEN F$="V DC":M=0.01                   '20v DC scale
     IF FUNCT=3 THEN F$="V DC":M=0.1                    '200v DC scale
     IF FUNCT=4 THEN F$="V DC":M=1                      '1000v DC scale
     IF FUNCT=5 THEN F$="Hz":M=1                        'Frequency
     IF FUNCT=6 THEN F$="V DC <CONT/DIODE>":M=0.001     'Diode/Continuity scale
     IF FUNCT=8 THEN F$="Ohms":M=0.1                    '200 W Resistance scale
     IF FUNCT=9 THEN F$="Ohms":M=1                      '2K W Resistance scale
     IF FUNCT=10 THEN F$="Ohms":M=10                    '20K W Resistance
     IF FUNCT=12 THEN F$="Ohms":M=100                   '200K W Resistance
     IF FUNCT=16 THEN F$="Ohms":M=1000                  '2M W Resistance scale
     IF FUNCT=17 THEN F$="Ohms":M=10000                 '20M W Resistance scale
     IF FUNCT=18 THEN F$="CAP (F)":M=1E-8               '20 F Capacitance scale
     IF FUNCT=20 THEN F$="CAP (F)":M=1E-9               '2 F Capacitance scale
     IF FUNCT=24 THEN F$="CAP (F)":M=1E-10              '200nF Capacitance scale
     IF FUNCT=32 THEN F$="CAP (F)":M=1E-12              '2000pF Capacitance scale
     IF FUNCT=33 THEN F$="A DC":M=0.01                  '20 Amp DC scale
     IF FUNCT=34 THEN F$="A DC":M=0.0001                '200 mA DC scale
     IF FUNCT=36 THEN F$="A DC":M=1E-5                  '20 mA DC scale
     IF FUNCT=40 THEN F$="A DC":M=1E-6                  '2 mA DC scale
     IF FUNCT=48 THEN F$="A DC":M=1E-7                  '200 A DC scale
     IF FUNCT=64 THEN F$="DEG F":M=0.1                  'Temperature 200E F
     IF FUNCT=65 THEN F$="DEG F":M=1                    'Temperature 2000E F
     IF FUNCT=66 THEN F$="DEG C":M=0.1                  'Temperature 200E C
     IF FUNCT=68 THEN F$="DEG C":M=1                    'Temperature 2000E C
     IF FUNCT=128 THEN F$="V AC":M=0.0001               '200mv AC scale
     IF FUNCT=129 THEN F$="V AC":M=0.001                '2v AC scale
     IF FUNCT=130 THEN F$="V AC":M=0.01                 '20v AC scale
     IF FUNCT=131 THEN F$="V AC":M=0.1                  '200v AC scale
     IF FUNCT=132 THEN F$="V AC":M=1                    '750v AC scale
     IF FUNCT=161 THEN F$="A AC":M=0.01                 '20 Amp AC scale
     IF FUNCT=162 THEN F$="A AC":M=0.0001               '200 mA AC scale
     IF FUNCT=164 THEN F$="A AC":M=1E-5                 '20 mA AC scale
     IF FUNCT=168 THEN F$="A AC":M=1E-6                 '2 mA AC scale
     IF FUNCT=176 THEN F$="A AC":M=1E-7                 '200 A AC scale
     IF FUNCT=255 THEN F$="*** HOLD ***"         'HOLD reading (HOLD button is pressed)
'
     POL=1-(1-(VAL1 AND 1))*2                                'Polarity
     IF FUNCT=5 THEN POL=1:IF (VAL1 AND 1)=1 THEN M=1E4      'Frequency Range
'
'--- Extract meter reading from data bytes ---
     NUM=(VAL2 AND 3CH)/4:CALL XPOSE:VALUE=Q              'LSD of result
     NUM=(VAL2 AND 3)*4+(VAL1 AND 0C0H)/64:CALL XPOSE
     VALUE=Q*10+VALUE
     NUM=(VAL1 AND 3CH)/4:CALL XPOSE:VALUE=Q*100+VALUE
     VALUE=(VAL1 AND 2)*500+VALUE                         'MSD of result
'
     IF (VAL2 AND 40H)=1 THEN VALUE=VALUE*100             'Decimal position
     IF (VAL2 AND 80H)=1 THEN VALUE=VALUE*10
     VALUE=VALUE*M*POL                      'Scale value to basic units & add polarity
'
     CURSOR 2,1:DISP #D;VALUE;" ";F$        'Display meter reading and units on LCD
'
L1:  DELAY 500:IF FUNCT=5 THEN DELAY 500   'Delay 2 sec. (If frequency, delay 1 sec.)
     GOTO L0
'
'
'******* SUBROUTINE TO TRANSPOSE BITS *******
' Input: NUM = number to transpose
' Output: Q = result
'
XPOSE: Q=0:FOR I=1 TO 4
       SHL Q:Q=Q+(NUM AND 1):SHR NUM
       NEXT:RETURN
/

NOTICE:  Every effort has been made to insure the accuracy of the information contained in this document, however
                   Y-tek is not responsible for any consequences resulting from erroneous or inaccurate information.

go back to Application Notes go to Home Page

 

Home

FT-100a Functional Tester

Custom-Designed Test Systems

Feedback

Y-tek, Inc.    851 Seton Court, Suite 1B, Wheeling, IL 60090        Phone: (847) 436-9835

Y-tek, FT-100 and FT-100a are trademarks of Y-tek, Inc. and may not be reproduced in any way without express
permission from Y-tek, Inc.  Any questions regarding this web site should be directed to
info@Y-tek.com