Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: switchres support for "VIDEOAMP" (CRT EDID alternative to ATI card & emudriver)  (Read 1334 times)

0 Members and 1 Guest are viewing this topic.

flybynight

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 76
  • Last login:May 23, 2024, 06:36:36 am
  • I want to build my own arcade controls!
Bandicoot and njz3 from the French gameoover forums have made this great little device called VIDEOAMP.

It sits between your CRT and graphics card. Any graphics card on any PC. Even a laptop. No test mode or ATI card or emudriver required.

It's compatible with the the custom modeline text file that's generated from vmmaker. The file imports into the VIDEOAMP software and flashes the EDID data.


The problem is, switchres in groovymame always picks the 2560x240 60hz value. There are 15 modelines generated and imported, I see them all listed in the windows settings display resolution drop down but swithcres always picks the same one.  I tried using the old "static" mode with the "Max number of modes" uncapped but I get the same 15x modelines regardless if I choose "dynamic" or "static" (with the mame exe and XML options" selected).

1. Could switchres be configured to dynamically set custom EDID to the VIDEOAMP like it does with emudriver and ATI cards?

2. Is there a bug in vmmaker that the old "static" mode table method no longer works?



With a few tweaks I think this VIDEOAMP device could be a really amazing solution to future proof the CRT, switchres and groovymame ecosystem since it doesn't rely on using a dedicated PC in test mode with older ATI card / older drivers. You plug in the USB/video cable to the VIDEOAMP, connect it up to the CRT as the second screen, add "screen \\.\DISPLAY2" to the mame.ini then run groovymame on your main PC still with your HDMI 4K monitor attached.
I know some people are using groovymister for this same purpose but this is a lot cheaper.

More info if you are interested:
French: https://www.gamoover.net/Forums/index.php?topic=44224.0
English: https://www.arcade-projects.com/threads/vga-video-amplifier-board-for-arcade-monitor-with-sync-filter.24936/








« Last Edit: April 25, 2024, 07:52:45 pm by flybynight »

njz3

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 5
  • Last login:Today at 02:38:03 am
  • I want to build my own arcade controls!
Yes I agree that would be nice to get a switchres support for the board.
The board's firmware uses a simple serial communication protocol to store an EDID: basically set the EDID size in 128bytes blocks (up to 30kbytes), then send a write command with a leading adress value in hexadecimal text and a chunk of 16 bytes encoded also in hexadecimal.
What could be tricky is to perform a re-read of the EDID without restarting the whole graphics stack.

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1479
  • Last login:May 23, 2024, 05:01:23 am
  • retro maniac
Never heard of this project. Looks really interesing. Would it work with 2 CRTs? Assuming that I need two VideoAmps.

Is there any site where I can buy this VideoAmp ? I see people are taking straight from bandicoot.
« Last Edit: May 13, 2024, 02:52:13 am by haynor666 »

flybynight

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 76
  • Last login:May 23, 2024, 06:36:36 am
  • I want to build my own arcade controls!
I sent a PM to njz3 and bought one through paypal. This was a while ago so there may be a web shop now.

It's actually a great little device because I can use my main gaming PC for both CRT emulation and as the main PC gaming.

Before I needed a separate PC for emudriver/CRT because I couldn't do regular gaming on it (once the epicgames loader detected TEST mode in Windows it wouldn't load the PC games, not to mention the R9 380 card was getting a bit old).


bandicoot

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 116
  • Last login:May 22, 2024, 01:53:20 am
yes you can contact me or NJZ3 ;)

njz3

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 5
  • Last login:Today at 02:38:03 am
  • I want to build my own arcade controls!
I added more verbose traces for the communication when using the videoampcmd.exe command line tool.
If Calamity reads this topic, maybe he can find this information helpful to add the support for the videoamp into switchres/groovymame.

Here are some outputs of examples commands, all in text format.

