Moar hardware: Retro Scaler A1

The place for all discussion on gaming hardware
User avatar
invzim
Posts: 45
Joined: Tue Jul 24, 2007 8:40 am
Location: https://irkenlabs.com/
Contact:

Moar hardware: Retro Scaler A1

Post by invzim »

Something I've been working on forever is starting to take form:

Image

it actually scales too:
Image

Takeaway here is that you can actually see the bottom of the frame, which I belive no other scaler does.

It's purpose built for arcade PCB's, and has a couple of tricks:
  • Automatic Analog bypass when sync is 31k, so it can be connected 'in-line' for use with Naomi etc.
    No touch (so far) sync processing that deals with stuff like Taito F3 and other tricky titles
    30 bit ADC and DAC
    Works by line-doubling (lag-free)
    expensive (ADC and DAC from Analog Devices)
    Power via micro-USB
It's different from the OSSC in a few key ares, different ADC, analog output, input processing made for PCB's. It's not going to be open source, and it's not based on OSSC. It's got an Arm cortex M4 for control, and the FPGA stuff is VHDL.

It's far from complete, right now I'm working on the OSD, but the hardware part is working pretty well so far. My goal is to make something as good as or better than the XRGB2.
User avatar
Xyga
Posts: 7181
Joined: Tue Nov 05, 2013 8:22 pm
Location: block

Re: Moar hardware: Retro Scaler A1

Post by Xyga »

Nice! More new designs are always good news.

I wouldn't necessarily use the XRGB2 as a reference doubler for arcade sources though. The XRGB1/DISPL design also allowed to show the full frame and had a sharper and more stable image.
What the XRGB2 had better was higher compatibility with even LCD monitors due to its forced 480 lines output (and therefore cut image) but although it depends on a display's flexibility, the X1/DISPL design allows incredible compatibility on LCDs too (saying that I haven't tested tons of arcade hardwares w/ it htough)
Strikers1945guy wrote:"Do we....eat chicken balls?!"
juji82
Posts: 349
Joined: Sat Nov 16, 2013 3:05 am
Location: Tokyo, Japan

Re: Moar hardware: Retro Scaler A1

Post by juji82 »

Displ 2.0 ? Oh YES! :D
Woozle
Posts: 232
Joined: Wed Jun 24, 2015 8:27 pm
Location: Florida

Re: Moar hardware: Retro Scaler A1

Post by Woozle »

Is the ARM necessary? It seems to eat a lot of board area for what's likely just SPI and I2C.

Have you thought about using more compact dual output LDOs?

Since the ADC is dual input and does YPbPr, do you think you'll add those features? (Maybe add a second input with a mini DIN connector).

Pictures of the bottom?

Looks great so far :)
User avatar
invzim
Posts: 45
Joined: Tue Jul 24, 2007 8:40 am
Location: https://irkenlabs.com/
Contact:

Re: Moar hardware: Retro Scaler A1

Post by invzim »

Woozle wrote:Is the ARM necessary? It seems to eat a lot of board area for what's likely just SPI and I2C.

Have you thought about using more compact dual output LDOs?

Since the ADC is dual input and does YPbPr, do you think you'll add those features? (Maybe add a second input with a mini DIN connector).

Pictures of the bottom?

Looks great so far :)
The ARM is really nice to have, as it it's the brains of controls and deal with USB and SDIO for the micro-sd card, and will also drive the OSD stuff, something that would eat a lot of capacity on the FPGA. With the ARM, I don't really have to worry about software size or ram. The PCB itself is already pretty small, see picture BELOW. I looked into more advanced power solutions, but they tend to be expensive and not always readily available, and who knows what will be available a few years down the line.

I actually use both inputs of the ADC. Input can be switched to 3 different 'channels'
  • Analog bypass
    Channel 0 of ADC, for high impedance Arcade stuff with 1Kohm impedance and VPP 0-5V
    Channel 1 of ADC, for low impedance stuff with 75ohm impedance and VPP 0-1V.
