The NEW Build Your Own Arcade Controls

Software Support => GroovyMAME => Topic started by: Doozer on March 12, 2019, 08:37:38 am

Title: Linux 15kHz patches
Post by: Doozer on March 12, 2019, 08:37:38 am
I have released the latest 15 kHz patches with additional features in a dedicated repository.

The purpose of this repository is to keep the 15 kHz patches synchronized with future kernel releases.

Optional patches are also available to make groovymame experience even more realistic and similar to real hardware. If running groovymame is not targetted, they can be omitted.


Link: https://github.com/D0023R/linux_kernel_15khz (https://github.com/D0023R/linux_kernel_15khz)
Title: Re: Linux 15kHz patches
Post by: donluca on March 12, 2019, 05:56:52 pm
Wow, thanks for this! I'll definitely take a peek.

Also, this means we can now make our own GroovyMAME distro, right?
Title: Re: Linux 15kHz patches
Post by: keilmillerjr on March 12, 2019, 11:39:24 pm
Woohoo for linux support! What would be different to the end user in lamens terms with the optional scanline reporting position patch?
Title: Re: Linux 15kHz patches
Post by: Doozer on March 13, 2019, 04:12:41 am
Woohoo for linux support! What would be different to the end user in lamens terms with the optional scanline reporting position patch?

In the current GM release having a kernel with the scanline patch will change nothing. The system will behave exactly the same way.

Somewhere in the future, GM might be enhanced with a set of new functions that would enable better frame_delay mechanism. Still, the patch will be optional and the system will detect if the kernel has it applied or not to select the appropriate method.

Title: Re: Linux 15kHz patches
Post by: Substring on March 13, 2019, 05:42:28 am
Looks like making a linux-15khz arch kernel package could be useful for GroovyArcade (easier build, easier updates) ! I'll have a look at it in the coming days
Title: Re: Linux 15kHz patches
Post by: Calamity on March 14, 2019, 11:38:04 am
In the future, I'd like that custom-kHz kernel mode setting is achieved through EDID emulation rather than kernel hardcoded modelines. This has been succesfully tested in the past but has never been implemented in a customizable way.
Title: Re: Linux 15kHz patches
Post by: Substring on March 14, 2019, 05:01:21 pm
In the future, I'd like that custom-kHz kernel mode setting is achieved through EDID emulation rather than kernel hardcoded modelines. This has been succesfully tested in the past but has never been implemented in a customizable way.

Do you mean something like https://github.com/Ansa89/linux-15khz-patch/tree/master/edid ?
Title: Re: Linux 15kHz patches
Post by: Doozer on March 15, 2019, 08:08:57 am
In the future, I'd like that custom-kHz kernel mode setting is achieved through EDID emulation rather than kernel hardcoded modelines. This has been succesfully tested in the past but has never been implemented in a customizable way.

I must admit that I never tested custom EDID solution via kernel commandline. I was convinced that this would work with recent monitor but not usable on CRT. If it was successfully tested, does it means that the EDID can override the ppl dot clock limitation in the driver? I always used it in combination with the 15 kHz patch.
Title: Re: Linux 15kHz patches
Post by: Substring on March 15, 2019, 09:25:16 am
EDID is supposed to provide the different modes that are supported by a screen. If that means writing modes for every possible resolutions, or just a few custom super resolutions, we'd need to check that the EDID standard allows more than 1 custom mode, which I doubt.
Title: Re: Linux 15kHz patches
Post by: Calamity on March 15, 2019, 02:02:03 pm
EDID is supposed to provide the different modes that are supported by a screen. If that means writing modes for every possible resolutions, or just a few custom super resolutions, we'd need to check that the EDID standard allows more than 1 custom mode, which I doubt.

No, I don't mean that. Using EDID overrides as the custom video source for emulation is a big step backwards.