Get status from the board at COM4 baudrate 500000:
Code: [Select]
$ ./VideoampCmd.exe -status -verbose
[USBSerial] Opened port COM4 at 500000
[USBSerial] SEND>>U
[USBSerial] RECV<<Mhsy=0 frq=0.00 dip=0 min=0.00 max=0.00 edi=0
[USBSerial] SEND>>F
[USBSerial] RECV<<Mfmi0=14500.00 fma0=16000.00 fen0=0 fmi1=23500.00 fma1=25500.00 fen1=0 fmi2=29000.00 fma2=31500.00 fen2=0 fmi3=0.00 fma3=80000.00 fen3=0
[USBSerial] SEND>>$get edidmode
[USBSerial] RECV<<Medidmode=801
[USBSerial] SEND>>$get edidpid
[USBSerial] RECV<<Medidpid=5
[USBSerial] SEND>>$get edidseg
[USBSerial] RECV<<Medidseg=1
Status:
        Firmware ver.=  0.3.2.24
        Board type=     0x0
        Serial number=  0x0
        Sync active=    0
        Current Freq=   0.00
        DIP switches=   0000
        Min Frequency=  0.00
        Max Frequency=  0.00
        EDID Bus Read=  0
        EDID VideoMode= 0x0801
        EDID ProductID= 0x0005
        EDID Segments=  1
[USBSerial] Closing port COM4
Now more explanations on the text commands we can see:
- the board wait for a first character that is either a command by itself, or a "long" command starting with a special "$" character.
- the board replies with messages starting by letter "M" (for Message)
- "U" command returns : hsync (hsy) enable (1) or not (0), current measured hsync frequency (frq), Dip switch position (dip), current filter range (min)/(max), number of reads of the EDID performed by the computer (edi)
- "F" command returns the 4 filter banks parameters: min (fmi0), max (fma0), always enabled (fen0)
- "$get edidmode" long command to get EDID mode of the board (reserved for internal use).
- "$get edidpid" long command to get EDID product ID (reserved for internal use).
- "$get edidset" long command to get EDID buffer size expressed in 128-bytes segments.

Set a 128 bytes EDID from a file "generic_15.bin" (obtained from switchres) into the board's eprom, still at COM4 baudrate 500000:
Code: [Select]
$ ./VideoampCmd.exe -edid generic_15.bin -verbose
[USBSerial] Opened port COM4 at 500000
Set EDID mode to external
[USBSerial] SEND>>$set edidmode=0801
[USBSerial] RECV<<MSet uint16 edidmode to 0x801
EDID to write:
0x0000: 00 FF FF FF FF FF FF 00 4E F2 00 00 00 00 00 00
0x0010: 05 1F 01 03 6D 30 24 78 0A 5E C0 A4 59 4A 98 25
0x0020: 20 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
0x0030: 01 01 01 01 01 01 8B 02 40 60 10 F0 15 00 0D 1F
0x0040: 23 00 E5 6C 11 00 00 18 00 00 00 FF 00 53 77 69
0x0050: 74 63 68 72 65 73 32 30 30 0A 00 00 00 FD 00 31
0x0060: 41 0F 0F FF 00 0A 20 20 20 20 20 20 00 00 00 FC
0x0070: 00 67 65 6E 65 72 69 63 5F 31 35 00 00 0A 00 05
Number of 128-bytes segments: 1
[USBSerial] SEND>>$set edidseg=0001
[USBSerial] RECV<<MSet uint8 edidseg to 0x1
[USBSerial] SEND>>$setedid 0000 00 FF FF FF FF FF FF 00 4E F2 00 00 00 00 00 00
[USBSerial] RECV<<MEDID set at 0x0000: 00 FF FF FF FF FF FF 00 4E F2 00 00 00 00 00 00
[USBSerial] SEND>>$setedid 0010 05 1F 01 03 6D 30 24 78 0A 5E C0 A4 59 4A 98 25
[USBSerial] RECV<<MEDID set at 0x0010: 05 1F 01 03 6D 30 24 78 0A 5E C0 A4 59 4A 98 25
[USBSerial] SEND>>$setedid 0020 20 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
[USBSerial] RECV<<MEDID set at 0x0020: 20 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
[USBSerial] SEND>>$setedid 0030 01 01 01 01 01 01 8B 02 40 60 10 F0 15 00 0D 1F
[USBSerial] RECV<<MEDID set at 0x0030: 01 01 01 01 01 01 8B 02 40 60 10 F0 15 00 0D 1F
[USBSerial] SEND>>$setedid 0040 23 00 E5 6C 11 00 00 18 00 00 00 FF 00 53 77 69
[USBSerial] RECV<<MEDID set at 0x0040: 23 00 E5 6C 11 00 00 18 00 00 00 FF 00 53 77 69
[USBSerial] SEND>>$setedid 0050 74 63 68 72 65 73 32 30 30 0A 00 00 00 FD 00 31
[USBSerial] RECV<<MEDID set at 0x0050: 74 63 68 72 65 73 32 30 30 0A 00 00 00 FD 00 31
[USBSerial] SEND>>$setedid 0060 41 0F 0F FF 00 0A 20 20 20 20 20 20 00 00 00 FC
[USBSerial] RECV<<MEDID set at 0x0060: 41 0F 0F FF 00 0A 20 20 20 20 20 20 00 00 00 FC
[USBSerial] SEND>>$setedid 0070 00 67 65 6E 65 72 69 63 5F 31 35 00 00 0A 00 05
[USBSerial] RECV<<MEDID set at 0x0070: 00 67 65 6E 65 72 69 63 5F 31 35 00 00 0A 00 05
[USBSerial] SEND>>$savecfg
[USBSerial] Closing port COM4
Here are the explanations:
- the protocol always expects unsigned hex digits (2/4/8 depending on the integer) or float32 values.
- to set a value, a long command using "$" is needed.
- to set the EDID data, many chunks of 16 bytes in hex is used.
- "$set edidmode=0801" long command set the edidmode value to hex 0801 (external binary EDID).
- "$set edidseg=0001" long command set the number of 128bytes segments for the EDID to hex 0001 (1 segment of 128 bytes).
- "$setedid 0000 00 FF FF FF FF FF FF 00 4E F2 00 00 00 00 00 00" long command set 16 bytes of the EDID binary buffer at offset 0x0000 to the bytes 00 FF FF FF FF FF FF 00 4E F2 00 00 00 00 00 00.
- "$savecfg" save the current edid configuration (mode and segment number) to internal eprom.
« Last Edit: May 17, 2024, 05:47:43 am by njz3 »