An earlier revision/proto used the mini-din with frame-meister pinout, but I opted for the switching described above instead to keep things simple. What tilted my decision was the availability of cheap VGA breakout connectors on ebay, as people likely have to deal with some cable hackery regardless. Also, this way I have all inputs/control on the edge, so it's possible to put it in an aluminum enclosure even though this makes it more expensive and more boring looking :)

Image
Image
User avatar
donluca
Posts: 852
Joined: Sat Feb 28, 2015 8:51 pm
Location: Italy
Contact:

Re: Moar hardware: Retro Scaler A1

Post by donluca »

I'd love to see the exact opposite, something I feed whatever I want, be a 31khz arcade game, an xbox360/PS3/PS2/whatever and it spits out a correct 15khz signal for my arcade monitor.

But nice design nonetheless, I'm sure there are more than few folks out there who would grab this in a heartbeat.
User avatar
theclaw
Posts: 265
Joined: Sat Nov 26, 2011 2:41 pm

Re: Moar hardware: Retro Scaler A1

Post by theclaw »

Looks promising. A box to double 240p component to 480p component without feature creep would be nice, assuming there isn't yet.
I don't closely follow developments in scalers.
User avatar
opt2not
Posts: 1283
Joined: Fri May 20, 2011 6:31 pm
Location: Southern California

Re: Moar hardware: Retro Scaler A1

Post by opt2not »

donluca wrote:I'd love to see the exact opposite, something I feed whatever I want, be a 31khz arcade game, an xbox360/PS3/PS2/whatever and it spits out a correct 15khz signal for my arcade monitor.

But nice design nonetheless, I'm sure there are more than few folks out there who would grab this in a heartbeat.
There really is a space in the arcade market for this, now that the Ultracade UVC is harder to come by these days.
An HDMI downscale to RGBHV would be a pretty incredible project that I'm sure the arcade community would jump on.
mufunyo
Posts: 176
Joined: Thu Jun 19, 2008 11:45 am

Re: Moar hardware: Retro Scaler A1

Post by mufunyo »

donluca wrote:I'd love to see the exact opposite, something I feed whatever I want, be a 31khz arcade game, an xbox360/PS3/PS2/whatever and it spits out a correct 15khz signal for my arcade monitor.
Line halving would theoretically be possible with the exact same hardware. For primitive halving, just sample one scanline, and start outputting it at a slower rate. Meanwhile, wait for the next input scanline to finish scanning, thereby skipping it, and sample the next one after that again. Repeat for the rest of the frame. An interlaced mode would work the same, but would alternate skipping the even/odd lines each scanout period.

For advanced halving, you could buffer two scanlines, average them, and output as a single line. Interlaced mode would require buffering three lines, and use a 3-tap one-dimensional FIR filter to slightly blur the input to prevent picture trembling.

All of these methods would only work for 31KHz modes though, because they exactly halve the scan rate.
User avatar
Fudoh
Posts: 13015
Joined: Mon Mar 06, 2006 3:29 am
Location: Germany
Contact:

Re: Moar hardware: Retro Scaler A1

Post by Fudoh »

For advanced halving, you could buffer two scanlines, average them
not neccessary. It doesn't have any advantages and only results in a blurrier image, especially when the source has been filtered. Ideally you would be able to choose the starting line though (line 1 or 2).
User avatar
cvaniafan
Posts: 441
Joined: Thu Sep 25, 2008 11:03 pm
Location: Франция !

Re: Moar hardware: Retro Scaler A1

Post by cvaniafan »

Can't wait to see the final product on sale ! :)
User avatar
donluca
Posts: 852
Joined: Sat Feb 28, 2015 8:51 pm
Location: Italy
Contact:

Re: Moar hardware: Retro Scaler A1

Post by donluca »