I mean this (http://forum.arcadecontrols.com/index.php/topic,140215.msg1447520.html#msg1447520).

This is meant for the boot process only. Once you launch X, it's X which handles custom video through X modelines, in a totally flexible way.

What this allows is to boot at 15 kHz with a stock kernel.

(Or any random frequency, not everything is 15 kHz).
Title: Re: Linux 15kHz patches
Post by: Doozer on March 16, 2019, 02:07:03 am

I will do some fresher tests to confirm.
Title: Re: Linux 15kHz patches
Post by: Doozer on March 16, 2019, 02:27:36 am

I did run some tests and I can confirm that the EDID parameter on the kernel command line is indeed doing the job. It means that 15kHz is perfectly doable without the 15 kHz patch.

Only issue is with the interlaced resolution. In such a case you still need to apply the fix to get the correct emulation speed. This can be resolved with next GM development and timing the vblank.

Forcing another resolution via xorg.conf is no more possible. Using xrandr and libdrm is working as expected. Groovymame video output is not impacted.

Code: [Select]
[   664.729] (II) RADEON(0): EDID vendor "SWR", prod id 0
[   664.729] (II) RADEON(0): Using hsync ranges from config file
[   664.729] (II) RADEON(0): Using vrefresh ranges from config file
[   664.729] (II) RADEON(0): Printing DDC gathered Modelines:
[   664.729] (II) RADEON(0): Modeline "768x576i"x0.0   14.87  768 792 864 952  576 582 587 625 interlace -hsync -vsync (15.6 kHz eP)
Title: Re: Linux 15kHz patches
Post by: Substring on May 07, 2019, 04:15:15 am
Thank you for being so reactive and keeping your patches always up to date ! that really saved me some time with the 5.1 bump ;)
Title: Re: Linux 15kHz patches
Post by: Substring on May 15, 2019, 02:44:35 pm

I did run some tests and I can confirm that the EDID parameter on the kernel command line is indeed doing the job. It means that 15kHz is perfectly doable without the 15 kHz patch.

Only issue is with the interlaced resolution. In such a case you still need to apply the fix to get the correct emulation speed. This can be resolved with next GM development and timing the vblank.

Forcing another resolution via xorg.conf is no more possible. Using xrandr and libdrm is working as expected. Groovymame video output is not impacted.

Code: [Select]
[   664.729] (II) RADEON(0): EDID vendor "SWR", prod id 0
[   664.729] (II) RADEON(0): Using hsync ranges from config file
[   664.729] (II) RADEON(0): Using vrefresh ranges from config file
[   664.729] (II) RADEON(0): Printing DDC gathered Modelines:
[   664.729] (II) RADEON(0): Modeline "768x576i"x0.0   14.87  768 792 864 952  576 582 587 625 interlace -hsync -vsync (15.6 kHz eP)

Which kernel version were you using ? I've tried with arch 5.1.2 in virtual box, i get no EDID message in kernel log, and xorg reports the EDID from virtual box ... I've seen a bug at freedesktop mentionning it was broken since 4.15 ...
Title: Re: Linux 15kHz patches
Post by: Doozer on May 18, 2019, 10:23:10 am

I did run some tests and I can confirm that the EDID parameter on the kernel command line is indeed doing the job. It means that 15kHz is perfectly doable without the 15 kHz patch.

Only issue is with the interlaced resolution. In such a case you still need to apply the fix to get the correct emulation speed. This can be resolved with next GM development and timing the vblank.

Forcing another resolution via xorg.conf is no more possible. Using xrandr and libdrm is working as expected. Groovymame video output is not impacted.

Code: [Select]
[   664.729] (II) RADEON(0): EDID vendor "SWR", prod id 0
[   664.729] (II) RADEON(0): Using hsync ranges from config file
[   664.729] (II) RADEON(0): Using vrefresh ranges from config file
[   664.729] (II) RADEON(0): Printing DDC gathered Modelines:
[   664.729] (II) RADEON(0): Modeline "768x576i"x0.0   14.87  768 792 864 952  576 582 587 625 interlace -hsync -vsync (15.6 kHz eP)

Which kernel version were you using ? I've tried with arch 5.1.2 in virtual box, i get no EDID message in kernel log, and xorg reports the EDID from virtual box ... I've seen a bug at freedesktop mentionning it was broken since 4.15 ...
Hi,

Not sure virtual box is emulating edid feature on the virtual video output. The standard kernel driver or specific virtio must be checked to see if edid helper is provided.
Title: Re: Linux 15kHz patches
Post by: Substring on May 18, 2019, 12:31:58 pm
Hi,

Not sure virtual box is emulating edid feature on the virtual video output. The standard kernel driver or specific virtio must be checked to see if edid helper is provided.
Oh well, I'm good to test this straight on a computer rather than a VM .. too bad