* Z:\home\khalils\Downloads\files\data\raw_asc\04ed80853f24_4B3Sw555.asc
* Generated by LTspice 26.0.1 for Windows.
* V=1-((V(N_Q)+.5)+V(N3))+1-u(v(4)-.5) (LtSpice)
r1 ref33 1 5k
r3 8 5 5k
SH 8 3 Q 1 Sout
Bcp2 R 1 V=u(V(ref33,2))
SL 3 1 1 Q Sout
R6_1 6 1 1e8
Sds 1 7 _Q 1 Sdis
r2 5 ref33 5k
r4 8 1 4k
BFfa Q 1 V=.5-u(V(S)+V(_Q))
BfOr _Q 1 V=.9999-((V(Q)+.5)+V(R))+1-u(v(4)-.5)
Bcp1 S 1 V=u(V(6,5))
R2_1 2 1 1e7
R4_1 4 1 1e5
.model Sdis Sw(Ron=10 Roff=1g Vt=.75 Vh=.2)
.model Sout Sw(Ron=5 Roff=1e6 Vt=0 Vh=.4)
.backanno
.end

* LTspice schematic (.asc):
Version 4
SHEET 1 1704 916
WIRE -544 256 -576 256
WIRE -432 256 -464 256
WIRE 144 256 -432 256
WIRE 272 256 224 256
WIRE 320 256 272 256
WIRE 416 256 400 256
WIRE -576 288 -576 256
WIRE -560 288 -576 288
WIRE 272 288 272 256
WIRE -576 320 -576 288
WIRE -480 320 -432 256
WIRE -432 320 -432 256
WIRE 208 352 208 304
WIRE 336 352 336 304
WIRE 336 352 208 352
WIRE 160 368 160 304
WIRE 256 368 160 368
WIRE 384 368 384 304
WIRE 384 368 256 368
WIRE 416 368 416 256
WIRE 416 368 384 368
WIRE 256 432 256 368
WIRE 288 432 256 432
WIRE 384 432 368 432
WIRE -576 448 -576 400
WIRE -560 448 -576 448
WIRE 208 448 208 352
WIRE -576 496 -576 448
WIRE 208 496 208 448
WIRE -368 512 -368 496
WIRE -272 512 -272 496
WIRE -176 512 -176 496
WIRE 352 512 352 480
WIRE 352 512 336 512
WIRE -96 528 -96 448
WIRE 96 528 96 448
WIRE 352 528 352 512
WIRE -480 608 -496 608
WIRE -576 624 -576 576
WIRE -480 624 -480 608
WIRE -480 624 -576 624
WIRE -432 624 -432 400
WIRE -432 624 -480 624
WIRE -368 624 -368 592
WIRE -368 624 -432 624
WIRE -272 624 -272 592
WIRE -272 624 -368 624
WIRE -176 624 -176 592
WIRE -176 624 -272 624
WIRE -96 624 -96 608
WIRE -96 624 -176 624
WIRE 96 624 96 608
WIRE 96 624 -96 624
WIRE 208 624 208 576
WIRE 208 624 96 624
WIRE 256 624 256 432
WIRE 256 624 208 624
WIRE 304 624 304 480
WIRE 304 624 256 624
WIRE 352 624 352 608
WIRE 352 624 304 624
IOPIN -560 448 Out
IOPIN -560 288 In
IOPIN 384 432 Out
IOPIN 272 288 Out
IOPIN -272 496 In
IOPIN -176 496 In
IOPIN -96 448 Out
IOPIN -368 496 In
IOPIN 96 448 Out
IOPIN 208 448 Out
SYMBOL bv -96 512 R0
WINDOW 0 -28 59 Left 2
WINDOW 3 135 98 Right 2
SYMATTR InstName Bcp1
SYMATTR Value V=u(V(6,5))
SYMBOL res -448 240 R90
WINDOW 0 17 106 VBottom 2
WINDOW 3 -11 6 VTop 2
SYMATTR InstName r3
SYMATTR Value 5k
SYMBOL res -592 480 R0
WINDOW 0 31 47 Left 2
WINDOW 3 33 80 Left 2
SYMATTR InstName r1
SYMATTR Value 5k
SYMBOL res -592 304 R0
WINDOW 0 37 43 Left 2
WINDOW 3 37 74 Left 2
SYMATTR InstName r2
SYMATTR Value 5k
SYMBOL res -288 496 R0
WINDOW 0 -48 28 Left 2
WINDOW 3 -39 63 Left 2
SYMATTR InstName R4_1
SYMATTR Value 1e5
SYMBOL res -384 496 R0
WINDOW 0 -42 30 Left 2
WINDOW 3 -37 64 Left 2
SYMATTR InstName R2_1
SYMATTR Value 1e7
SYMBOL res -192 496 R0
WINDOW 0 9 27 Right 2
WINDOW 3 -36 64 Left 2
SYMATTR InstName R6_1
SYMATTR Value 1e8
SYMBOL bv 208 480 R0
WINDOW 0 -25 59 Left 2
WINDOW 3 -55 -94 VRight 2
SYMATTR InstName BFfa
SYMATTR Value V=.5-u(V(S)+V(_Q))
SYMBOL bv 352 512 R0
WINDOW 0 -25 58 Left 2
WINDOW 3 29 128 Right 2
SYMATTR InstName BfOr
SYMATTR Value V=.9999-((V(Q)+.5)+V(R))+1-u(v(4)-.5)
SYMBOL sw 272 432 R270
WINDOW 0 -15 35 VRight 2
WINDOW 3 47 31 VRight 2
SYMATTR InstName Sds
SYMATTR Value Sdis
SYMBOL sw 304 256 R270
WINDOW 0 -14 42 VRight 2
WINDOW 3 16 -29 VRight 2
SYMATTR InstName SL
SYMATTR Value Sout
SYMBOL bv 96 512 R0
WINDOW 0 -28 59 Left 2
WINDOW 3 -166 -3 Left 2
SYMATTR InstName Bcp2
SYMATTR Value V=u(V(ref33,2))
SYMBOL res -448 304 R0
WINDOW 0 -38 43 Left 2
WINDOW 3 -35 73 Left 2
SYMATTR InstName r4
SYMATTR Value 4k
SYMBOL sw 128 256 R270
WINDOW 0 -14 40 VRight 2
WINDOW 3 14 -36 VRight 2
SYMATTR InstName SH
SYMATTR Value Sout
FLAG -560 448 ref33
FLAG -560 288 5
FLAG 384 432 7
FLAG 336 512 _Q
FLAG -480 320 8
FLAG 272 288 3
FLAG -496 608 1
FLAG -272 496 4
FLAG -176 496 6
FLAG -96 448 S
FLAG -368 496 2
FLAG 96 448 R
FLAG 208 448 Q
TEXT -376 288 Left 2 !.model Sdis Sw(Ron=10 Roff=1g Vt=.75 Vh=.2)\n.model Sout Sw(Ron=5 Roff=1e6 Vt=0 Vh=.4)
TEXT -552 640 Left 2 ;V=1-((V(N_Q)+.5)+V(N3))+1-u(v(4)-.5) (LtSpice)