Cross-posting from: https://forum.mystorm.uk/t/dvi-hdmi-pmod/505

The Lattice iCE40 FPGAs have LVDS inputs, but they don’t actually have LVDS outputs - they ‘emulate’ LVDS outputs using two LVCMOS outputs and three external resistors, which “should be surface mounted as close as possible to the FPGA output pins”!

I have had a go at putting together a DVI / HDMI Pmod by level-shifting 3.3V down to 1.2V using a SN74AXC8T245, and then feeding that (AC-coupled) into a PTN3366 to achieve proper TMDS / CML outputs:

My monitor recognises the signal as 640x480 @ 60Hz, but has trouble keeping sync, and I am getting some weird interference / glitchy vertical lines - my feeling is that this may be due to high-frequency ‘reflections’ and requires better hardware design… my hope is that someone will spot something in the code that may help?

This is based on Mike Field’s work (see below lnks) and uses the iCE40’s DDR output mode to get 250MHz outputs from a 125MHz clock…


I have a couple of these Pmod boards to spare if anyone else wants to take a crack at it?


Turns out the interference was actually due to the cable… I had been using a 1.5m HDMI to DVI cable, and trying hard to optimise the code any way I could - eventually I kidnapped the monitor from the family computer (which has a HDMI input), switched to using a 0.5m HDMI to HDMI cable… and no more interference! :joy: Sync was still a little glitchy, but a couple of minor adjustments to the original unoptimised code fixed it! The code is still a little ‘fragile’, but a picture is worth a thousand tiny cuts:


Where can I get one? Are you going to sell any?


Happy to send one to you @lawrie.griffiths - just PM a postal address to me?

Bear in mind that it only works experimentally at best right now though, seems to depend on the tolerance of the screen being used - I have one monitor with HDMI input that displays this test pattern no problem, but my TV does not like it… I would recommend getting a short HDMI cable as well to avoid the interference I was experiencing (0.5m is what worked for me, but I think you can even get them as short as 0.25m). I have ordered one of these adapters to try out the shorter HDMI cable with the other monitors in the house which have DVI inputs:

…will have to wait and see how that goes! :smile:


Have banged out a small write-up of this:


I have a couple of monitors and some TVs I can try it with and some very short HDMI cables.


I have been wondering if this was possible for a while. I had looked at the Ken Hubbard’s (Black Mesa Labs) project and at @mattvenn’s DVI project on Blackice.

It would be really good if we could produce a games console with HDMI output.