mufunyo wrote:Line halving would theoretically be possible with the exact same hardware.
Do it.
Please.
For primitive halving, just sample one scanline, and start outputting it at a slower rate. Meanwhile, wait for the next input scanline to finish scanning, thereby skipping it, and sample the next one after that again. Repeat for the rest of the frame. An interlaced mode would work the same, but would alternate skipping the even/odd lines each scanout period.
This sounds like the best way and since it's not using buffer, I guess it's completely lag free, correct?

Also, if possible, it would be nice to leave the choice to the user to either use a halved progressive image or an interlaced one.
All of these methods would only work for 31KHz modes though, because they exactly halve the scan rate.
That's basically what I wanted, plus an integrated video amplifier and, most importantly, a DC Restore/Sync tip clamp circuit as most consoles output AC Coupled signals and an arcade monitor expects a DC Coupled one.
mufunyo
Posts: 176
Joined: Thu Jun 19, 2008 11:45 am

Re: Moar hardware: Retro Scaler A1

Post by mufunyo »

Fudoh wrote:
For advanced halving, you could buffer two scanlines, average them
not neccessary. It doesn't have any advantages and only results in a blurrier image, especially when the source has been filtered. Ideally you would be able to choose the starting line though (line 1 or 2).
Perhaps surprisingly ;), most 31KHz arcade games are actually natively 480p, and not simply doubled 240p. This would be for scaling those sources to a monitor that only does 15KHz.
donluca wrote:Do it.
Please.
Ask invzim, it's his project, and he's the VHDL guru. ;)
donluca wrote:This sounds like the best way and since it's not using buffer, I guess it's completely lag free, correct?
One scanline of lag, same as when upscaling, so that's in the order of microseconds (µs).
User avatar
invzim
Posts: 45
Joined: Tue Jul 24, 2007 8:40 am
Location: https://irkenlabs.com/
Contact:

Re: Moar hardware: Retro Scaler A1

Post by invzim »

Sorry for lack of updates, there is quite a bit of 'plumbing' to be done for this to work outside the lab with stuff like firmware updates and the like. SPI flash control is pretty much done, microSD/SDIO is up next.

About 31-15k, it's not a priority. This will be designed to be as plug&play as possible, and primarily for arcade pcb's. Not even sure how the user would switch output from 31k to 15k in an intuitive way + the output is 0-1V Vpp 75ohm impedance, which is not native arcade monitor, and further, support for such a feature would be very hard as I'm sure there is a ton of ways for the input to the scaler to be be anything but 480p :)
mufunyo
Posts: 176
Joined: Thu Jun 19, 2008 11:45 am

Re: Moar hardware: Retro Scaler A1

Post by mufunyo »

invzim wrote:About 31-15k, it's not a priority. This will be designed to be as plug&play as possible, and primarily for arcade pcb's. Not even sure how the user would switch output from 31k to 15k in an intuitive way + the output is 0-1V Vpp 75ohm impedance, which is not native arcade monitor, and further, support for such a feature would be very hard as I'm sure there is a ton of ways for the input to the scaler to be be anything but 480p :)
Doing it or not is your prerogative, obviously. 75 ohm d-sub is supported by manual sync monitors like the MS2930, and there is a definite use case for sync halving there - like soft15khz/emudriver setups that boot in 31KHz while the monitor is set to 15KHz. There are also cheap video amps available that are just a tiny board with a female VGA connector on it and some screw terminals for the output - I know it goes against the plug&play concept but considering the lack of options on the market, it sounds like people would be happy to just have the feature at all. Just blank any inputs that are out of range, maybe display "out of range" on the OSD if that's possible. As for switching the board between doubling and halving, I'd make it an option in the OSD menu that applies on the next powerup. That way you don't accidentally send 15KHz signals to a monitor dip switched to 31KHz or vice versa.
User avatar
DirkSwizzler
Posts: 548
Joined: Fri Apr 28, 2017 8:23 pm
Location: Bellevue, Washington, USA
Contact:

Re: Moar hardware: Retro Scaler A1

Post by DirkSwizzler »

