RetroFlag / GPiCase2-Script

RetroFlag GPiCase 2 CM4 Safeshutdown with automatically switch LCD and HDMI display script
MIT License
38 stars 12 forks source link

Display Switching Does Not Work #6

Open Hroth-Rosen opened 2 years ago

Hroth-Rosen commented 2 years ago

Replicated Recalbox 8.0, Replicated RetroPie 4.7.1, clean installs.

Process: Install Distro Install Case Patch. Confirm Dock is working while using config_HDMI file. displays and runs correctly without any issue Install Safe Shutdown script from github Dock no longer displays output once Emulationstation is running. Bootup and Shutdown messages display correctly. Removing gpi from dock displays video and sound on the LCD. Dock does not display any image apart from bootup image when shut down / powering on when connected. All testing has been done from a complete shutdown and power cycle while connected.

Config Files are stock included with the Case Patch, no alterations made.

Safe shutdown script has been installed both when using the config_hdmi as the configuration file and when the standard config.txt is used. Testing has been done on fresh installs of RecalBox and Retropie

Issue still occurs when changing the config files between config.txt, config_hdmi and config_lcd.

djnews24 commented 2 years ago

Same Problem here. With HDMI I have no Output and my Monitor and TV says unsupported input.

With the Retropie it works. Just Recalbox have this issue

Hroth-Rosen commented 2 years ago

I'm having the issue with Recalbox, Retropie and also Batocera. :(

Also spent a few hours messing with config.txt, config_hdmi.txt and config_lcd.txt to try and pinpoint something such as which file was being used when booted on the dock, but I wasn't able to glean anything other than the safe shutdown script may be failing it's weird copying and shuffling of these config files on boot. :(

Also noticed that when taking the gpi case off the dock, there's an under-voltage indicator for a brief second, but this is also displayed when putting the system into low power mode.

Hnngh. Frustrating.

djnews24 commented 2 years ago

Well a fix for Recalbox is removing the the parameters

hdmi_group and hdmi_mode

in the config_hdmi.txt file while using it in the lcd mode. after that I got it working.

Next is the swap scripts are really bad written bash scripts. I think I will rewrite them at the weekend.

Hroth-Rosen commented 2 years ago

I will give this a try on a recalbox install and let you know if I have the same result.

If / when you rewrite the swap scripts, let me know and I'll also test them for you. Thanks!

dmowcomber commented 2 years ago

This is one of the reasons why it's not working on Recalbox. https://github.com/RetroFlag/GPiCase2-Script/blob/9001eb2fd4990f54b529d98ffe0a045f228add22/recalbox_install_gpi2.sh#L56 The Recalbox install script is referencing a file that only exists on the RetroPie image.

djnews24 commented 2 years ago

@dmowcomber thats not correct. The install script will download that file https://github.com/RetroFlag/GPiCase2-Script/blob/main/recalbox_install_gpi2.sh#L33

djnews24 commented 2 years ago

Some update about the Swap Script. Currently i think will put everything directly into the python deamon. But first i need to time to do that. My Daytime work kills me currently :D

Currently its possible that lcdfirst and lcdnext will booth rewrite and hang. I got it now 3 times that the device hangs and i could not put it off because the python script will not killed while shutdown. In this case and needed to remove the board while its powered on :/ I would be really good that the case have something like a HARD Reset. Maybe when pressing each buttons in the same time or something.

dmowcomber commented 2 years ago

@djnews24 Good idea having the config.txt updates happen in one place. Yeah, it would be nice if the case had a reset switch.

BTW /opt/RetroFlag doesn't exist for me on the Recalbox image that I downloaded from the recalbox webside. Maybe we need to use the -p flag when calling mkdir here https://github.com/RetroFlag/GPiCase2-Script/blob/main/recalbox_install_gpi2.sh#L22 I can try that later.

djnews24 commented 2 years ago

The files and directories will be created by this install script. It’s not in the image. You need to execute this script as written in the readme πŸ˜‚

https://github.com/RetroFlag/GPiCase2-Script#for-recalbox71180

dmowcomber commented 2 years ago

lol. That's the script that I'm trying to say doesn't work because its not correctly creating the /opt/RetroPie directory that wget uses to download the lcdfirst.sh and lcdnext.sh files. That's ok I'll create a PR to fix the install script so the files at least exist.

dmowcomber commented 2 years ago

Never mind. I just did a fresh install of Recalbox and ran the install script and it created lcdfirst.sh and lcdnext.sh files just fine. I'm not sure what I did wrong last time πŸ˜•

Cacodaimon commented 2 years ago

I had some similar issues with the wired bunch of scripts provided by RetroFlag, once it even overwrote the HDMI config file with the LCD configuration file, which took me hours to figure out.

Maybe someone had similar issues, might thy my own script set

djnews24 commented 2 years ago

@Cacodaimon Omg thank you for this. I stopped writing my own in lack of time. Thank you for your work. I will try it out later after daytime work <3

Cacodaimon commented 2 years ago

I will try it out later after daytime work <3

I would be happy to hear your feedback.

djnews24 commented 2 years ago

I will try it out later after daytime work <3

I would be happy to hear your feedback.

Sorry for the late reply. It works great here. thank you for your work!

Cacodaimon commented 2 years ago

I will try it out later after daytime work <3

I would be happy to hear your feedback.

Sorry for the late reply. It works great here. thank you for your work!

Thank you for the feedback!

Cacodaimon commented 2 years ago

The patched HDMI config option hdmi_mode=69 might be the root cause for many HDMI display issues, resolution is "1920x1200 60Hz" and therefore a little bit larger as the common Full HD (1920x1080) resolution.

https://github.com/Cacodaimon/CacosGPiCASE2Script/issues/1#issuecomment-1163658153

djnews24 commented 2 years ago

The patched HDMI config option hdmi_mode=69 might be the root cause for many HDMI display issues, resolution is "1920x1200 60Hz" and therefore a little bit larger as the common Full HD (1920x1080) resolution.

Cacodaimon/CacosGPiCASE2Script#1 (comment)

thx for adding that to your scripts :D