GBS 8200/8220 CFW Project

The place for all discussion on gaming hardware
Ryoandr
Posts: 269
Joined: Mon Jun 12, 2017 4:12 am

Re: GBS 8200/8220 CFW Project

Post by Ryoandr »

that's weird, I get user preset errors now

userprefs open failed
saveUserPrefs: open file failed
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

Hey roxas232,
those are bogus values. The I2C communication isn't working.
Have you set the jumper to disable the original MCU?
Are your cables okay?

@Ryoandr
SPIFFS is set to 4M (1M SPIFFS)?
roxas232
Posts: 2
Joined: Thu Jul 25, 2019 11:40 pm

Re: GBS 8200/8220 CFW Project

Post by roxas232 »

Thanks rama, I reseated the cables and it seems to work! Sadly my capture card hates the input but not sure there's much I can do about that. Looks super nice on my lcd monitor though. Wish my pexhdcap was less finicky!
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

Hmm, that's odd.
Doesn't the card accept any preset?
At least one of them should work, I'd hope.
Is this a 50Hz source by chance?
tomrev
Posts: 23
Joined: Tue Jul 02, 2019 4:31 am

Re: GBS 8200/8220 CFW Project

Post by tomrev »

When I play PS2 NTSC 240p game like ICO and looking for gbs's register to report input as progressive mode but S0_00[3] show as 1 which mean interlaced mode. It is the same as 480i input.


How to distinct between 240p and 480i?
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

Nice, you read the docs! ;D

What you see is the Mode Detect unit result.
That unit simply counts the number of lines per field, and if it matches the programmable count, it reports it as the SD mode.
The actual difference between 240p and 480i is within a single line though, so that unit is too coarse to make a distinction.

I poll the Input Formatter line counter instead, which has better precision (but no status readouts).
You can see that line count in information mode as the "v: xxx" readout.
If you switch between 240p / 480i, you'll notice that the line count changes by 1 exactly.

So yeah, the chip is great hardware, but it doesn't always make it easy ;p
tomrev
Posts: 23
Joined: Tue Jul 02, 2019 4:31 am

Re: GBS 8200/8220 CFW Project

Post by tomrev »

rama wrote:Nice, you read the docs! ;D

What you see is the Mode Detect unit result.
That unit simply counts the number of lines per field, and if it matches the programmable count, it reports it as the SD mode.
The actual difference between 240p and 480i is within a single line though, so that unit is too coarse to make a distinction.

I poll the Input Formatter line counter instead, which has better precision (but no status readouts).
You can see that line count in information mode as the "v: xxx" readout.
If you switch between 240p / 480i, you'll notice that the line count changes by 1 exactly.

So yeah, the chip is great hardware, but it doesn't always make it easy ;p
How decryptic. :D I got it. Thank you, rama.
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

Can this device (or CFW) convert arcade RGB voltage levels to VGA levels?

