11
\$\begingroup\$

So, I'm generating a 1280x1024 (native screen resolution) VGA signal using a Lattice HX8K > Yosys, according to these timings, and a PLL of 107.812Mhz of Pixel Frequency. I then pass it through a simple scaler to achieve an effective pixel resolution of 320x256.

All signals are being buffered through a 74HC245 and some resistors. I would like to use the 74ALVC245 variant, but I'm still waiting for the order to arrive.

schematic

simulate this circuit – Schematic created using CircuitLab

The monitor detects and displays the correct image, but there is noticeable "ghosting" in the bottom of the image (something that is quite absent in the top):

enter image description here

What could possible be the culprit? Would the ALVC solve it?


Addendum: Per channel ghosting:

Red Ghosting Green Ghosting Blue Ghosting


Addendum 2: Some curious findings:

Ok, here's something I wasn't expected. While disconnecting the ~500Ohm resistor in the green channel (to test a different one), I was expecting to see the image completely black. Instead, this is what I saw:

enter image description here

After which I tried to leave the green channel on, and directly connect the red and blue channel to ground:

enter image description here

Could this be bad cable shielding? I tried this cable with a raspberry PI and a HDMI -> VGA adapter, and I couldn't see any artefacts resembling these images.


Addendum 3: If I just disconnect the red and blue channels (leave them floating), then I get a perfect green image. Could this be noise in my GND lane?


Addendum 4: So many new things after going through an oscilloscope. Let's start from the beginning; measuring the freaking 3.3V source from the PMOD connection of the FPGA:

enter image description here

You would imagine a stabilised 3.3V source, right? Guess what:

enter image description here

That's 306mV of noise measured right at the PMOD. There's definitely some internal coupling going on with a ~1.4Mhz signal which I can't even begin to identify.


Now the easy things. Is the 74HC245 introducing more lag than it should? Let's compare IN vs OUT at the VSync pins:

enter image description here

These don't seem to be a problem; the 3.5V Pk-Pk seem inside range, given the oscillations of the power supply. But zooming out on the HSync:

enter image description here

Green is after the 74xx245, yellow is before. There's so much noise going on when the signal is high, that it actually pushed the envelope to 4.06V! How's VSync side-to-side with HSync?

enter image description here

Not bad; but not a pretty signal, though, considering I'm filtering both of them with a couple of 22pF capacitors.


And what about the individual pixels? Well, being this a 70Mhz oscilloscope, I don't have enough resolution to capture individual pixel measurements. But zooming in on a very fine region of the red channel:

enter image description here

Which gives a 600mv envelope; very nice for the 0.7V VGA target input, right? What happens when I zoom out?

enter image description here

OMG... It's like, there are two signals superimposed on top of each other (with lots of added noise), and an offset of some hundreds mVs, enough to push the envelope to 1.61V Pk-Pk. This seems crazy, and I bet this is the the probable source of the ghosting...


Now what? I'm completely out of my comfort zone, so all your help would be appreciated guys :)


Addendum 5:

After reading a lot here about wires, and also here thanks to @Peter Smith, I decided to cut the cables that connect to back of the monitor to about 1/3rd of their size (they had around 1m, and are 24AWG). The ghosting is way better now, but you can still see some weird superposition:

enter image description here

Here's the physical setup photo, as some requested (sorry for the xmas-themed table towel):

enter image description here

\$\endgroup\$
1
  • \$\begingroup\$ Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or any answer(s). \$\endgroup\$
    – Dave Tweed
    Commented Dec 31, 2019 at 12:52

2 Answers 2

3
\$\begingroup\$

Based of the extensive discussions above, I think the problem is with the OP's interface between his breadboard and the VGA display itself. Secondary to this may be the breadboard setup itself.

OP agrees that the only thing that has made a noticeable difference is when he shortened the wires from the breadboard to the display from 1M to ~ 12 inches. That has to mean something.

Single ended, unshielded wires from the 'HC245 to the display is not the proper way to send 100 MHz+ signals. In the short term, as I think someone else suggested, I would twist a ground wire with each signal going to the display, and connect that wire to GND on both ends.

Ideally, in a perfect world you should have 5 coax cables to the VGA display.

\$\endgroup\$
1
  • \$\begingroup\$ This was exactly what did the most difference. I made twisted pairs for each signal with GND, and the ghosting was reduced significantly. It's still not perfect, but it is far better than the initial image. \$\endgroup\$ Commented Jan 8, 2020 at 1:12
1
\$\begingroup\$

I believe there is sufficient synchronous noise crosstalk to the Hsync signal to cause jitter on the video which appears to get progressively worse after vertical sync.

A 0.1uF decoupling cap directly across Vdd:Vss on the IC is needed, not inductive jumpers to the breadboard rail.

All fast risetime signals with inductive jumpers are easy targets for mutual coupling. I would add a <=220R load to attenuate crosstalk and/or use twisted pairs on each critical signal.

enter image description here

All scope traces need the ground clip to be removed with probe tip also and measured across a leaded resistor (tip & Ring) Otherwise you see >20MHz false noise

\$\endgroup\$
4
  • 1
    \$\begingroup\$ I understand what you're saying about the xtalk between Hsync & the video. But why would it get worse after Vsync? \$\endgroup\$
    – SteveSh
    Commented Dec 31, 2019 at 2:38
  • \$\begingroup\$ That depends on the coherence of crosstalk and harmonic differences of HS with the crosstalk , however that is Generated... keep unshielded Signal wire length short. USe your fingers to locate the interference \$\endgroup\$
    – D.A.S.
    Commented Dec 31, 2019 at 2:47
  • 1
    \$\begingroup\$ " USe your fingers to locate the interference...". Or the hot component <wink>? \$\endgroup\$
    – SteveSh
    Commented Dec 31, 2019 at 3:14
  • \$\begingroup\$ I meant use the fingers as shunts or bridges to see the path effects on scope and LCD from pF to nF THEN SHIELD those signals \$\endgroup\$
    – D.A.S.
    Commented Dec 31, 2019 at 3:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.