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

    Xboxdrv - Per game basis? (Metal Gear MSX)

    Scheduled Pinned Locked Moved Help and Support
    xboxdrvmsxmetal gearkey bindingskey mapping
    3 Posts 2 Posters 412 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.
    • retropieuser555R
      retropieuser555
      last edited by

      Hello, I'm wondering if someone could take me through this process I'd need to get xboxdrv to change it's settings on a rom by rom basis? In the example given on github for Retropie and xboxdrv they set up runcommand-onstart.sh to get check if the program being run is Scummvm.

      if [ "$1" = "scummvm" ]
      then
      sudo killall >> /dev/shm/runcommand.log 2>&1 xboxdrv
      sudo /opt/retropie/supplementary/xboxdrv/bin/xboxdrv >> /dev/shm/runcommand.log 2>&1 \
      	--evdev /dev/input/by-id/[•] \
      	--silent \
      	--detach-kernel-driver \
      	--force-feedback \
      	--deadzone-trigger 15% \
      	--deadzone 4000 \
      	--mimic-xpad \
      	--evdev-absmap ABS_[•]=x1,ABS_[•]=y1,ABS_[•]=x2,ABS_[•]=y2,ABS_[•]=lt,ABS_[•]=rt,ABS_[•]=dpad_x,ABS_[•]=dpad_y \
      	--evdev-keymap BTN_[•]=a,BTN_[•]=b,BTN_[•]=x,BTN_[•]=y,BTN_[•]=lb,BTN_[•]=rb,BTN_[•]=tl,BTN_[•]=tr,BTN_[•]=guide,BTN_[•]=back,BTN_[•]=start \
      	--axismap -Y1=Y1,-Y2=Y2 \
      	--ui-axismap x1=REL_X:10,y1=REL_Y:10 \
      	--ui-buttonmap b=BTN_LEFT,a=BTN_RIGHT,start=KEY_F5 \
      	--ui-buttonmap guide=void,x=void,y=void,lb=void,rb=void,tl=void,tr=void,lt=void,rt=void,back=void \
      	--ui-axismap x2=void \
      &
      fi
      

      This mainly makes sense to me, so I could change Scummvm to MSX, no problem. But if I say wanted to run this for just one specific game what would you need to type for the opening if line?

      Pi 5 4GB

      Retroflag GPI with raspberry pi zero 2 w/ wifi

      Retroachievements:- lovelessrapture

      1 Reply Last reply Reply Quote 0
      • mituM
        mitu Global Moderator
        last edited by

        You'd need to test using the $3 parameter, which holds the name of the ROM - see https://retropie.org.uk/docs/Runcommand/#runcommand-onstart-and-runcommand-onend-scripts.

        1 Reply Last reply Reply Quote 0
        • retropieuser555R
          retropieuser555
          last edited by

          @mitu Ah I see! That makes a lot of sense. I've got it now thanks! Just need to figure out what buttons I've got and it's all dandy. Although I guess I also need to map some of them so I can still exit retroarch.

          Pi 5 4GB

          Retroflag GPI with raspberry pi zero 2 w/ wifi

          Retroachievements:- lovelessrapture

          1 Reply Last reply Reply Quote 0
          • 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.