Re: MiSTer Super Attract Mode (SAM) is now available - the first game screensaver for your MiSTer!
Posted: Tue Apr 27, 2021 11:55 am
This was great and really easy to set up. Thanks for all the work!
The online community for MiSTer FPGA enthusiasts
https://misterfpga.org/
No, not so far. The systems I dropped have disappeared from the rotation. Have you edited the right version of the ini? It should be in Scripts.Ross_Jolet wrote: ↑Mon Apr 26, 2021 10:32 pm I’ve modified the .ini file several times not to include the cd systems, yet it still runs those systems. Is anyone else having this problem?
This suggests it's having a problem finding games for the other systems. If you want to see more run the script via ssh.LamerDeluxe wrote: ↑Mon Apr 26, 2021 7:59 pm It only selects arcade games now for some reason, even though the ini file is still set to run all systems.
Code: Select all
/media/fat/Scripts/MiSTer_SAM_on.sh
Please submit a copy of your INI file via GitHub so we can take a look.Ross_Jolet wrote: ↑Mon Apr 26, 2021 10:32 pm I’ve modified the .ini file several times not to include the cd systems, yet it still runs those systems. Is anyone else having this problem?
It may be the Daemonbright controllers aren't being picked up like other controllers. You can use another controller, keyboard, or mouse to stop the game cycling. If you want to troubleshoot further SSH to your MiSTer and runredsteakraw wrote: ↑Mon Apr 26, 2021 11:21 am If I go into a game and start playing it will continue to cycle after 3 minutes.
Code: Select all
dmesg | grep input
Thanks for the suggestion!keilmillerjr wrote: ↑Mon Apr 26, 2021 6:59 am Try using $RANDOM and and select the game or core within the list instead of shuf. I can provide an example or a pr, but have no way of testing actual script on hardware.
We now have a public test branch, which has a timestamped log of all the games launched. We don't keep it between runs though, as it is written to memory only to avoid wear on the microSD card.Stupid Dufus wrote: ↑Sun Apr 25, 2021 9:06 am Would it be possible to have it keep a record of what games it's cycled though?
Like I mentioned it worked with the previous version (when it suddenly did run, by itself right after starting the MiSTer).Mellified wrote: ↑Tue Apr 27, 2021 3:18 pmThis suggests it's having a problem finding games for the other systems. If you want to see more run the script via ssh.LamerDeluxe wrote: ↑Mon Apr 26, 2021 7:59 pm It only selects arcade games now for some reason, even though the ini file is still set to run all systems.
The rom choices are still going to be at the mercy of partun's random algorithm (when they are in zip files, which I suspect many are). Regardless, "real" randomness isn't what people actually want when they ask for something like this. They want randomness that's biased against 'recent' choices. Much more annoying to implement.keilmillerjr wrote: ↑Mon Apr 26, 2021 6:59 amTry using $RANDOM and and select the game or core within the list instead of shuf. I can provide an example or a pr, but have no way of testing actual script on hardware.Mellified wrote: ↑Mon Apr 26, 2021 3:26 amInteresting idea! We've noticed that SAM doesn't seem as random as we'd like. We're definitely considering how to address this. I'll add this to the list of ideas!Stupid Dufus wrote: ↑Sun Apr 25, 2021 9:06 am Would it be possible to have it keep a record of what games it's cycled though? My thinking is that if it did this, you could have the script cycle through all the user's titles before repeating them again.
https://github.com/mrchrisster/MiSTer_S ... AM.sh#L221
That error is... bizarre. I don't know why you'd be seeing that. It suggests that SAM is trying to look in the /media/fat/Scripts/ directory for games. At least that's the only reason I can think of you'd see Update_MiSTerBIOS.sh referenced. That's not even part of SAM!LamerDeluxe wrote: ↑Tue Apr 27, 2021 6:57 pm And then this error gets repeated between rom searches:
"find: paths must precede expression: Update_MiSTerBIOS.sh
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]"
Code: Select all
rm -fr /media/fat/MiSTer_SAM /media/fat/Scripts/.MiSTer_SAM /media/fat/Scripts/MiSTer_SAM_off.sh /media/fat/Scripts/MiSTer_SAM.ini /media/fat/Scripts/MiSTer_SAM_now.sh /media/fat/Scripts/MiSTer_SAM_on.sh
I removed everything, including old attract mode scripts and folders and reinstalled the MiSTer_SAM_on script but it didn't make a difference.Mellified wrote: ↑Wed Apr 28, 2021 4:24 amThat error is... bizarre. I don't know why you'd be seeing that. It suggests that SAM is trying to look in the /media/fat/Scripts/ directory for games. At least that's the only reason I can think of you'd see Update_MiSTerBIOS.sh referenced. That's not even part of SAM!LamerDeluxe wrote: ↑Tue Apr 27, 2021 6:57 pm And then this error gets repeated between rom searches:
"find: paths must precede expression: Update_MiSTerBIOS.sh
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]"
My only thought is to have you delete everything SAM related and start over. Something is not right. I suggest something like this via ssh to clean up:If the current release version doesn't work you could try the test branch version, which has more logging via ssh.Code: Select all
rm -fr /media/fat/MiSTer_SAM /media/fat/Scripts/.MiSTer_SAM /media/fat/Scripts/MiSTer_SAM_off.sh /media/fat/Scripts/MiSTer_SAM.ini /media/fat/Scripts/MiSTer_SAM_now.sh /media/fat/Scripts/MiSTer_SAM_on.sh
I don't understand what partnuns random algorithm is. Regardless, it would take more time to shuffle a list than to select a random line/index from a list.zakk4223 wrote: ↑Tue Apr 27, 2021 7:02 pmThe rom choices are still going to be at the mercy of partun's random algorithm (when they are in zip files, which I suspect many are). Regardless, "real" randomness isn't what people actually want when they ask for something like this. They want randomness that's biased against 'recent' choices. Much more annoying to implement.keilmillerjr wrote: ↑Mon Apr 26, 2021 6:59 amTry using $RANDOM and and select the game or core within the list instead of shuf. I can provide an example or a pr, but have no way of testing actual script on hardware.
https://github.com/mrchrisster/MiSTer_S ... AM.sh#L221
Yeah, that is a mystery! I'm so glad you got it all working now though. Have you tried the new menu?LamerDeluxe wrote: ↑Mon May 10, 2021 8:51 pm I've just managed to fix the problem I was having, error messages involving Update_MiSTerBIOS.sh, by deleting that script and all other scripts that turned out to be related to the old RetroDriven update scripts. It used to only pick arcade games and now it picks other systems as well.
Still completely incomprehensible how that bug works.
Yes, I did, really cool! And a handy way to test if a certain platform works.Mellified wrote: ↑Tue May 11, 2021 3:10 amYeah, that is a mystery! I'm so glad you got it all working now though. Have you tried the new menu?LamerDeluxe wrote: ↑Mon May 10, 2021 8:51 pm I've just managed to fix the problem I was having, error messages involving Update_MiSTerBIOS.sh, by deleting that script and all other scripts that turned out to be related to the old RetroDriven update scripts. It used to only pick arcade games and now it picks other systems as well.
Still completely incomprehensible how that bug works.
I don't think you're messing anything up. The default flow tries to self-update, install the autoplay feature, and start SAM immediately. Instead you can press "up" to enter the menu and enable autoplay that way. It won't need an Internet connection from that point. I'll make a note to improve our instructions!hipsofjw wrote: ↑Thu May 13, 2021 1:33 am Has anyone else tested the offline mode? I copied the .ini and .sh files into my Scripts folder and the five files from the github folder into Scripts/.MiSTer_SAM. When I run the script, I get a message saying that SAM will start running in 10 seconds. Then 10 seconds later, it says that I'm not connected to the internet. Any idea what I'm messing up?
Ah! That makes sense. I'll give it a shot when I get home this evening. Thanks for the help.Mellified wrote: ↑Thu May 13, 2021 2:58 amI don't think you're messing anything up. The default flow tries to self-update, install the autoplay feature, and start SAM immediately. Instead you can press "up" to enter the menu and enable autoplay that way. It won't need an Internet connection from that point. I'll make a note to improve our instructions!
Finally found some time sit down and try this. For me, hitting up just seems to restart the timer and doesn't enter me into the menu.Mellified wrote: ↑Thu May 13, 2021 2:58 amI don't think you're messing anything up. The default flow tries to self-update, install the autoplay feature, and start SAM immediately. Instead you can press "up" to enter the menu and enable autoplay that way. It won't need an Internet connection from that point. I'll make a note to improve our instructions!hipsofjw wrote: ↑Thu May 13, 2021 1:33 am Has anyone else tested the offline mode? I copied the .ini and .sh files into my Scripts folder and the five files from the github folder into Scripts/.MiSTer_SAM. When I run the script, I get a message saying that SAM will start running in 10 seconds. Then 10 seconds later, it says that I'm not connected to the internet. Any idea what I'm messing up?
From the controller or keyboard? If you are using the controller make sure you've configured it in the MiSTer main menu (F12 -> "Define joystick buttons").hipsofjw wrote: ↑Sun May 16, 2021 10:44 amFinally found some time sit down and try this. For me, hitting up just seems to restart the timer and doesn't enter me into the menu.Mellified wrote: ↑Thu May 13, 2021 2:58 amI don't think you're messing anything up. The default flow tries to self-update, install the autoplay feature, and start SAM immediately. Instead you can press "up" to enter the menu and enable autoplay that way. It won't need an Internet connection from that point. I'll make a note to improve our instructions!hipsofjw wrote: ↑Thu May 13, 2021 1:33 am Has anyone else tested the offline mode? I copied the .ini and .sh files into my Scripts folder and the five files from the github folder into Scripts/.MiSTer_SAM. When I run the script, I get a message saying that SAM will start running in 10 seconds. Then 10 seconds later, it says that I'm not connected to the internet. Any idea what I'm messing up?
Two different keyboards and two different controllers. All 4 are regularly used with the MiSTer and have their inputs defined.Mellified wrote: ↑Mon May 17, 2021 1:01 amFrom the controller or keyboard? If you are using the controller make sure you've configured it in the MiSTer main menu (F12 -> "Define joystick buttons").hipsofjw wrote: ↑Sun May 16, 2021 10:44 amFinally found some time sit down and try this. For me, hitting up just seems to restart the timer and doesn't enter me into the menu.Mellified wrote: ↑Thu May 13, 2021 2:58 am
I don't think you're messing anything up. The default flow tries to self-update, install the autoplay feature, and start SAM immediately. Instead you can press "up" to enter the menu and enable autoplay that way. It won't need an Internet connection from that point. I'll make a note to improve our instructions!
Please do an auto-update and try again. The keyboard method to enter the menu is the same used by Update_All - does it work for you with that script?hipsofjw wrote: ↑Mon May 17, 2021 2:25 amTwo different keyboards and two different controllers. All 4 are regularly used with the MiSTer and have their inputs defined.
Thought of one more thing... you are pushing up on the controller D-pad - not the stick? And up on the keyboard arrow keys? No special keyboard modes or functions on?
Code: Select all
/media/fat/Scripts/MiSTer_SAM_on.sh menu
Thanks for the kind words! Glad you're enjoying it.
Code: Select all
/media/fat/Scripts/MiSTer_SAM_on.sh monitor
Code: Select all
/media/fat/Scripts/MiSTer_SAM_on.sh start
Code: Select all
cat /tmp/SAM_Game.txt
Code: Select all
cat /tmp/SAM_Games.log
It works great thanks for your project.
Code: Select all
echo "000,9,1, ${1}" > "${ttydevice}"
Code: Select all
echo "000,10,1,${1}" > "${ttydevice}"
Code: Select all
echo "000,11,1,${1}" > "${ttydevice}"
I improved SAM today with a more consistent handling of the s60tty2oled daemon. I added a fix so SAM doesn't inadvertently kill the inotifywait daemon tty2oled is using. I also included the fix you suggested for the top line of text. I'd noticed it but forgot to go back and investigate.
Done
Code: Select all
"CMDCLS" Clear Screeen
"CMDTXT,[Parameter]" Text-Ouput, Parameter-Format = "f,c,x,y,[Text]
"CMDGEO,[Parmeter]" Geometric-Output, Parameter-Format = "g,c,x,y,i,j,k"
Thx, Great!