i am trying to generate sinusoidal PWM by comparing sine and triangular wave.
First i just tried to compare sine wave with reference voltage in order to check the working of op-amp. I get a problem in using op-amp(741) as a comparator at high frequency, so i used comparator by the suggestions from electronics stack exchange. enter link description here
Which work great for comparing sine with reference voltage. Later i noticed that there is a offset problem. Input waveform having an offset of 0 volt, but when i connect my input (both sine or triangular wave) to a comparator. The input waveform get changes by it dc offset to 6 volt.
Input waveform before connecting to a comparator
Input waveform after connecting to a comparator
How to compensate the offset voltage to zero volt after connecting with comparator.
Circuit..
Triangular Waveform...
Comparing triangular wave reference voltage...
Without connecting with comparator
How to compensate the offset voltage to zero volt after connecting with comparator.