For example, most arcade PCBs output RGB at 0-4v (from what I've heard), but VGA uses 0-0.7v p-p. I don't want any color space conversions, resolution scaling, etc. I simply want to input RGB at high levels (0-4v) and get RGB back out at 0-0.7v.

The chain would look like: Arcade PCB -> GBS8200 -> DB15 output.

The DB15 output would be fed into a separate RGB (VGA) to Component transcoder.

Ideally I'd like perfect output quality since I don't need any scaling or anything. Is the GBS8200 with or without CFW capable of this?
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

sofakng wrote:Can this device (or CFW) convert arcade RGB voltage levels to VGA levels?

For example, most arcade PCBs output RGB at 0-4v (from what I've heard), but VGA uses 0-0.7v p-p. I don't want any color space conversions, resolution scaling, etc. I simply want to input RGB at high levels (0-4v) and get RGB back out at 0-0.7v.

The chain would look like: Arcade PCB -> GBS8200 -> DB15 output.

The DB15 output would be fed into a separate RGB (VGA) to Component transcoder.

Ideally I'd like perfect output quality since I don't need any scaling or anything. Is the GBS8200 with or without CFW capable of this?
No it is not, you would want a video buffer IC like the THS series with a resistor divider on the inputs to bring the levels down
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

Do you know of any example circuits or PCBs that can do what I need? (or other pre-built devices)
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

sofakng wrote:Do you know of any example circuits or PCBs that can do what I need? (or other pre-built devices)
Only thing would be the various superguns out there
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

OK, I'll have to do some extra research.

Can the GBS8200 accept RGB TTL (Arcade PCB voltage, 0-4v etc) and convert it to safe VGA levels? (even if it does require it to be scaled, etc)

I'm just wondering if I can use the GBS8200 temporarily until I get a supergun for better quality (i.e. no conversions except voltage levels).
tomrev
Posts: 23
Joined: Tue Jul 02, 2019 4:31 am

Re: GBS 8200/8220 CFW Project

Post by tomrev »

sofakng wrote:OK, I'll have to do some extra research.

Can the GBS8200 accept RGB TTL (Arcade PCB voltage, 0-4v etc) and convert it to safe VGA levels? (even if it does require it to be scaled, etc)

I'm just wondering if I can use the GBS8200 temporarily until I get a supergun for better quality (i.e. no conversions except voltage levels).
GBS82xx does not compatible with any input more than 3.xx volt. You must reduce voltage by voltage divider circuit.
User avatar
Nuck-TH
Posts: 18
Joined: Tue Apr 23, 2019 12:52 pm

Re: GBS 8200/8220 CFW Project

Post by Nuck-TH »

What are you all talking about? Potentiometers on the input is exactly that "divide circut".
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

Nuck-TH wrote:What are you all talking about? Potentiometers on the input is exactly that "divide circut".
Lol you're totally right, I completely forgot about those pots since I desoldered them off my board immediately when I got it
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

OK - That's what I thought. The potentiometers adjust the resistance and thus the output voltage level, right?

Does that mean I can fed it RGB TTL (2-5v p-p) and output 15 kHz VGA (0.7 p-p) ?
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

sofakng wrote:OK - That's what I thought. The potentiometers adjust the resistance and thus the output voltage level, right?

Does that mean I can fed it RGB TTL (2-5v p-p) and output 15 kHz VGA (0.7 p-p) ?
If you use CFW, there is a pass through mode to output 15kHz (RGBHV at 700mVpp)

I don't know what the values are on the pots, but 5Vpp is probably pushing it - most arcade boards are ~3-3.5Vpp
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

sofakng:
Please remember to report how it went ;p

Ryoandr:
I managed to get some improvement out of the WiFi situation.
The server will now disconnect very slow clients, stopping the program stalls when it happen.
Logging format changes now happens as late as possible, so even if the new preset disturbs WiFi, there'll be a picture at least.
The website won't be as aggressive trying to reconnect, as that only saturates the few packets that get through.

Overall, this smoothes out a bad situation a little.
It's still much recommended to just move the ESP8266 away from the scaler.
Having the ESP8266 module next to the GBS board, to the right for example, is enough to fix the issue here.
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

rama wrote:sofakng:
Please remember to report how it went ;p
Well, it does appear to be working and nothing is dead so that's a plus! :)

I've also setup the GBS Control software and it's working perfectly too. I'm still concerned about the RGB TTL level but if anything is going to fry it should be the GBS and not anything after (i.e. OSSC, etc), right? :)
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

I'm not sure what they put on superguns for protection, but don't expect the GBS to have it.
The common GBS board only has minimal protection against ESD, for example.

It will accept and convert pretty high level video. Up to 1.0V is in the ADC range.
And it will not *generate* anything above ~0.8Vpp on the RGB output and ~3.3Vpp on the HV Sync outputs.

What I can't promise though is that it protects against anything nasty that your arcade board may do.
If there's an electrostatic discharge for example, that could travel right through to your other devices.
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

Ahhh, OK. I was trying to understand your comment in the issues page on Github. (I'm trying to learn electronics but still just a beginner)

So the ADC accepts up to 1.0v and the potentiometers reduce the incoming voltage so it's below 1.0v? Therefore, if the incoming RGB TTL is ~2-5v then the potentiometers reduce it before the ADC?

I also understand what you're saying about the output. It sounds like unless something unexpected happens, the GBS will always output safe (0.7v) RGB levels. (but it can't protect against something bad happening causing a higher voltage)
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

Yep, more or less that's the gist of it.

I can't tell what RGB levels will appear at the ADC inputs, but if you check the GBS output, the colors should not be crushed / overly bright.
It's best to verify this with a test image. Hopefully your arcade board has one.
sofakng
Posts: 216
Joined: Fri Sep 02, 2016 1:30 am

Re: GBS 8200/8220 CFW Project

Post by sofakng »

Awesome ... is the goal of the potentiometers to reduce the incoming voltage to exactly 1.0v (or 0.7v) (i.e. safe level for the ADC inputs) ?
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

just an aside - it is not proper to refer to video coming from arcade boards as "RGB TTL"

TTL RGB is used in CGA and EGA PC graphics cards to transmit digital RGB (subpixel fully on or fully off, represented by logic high or logic low)

arcade boards use regular analog RGB, at higher amplitude
Last edited by maxtherabbit on Wed Jul 31, 2019 12:57 am, edited 1 time in total.
User avatar
maxtherabbit
Posts: 1763
Joined: Mon Mar 05, 2018 4:03 pm

Re: GBS 8200/8220 CFW Project

Post by maxtherabbit »

sofakng wrote:Awesome ... is the goal of the potentiometers to reduce the incoming voltage to exactly 1.0v (or 0.7v) (i.e. safe level for the ADC inputs) ?
yes, they form a voltage divider along with the termination resistors to bring the incoming levels down within the ADC's sampling range
tomrev
Posts: 23
Joined: Tue Jul 02, 2019 4:31 am

Re: GBS 8200/8220 CFW Project

Post by tomrev »

Does GBS82xx have capability to process pixel perfect? It may not the main functionality but it's my curiousity.
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

If asked like that, sure :p
At a high level, the unit has a processing chain that allows digitization of 1024 distinct horizontal pixels at however many lines.
That digital data can then be mapped onto a perfectly fitting output resolution (line doubling, scaling at integer multiples with no interpolation, etc).

That's just the high level view though.
In practice, there are many details that make a full purist approach impractical or that won't produce the desired results.
For example, all digital processing is done in a 4:2:2 YUV color space, using filters to work with the reduced UV resolution.
These filters are good, but probably not perfect, so a carefully crafted test image could expose them.

Overall, it's best not to try and emulate an OSSC, but rather the Framemeister.

Edit:
Oh, and an easy cop out to that question:
Use bypass mode and manually tune in a perfect ADC sample rate.
That's it, perfect processing and it's in 4:4:4 directly to the output.
Ryoandr
Posts: 269
Joined: Mon Jun 12, 2017 4:12 am

Re: GBS 8200/8220 CFW Project

Post by Ryoandr »

Hey rama, sorry for not responding sooner, so settings not saving was because of no SPIFFS (probably happened because of library update)
Tried different wifi channels and 13 (the highest possible) is definitively the better, I had no problem in AP during a demo I made with an MVS even with 640x480, note that I have the ESP fairly far from the scaler chip also.
rama
Posts: 1373
Joined: Wed Mar 08, 2017 3:15 pm

Re: GBS 8200/8220 CFW Project

Post by rama »

I've just changed the default AP channel to 11, the highest internationally allowed one.
But which channel it is isn't so important, as the disturbance is a function of the source HSync timing and the programmed H-PLL in the 5725.
You can easily provoke the issue by incrementing the "PLL divider" in the web ui a little. It'll shift the EMI into the range of where it affects the ESP8266 radio.

I don't know why it failed even with the ESP8266 moved away.
But it's telling that you had issues at certain presets only.
This is definitely an EMI problem, so moving the ESP8266 away from that source should fix it.

The blocking nature of the websockets library I use doesn't help either. Any brief disturbance can cause a 2 second delay in the sketch.
I've since changed the code a little to address this, but it looks like I need to switch to the async version of the library.
Lots of work, and I'm not sure it will actually help with the issue :/
tomrev
Posts: 23
Joined: Tue Jul 02, 2019 4:31 am

Re: GBS 8200/8220 CFW Project

Post by tomrev »

I make a tutorial video for setup gbs-control.

Step by step GBS8200 / GBS8220 gbs-control minimal setup for beginner in 7 minutes.
https://youtu.be/MIrtcO7L3Zk
Post Reply