Software Support > GroovyMAME

GroovyArcade live-CD 2022 (collaborative effort)

<< < (110/112) > >>

ondafly:

--- Quote from: Substring on January 20, 2024, 12:35:07 pm ---Got a 705 G4 with a ryzen 2200G. It had 3 DP outputs, but I managed to find a VGA plugin card to replace the 1st DP connector. Works good, but you'd better go with EDID emulation.

--- End quote ---

Just seeing this now - apologies. I went with 15hz at the initial install and later selected Tri-sync monitor. What I have noticed is on the AttractPlus page - a graphical flicker/glitch which goes away. Hopefully not a CAP issue, although I've had this screen for many many many years.

Video of it happening. Only happens on the Attract screen.
https://youtu.be/hmFFXljDtzg?si=1_fTaABU4Ubb7-bR

Whereas on the desktop - which I think might be 30hz ? its mostly fine
https://youtube.com/shorts/FripR_XncEw

Can I change do EDID emulation at this stage ? or should I reinstall ?

Substring:
No that's a mesa problem, and I couln't find the root cause of the problem sadly. To fix it, run sudo pacman -U https://archive.archlinux.org/packages/m/mesa/mesa-23.0.3-1-x86_64.pkg.tar.zst https://archive.archlinux.org/packages/l/llvm-libs/llvm-libs-15.0.7-3-x86_64.pkg.tar.zst from the command line

intealls:
Hi Calamity and Substring, and first just wanted to say, AWESOME work on groovy+drmkms! Really cool having an X-less setup, and reminds me of AdvanceMAME!

The last few days I've been messing around with putting together a highly optimized setup with some new audio synchronization code I've been working on, which should allow for under/overrun free playback when no frames are dropped and a decent estimate is found. This usually takes a couple of seconds. It uses a finer granularity than the soundsync currently in groovy, and is quite restrictive with the estimate, so there should be no audible pitch shifts. I've attached a plot of the number of samples in the audio buffer during a 6-ish minute run of Sonic Wings 2, the buffered number of samples seem to consistently be less than 1 millisecond!

I've patched the 6.5 linux-rt arch package with the 15khz patches, and done everything here https://wiki.archlinux.org/title/Professional_audio . It's currently running on an i5-4690K@4.6 GHz, with idle=poll as an added kernel boot option. I'm using a R7 260 and have blacklisted the amdgpu driver, so the radeon driver is used. I'm not sure the -rt package improve things substantially, but it doesn't seem to hurt.

The complete kernel boot is BOOT_IMAGE=/vmlinuz-linux-rt root=/dev/disk/by-uuid/305991b6-4ba1-4094-8b80-5d3ebc1966aa rw quiet rd.udev.log-priority=3 mitigations=off audit=0 consoleblank=0 monitor=generic_15 video=DVI-I-1:640x240S idle=poll drm.edid_firmware=DVI-I-1:edid/generic_15.bin initrd=/initramfs-linux-rt.img

I'm using

groovyarcade/sdl2 2.28.5-2 [installed]
extra/mesa 1:23.3.5-1 [installed: 23.0.3-1]
linux-rt-6.5.2.8.realtime1-1 with 15 khz patches applied

6.5 seems to work fine. With 6.6 or later I get issues (black screen when starting GM).

I found that the latest mesa package (23.3.5) seems to break (or at least impair) next frame response? When installing 23.0.3 as suggested earlier in the thread it seems to work fine.

I have one issue though I really hope can be sorted - and that is that you have to launch the games directly (not from the MAME UI) in order to get a working display.

When looking through the logs I can see this:

First run (mame aes -cart sonicwi2):

--- Code: ---Available videodrivers: x11 wayland KMSDRM offscreen dummy evdev
Current Videodriver: KMSDRM
Display #0
Desktop Mode:         640x240-32@60
Current Display Mode: 640x240-32@60
Renderdrivers:
    opengl (0x0)
opengles2 (0x0)
  software (0x0)
...
Switchres: Monitor range 15625.00-15750.00,49.50-65.00,2.000,4.700,8.000,0.064,0.192,1.024,0,0,192,288,448,576
parsing /etc/switchres.ini
Switchres/SDL2: Detected SDL version 2.30.0 on KMSDRM
Switchres: get_mode(0) 320 224 59.185606 1.333333
Switchres: Calculating best video mode for 320x224@59.185608 orientation: normal
Switchres: Modeline "320x224_59 15.625000KHz 59.185608Hz" 6.734375 320 339 370 431 224 235 238 264   -hsync -vsync
SwitchRes: Setting option -nokeepaspect
SwitchRes: Setting option -nounevenstretch
SwitchRes: Setting option -nounevenstretchx
SwitchRes: Setting option -waitvsync
SwitchRes: Setting option -syncrefresh
SwitchRes: Setting option -nofilter
drm_open: /dev/dri/card0 successfully opened
OpenGL: AMD
OpenGL: BONAIRE (, LLVM 15.0.7, DRM 2.50, 6.5.2.8.realtime1-1-rt)
OpenGL: 4.5 (Compatibility Profile) Mesa 23.0.3
OpenGL: texture rectangle supported
OpenGL: non-power-of-2 textures supported (new method)
OpenGL: vertex buffer supported
OpenGL: pixel buffers supported
OpenGL: framebuffer object supported
OpenGL: GLSL supported, but disabled
OpenGL: max texture size 16384 x 16384
Leave renderer_ogl::create
...