Fudoh wrote:
For advanced halving, you could buffer two scanlines, average them
not neccessary. It doesn't have any advantages and only results in a blurrier image, especially when the source has been filtered. Ideally you would be able to choose the starting line though (line 1 or 2).
Blurrier, yes. But sometimes blurrier is more accurate to some people. It's easier to poke holes in point sampling techniques If you consider a white/black checkerboard pattern.

I believe in this case you'd either have jailbars with no blurring, or gray with blurring. Neither are "correct", but opinion varies on which is more accurate.
User avatar
invzim
Posts: 45
Joined: Tue Jul 24, 2007 8:40 am
Location: https://irkenlabs.com/
Contact:

Re: Moar hardware: Retro Scaler A1

Post by invzim »

Necrobump - project is not dead :)

Did a quick and dirty video with my iphone 5se, it looks a LOT better in real life and especially the drop shadow test got messed up.

https://www.youtube.com/watch?v=MUx4QuohGdg

This is Dreamcast straight to the scaler. Not that useful in itself, but it's a good source for test signals. The interlace stuff was a bit of a brain-teaser, but think I figured it out. How is the switching speed compared to other scalers?
User avatar
orange808
Posts: 3196
Joined: Sat Aug 20, 2016 5:43 am

Re: Moar hardware: Retro Scaler A1

Post by orange808 »

Just for reference, there's still a gaping hole in gaming video processing: 480i to 240p by tuning the field offsets to overlap.

A low lag box to get 240p from 480i would get significant attention and there are no good current options for that use case.
We apologise for the inconvenience
User avatar
FinalBaton
Posts: 4461
Joined: Sun Mar 08, 2015 10:38 pm
Location: Québec City

Re: Moar hardware: Retro Scaler A1

Post by FinalBaton »

orange808 wrote:A low lag box to get 240p from 480i would get significant attention and there are no good current options for that use case.
omg YES

This would be incredibly handy for many a people
-FM Synth & Black Metal-
User avatar
donluca
Posts: 852
Joined: Sat Feb 28, 2015 8:51 pm
Location: Italy
Contact:

Re: Moar hardware: Retro Scaler A1

Post by donluca »

I think this is possible with the modified firmware on the GBS board Rama is working on. I asked about the possibility of using it as a downscaler and he wrote that it's possible, but needs to make the presets.
thchardcore
Posts: 481
Joined: Wed Jun 22, 2005 9:20 am
Location: Liberal cesspool

Re: Moar hardware: Retro Scaler A1

Post by thchardcore »

I can't wait too see this project come to life. Great stuff.
A camel is a horse designed by a committee
User avatar
invzim
Posts: 45
Joined: Tue Jul 24, 2007 8:40 am
Location: https://irkenlabs.com/
Contact:

Re: Moar hardware: Retro Scaler A1

Post by invzim »

thchardcore
Posts: 481
Joined: Wed Jun 22, 2005 9:20 am
Location: Liberal cesspool

Re: Moar hardware: Retro Scaler A1

Post by thchardcore »

Awesome Christmas gift! Thank you again for all your work on this project!
A camel is a horse designed by a committee
User avatar
kitty666cats
Posts: 1270
Joined: Tue Nov 05, 2019 2:03 am
Location: Massachusetts, USA

Re: Moar hardware: Retro Scaler A1

Post by kitty666cats »

So, anyone here tried the thing out? It's been radio silence! Looks real cool, I hope to hear plenty of good things :)
thchardcore
Posts: 481
Joined: Wed Jun 22, 2005 9:20 am
Location: Liberal cesspool

Re: Moar hardware: Retro Scaler A1

Post by thchardcore »

kitty666cats wrote:So, anyone here tried the thing out? It's been radio silence! Looks real cool, I hope to hear plenty of good things :)
It's rock solid. Not a bit of jitter. Plug and play. Sharper output than any micomsoft box and just as sharp as an OSSC but much more stable. Basically turns a high end PC CRT into a BVM.
A camel is a horse designed by a committee
doonut
Posts: 28
Joined: Mon Aug 07, 2017 7:07 am