Substring

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 819
  • Last login:Yesterday at 03:26:31 am
  • Forking GroovyArcade
    • forum.arcadecontrols.com/index.php/topic,160023.0.html
    • GroovyArcade active fork
I can't understand the need of setting on the fly an EDID for modeswitching. That is almost absurd : you need to trigger a read of the EDID at OS level. This is slow, has got a massive impact on the OS. So why ?

flybynight

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 76
  • Last login:May 23, 2024, 06:36:36 am
  • I want to build my own arcade controls!
Is it not needed for the random dynamic resolutions in mame.ini:
monitor custom
Otherwise it's stuck with the 10x or so pre-set hard coded resolutions?
« Last Edit: May 20, 2024, 10:09:55 am by flybynight »

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1479
  • Last login:May 23, 2024, 05:01:23 am
  • retro maniac
yes you can contact me or NJZ3 ;)

I would interested but if this work on two CRT setup ?

njz3

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 5
  • Last login:Today at 02:38:03 am
  • I want to build my own arcade controls!
You need one video output port per monitor on your computer video adapter, and 1xvideoamp per monitor.
What would be your use case?

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1479
  • Last login:May 23, 2024, 05:01:23 am
  • retro maniac
I have videocard with DVI-I output (via VGA to DVI modules) and VGA. I'm using one CRT for vertical games ans second for horizontal games but pictures are independent so CRT horizontal is DISPLAY1 and vertical is DISPLAY2 so I assume I need two videoamps.

But there is plan to use two videocards (more powerfull - needed for flycast and other "hungry" emulators), each with one DVI-I or VGA.
« Last Edit: May 23, 2024, 03:27:54 am by haynor666 »

njz3

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 5
  • Last login:Today at 02:38:03 am
  • I want to build my own arcade controls!
It should work given you have 2 analog outputs.
Each monitor will appear as a "standard" monitor for your OS.