I have a 4.43MHz sinusoidal output from an IC that I want to convert to a TTL square wave to use as a clock. The signal has a DC offset of around 2.5V and has an amplitude of about 0.5V peak to peak.
I attempted to convert this to a 0-5V square wave using a TLV3501 high speed comparator with this circuit.
The comparator appears to work as expected: with RV1 at one extreme the output at SQ_OUT is 0V, at the other it is 5V, at a point roughly in the middle I see a waveform. However it has a DC offset and doesn't look much like a square wave.
(Above is 0.5V / div and has a DC offset of nearly 2V).
The datasheet shows a square wave generated from a 50MHz signal so obviously I am doing something wrong. I am using a breadboard but the IC is on an adapter with C1 and C2 soldered to the pins. I also tried disconnecting SQ_OUT from the breadboard and measuring the output at the pin, but saw the same result. How can I get a 0-5V square wave?
Following the suggestions here I fed the comparator with signals ranging from 500hz to 20000hz and offset by 2.5VDC. I mostly observed the same result: with RV1 at one extreme, a 5V flatline, at the other, 0V, and in between a waveform of about .5Vp/p and offset at around 2.5V (the offset varied depending on RV1).
The closest I ever got to expected output had flat peaks at 5V but still not swinging between 0 and 5V.
This would seem to rule out scope issues, so it must be either the electrical environment (I'm using a breadboard) or else I've wired it wrong (which I doubt, but I will certainly be triple and quadruple checking). Or possibly a dud chip, which also seems unlikely.
I'm wondering if these issues could be a factor:
- I'm using a breadboard (SQ_OUT is not connected to the breadboard though).
- There is no load connected, except for the scope probe. Previously when I was feeding 4.43MHz there was a load connected (clock input on an AD724).
- Could RV1 which is a 20K voltage divider be too much resistance?
I believe my problems were caused by a noisy power supply (5V unfiltered USB), and exacerbated by stray capacitance from the breadboard. With the USB supply the comparator seemed to have 3 states: flatlining at 0V, flatlining at 5V, or the voltage at the input. This was the case even without any signal, just 2.5VDC. I'm guessing the "middle state" was high frequency oscillation. I managed to get the expected output by powering the circuit from a battery and got best results when I removed it completely from the breadboard. Only then did I get only 0V or 5V flat lines with no "middle state". On the breadboard and supplying a 1000hz signal, I see a 0-5V square wave with some zigs and zags around 2.5V, showing that the output is not a clean. I guess if I want to continue with this device I'll have to put it on its own board and filter the power supply. Thanks to everyone who contributed.