Re: Moar hardware: Retro Scaler A1

Post by doonut »

fernan1234
Posts: 2175
Joined: Mon Aug 14, 2017 8:34 pm

Re: Moar hardware: Retro Scaler A1

Post by fernan1234 »

I'd really like to check out one of these scalers. I know it was designed primarily for arcade boards, but it lists support for 480i/576i, so I'm wondering how interlaced 15khz looks like scan converted to the 31khz output. Does it look like the well-regarded de-interlaced output of the Micomsoft scalers, or maybe even better? And are in-game resolution changes (especially 480i<-->240p) handled without sync drops by this scaler?
User avatar
orange808
Posts: 3196
Joined: Sat Aug 20, 2016 5:43 am

Re: Moar hardware: Retro Scaler A1

Post by orange808 »

fernan1234 wrote:I'd really like to check out one of these scalers. I know it was designed primarily for arcade boards, but it lists support for 480i/576i, so I'm wondering how interlaced 15khz looks like scan converted to the 31khz output. Does it look like the well-regarded de-interlaced output of the Micomsoft scalers, or maybe even better? And are in-game resolution changes (especially 480i<-->240p) handled without sync drops by this scaler?
Unlikely.

Without a full frame buffer, high quality adaptive deinterlacing and frame rate conversion seem impossible.

With that said, MiSTer has an interesting pixel clock trick that might show promise for better frame rate conversion in a future device.
https://github.com/MiSTer-devel/Main_Mi ... oth-output
We apologise for the inconvenience
User avatar
Fudoh
Posts: 13015
Joined: Mon Mar 06, 2006 3:29 am
Location: Germany
Contact:

Re: Moar hardware: Retro Scaler A1

Post by Fudoh »

MiSTer has an interesting pixel clock trick that might show promise for better frame rate conversion in a future device.
either I don't understand what he's writing or that's about the silliest text I've ever read to describe a workaround that isn't really a workaround in the first place.

What he describes has been done to frame lock output refresh rates since digital video transmission existed. Timing parameters remain to spec with just the refresh being locked to the input (or emu core in this case). This naturally adjusts the pixel clock slightly up or down depending on the target refresh rate.

So, yes, it's good that frame lock is available on MISTer, but what's the big deal?

And how does this relate to frame rate conversion, when it's actually about NOT changing the frame rate at all?
User avatar
orange808
Posts: 3196
Joined: Sat Aug 20, 2016 5:43 am

Re: Moar hardware: Retro Scaler A1

Post by orange808 »

Fudoh wrote:
MiSTer has an interesting pixel clock trick that might show promise for better frame rate conversion in a future device.
either I don't understand what he's writing or that's about the silliest text I've ever read to describe a workaround that isn't really a workaround in the first place.

What he describes has been done to frame lock output refresh rates since digital video transmission existed. Timing parameters remain to spec with just the refresh being locked to the input (or emu core in this case). This naturally adjusts the pixel clock slightly up or down depending on the target refresh rate.

So, yes, it's good that frame lock is available on MISTer, but what's the big deal?

And how does this relate to frame rate conversion, when it's actually about NOT changing the frame rate at all?
Shouldn't I be able to use a partial frame buffer and manipulate the pixel clock to tolerate a certain amount of fluctuation with the incoming frame rate with a small amount of potential tearing? 240p and 480i timings should be fairly close, in theory.

Also, the MiSTer scaler seems to pull the Neo Geo MVS frame rate up to around 59.7Hz. The OSSC doesn't report frame rates perfectly, but I'm pretty sure MiSTer is changing the frame rate. I could be wrong.

A real MVS board reports 59.18Hz. The direct MiSTer analog output for MVS (without the scaler) also returns 59.18Hz.

Sorry for all the edits:
That scaler frame rate is in the MiSTer's low latency mode.
Last edited by orange808 on Mon Jan 13, 2020 5:30 pm, edited 3 times in total.
We apologise for the inconvenience
Post Reply