Hi People.
I've got a problem with a PWM circuit that just refuses to work properly. First, let me add the circuit (see below)
It works perfectly in a simulator, but in reality it doesn't work so well, but I'm pulling my hair out as to why! I'm sure it’s something in the PWM circuit itself, but I don't understand enough about it to work out exactly what. The resistors I am using are all 1%
The problem with it is that at the very beginning when it changes the duty cycle between about 1-3%, the PWM output goes haywire (see the scope shot). At 0% its ok, at 4% to 96% it works fine and is stable, at 97-100% it goes crazy again.
I've tried to catch the scope images do you can see.
Changing the frequency doesn't make any difference, I've tried different filtering with caps and diodes which helped smooth the signal, but didn't fix the problem. The trimpot marked TSS in the schematic is for adjusting the end position of the input pots (because some of the 10k pots I have start and finish in different positions depending on the brand).
The sawtooth output into the negative of the second comparator (pin 6) of the lm2903 is dead steady. The scope readings were taken from Pin 7 (the second comparator output).
The PWM square wave output from Pin 1 is stable; however I have noticed that at the problem points in the potentiometer travel (1-3% and 97-100%) it grows the smallest margin wider (time) until you cross past these problem spots.
The diode D3 on the output helped clean the signal, and so did a capacitor, but again not fixing the problem.
I've tried external 5v power sources, but it still bugs out. I've tried taking all other circuits out of the design and leaving just the PWM and the 5v reg, but it still bugs out. I can cheat by adjusting the maximum start and end positions, but this is more of a hack and not really fixing the problem.
I'm just stumped and would appreciate any help I can get!
The circuit:
0% duty cycle, stable (no picture)
1-3% Duty Cycle, Crazed, you can’t see it but its shifting horizontally across the screen
~50% duty cycle, stable
97% Crazed!
99% crazed
The PWM is based on Sarges design.
I'm stuck!
I've got a problem with a PWM circuit that just refuses to work properly. First, let me add the circuit (see below)
It works perfectly in a simulator, but in reality it doesn't work so well, but I'm pulling my hair out as to why! I'm sure it’s something in the PWM circuit itself, but I don't understand enough about it to work out exactly what. The resistors I am using are all 1%
The problem with it is that at the very beginning when it changes the duty cycle between about 1-3%, the PWM output goes haywire (see the scope shot). At 0% its ok, at 4% to 96% it works fine and is stable, at 97-100% it goes crazy again.
I've tried to catch the scope images do you can see.
Changing the frequency doesn't make any difference, I've tried different filtering with caps and diodes which helped smooth the signal, but didn't fix the problem. The trimpot marked TSS in the schematic is for adjusting the end position of the input pots (because some of the 10k pots I have start and finish in different positions depending on the brand).
The sawtooth output into the negative of the second comparator (pin 6) of the lm2903 is dead steady. The scope readings were taken from Pin 7 (the second comparator output).
The PWM square wave output from Pin 1 is stable; however I have noticed that at the problem points in the potentiometer travel (1-3% and 97-100%) it grows the smallest margin wider (time) until you cross past these problem spots.
The diode D3 on the output helped clean the signal, and so did a capacitor, but again not fixing the problem.
I've tried external 5v power sources, but it still bugs out. I've tried taking all other circuits out of the design and leaving just the PWM and the 5v reg, but it still bugs out. I can cheat by adjusting the maximum start and end positions, but this is more of a hack and not really fixing the problem.
I'm just stumped and would appreciate any help I can get!
The circuit:
0% duty cycle, stable (no picture)
1-3% Duty Cycle, Crazed, you can’t see it but its shifting horizontally across the screen
~50% duty cycle, stable
97% Crazed!
99% crazed
The PWM is based on Sarges design.
I'm stuck!
Last edited: