Chapter 12 - Integrated Circuit Logic Gates

Example E1 - Pg 372

In [1]:
#Caption: Determine fan out for DTL NAND gate 
hfe=19.1
Vbe=0.7#Base emitter voltage(in volts)
R3=6.#Resistance(in kilo ohm)
R2=5.#Resistance(in kilo ohm)
Vcc=5.#Supply voltage(in volts)
R1=2.#Resistance(in kilo ohm)
Vce=0.2#Collector emitter voltage(in volts)
Vf4=0.7#Diode forward voltage
Vf5=Vf4
Vf6=Vf4
I2=Vbe/R2
Va=Vf4+Vf5+Vbe
I1=(Vcc-Va)/R1
Ib=I1-I2
Ic1=hfe*Ib
I3=(Vcc-Vce)/R3
Iol=Ic1-I3
R4=R1
Iil=(Vcc-Vf6)/R4
fo=Iol/Iil
print '%s %.f' %('Fan out=',fo)
Fan out= 11

Example E2 - Pg 381

In [2]:
#Caption:Determine Resistance to drive inputs of 5 TTL gates
Ii=1.6#Maximum input current(in mA)
Io=16.#Maximum output current(in mA)
Vcc=5.#Supply voltage(in volts)
Vo=0.4#Maximum output voltage(in volts)
Il=5.*Ii
Irc=Io-Il
Vrc=(Vcc-Vo)
Rc=Vrc*1000./Irc
print '%s %.f' %('Required resistance(in ohm)=',Rc)
Required resistance(in ohm)= 575

Example E4 - Pg 403

In [3]:
#Caption:Design a interface circuit for CMOS
Vdd=15.#Drain voltage(in volts)
Rd=1.#Drain resistance(in kilo ohm)
Vcc=5.#Supply voltage(in volts)
Ih=40.#Current(in micro ampere)
hfe=20.
Vce=0.2#Saturated collector emitter voltage(in volts)
vih=2.#High input voltage(in volts)
il=1.6#Low input current
Vbe=0.7#Base emitter voltage(in volts)
Rc=(Vcc-vih)*1000./(2.*Ih)
Ic=((Vcc-Vce)/Rc)+(2.*il)
Ib=Ic/hfe
R=(Vdd-Vbe)/Ib
Rb=R-Rd
print '%s %.1f %s %.1f' %('Components required to design circuit are resistors \nRb(in kilo ohm)=',Rb,'\nRc(in kilo ohm)=',Rc)
Components required to design circuit are resistors 
Rb(in kilo ohm)= 84.9 
Rc(in kilo ohm)= 37.5