English
Language : 

LTC2421_15 Datasheet, PDF (26/32 Pages) Linear Technology – 1-/2-Channel 20-Bit Power No Latency ADCs in MSOP-10
LTC2421/LTC2422
APPLICATIO S I FOR ATIO
nummeas = nummeas + c1%
LOCATE 2, 2: PRINT "Scan#="; nummeas; " "; DATE$; " "; TIME$;
OUT mcr%, c0%: 'Initialize SCLK=0
k1 = km: d2400 = 0: chan% = c0%: signneg% = c0%
FOR bita% = 31 TO 0 STEP -1: v31 = 1
148 GOSUB 2200: v31 = v31 + 1
150 IF bita% = 31 THEN GOTO 152 ELSE 156
152 IF dfrm% = c0% THEN GOTO 156
155 IF v31 > 2 THEN LOCATE 16, 16: OUT port, c0%: PRINT "waiting for eoc":
IF v31 < 20000 THEN IF dfrm% = c1% THEN GOTO 148
IF dfrm% = 1 THEN LOCATE 17, 16: PRINT "Timed out on EOC,not fatal"
FOR bs = 1 TO 32: ' never got an eoc => clock it 32 times
GOSUB 2000: NEXT bs: GOTO 1800
156 LOCATE 16, 16: PRINT"
": GOSUB 2000
IF bita% = 30 THEN 161 ELSE 171 ' CHANNEL BIT !!!!!!!!!!!!!!!
161 IF dfrm% = c1% THEN chan% = c1%: ch1% = c0%
IF dfrm% = c0% THEN chan% = c0%: ch1% = ch1% + c1%
IF ch1% > c4% THEN GOSUB 3700: ch1% = c1%
171 IF bita% = 29 THEN IF dfrm% = c0% THEN signneg% = c1%: ' NEG
IF bita% <= 28 THEN d2400 = d2400 + (dfrm% * k1): k1 = k1 / c2%
NEXT bita%: k1 = 1: digin% = c0%: 'MATH BELOW
1600 PPM = (d2400 / km) * kn: rw% = 6: hz% = (chan% * 20) + 1
IF signneg% = c1% THEN 1700 ELSE 1705
1700 IF d2400 <> c0% THEN PPM = (PPM - 2000000)
1705 LOCATE rw%, hz%: PRINT PPM; " "; : LOCATE rw%, hz% + 11:
PRINT "PPM";
LOCATE rw% + 1, (chan% * 20) + 1: GOSUB 3800: 'THIS WORKS!
1800 LOOP WHILE INKEY$ = "": REM Works with "DO"
GOTO 5000 ’rem END!!-------------- Subs follow !!----------------!!!
1900 ’ESSENTIAL INITIALIZATIONS
REM set some constants, since they can be accessed much faster
LET c128% = 128: c64% = 64: c32% = 32: c16% = 16: c8% = 8: c4% = 4
LET c3% = 3: c2% = 2: c1% = 1: c0% = 0: km = (2 ^ 30) - 1: kn = 1000000
IF cport = 2 THEN OPEN "COM2:300,N,8,1,CD0,CS0,DS0,OP0,RS" FOR
RANDOM AS #1: port = (&H2F8)
IF cport = 1 THEN OPEN "COM1:300,N,8,1,CD0,CS0,DS0,OP0,RS" FOR
RANDOM AS #1: port = (&H3F8)
LOCATE 5, 21: PRINT "CHANNEL 1": LOCATE 5, 2: PRINT "CHANNEL 0"
FOR n% = port TO port + 7: OUT n%, 0: NEXT n%: ’Init UART regs
CLOSE #1: DEF SEG = 0: RETURN ’--------------------------------------
2000 ’SUB read MSR AND RETURN data dfrm% INTERFACE
x3% = INP(msr%) AND c16%: OUT mcr%, c1%
GOSUB 3000: OUT mcr%, c0%
2040 IF x3% = c16% THEN dfrm% = c1% ELSE dfrm% = c0%
OUT mcr%, c0%: RETURN ’---------------------------------------------
2200 ’SUB READ THE DATA BIT dfrm% does NOT change sclock
x3% = INP(msr%) AND C16%: GOTO 2040: RETURN’----------------
3000 REM delay sub !!!!!!!!!!
FOR n8% = 0 TO 1: OUT port, c0%: NEXT n8%: RETURN: ’----------
3700 FOR n = 6 TO 9: LOCATE n, 20
PRINT "
": NEXT n: RETURN’---------------------------
3800 ’SUB to convert PPM into Volts and print it
v = PPM * (5 / 1000000): v1 = v * 1000000: hz% = (chan% * 20) + 12
IF v <= .1 THEN PRINT v1; " "; : LOCATE rw% + 1, hz%: PRINT "uV "
IF v > .1 THEN PRINT v; " "; : LOCATE rw% + 1, hz%: PRINT "Volts";
RETURN’----------------------------------------------------------------
4970 PRINT "ERROR !!!!!!!!!!!!!!!"
5000 PRINT : LOCATE 18, 1: PRINT "Ending!!": PRINT "Hit any key to exit."
PRINT "Start ="; timestart$; " End = "; TIME$; " # samples ="; nummeas
CLOSE #1: END
Single Ended Half-Bridge Digitizer
with Reference and Ground Sensing
Sensors convert real world phenomena (temperature, pres-
sure, gas levels, etc.) into a voltage. Typically, this voltage
is generated by passing an excitation current through the
sensor. The wires connecting the sensor to the ADC form
parasitic resistors RP1 and RP2. The excitation current also
flows through parasitic resistors RP1 and RP2, as shown in
Figure 29. The voltage drop across these parasitic resis-
tors leads to systematic offset and full-scale errors.
In order to eliminate the errors associated with these para-
sitic resistors, the LTC2421/LTC2422 include a full-scale
set input (FSSET) and a zero-scale set input
(ZSSET). As shown in Figure 30, the FSSET pin acts as a
zero current full-scale sense input. Errors due to parasitic
24212f
26