Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware?

You can talk about almost anything that you want to on this board.

Moderator: Moderators

User avatar
Drew Sebastino
Formerly Espozo
Posts: 3496
Joined: Mon Sep 15, 2014 4:35 pm
Location: Richmond, Virginia

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by Drew Sebastino »

Would it really be that expensive? I've found 8 bit shift registers for less than a dollar, although I'm assuming that they're not even a fraction as fast. I can't imagine the price being higher than $10, although you'll need 3 of them.
User avatar
Dwedit
Posts: 4924
Joined: Fri Nov 19, 2004 7:35 pm
Contact:

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by Dwedit »

LOL PI ZERO
That's the eternal problem with rigging up ancient-style hardware, you get beaten by cheap new components.
Here come the fortune cookies! Here come the fortune cookies! They're wearing paper hats!
tepples
Posts: 22708
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by tepples »

Granted. But how easily do "cheap new components" compete latency-wise with good old SPI bit banging for the input and scanline rendering for the video output? The average video latency on an NES or Super NES with wired controllers and a CRT SDTV is 2 frames or 33 ms:
  • Average 1/2 frame between button press and next controller read
  • Fixed 1 frame to process game logic, create a display list, and send it to the PPU
  • Average 1/2 frame from top of picture to player character's position
Kev's Hi-Def NES adds 1 to 2 ms at the most, plus whatever lag the TV's scaler adds.

How close do frame buffer based systems come?
lidnariq
Posts: 11432
Joined: Sun Apr 13, 2008 11:12 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by lidnariq »

The cheapest digital-parallel-24-bit-to-HDMI IC seems to be the TDA19988 , at $5/@1 via Mouser. I think the biggest problem you'll have is that if you're using the "480i over HDMI" timing, the TV is going to deinterlace it, which will add tons of latency.

It wouldn't be hard to generate 640x480 at 1bpp—after all, the original VGA card managed 640x480@4bpp by using a 32-bit wide data bus and a 3MHz master clock—but it would get fiddly, and be more expensive than just using a cheap FPGA.


I suppose the question is, for anyone who has a linux machine and a Real TV, what happens if you try any of the following modelines?

Code: Select all

xrandr --newmode "320x240in640x480-60" 25.175 320 656 752 800 240 490 492 525 -hsync -vsync; xrandr --addmode HDMI-1 "320x240in640x480-60"
xrandr --newmode "320x240in1280x240-60" 25.175 320 1312 1504 1600 240 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "320x240in1280x240-60"
xrandr --newmode "1440x242-BT601-60" 27 1440 1456 1584 1716 242 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "1440x242-BT601-60"
Rahsennor
Posts: 479
Joined: Thu Aug 20, 2015 3:09 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by Rahsennor »

lidnariq wrote:I suppose the question is, for anyone who has a linux machine and a Real TV, what happens if you try any of the following modelines?

Code: Select all

xrandr --newmode "320x240in640x480-60" 25.175 320 656 752 800 240 490 492 525 -hsync -vsync; xrandr --addmode HDMI-1 "320x240in640x480-60"
xrandr --newmode "320x240in1280x240-60" 25.175 320 1312 1504 1600 240 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "320x240in1280x240-60"
xrandr --newmode "1440x242-BT601-60" 27 1440 1456 1584 1716 242 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "1440x242-BT601-60"
I get a black screen on the first two and a very narrow image for the third. I can stretch it to fill the screen (with significant overscan) by changing the aspect ratio, but the scaler looks awful as usual.
lidnariq
Posts: 11432
Joined: Sun Apr 13, 2008 11:12 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by lidnariq »

Very narrow PAR (expected) or very narrow DAR?
Rahsennor
Posts: 479
Joined: Thu Aug 20, 2015 3:09 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by Rahsennor »

1:1 PAR by default. I can get the expected 4:3 DAR and ~2:9 PAR by hitting the aspect button a few times though.
lidnariq
Posts: 11432
Joined: Sun Apr 13, 2008 11:12 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by lidnariq »

After a little while of thinking on it, I'm curious what happens if you use the functioning modeline ("BT601") but increase the horizontal blanking a lot so that its normal 1:1 PAR produces a 4:3 or 16:9 DAR?

i.e. 27 WIDTH 1456 1584 1716 240 245 248 262 -hsync -vsync with WIDTH = 320 or 424
Rahsennor
Posts: 479
Joined: Thu Aug 20, 2015 3:09 am

Re: Rigging 3 8 bit bus CPUs to HDMI for "2D" video hardware

Post by Rahsennor »

Both of these give me a blank screen, and a "NO SIGNAL" message when I switch from another input to HDMI:

Code: Select all

xrandr --newmode "TEST1" 27 320 1456 1584 1716 240 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "TEST1"
xrandr --newmode "TEST2" 27 424 1456 1584 1716 240 245 248 262 -hsync -vsync; xrandr --addmode HDMI-1 "TEST2"
Do modern TVs even care about blanking? I'm pretty sure they'd just dump the active pixels into a framebuffer by now.
Post Reply