* Z:\home\khalils\Downloads\files\data\raw_asc\c4c4e8714c93_2range_curr_2.asc
* Generated by LTspice 26.0.1 for Windows.
* 5mA=2V50
* 2A=2V50
* 4V7
* h_lev=3V3
* l_satur.
* h_satur.
* Library below included based on ModelFile attribute of instance XU1, XU2, XU3, XU4, XU6, XU5 (C:\users\khalils\AppData\Local\LTspice\lib\sym\OpAmps\LT1022A.asy)
* Library below included based on ModelFile attribute of instance XU7, XU8, XU9 (C:\users\khalils\AppData\Local\LTspice\lib\sym\References\LT1004-2.5.asy)
R18 N010 N013 2K2
V1 Vcc 0 15.0V
XU6 0 N001 Vcc Vee N003 LT1022 ;pnba In+)In-)V+)V-)OUT
R3 N002 N006 4K7
C2 +Curr_in N002 10n
R17 0 HIGH_range 4K7
XU5 N018 ADC_highR Vcc Vee N017 LT1022 ;pnba In+)In-)V+)V-)OUT
R13 Vcc +2.5 2K7
XU4 N008 ADC_lowR Vcc Vee N007 LT1022 ;pnba In+)In-)V+)V-)OUT
XU1 0 +Curr_in Vcc Vee N002 LT1022 ;pnba In+)In-)V+)V-)OUT
V2 0 Vee 15.0V
D6 0 ADC_highR BAT54
R7 N015 N014 62K
XU9 N004 -5 LT1004-2.5 ;pnba VOUT)GND
R6 N014 -Curr_out 1K0
R1 0 -Curr_out 0.02R
XU2 0 N014 Vcc Vee N016 LT1022 ;pnba In+)In-)V+)V-)OUT
R11 N001 N002 20K0
Q2 0 N011 N013 0 BC807-25
C6 N016 N014 10p
C3 N017 ADC_highR 33p
Q1 Vcc N011 N013 0 BC817-25
R2 +Curr_in N002 1K0
D3 ADC_lowR N007 NSCW100
XU8 0 N004 LT1004-2.5 ;pnba VOUT)GND
R4 N012 N013 22R
R14 -5 N009 22K
C5 N007 ADC_lowR 33p
D1 N006 N005 1N4148
R5 N005 N011 2K2
D2 ADC_highR N017 NSCW100
R9 ADC_highR N016 2K2
XU7 +2.5 0 LT1004-2.5 ;pnba VOUT)GND
R19 N008 +2.5 22K
D4 0 N010 1N750
D5 0 ADC_lowR BAT54
R15 Vee -5 2k2
C1 N003 N001 100p
R16 HIGH_range N010 1K8
R8 ADC_lowR N003 2K2
XU3 N009 N006 Vcc Vee N005 LT1022 ;pnba In+)In-)V+)V-)OUT
M1 +Curr_in N012 0 0 IRF6609
R12 ADC_lowR N001 10K0
R10 ADC_highR N015 510R0
R20 +2.5 N018 22K
.model D D
.lib C:\users\khalils\AppData\Local\LTspice\lib\cmp\standard.dio
.model NPN NPN
.model PNP PNP
.lib C:\users\khalils\AppData\Local\LTspice\lib\cmp\standard.bjt
.model NMOS NMOS
.model PMOS PMOS
.lib C:\users\khalils\AppData\Local\LTspice\lib\cmp\standard.mos
.lib LTC.lib
.lib LTC3.lib
.backanno
.end

