RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login

    Development of module-script generator for lr-mess, lr-mame and mame standalone

    Scheduled Pinned Locked Moved Ideas and Development
    developmentlr-messmamelr-mamescripts
    2.2k Posts 36 Posters 6.1m Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      Folly @DTEAM
      last edited by

      @dteam

      Indeed, I was thinking you knew about the scroll-lock part ,so indeed it had to be something else.
      Nice to have that one fixed !

      1 Reply Last reply Reply Quote 0
      • DTEAMD
        DTEAM @Folly
        last edited by DTEAM

        @folly said in Development of module-script generator for lr-mess and mame standalone:

        I did one test.
        Can you both do some tests too ?
        I like to know if it still works ok.

        Nothing happens for me. Is It supposed to generate a .cmd (per game) file in /home/pi/RetroPie/roms/cdimono1 when we load a game?

        It works

        F 1 Reply Last reply Reply Quote 1
        • F
          Folly @DTEAM
          last edited by Folly

          @DTEAM

          Nice to hear it works !
          I think @RussellB will test it with some bezels, don't you think too ?

          R 1 Reply Last reply Reply Quote 0
          • F
            Folly
            last edited by Folly

            For those who are reading these posts and really don't know what the run_mess.sh does :

            The run_mess.sh makes a temporary <game>.cmd file to start the game with lr-mess and adds all the necessary things in this .cmd file to start the game correctly .
            The original version of run_mess.sh always made the same <game>.cmd named tmpmess.cmd .
            After you have played the game, this tmpmess.cmd file is removed again.

            The edited version of run_mess.sh now makes the <game>.cmd named after the game.
            That way it's unique per rom/game.
            This allows us to specify custom configs, including bezels and screen locations, etc. per rom/game that wasn't possible with the original run_mess.sh.

            DTEAMD 1 Reply Last reply Reply Quote 0
            • DTEAMD
              DTEAM @Folly
              last edited by DTEAM

              @folly
              SOLVED : For Coleco_sgm, I'm trying set scroll-lock automaticly when we the system load.

              Any idea you need -ui_active

              mame-system-adam-cart1-autoframeskip = "/opt/retropie/emulators/mame/mame -v -c -autoframeskip adam -ui_active -cart1 %ROM%"
              
              F 1 Reply Last reply Reply Quote 0
              • F
                Folly @DTEAM
                last edited by Folly

                @dteam

                I tried this :

                mame-system-adam-cart1-ui = "/opt/retropie/emulators/mame/mame -v -c adam -uimodekey TAB -cart1 %ROM%"
                

                Now the TAB works as (SCRLOCK + UI) button at the same time.
                Seems quite nice, you preserve FULL keyboard emulation until TAB is pressed.

                Edit :
                I will try that -ui_active too.
                OK, that works too, nice finding !

                It looks like you boot in PARTIAL keyboard emulation.
                Don't know if that could be a problem.

                We should do some more tests.
                This would be nice function to add, it could make things much simpler..

                DTEAMD 1 Reply Last reply Reply Quote 0
                • DTEAMD
                  DTEAM @Folly
                  last edited by

                  @folly
                  It works also for Lr-Mess .

                  lr-mess-system-adam-cart1 = "/home/pi/RetroPie-Setup/scriptmodules/run_mess.sh /opt/retropie/emulators/retroarch/bin/retroarch /opt/retropie/libretrocores/lr-mess/mess_libretro.so /opt/retropie/configs/coleco_sgm/retroarch.cfg \adam /home/pi/RetroPie/BIOS/mame -autoframeskip -ui_active -cart1 %ROM%"
                  
                  1 Reply Last reply Reply Quote 0
                  • DTEAMD
                    DTEAM
                    last edited by

                    @folly said in Development of module-script generator for lr-mess and mame standalone:

                    Could be nice to add one of these functions.

                    Absolutely

                    F 1 Reply Last reply Reply Quote 0
                    • F
                      Folly @DTEAM
                      last edited by Folly

                      @dteam

                      Great to hear that this also works on lr-mess !
                      Did you try "-uimodekey TAB" too ?
                      What do you think?

                      DTEAMD 1 Reply Last reply Reply Quote 0
                      • DTEAMD
                        DTEAM @Folly
                        last edited by DTEAM

                        @folly said in Development of module-script generator for lr-mess and mame standalone:

                        Great to hear that this also works on lr-mess !
                        Did you try "-uimodekey TAB" too ?
                        What do you think?

                        It changes Scroll lock for TAB. Same problem if you don't have a keyboard.

                        -ui_active is the best option for me. I don't see problems. Most of the time, It's already activated.

                        F 1 Reply Last reply Reply Quote 1
                        • R
                          RussellB @Folly
                          last edited by

                          @folly I've tested this with mess running tic-80 games, Sega VMS, and CD-i and each game gets its own config file. I had config files already from the bezelproject for CD-i and they immediately came up as it was no longer reading tmpmess.cmd. Looks good from my testing.

                          F 2 Replies Last reply Reply Quote 1
                          • F
                            Folly @DTEAM
                            last edited by Folly

                            @dteam said in Development of module-script generator for lr-mess and mame standalone:

                            @folly said in Development of module-script generator for lr-mess and mame standalone:

                            Great to hear that this also works on lr-mess !
                            Did you try "-uimodekey TAB" too ?
                            What do you think?

                            It changes Scroll lock for TAB. Same problem if you don't have a keyboard.

                            -ui_active is the best option for me. I don't see problems. Most of the time, It's already activated.

                            Ok, good to know.

                            I think it's in our best interest not to make separate lines for that.
                            I would want to add -ui_active to the normal lines, I think that's the best option, for now.

                            I also want to remove the separate line mame-system-xxxxxxx-autoframeskip= .
                            Using 1 string we can add all options to both mame and lr-mess :

                            mamedevcfgoptions="-v -c -autoframeskip -ui_active"
                            

                            This way, I only have to edit above line and we reduce some starter lines making it a bit simpler.
                            Good idea ?

                            If we run into problems we can always revert it.

                            BTW.
                            Don't know if we should add this to the CMD and BASENAME lines, we could get into trouble, agreed ?

                            DTEAMD 1 Reply Last reply Reply Quote 0
                            • F
                              Folly @RussellB
                              last edited by Folly

                              @russellb said in Development of module-script generator for lr-mess and mame standalone:

                              @folly I've tested this with mess running tic-80 games, Sega VMS, and CD-i and each game gets its own config file. I had config files already from the bezelproject for CD-i and they immediately came up as it was no longer reading tmpmess.cmd. Looks good from my testing.

                              Super, very nice what you made 👍

                              Thanks for testing.
                              I will add this information to the first^post .
                              You should upvote your own idea in post 1, then we improve our ranking.

                              😉

                              1 Reply Last reply Reply Quote 0
                              • DTEAMD
                                DTEAM @Folly
                                last edited by DTEAM

                                @folly said in Development of module-script generator for lr-mess and mame standalone:

                                Ok, good to know.
                                I think it's in our best interest not to make separate lines for that.
                                I would want to add -ui_active to the normal lines, I think that's the best option, for now.
                                I also want to remove the separate line mame-system-xxxxxxx-autoframeskip= .
                                Using 1 string we can add all options to both mame and lr-mess :
                                mamedevcfgoptions="-v -c -autoframeskip -ui_active"

                                This way, I only have to edit above line and we reduce some starter lines making it a bit simpler.
                                Good idea ?
                                If we run into problems we can always revert it.
                                BTW.
                                Don't know if we should add this to the CMD and BASENAME lines, we could get into trouble, agreed ?

                                For -ui_active I agree, but for -autoframeskip, be aware that it slowed down some systems a bit with lr-mess and MAME, but most of the time it is beneficial.

                                So, yes, I agree with your approach.

                                mamedevcfgoptions="-v -c -autoframeskip -ui_active"
                                

                                It's simpler for the user and he can always set buttons to set frameskip option if needed.

                                F 2 Replies Last reply Reply Quote 0
                                • F
                                  Folly @DTEAM
                                  last edited by Folly

                                  @dteam

                                  I have had a few hours re-thinking it.
                                  Now I think it's better to do small steps, so I didn't add that much.
                                  Editing the files, it struck me, that the "string" isn't that handy after all, so I have removed it.
                                  That way the options are right in the lines where they suppose to be and the scripts have less lines.
                                  I left the mame-xxxx-autoframeskip line in there, I think you have a point, when you say it doesn't always help that it is on. So I kept both lines.
                                  With lr-mess we already had -autoframeskip in the standard line, so I left it there.

                                  https://github.com/FollyMaddy/RetroPie-Share/commit/1843471347f30fe102b3690bb0652d1af77240e4

                                  1 Reply Last reply Reply Quote 1
                                  • F
                                    Folly @RussellB
                                    last edited by

                                    @russellb

                                    Would you like to help more, in improving the scripts ?

                                    R 1 Reply Last reply Reply Quote 0
                                    • F
                                      Folly @DTEAM
                                      last edited by Folly

                                      @dteam

                                      I found the answers to improve the front-end script !
                                      As I told before I now use comma separate value's within the array's.
                                      This worked from the beginning, but there was a problem with speed.
                                      Al the things I used before were very slow for the 38000 entry's of mame.
                                      I couldn't use cut that's why it took so long to find a better solution.
                                      Now I use sed to convert the lines into csv and I use IFS to cut on delimiter and get the correct value's.
                                      I also implemented a way of re-using the data of mame within the different menu choices. So it will read all in one time for 20 sec. and re-use this data which takes 4 sec.

                                      It now works, only the generator_script part is still old.
                                      For that i also have to fix some things, but those are not that difficult I think.

                                      I worked from what I could accomplish, I hope it will match the direction of our ideas.

                                      Here are some pictures :
                                      2021-05-08-221723_1600x900_scrot-resized.png 2021-05-08-221731_1600x900_scrot-resized.png
                                      2021-05-08-221756_1600x900_scrot-resized.png 2021-05-08-221802_1600x900_scrot-resized.png
                                      2021-05-08-223557_1600x900_scrot-resized.png

                                      DTEAMD 1 Reply Last reply Reply Quote 1
                                      • DTEAMD
                                        DTEAM @Folly
                                        last edited by

                                        @folly
                                        This is very nice!!! good work !

                                        F 2 Replies Last reply Reply Quote 0
                                        • F
                                          Folly @DTEAM
                                          last edited by

                                          @dteam

                                          I didn't put it on github yet, there are a still a few little things to do and to check.
                                          But I hope soon.
                                          It's really quite amazing !

                                          1 Reply Last reply Reply Quote 0
                                          • F
                                            Folly @DTEAM
                                            last edited by Folly

                                            @DTEAM
                                            @RussellB
                                            @valerino

                                            I moved to 2 versions of the generate-script, replacing 1v8 and 2v0:

                                            • generate-systems-lr-mess_mame-2v1.sh generates in ~/RetroPie-Setup
                                            • generate-systems-lr-mess_mame-2v1-ext.sh generates in ~/RetroPie-Setup/ext/RetroPie-Share

                                            Example to generate in ~/RetroPie-Setup :

                                            curl "https://raw.githubusercontent.com/FollyMaddy/RetroPie-Share/main/00-scripts-00/generate-systems-lr-mess_mame-2v1.sh" | bash -s coleco
                                            

                                            Example to generate in ~/RetroPie-Setup/ext/RetroPie-Share :

                                            curl "https://raw.githubusercontent.com/FollyMaddy/RetroPie-Share/main/00-scripts-00/generate-systems-lr-mess_mame-2v1-ext.sh" | bash -s coleco
                                            

                                            Only the ext string is different, this defines if the files should be written in the normal directory or in the ext directory !
                                            --> see_this_commit <--
                                            Both files can now be pasted in as a function in add-mamedev-systems.sh front-end module-script

                                            Edit :
                                            With the add-mamedev-systems-test6.sh I did the same :

                                            • add-mamedev-systems-test6.sh generates in ~/RetroPie-Setup/
                                            • add-mamedev-systems-test6-ext.sh generates in ~/RetroPie-Setup/ext/RetroPie-Share

                                            Get the script (in ~/RetroPie-Setup ) to generate in ~/RetroPie-Setup :

                                            wget -q -nv -O /home/$(ls /home)/RetroPie-Setup/scriptmodules/supplementary/add-mamedev-systems.sh https://raw.githubusercontent.com/FollyMaddy/RetroPie-Share/main/00-workdir-00/add-mamedev-systems-test6.sh
                                            
                                            

                                            Get the script (in ~/RetroPie-Setup ) to generate in ~/RetroPie-Setup/ext/RetroPie-Share :

                                            wget -q -nv -O /home/$(ls /home)/RetroPie-Setup/scriptmodules/supplementary/add-mamedev-systems.sh https://raw.githubusercontent.com/FollyMaddy/RetroPie-Share/main/00-workdir-00/add-mamedev-systems-test6-ext.sh
                                            
                                            

                                            or(only 1 version here)
                                            You can also update the RetroPie-Share through the add-ext-repos.sh module-script.
                                            (gets it in ~/RetroPie-Setup/ext/RetroPie-Share and generates in ~/RetroPie-Setup/ext/RetroPie-Share !)


                                            Happy testing !

                                            1 Reply Last reply Reply Quote 1
                                            • First post
                                              Last post

                                            Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                                            Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.