NigthMoth
Member level 1
Hello all
I was studying how to use comparators, so decided to feed LM311P comparator with 10kHz sinusoidal waveform generated by Colpitts oscillator to confirm the comparator behaviour. But (as you've probably already guessed) LM311P didn't behave as I expected (and Colpitts oscillator as well).
Here is what I've done, and questions at the end of this post:
and
Here is what I got:
Setup 1: Colpitts oscillator - OK, but frequency is not as I expected
Setup 2: Colpitts oscillator & LM311P (Emitter output) - OK, but output voltage less than expected
Setup 3: Colpitts oscillator & LM311P (Collector output) - Fail
My questions:
1) Colpitts oscillator frequency question (Setup 1)
I was trying to setup 10kHz frequency for Colpitts oscillator
I checked values for C1,C2 and L1 in tank circuit with RLC meter and they almost as specified (within +/-5%)
But I got 13.69kHz instead of ~10kHz.
And i cant figure out why?
My first guess was that my Lchoke inductivity is too high, and, as I undersand, It appears in parallel with C1 in AC equivalent circuit,
so tank circuit becomes more complicated?
And, for example, if I substitute (L1||Lchoke) = 5mH into tank circuit equation i get 14kHz, almost as 13.69kHz measured with oscilloscope.
When I simulate this oscillator with Micro-Cap 12, I got ~11.7kHz
It is as close to 10kHz (expected) as to 13.69kHz (received), so I'm confused..
Also, if Lchoke < 10mH, there is no oscillations. I picked up 10mH value manually, not by calculation.
2) Question regarding "Emitter output" from LM311P (Setup 2)
Almost as I expected, but why amplitude of square wave is only +2.24V but not ~Vcc(+5V)?
3) Question egarding "Collector output" from LM311P (Setup 3)
Why there is no square wave from comparator's collector output regardless of Pot1 referrence voltage in my Setup 3?
It works rather like some kind of flip-flop: always LOW when Vref(IN-) <0.22V and always HIGH when Vref(IN-) >0.22V,
even if IN+ is a sinusoid oscillating from 1.86V to 3.86V.
I was studying how to use comparators, so decided to feed LM311P comparator with 10kHz sinusoidal waveform generated by Colpitts oscillator to confirm the comparator behaviour. But (as you've probably already guessed) LM311P didn't behave as I expected (and Colpitts oscillator as well).
Here is what I've done, and questions at the end of this post:
Colpitts oscillator design for10kHz ~5Vpp oscillations
Actually I don't know how to estimate Colpitts oscillations Vpp, so decided to set power supply as +5V
Transistor biasing:
- R1, R2, Rc, Re for voltage divider configuration bias selected so @Vcc = 5V, Ic~=1mA, Vce~=0.5*Vcc;
- Ce selected so X_Ce @10kHz < 0.1*Re => Ce > 0.34uF, 0.47uF is OK;
- Cin selected so X_Cin @10kHz < 0.1*(R1||R2) => Cin > 0.69uF, 10uF is OK;
- Cout selected so X_Cout @10kHz < 0.1*Rload and Rload will be at least 10xRc => Cout > 0.009uF, 47uF is OK;
Tank circuit
C = C1*C2/(C1+C2) ~= 0.025uF;
f = 1/[2*pi*sqrt(L1*C)] ~=10.1kHz;
I estimated Av for this confirguration as described here
r'e ~= 25mV/Ie = 25mV/1mA = 25 Ohm
Av ~= Rc/r'e = 1800Ohm/25Ohm = 72
Criterion for oscillations to start from as described here:
beta = C1/C2 = 0.082 and 1/beta = 12
72 >= 12 so Av >= 1/beta so it is ok for oscillations
Actually I don't know how to estimate Colpitts oscillations Vpp, so decided to set power supply as +5V
Transistor biasing:
- R1, R2, Rc, Re for voltage divider configuration bias selected so @Vcc = 5V, Ic~=1mA, Vce~=0.5*Vcc;
- Ce selected so X_Ce @10kHz < 0.1*Re => Ce > 0.34uF, 0.47uF is OK;
- Cin selected so X_Cin @10kHz < 0.1*(R1||R2) => Cin > 0.69uF, 10uF is OK;
- Cout selected so X_Cout @10kHz < 0.1*Rload and Rload will be at least 10xRc => Cout > 0.009uF, 47uF is OK;
Tank circuit
C = C1*C2/(C1+C2) ~= 0.025uF;
f = 1/[2*pi*sqrt(L1*C)] ~=10.1kHz;
I estimated Av for this confirguration as described here
r'e ~= 25mV/Ie = 25mV/1mA = 25 Ohm
Av ~= Rc/r'e = 1800Ohm/25Ohm = 72
Criterion for oscillations to start from as described here:
beta = C1/C2 = 0.082 and 1/beta = 12
72 >= 12 so Av >= 1/beta so it is ok for oscillations
and
According to Datasheet
- Vcc(min) = 3.5V - OK, my Vcc is 5V
- Vi(min) = Vcc- +0.5V = 0+0.5V= 0.5V - OK, expected Vin(min) is 1.43V, minimum of sin wave from Colpitts oscillator Setup 1
- Vi(max) = Vcc+ -1.5V = 5-1.5V= 3.5V - OK, expected Vin(max) is 2.76V, maximum of sin wave from Colpitts oscillator Setup 1
- Icc+(max) = 7.5mA - OK, R3 = 2.7kOhm to ensure supply current <7.5mA
(I have +5V and +18V power supply, I'm affraid to use +18V by mistake, so select 2.7k resistor)
- Vcc(min) = 3.5V - OK, my Vcc is 5V
- Vi(min) = Vcc- +0.5V = 0+0.5V= 0.5V - OK, expected Vin(min) is 1.43V, minimum of sin wave from Colpitts oscillator Setup 1
- Vi(max) = Vcc+ -1.5V = 5-1.5V= 3.5V - OK, expected Vin(max) is 2.76V, maximum of sin wave from Colpitts oscillator Setup 1
- Icc+(max) = 7.5mA - OK, R3 = 2.7kOhm to ensure supply current <7.5mA
(I have +5V and +18V power supply, I'm affraid to use +18V by mistake, so select 2.7k resistor)
Here is what I got:
Setup 1: Colpitts oscillator - OK, but frequency is not as I expected
Setup 1: Circuit diagram | Setup 1: Realisation | Setup 1: Test |
Setup 2: Colpitts oscillator & LM311P (Emitter output) - OK, but output voltage less than expected
Setup 2: Circuit diagram | Setup 2: Realisation | Setup 2: Test |
Setup 3: Colpitts oscillator & LM311P (Collector output) - Fail
Setup 3: Circuit diagram | Setup 3: Realisation | Setup 3: Test |
My questions:
1) Colpitts oscillator frequency question (Setup 1)
I was trying to setup 10kHz frequency for Colpitts oscillator
I checked values for C1,C2 and L1 in tank circuit with RLC meter and they almost as specified (within +/-5%)
But I got 13.69kHz instead of ~10kHz.
And i cant figure out why?
My first guess was that my Lchoke inductivity is too high, and, as I undersand, It appears in parallel with C1 in AC equivalent circuit,
so tank circuit becomes more complicated?
And, for example, if I substitute (L1||Lchoke) = 5mH into tank circuit equation i get 14kHz, almost as 13.69kHz measured with oscilloscope.
When I simulate this oscillator with Micro-Cap 12, I got ~11.7kHz
It is as close to 10kHz (expected) as to 13.69kHz (received), so I'm confused..
Also, if Lchoke < 10mH, there is no oscillations. I picked up 10mH value manually, not by calculation.
2) Question regarding "Emitter output" from LM311P (Setup 2)
Almost as I expected, but why amplitude of square wave is only +2.24V but not ~Vcc(+5V)?
3) Question egarding "Collector output" from LM311P (Setup 3)
Why there is no square wave from comparator's collector output regardless of Pot1 referrence voltage in my Setup 3?
It works rather like some kind of flip-flop: always LOW when Vref(IN-) <0.22V and always HIGH when Vref(IN-) >0.22V,
even if IN+ is a sinusoid oscillating from 1.86V to 3.86V.