Welcome to ETO!
Please note that using all capitals is regarded as shouting.
Your Sine and Tri labels should be swapped.
Try googling "sine wave pwm" to see the standard ways to do this.
....To get sinusoidal PWM....you put the sine into the comparator, along with the repeating ramping wave.
So re-base the sine so its always positive........from 0 to 5V say....that being peak to peak...
Then you shove the ramp into the other comparator input.....ensure that the ramp's peak is slightly higher than the sine's peak.
Obviously the frequency of the ramp should be much much faster than the sines frequency.
Welcome to ETO!
Please note that using all capitals is regarded as shouting.
Your Sine and Tri labels should be swapped.
Try googling "sine wave pwm" to see the standard ways to do this.
....To get sinusoidal PWM....you put the sine into the comparator, along with the repeating ramping wave.
So re-base the sine so its always positive........from 0 to 5V say....that being peak to peak...
Then you shove the ramp into the other comparator input.....ensure that the ramp's peak is slightly higher than the sine's peak.
Obviously the frequency of the ramp should be much much faster than the sines frequency.
triangle (ramp) freq must be much greater than sine frequency......say >30kHz.
What comparator?.....Any general purpose comparator will be ok.
(as long as it accepts the voltages you will be using with it)
An LM339/393 is a common comparator that should work for your purposes.
Note that, since the output is an open collector, it requires an output pull-up resistor of a few kohm to the V+ supply for proper operation.
Reversing the two input signals to the comparator will reverse the output signal polarity.
You can also use another comparator to reverse the signal polarity.
here i Have attached the file with sine and triangle(ramp) signal in it.
could you please compare it and invert the output signal. and upload it here please
An LM339/393 is a common comparator that should work for your purposes.
Note that, since the output is an open collector, it requires an output pull-up resistor of a few kohm to the V+ supply for proper operation.
Reversing the two input signals to the comparator will reverse the output signal polarity.
You can also use another comparator to reverse the signal polarity.
No.
Do you know how op amps work?
Do you know what an analog comparator is?
If not I suggest you look them up before you come back with any more questions.