* LTspice schematic (.asc):
Version 4
SHEET 1 1456 828
WIRE 304 -240 272 -240
WIRE 544 -240 384 -240
WIRE 896 -240 896 -256
WIRE 992 -240 896 -240
WIRE 1088 -240 1072 -240
WIRE -272 -224 -352 -224
WIRE -64 -224 -272 -224
WIRE 896 -224 896 -240
WIRE -352 -208 -352 -224
WIRE -272 -208 -272 -224
WIRE 624 -208 624 -224
WIRE 656 -208 624 -208
WIRE 752 -208 736 -208
WIRE -64 -176 -64 -224
WIRE 144 -176 -64 -176
WIRE 160 -176 144 -176
WIRE 272 -176 272 -240
WIRE 272 -176 240 -176
WIRE 352 -176 272 -176
WIRE 432 -176 416 -176
WIRE 624 -144 624 -208
WIRE 896 -144 896 -160
WIRE 144 -128 144 -176
WIRE -640 -112 -640 -128
WIRE -576 -112 -640 -112
WIRE -512 -112 -512 -128
WIRE -512 -112 -576 -112
WIRE 272 -112 272 -176
WIRE 304 -112 272 -112
WIRE -576 -96 -576 -112
WIRE -352 -96 -352 -128
WIRE -272 -96 -272 -144
WIRE -272 -96 -352 -96
WIRE -240 -96 -272 -96
WIRE 432 -96 432 -176
WIRE 432 -96 368 -96
WIRE 448 -96 432 -96
WIRE 544 -96 544 -240
WIRE 544 -96 528 -96
WIRE -64 -80 -64 -176
WIRE -64 -80 -176 -80
WIRE 304 -80 272 -80
WIRE -240 -64 -304 -64
WIRE 624 -64 624 -80
WIRE 896 -64 896 -80
WIRE 272 -48 272 -80
WIRE 32 -16 -16 -16
WIRE 144 -16 144 -48
WIRE 144 -16 96 -16
WIRE 544 0 544 -96
WIRE 720 0 544 0
WIRE 784 0 720 0
WIRE 1072 0 784 0
WIRE 1120 0 1072 0
WIRE -16 16 -16 -16
WIRE -16 16 -64 16
WIRE 720 16 720 0
WIRE 784 16 784 0
WIRE 1072 16 1072 0
WIRE -64 32 -64 16
WIRE -384 64 -608 64
WIRE 544 80 544 0
WIRE 576 80 544 80
WIRE -160 96 -160 80
WIRE 144 96 144 -16
WIRE 144 96 112 96
WIRE 720 96 720 80
WIRE 720 96 640 96
WIRE 784 96 784 80
WIRE 784 96 720 96
WIRE 1072 96 1072 80
WIRE -384 112 -384 64
WIRE -352 112 -352 -96
WIRE -352 112 -384 112
WIRE -16 112 -16 16
WIRE 48 112 -16 112
WIRE 448 112 384 112
WIRE 576 112 528 112
WIRE 144 128 112 128
WIRE 240 128 224 128
WIRE 912 128 800 128
WIRE 944 128 912 128
WIRE 1072 128 1024 128
WIRE 1104 128 1072 128
WIRE -384 144 -384 112
WIRE -64 144 -64 112
WIRE -64 144 -96 144
WIRE 912 160 912 128
WIRE 1072 160 1072 128
WIRE -272 224 -336 224
WIRE -160 224 -160 192
WIRE -160 224 -192 224
WIRE -16 224 -160 224
WIRE 800 224 800 128
WIRE 800 224 64 224
WIRE 912 240 912 224
WIRE -160 256 -160 224
WIRE 1072 256 1072 240
WIRE -384 272 -384 240
WIRE -384 272 -496 272
WIRE -304 272 -304 -64
WIRE -304 272 -384 272
WIRE -384 304 -384 272
WIRE -288 304 -384 304
WIRE -64 304 -64 144
WIRE -64 304 -96 304
WIRE 112 304 80 304
WIRE 288 304 192 304
WIRE 464 304 368 304
WIRE 720 304 464 304
WIRE 912 304 720 304
WIRE 960 304 912 304
WIRE 1104 304 960 304
WIRE 1120 304 1104 304
WIRE 912 320 912 304
WIRE 960 320 960 304
WIRE -496 336 -496 272
WIRE 80 352 80 304
WIRE 208 352 80 352
WIRE 288 352 272 352
WIRE 1104 352 1104 304
WIRE -336 384 -384 384
WIRE -160 384 -160 352
WIRE 720 384 720 304
WIRE 768 384 720 384
WIRE 912 400 912 384
WIRE 912 400 832 400
WIRE 960 400 960 384
WIRE 960 400 912 400
WIRE -384 416 -384 384
WIRE -384 416 -608 416
WIRE -336 416 -336 384
WIRE -32 416 -336 416
WIRE 80 416 80 352
WIRE 80 416 48 416
WIRE 112 416 80 416
WIRE 624 416 592 416
WIRE 768 416 704 416
WIRE 288 432 288 352
WIRE 288 432 176 432
WIRE 336 432 288 432
WIRE 464 432 464 304
WIRE 464 432 416 432
WIRE 1104 432 1104 416
WIRE -288 448 -288 304
WIRE 112 448 -288 448
IOPIN 1120 0 Out
IOPIN 1120 304 Out
IOPIN 1104 128 Out
IOPIN -608 64 In
IOPIN -608 416 In
LINE Normal -544 128 -704 128 2
LINE Normal -544 320 -544 128 2
LINE Normal -544 368 -544 320 2
LINE Normal -704 368 -544 368 2
LINE Normal -672 352 -704 368 2
LINE Normal -672 384 -704 368 2
SYMBOL cap 272 336 R90
WINDOW 0 0 32 VBottom 2
WINDOW 3 32 32 VTop 2
SYMATTR InstName C6
SYMATTR Value 10p
SYMBOL res 208 288 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R7
SYMATTR Value 62K
SYMBOL References\\LT1004-2.5 896 -112 M180
WINDOW 3 30 -32 Left 2
WINDOW 0 16 32 Left 2
SYMATTR InstName U8
SYMBOL nmos -336 144 M0
SYMATTR InstName M1
SYMATTR Value IRF6609
SYMBOL schottky 1056 80 M180
WINDOW 0 24 64 Left 2
WINDOW 3 24 0 Left 2
SYMATTR InstName D5
SYMATTR Value BAT54
SYMATTR Description Diode
SYMATTR Type diode
SYMBOL voltage -640 -224 R0
WINDOW 123 0 0 Left 2
WINDOW 39 0 0 Left 2
SYMATTR InstName V1
SYMATTR Value 15.0V
SYMBOL res 256 -192 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R11
SYMATTR Value 20K0
SYMBOL res 1088 256 R180
WINDOW 0 36 76 Left 2
WINDOW 3 36 40 Left 2
SYMATTR InstName R17
SYMATTR Value 4K7
SYMBOL res 544 96 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R19
SYMATTR Value 22K
SYMBOL res -288 208 M90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R4
SYMATTR Value 22R
SYMBOL res 240 112 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R14
SYMATTR Value 22K
SYMBOL res 64 400 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R6
SYMATTR Value 1K0
SYMBOL res 128 -144 R0
SYMATTR InstName R3
SYMATTR Value 4K7
SYMBOL Opamps\\LT1022A -208 -144 R0
SYMATTR InstName U1
SYMBOL res 608 432 R270
WINDOW 0 32 56 VTop 2
WINDOW 3 0 56 VBottom 2
SYMATTR InstName R20
SYMATTR Value 22K
SYMBOL References\\LT1004-2.5 624 -112 R0
WINDOW 3 79 4 Left 2
WINDOW 0 28 2 Left 2
SYMATTR InstName U7
SYMBOL res -336 -112 R180
WINDOW 0 36 76 Left 2
WINDOW 3 36 40 Left 2
SYMATTR InstName R2
SYMATTR Value 1K0
SYMBOL zener 928 224 R180
WINDOW 0 24 64 Left 2
WINDOW 3 24 0 Left 2
SYMATTR InstName D4
SYMATTR Value 1N750
SYMATTR Description Diode
SYMATTR Type diode
SYMBOL Opamps\\LT1022A 608 32 R0
SYMATTR InstName U4
SYMBOL npn -96 96 M0
WINDOW 0 35 30 Left 2
WINDOW 3 39 56 Left 2
SYMATTR InstName Q1
SYMATTR Value BC817-25
SYMBOL res 384 288 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R10
SYMATTR Value 510R0
SYMBOL res 432 416 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R9
SYMATTR Value 2K2
SYMBOL res -48 16 M0
SYMATTR InstName R5
SYMATTR Value 2K2
SYMBOL cap 736 80 R180
WINDOW 0 24 56 Left 2
WINDOW 3 24 8 Left 2
SYMATTR InstName C5
SYMATTR Value 33p
SYMBOL res 544 -112 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R8
SYMATTR Value 2K2
SYMBOL Opamps\\LT1022A 80 48 M0
SYMATTR InstName U3
SYMBOL diode 96 -32 R90
WINDOW 0 0 32 VBottom 2
WINDOW 3 32 32 VTop 2
SYMATTR InstName D1
SYMATTR Value 1N4148
SYMBOL Opamps\\LT1022A 144 368 R0
SYMATTR InstName U2
SYMBOL Opamps\\LT1022A 800 336 R0
SYMATTR InstName U5
SYMBOL cap 416 -192 R90
WINDOW 0 0 32 VBottom 2
WINDOW 3 32 32 VTop 2
SYMATTR InstName C1
SYMATTR Value 100p
SYMBOL LED 768 16 R0
SYMATTR InstName D3
SYMATTR Value NSCW100
SYMATTR Description Diode
SYMATTR Type diode
SYMBOL pnp -96 352 R180
WINDOW 0 41 27 Left 2
WINDOW 3 30 55 Left 2
SYMATTR InstName Q2
SYMATTR Value BC807-25
SYMBOL res 400 -256 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R12
SYMATTR Value 10K0
SYMBOL cap 928 384 R180
WINDOW 0 24 56 Left 2
WINDOW 3 24 8 Left 2
SYMATTR InstName C3
SYMATTR Value 33p
SYMBOL voltage -512 -112 M180
WINDOW 0 24 96 Left 2
WINDOW 3 24 16 Left 2
WINDOW 123 0 0 Left 2
WINDOW 39 0 0 Left 2
SYMATTR InstName V2
SYMATTR Value 15.0V
SYMBOL Opamps\\LT1022A 336 -160 R0
SYMATTR InstName U6
SYMBOL schottky 1088 416 M180
WINDOW 0 24 64 Left 2
WINDOW 3 24 0 Left 2
SYMATTR InstName D6
SYMATTR Value BAT54
SYMATTR Description Diode
SYMATTR Type diode
SYMBOL res 1040 112 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R16
SYMATTR Value 1K8
SYMBOL LED 944 320 R0
SYMATTR InstName D2
SYMATTR Value NSCW100
SYMATTR Description Diode
SYMATTR Type diode
SYMBOL References\\LT1004-2.5 896 -192 M180
WINDOW 3 30 -32 Left 2
WINDOW 0 16 32 Left 2
SYMATTR InstName U9
SYMBOL cap -256 -144 R180
WINDOW 0 24 56 Left 2
WINDOW 3 24 8 Left 2
SYMATTR InstName C2
SYMATTR Value 10n
SYMBOL res -368 288 M0
SYMATTR InstName R1
SYMATTR Value 0.02R
SYMBOL res 1088 -256 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R15
SYMATTR Value 2k2
SYMBOL res 752 -224 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R13
SYMATTR Value 2K7
SYMBOL res 80 208 R90
WINDOW 0 0 56 VBottom 2
WINDOW 3 32 56 VTop 2
SYMATTR InstName R18
SYMATTR Value 2K2
FLAG -576 -96 0
FLAG -640 -208 Vcc
FLAG 144 400 Vcc
FLAG -512 -208 Vee
FLAG 144 464 Vee
FLAG -208 -112 Vcc
FLAG -208 -48 Vee
FLAG -160 384 0
FLAG -160 80 Vcc
FLAG 80 80 Vcc
FLAG 80 144 Vee
FLAG 752 -208 Vcc
FLAG 608 128 Vee
FLAG 336 -128 Vcc
FLAG 336 -64 Vee
FLAG 272 -48 0
FLAG 1120 0 ADC_lowR
FLAG 1120 304 ADC_highR
FLAG 1104 128 HIGH_range
FLAG 912 240 0
FLAG 1072 256 0
FLAG -496 336 0
FLAG 800 368 Vcc
FLAG 800 432 Vee
FLAG 384 112 +2.5
FLAG 608 64 Vcc
FLAG 624 -224 +2.5
FLAG 624 -64 0
FLAG -608 64 +Curr_in
FLAG -608 416 -Curr_out
FLAG 1072 96 0
FLAG 1104 432 0
FLAG 592 416 +2.5
FLAG 896 -64 0
FLAG 1088 -240 Vee
FLAG 896 -256 -5
FLAG 240 128 -5
TEXT 1168 32 Left 2 ;5mA=2V50
TEXT 1200 336 Left 2 ;2A=2V50
TEXT 832 192 Left 2 ;4V7
TEXT 1176 160 Left 2 ;h_lev=3V3
TEXT 864 48 Left 2 ;l_satur.
TEXT 968 424 Left 2 ;h_satur.