--- End code ---
When launching a new cart from within the UI:

--- Code: ---...
Available videodrivers: x11 wayland KMSDRM offscreen dummy evdev
Current Videodriver: offscreen
Display #0
Desktop Mode:         1024x768-24@0
Current Display Mode: 1024x768-24@0
Renderdrivers:
    opengl (0x0)
opengles2 (0x0)
  software (0x0)
...
Leave sdlwindow_init
Enter sdl_info::create
Switchres: Monitor range 15625.00-15750.00,49.50-65.00,2.000,4.700,8.000,0.064,0.192,1.024,0,0,192,288,448,576
parsing /etc/switchres.ini
Switchres/SDL2: (sdl2_display): SDL2 is only available for KMSDRM for now.
DRM/KMS: <1> (get_master_fd) No way to get master rights!
DRM/KMS: <1> (init) [ERROR] limited DRM rights on this screen
DRM/KMS: <1> (init) [ERROR] no screen detected
drm_open: /dev/dri/card0 successfully opened
Leave renderer_ogl::create
...

--- End code ---

I've attached the full log. At this point I'm not sure where to start looking, since launching games from the UI seemed to work better with mesa 23.3.5? Any pointers are appreciated. I tried closing the drm file descriptor in video_opengl::exit but this doesn't seem to help.

Edit: mesa 23.1.4 seems fine both in regards to next-frame response and launching/switching games from the UI.

Substring:
Hey !

so a few things about what you've posted :
- the RT patch hasn't proven being worth it. We couldn't get anything better with it, so I don't provide it. But I do provide the LTS kernel if you wish
- your boot resolution is a little messed : you're mixing a kernel built-in resolution with an EDID. Not really worth honnestly
- MESA is evil, definitely. I couldn't bisect the error when building it myself, nor could I reproduce the bug when self building it. I must have done something wrong, but it takes such a long time ....

Now for the real problem : you can't launch 2 games when using the MAME UI ? On the launch with error, can you check the contents of /sys/kernel/debug/dri/0/clients (or 1 instead of 0) and show the output ? you should see mame having master rights

intealls:

--- Quote from: Substring on February 11, 2024, 06:16:44 am ---- the RT patch hasn't proven being worth it. We couldn't get anything better with it, so I don't provide it. But I do provide the LTS kernel if you wish
- your boot resolution is a little messed : you're mixing a kernel built-in resolution with an EDID. Not really worth honnestly
- MESA is evil, definitely. I couldn't bisect the error when building it myself, nor could I reproduce the bug when self building it. I must have done something wrong, but it takes such a long time ....

--- End quote ---

Thanks, like I said I'm not certain yet if -rt improves things or not. Currently I'm trying to minimize the audio buffer and and maximize frame_delay, which will lead to very tight deadlines, so at least on paper the -rt patches seem like a good idea. :) But it needs more investigation. I actually got worse results for an audio-only setup with the -rt patches on another setup, but here it doesn't seem to cause any harm at least. When I'm done with the sync patch I'll setup a script and collect some stats to see if it helps out with the audio at all.


--- Quote from: Substring on February 11, 2024, 06:16:44 am ---Now for the real problem : you can't launch 2 games when using the MAME UI ? On the launch with error, can you check the contents of /sys/kernel/debug/dri/0/clients (or 1 instead of 0) and show the output ? you should see mame having master rights

--- End quote ---

I tried mesa 23.1.4 which seems to fix both next-frame response (I had issues with this on later mesa versions) and relaunching/launching new games from the UI (this was a problem with 23.0.3, next-frame response works with 23.0.3) with the R7 260. Here's the output from /sys/kernel/debug/dri/0/clients with mesa 23.0.3 and 23.1.4. 23.1.4 can be fetched from https://archive.archlinux.org/packages/m/mesa/mesa-23.1.4-2-x86_64.pkg.tar.zst .


--- Code: ---# mesa 23.0.3
# first run
[arcade@GroovyArcade ~]$ sudo cat /sys/kernel/debug/dri/0/clients
             command  tgid dev master a   uid      magic
                mame   696   0   y    y  1000          0
                mame   696   0   n    n  1000          0
# second run, after launching the same game again from the UI, doesn't work, no display (just console framebuffer)
[arcade@GroovyArcade ~]$ sudo cat /sys/kernel/debug/dri/0/clients
             command  tgid dev master a   uid      magic
                mame   696   0   y    y  1000          0
                mame   696   0   n    n  1000          0
                mame   696   0   n    n  1000          0

# mesa 23.1.4
# first run
[arcade@GroovyArcade ~]$ sudo cat /sys/kernel/debug/dri/0/clients
             command  tgid dev master a   uid      magic
                mame   792   0   y    y  1000          0
                mame   792   0   n    n  1000          0
# second run, after launching the same game again from the UI, works
[arcade@GroovyArcade ~]$ sudo cat /sys/kernel/debug/dri/0/clients
             command  tgid dev master a   uid      magic
                mame   792   0   y    y  1000          0
                mame   792   0   n    n  1000          0

--- End code ---

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version