Hi, all,
I thought I'd start a new thread for this since it looks like I'll be rambling on about it for some time...
OK, so at the bottom of the following post, I finally had success with generating HDMI directly from an FPGA...
http://www.assemblergames.com/forum...B-amp-mod-help&p=627612&viewfull=1#post627612
I already have the decoder block for extracting R/G/B/Sync from the digital video pins on the N64, so now I'm trying to see if I can get the N64 to work via the FPGA / HDMI interface...
I'm hoping it will be possible to output standard 480i / 576i (interlaced) directly via HDMI, but I can't seem to figure out what control bits or sync pulses the TV is expecting?
We know progressive VGA modes are working fine (well 640x480 atm), so if I can't get interlaced working directly, I'll need to convert N64's interlaced output to progressive.
Marshall has done a great job with his VGA adapter. I'll have to ask him if he wants to help out with the scan doubler code...
http://forums.benheck.com/viewtopic.php?f=5&t=43034
I don't have any photos or video yet, as the HDMI code is only outputting a VGA test pattern atm, so it's not very interesting.
When I try the N64 through the FPGA, my TV just says "Mode not supported", or no signal.
Obviously this is due to the incorrect sync timing, so I'm after some help with the correct timings...
The core protocol for DVI_D / HDMI is essentially the same, but HDMI has added support for lossy / lossless multichannel audio, CEC, Ethernet and a load of other junk we don't need right now.
Here is the DVI spec...
http://www.cs.unc.edu/Research/stc/FAQs/Video/dvi_spec-V1_0.pdf
The encoding is very convoluted, but most of that has been taken care of. The problem is, I don't know how the hell HDMI handles an interlaced source?
I know it's related to the pixel clock, and from that the DSR "Data Signalling Rate" is calculated?
OK, so what do we know about the N64 video output?...
Firstly, the encoding for the digital video bus has already been worked out (thanks to Tim)...
http://members.optusnet.com.au/eviltim/n64rgb/n64rgb.html
...and I know that part of code is working 'cos I used it a few years ago to generate analog RGB (SCART) directly from an FPGA.
The next important thing is the actual pixel clock timings...
On the NTSC N64, it uses a crystal which is four times the NTSC colour subcarrier frequency. ie. 3.579545 * 4 == 14.31818 MHz.
On most REVs, you can see this crystal on the board, usually marked "X1".
This is then multiplied 17 and divided by 5 using the PLL chip "U7". (14.31818 * 17) / 5 == 48.681812 MHz.
This roughly 50MHz "VCLK" clock is used as the master clock for the video DAC as well as the entire RCP.
(The RCP internally multiplies VCLK by 1.25 to get 62.5MHz. The CPU internally multiplies the 62.5MHz by 1.5 to get 93.75 MHz).
Interesting, so the NTSC consoles actually run their RCP at 60.852265 MHz, while the PAL consoles run the RCP at 62.0706625 MHz? hmmm
The N64 video bus uses a clocking scheme where it outputs one full pixel every four clocks.
So, the "pixel clock" on the NTSC console is effectively: 48.681812 / 4 == 12.170453 MHz ?
I think that pixel clock is a bit too non-standard to be transferred via HDMI directly? (not that it matters for the analog RGB encoding)
We could only halve the VCLK to give 24.340906 MHz, but it's the interlaced issue which is screwing things up.
Right, I think I'll have to do a scan doubler to get this to work easily. :stupid:
In the mean time, I have a few tricks to try.
All for now.
OzOnE.
I thought I'd start a new thread for this since it looks like I'll be rambling on about it for some time...
OK, so at the bottom of the following post, I finally had success with generating HDMI directly from an FPGA...
http://www.assemblergames.com/forum...B-amp-mod-help&p=627612&viewfull=1#post627612
I already have the decoder block for extracting R/G/B/Sync from the digital video pins on the N64, so now I'm trying to see if I can get the N64 to work via the FPGA / HDMI interface...
I'm hoping it will be possible to output standard 480i / 576i (interlaced) directly via HDMI, but I can't seem to figure out what control bits or sync pulses the TV is expecting?
We know progressive VGA modes are working fine (well 640x480 atm), so if I can't get interlaced working directly, I'll need to convert N64's interlaced output to progressive.
Marshall has done a great job with his VGA adapter. I'll have to ask him if he wants to help out with the scan doubler code...
http://forums.benheck.com/viewtopic.php?f=5&t=43034
I don't have any photos or video yet, as the HDMI code is only outputting a VGA test pattern atm, so it's not very interesting.
When I try the N64 through the FPGA, my TV just says "Mode not supported", or no signal.
Obviously this is due to the incorrect sync timing, so I'm after some help with the correct timings...
The core protocol for DVI_D / HDMI is essentially the same, but HDMI has added support for lossy / lossless multichannel audio, CEC, Ethernet and a load of other junk we don't need right now.
Here is the DVI spec...
http://www.cs.unc.edu/Research/stc/FAQs/Video/dvi_spec-V1_0.pdf
The encoding is very convoluted, but most of that has been taken care of. The problem is, I don't know how the hell HDMI handles an interlaced source?
I know it's related to the pixel clock, and from that the DSR "Data Signalling Rate" is calculated?
OK, so what do we know about the N64 video output?...
Firstly, the encoding for the digital video bus has already been worked out (thanks to Tim)...
http://members.optusnet.com.au/eviltim/n64rgb/n64rgb.html
...and I know that part of code is working 'cos I used it a few years ago to generate analog RGB (SCART) directly from an FPGA.
The next important thing is the actual pixel clock timings...
On the NTSC N64, it uses a crystal which is four times the NTSC colour subcarrier frequency. ie. 3.579545 * 4 == 14.31818 MHz.
On most REVs, you can see this crystal on the board, usually marked "X1".
This is then multiplied 17 and divided by 5 using the PLL chip "U7". (14.31818 * 17) / 5 == 48.681812 MHz.
This roughly 50MHz "VCLK" clock is used as the master clock for the video DAC as well as the entire RCP.
(The RCP internally multiplies VCLK by 1.25 to get 62.5MHz. The CPU internally multiplies the 62.5MHz by 1.5 to get 93.75 MHz).
Interesting, so the NTSC consoles actually run their RCP at 60.852265 MHz, while the PAL consoles run the RCP at 62.0706625 MHz? hmmm
The N64 video bus uses a clocking scheme where it outputs one full pixel every four clocks.
So, the "pixel clock" on the NTSC console is effectively: 48.681812 / 4 == 12.170453 MHz ?
I think that pixel clock is a bit too non-standard to be transferred via HDMI directly? (not that it matters for the analog RGB encoding)
We could only halve the VCLK to give 24.340906 MHz, but it's the interlaced issue which is screwing things up.
Right, I think I'll have to do a scan doubler to get this to work easily. :stupid:
In the mean time, I have a few tricks to try.
All for now.
OzOnE.
Amazing stuff.![[IMG]](https://web.archive.org/web/2im_/http://www.motiondsp.com/sites/default/files/deinterlace.png)