# Chapter 14 - Digital Counting and Measurment¶

## Example E1 - Pg 453¶

In [1]:
#Caption:Determine Resistors Rc and Rb
#Ex14.1
Vcc=5.#Collector voltage(in volts)
Vi=5.#Input voltage(in volts)
Vf=1.2#Diode forward voltage(in volts)
hfe=100.
I=20.#Diode minimum forward current(in mA)
Vce=0.2#Collector emitter saturated voltage(in volts)
Vbe=0.7#Base emitter voltage(in volts)
Rc=(Vcc-Vf-Vce)*1000./I
Ib=I*1000./hfe
Rb=(Vi-Vbe)*1000./Ib
print '%s %.f' %('Resistors are Rc(in kilo ohm) =',Rc)
print '%s %.1f' %('Resistors are Rb(in kilo ohm) =',Rb)

Resistors are Rc(in kilo ohm) = 180
Resistors are Rb(in kilo ohm) = 21.5


## Example E5 - Pg 475¶

In [2]:
#Caption:Determine meter indication when time base uses (a)6 decade counter (b)4 decade counter
#Ex14.5
f=3500.#Applied frequency(in hz)
F=10.**6.#Clock generator frequency(in hz)
f1=F/(10.**6.)
t1=1./f1
c1=f*t1
print '%s %.f' %('Cycles of input counted during t1=',c1)
f2=F/(10.**4.)
t2=1./f2
c2=f*t2
print '%s %.f' %('Cycles of input counted during t2=',c2)

Cycles of input counted during t1= 3500
Cycles of input counted during t2= 35


## Example E6 - Pg 483¶

In [3]:
#Caption:Determine required current
#Ex14.6
c=1280.#Input wave clock cycles
f=200.#Output frequency(in khz)
p=1000.#Pulses during t2
V=1.#Input voltage(in volts)
R=10.#Resistance(in kilo ohm)

Required current(in micro ampere)= 128