• Recent
  • Tags
  • Popular
  • Home
  • Docs
  • Register
  • Login
RetroPie forum home
  • Recent
  • Tags
  • Popular
  • Home
  • Docs
  • Register
  • Login
Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

Custom Hotkeys

Scheduled Pinned Locked Moved Help and Support
retroarchconfig gamepadhotkeysgame boymakey makey
10 Posts 3 Posters 2.2k 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
    flajubam
    last edited by 27 Aug 2018, 12:09

    Hope someone can help with what I'm trying to do here. I'm not going to lie I'm a bit of a novice here so please bare with me.

    So basically, as nerdy as it sounds, I'm making a life-size Gameboy outfit that I want to be working. I'm using a makey makey as my controller and I believe that it's recognised as a keyboard by retropie. What I want to do is to make it so I can press a button to load a specific game. I've looked around and seen you can edit the config file, would this be a way of doing it? I've also seen some people use scripts to get a specific action to happen, could this be another option?

    Any help would be much appreciated!

    1 Reply Last reply Reply Quote 0
    • D
      ddoherty958
      last edited by 27 Aug 2018, 12:38

      Try looking here: https://retropie.org.uk/forum/topic/10305/run-custom-action-on-custom-hotkey/2

      Raspberry pi B+, official pi power supply, Samsung 64gb SD card, SanDisk 32GB USB drive

      1 Reply Last reply Reply Quote 0
      • M
        mitu Global Moderator
        last edited by 27 Aug 2018, 12:56

        Raspbian includes the triggerhappy program that can do what you need, to trigger actions for certain key presses - https://github.com/wertarbyte/triggerhappy - and it's included and installed by default on a RetroPie image (well, Raspbian adds it by default).

        F 1 Reply Last reply 27 Aug 2018, 15:51 Reply Quote 0
        • F
          flajubam @mitu
          last edited by 27 Aug 2018, 15:51

          Thanks! After having a look that does look like it'd be able to do what I need it to! Because I am really a novice at this though it's causing me a bit of a headache. I've put a .conf file in:
          /etc/triggerhappy/triggers.d that contains:

          "KEY_G 1 /home/pi/RetroPie/roms/gb/Pokemon Red.gb"

          And that's not doing anything. But I'm also not sure if I need to preface the file directory in the config file with a load command or something.

          Thanks for the help again!

          M 1 Reply Last reply 27 Aug 2018, 15:55 Reply Quote 0
          • M
            mitu Global Moderator @flajubam
            last edited by 27 Aug 2018, 15:55

            @flajubam That's not the way to launch a ROM. The command to launch a ROM is more complex (e.g. something like https://retropie.org.uk/docs/FAQ/#how-would-i-start-from-command-line-say-the-snes-emulator-by-itself).
            What you can do is launch the ROM, then exit. Check the /dev/shm/runcommand.info file (last line) and you'll see the full command line used to launch the ROM, which you can use it in the trigger definition.

            F 1 Reply Last reply 27 Aug 2018, 16:56 Reply Quote 0
            • F
              flajubam @mitu
              last edited by 27 Aug 2018, 16:56

              @mitu Thanks again, that seems to be working. Although it's quite odd, when I load the game manually through the menu. The game has the classic green tinge, when I load it through this it goes to a basic white. Do you know any reason it'd be doing this?
              Also if I load it via the hotkey once I've already loaded it once, the pi just crashes.

              M 1 Reply Last reply 27 Aug 2018, 17:00 Reply Quote 0
              • M
                mitu Global Moderator @flajubam
                last edited by 27 Aug 2018, 17:00

                @flajubam How did you install RetroPie ?
                About the green vs. white tinge - that might be a shader not being applied; the crash thing might be normal if you start to run a 2nd instance again once it's started, so you should wrap the command in a shell script that checks if RetroArch is started and only starts the emulator if it's not currently running.

                F 1 Reply Last reply 27 Aug 2018, 17:19 Reply Quote 0
                • F
                  flajubam @mitu
                  last edited by 27 Aug 2018, 17:19

                  @mitu I installed it ages ago so I can't really remember, probably however the first result on google says to haha. How would I go about fixing the shader issue? Could I somehow tell retroarch to apply the shader when loading like this? With the shell script, would that not stop it working if I was in another rom in the same emulator? And do you know any places I could look to find out how to write a script like that?

                  Sorry for all the questions!

                  M 1 Reply Last reply 27 Aug 2018, 17:29 Reply Quote 0
                  • M
                    mitu Global Moderator @flajubam
                    last edited by mitu 27 Aug 2018, 17:29

                    @flajubam said in Custom Hotkeys:

                    How would I go about fixing the shader issue? Could I somehow tell retroarch to apply the shader when loading like this?

                    One you load the game, use the RGUI (Select + X) then choose a shader to apply - https://retropie.org.uk/docs/Shaders-and-Smoothing/#shaders. You can choose each shader in turn and find the one that suits you. You can then use the Configuration editor to have the shader load each time - either for your emulator or globally - or, from the RGUI, choose the Save Core override to have the shader configuration saved for that emulator.

                    As for the 2nd question, scripting is a large subject - the usual reference is the Advance Bash Scripting Guide.

                    F 1 Reply Last reply 31 Aug 2018, 13:00 Reply Quote 0
                    • F
                      flajubam @mitu
                      last edited by 31 Aug 2018, 13:00

                      @mitu Thanks for the links, I'll have a look and try to figure it out. I don't think it's shaders though as when I go into that menu for either it doesn't say any shaders are set and when I enable one I get serious lag issues. The only difference I could see was the colour palette was different. But when I change that to be the same I only get a very slight green tinge. So I'm a bit stuck on what's causing that 😅

                      1 Reply Last reply Reply Quote 0
                      5 out of 10
                      • First post
                        5/10
                        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.

                        This community forum collects and processes your personal information.
                        consent.not_received