configuring controllers in Reicast

Home Forums RetroPie Project Everything else related to the RetroPie Project configuring controllers in Reicast

RetroPie has a new website and forum. Please visit https://retropie.org.uk/ for the new site. The new forum is located at https://retropie.org.uk/forum/. This forum is left here as a read-only archive.

This topic contains 110 replies, has 15 voices, and was last updated by Profile photo of labelwhore labelwhore 1 year, 2 months ago.

Viewing 35 posts - 1 through 35 (of 111 total)
  • Author
    Posts
  • #94381
    Profile photo of labelwhore
    labelwhore
    Participant

    How can I configure my controllers in Reicast? I think I blew through the first menu too quickly on the first boot, and my controller isn’t set up correctly. How can I bring up the config menu? Is that possible to do via the kb since my controller buttons are currently borked? Or is there a file I can just edit to set up my controllers?

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    #94389
    Profile photo of herbfargus
    herbfargus
    Moderator

    Controller configurations are hardcoded into the source code and there is no keyboard support hence one of the many reasons it is experimental. So unless you modify the source code and recompile you’re out of luck for now.

    https://github.com/retropie/RetroPie-Setup/wiki/Dreamcast

    #98879
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Hi!

    So, I am such a Dreamcast fan that I decided to fork @gizmo98‘s Reicast repo and started to dig in. My main goal was to simply get a reasonable controller map going for the PS3 controller, which I use for everything ๐Ÿ˜€

    Success!

    https://github.com/free5ty1e/reicast-emulator

    Here is my fork. The first thing I attempted was to get the PS3 controls mapped, I finally got this figured out (along with laying much of the groundwork required to support multiplayer) in the “free5ty1e/ps3-controller-mappings” branch. Works great! I even got the L and R triggers mapped, and all the “extra” buttons (C, D, Z buttons) from special controllers mapped too! Rush 2049 is way fun again ๐Ÿ˜€

    I even coded up a quick and dirty “quit” button — when you press the PS3 button, Reicast quits.

    So, THEN I got ambitious. I noticed there were many improvements in the main repo that hadn’t made it through to gizmo’s repo, which we are building against. I figured my git-fu was advanced enough to handle the inevitable merge conflicts and compilation issues that would arise from bringing these improvements over to the Pi, so I dove in. The results are still a WIP but it works and currently has the latest upstream master branch code merged in. More to come, but so far there is a significant framerate improvement! I feel sometimes as though I’m playing at above 30fps. There are still random stutters that happen as things need to load from SD, but I’ve been enjoying the latest improvements playing Rush 2049 and Marvel Vs Capcom 2 and it’s damn near as fun as a real Dreamcast!!

    https://github.com/free5ty1e/reicast-emulator/tree/free5ty1e/rpi2/merged-impovements

    Here is my latest branch with the performance improvements also included (branch name is “free5ty1e/rpi2/merged-improvements”). Moar to come!

    Also, in case anyone cares, here is the script I’m using to pull and compile my latest work onto the Pi, utilizes RetroPie methods already in place as much as possible (I just change the git repo loocation):

    #!/bin/bash
    echo "Temporarily modifying RetroPie module..."
    sed -i '/gitPullOrClone/c\gitPullOrClone "$md_build" https://github.com/free5ty1e/reicast-emulator.git free5ty1e/rpi2/merged-impovements' ~/RetroPie-Setup/scriptmodules/emulators/reicast.sh
    
    echo "Requesting a build through official RetroPie calls..."
    sudo ~/RetroPie-Setup/retropie_packages.sh reicast
    
    echo "Restoring original RetroPie-Setup state..."
    pushd ~/RetroPie-Setup
    git reset --hard
    popd
    

    Not quite sure where to put a pull request in for these changes, as gizmo’s repo is forked from the upstream repo, and we are currently building a non-master branch from gizmo’s repo for reicast currently…. so here’s how I figured I’d open the discussions xD

    #98880
    Profile photo of herbfargus
    herbfargus
    Moderator

    Brilliant mate! I’ll have to give it a go when I’ve got the time. I’m not super sure on the upstream stuff as I’ve not been too involved with specific emulators but from what its looking like, at the very least retropie will have its own github organisation soon which should at least streamline all of the projects the main devs are working on.

    #98881
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Ah, excellent! I shall continue my work, and if anyone wants to test my latest stuffs feel free to use the bash script I posted, I’ll keep the best working updates merged into my free5ty1e/rpi2/merged-impovements branch… so anyone who runs this script will have a new Reicast to play with (installed just exactly the same as RetroPie does it) in roughly 5-10 mins of compilation time.

    #98882
    Profile photo of dishins
    dishins
    Participant

    wow, awesome work mate!

    i just tried using your script and got it to work in a very playable way! however the button mapping went all funny to me, i’m using a genuine PS3 controller.

    The PS button exit trick didn’t work and only the analog sticks are working for me. Any clues on how can i set a correct mapping in source to match my configuration?

    #98884
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Hmm, I should mention I am using a genuine PS3 controller over bluetooth. Haven’t tried over USB yet, it might show up a bit differently there. I’ll have to figure out how to bring the control mappings out to an ini file.

    #98886
    Profile photo of karloss
    karloss
    Participant

    Hey, Great work…

    At the moment my controller appears to be working fine on this emulator (not PS3) will this build mess that up and stop it from working?

    To install do I just need to paste this into the commandline?

    #!/bin/bash
    echo "Temporarily modifying RetroPie module..."
    sed -i '/gitPullOrClone/c\gitPullOrClone "$md_build" https://github.com/free5ty1e/reicast-emulator.git free5ty1e/rpi2/merged-impovements' ~/RetroPie-Setup/scriptmodules/emulators/reicast.sh
    
    echo "Requesting a build through official RetroPie calls..."
    sudo ~/RetroPie-Setup/retropie_packages.sh reicast
    
    echo "Restoring original RetroPie-Setup state..."
    pushd ~/RetroPie-Setup
    git reset --hard
    popd

    Thanks

    #98916
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Hi karloss!

    No worries; I added sensible controller-name-based detection that will only apply the PS3 mapping and Quit buttons if a PS3 (or Sony) controller is detected. Otherwise, the default USB gamepad map and the XBOX 360 controller maps will work as before.

    Also, that’s a bash script – you can just copy / paste that into an SSH terminal window to the Pi and have it work (minus the #!/bin/bash line), or just paste the entire thing into a new file and call it installReicastExperimental.sh or something like that. Then just run that script to build the latest Reicast.

    I’m currently rebasing these changes so they are palatable for a pull request to the master branch, as I plan to have this all fully compatible with non-Pi Reicast builds too. I want this to be easy to keep up to date with the latest enhancements from the upstream repo…

    And then yes I am going to figure out how to bring the controller mappings out to an .INI or .CFG file so they are no longer hard-coded into the damn source. ๐Ÿ˜€

    #98931
    Profile photo of dishins
    dishins
    Participant

    Hmm, I should mention I am using a genuine PS3 controller over bluetooth. Havenโ€™t tried over USB yet, it might show up a bit differently there. Iโ€™ll have to figure out how to bring the control mappings out to an ini file.

    i’m using the PS3 controller over bluetooth too, however the key mapping didn’t worked fine for me ๐Ÿ™

    #98970
    Profile photo of free5ty1e
    free5ty1e
    Participant

    iโ€™m using the PS3 controller over bluetooth too, however the key mapping didnโ€™t worked fine for me

    Hmm… I’ve tried a handful of various bluetooth adapters, and some show the PS3 controller differently than others.

    What does your PS3 controller’s name show up as in the OS? You can check by looking at how it shows up in EmulationStation’s config, type this and look for the NAME:

    nano ~/.emulationstation/es_input.cfg

    I’ll see if I can figure out how to get detection and mapping working for yours too ๐Ÿ˜€

    #99044
    Profile photo of dishins
    dishins
    Participant

    Here is it:

    deviceName="PLAYSTATION(R)3 Controller

    • This reply was modified 1 year, 10 months ago by Profile photo of dishins dishins.
    #99049
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Strange, mine shows up the exact same way. Does Reicast say “Using PS3 map” during startup? (If you launch it from command line and then exit right away, you’ll still have the launch log on screen and should see that. SHIFT+PGUP will scroll back up through your terminal buffer a short way too!)

    I will have some time to tinker more with it this weekend and will see what I can figure out.

    Are your 4 main Dreamcast buttons the START, SELECT, L3 and R3 buttons? If so, it’s using the default map and not detecting your controller for some reason.

    #99062
    Profile photo of labelwhore
    labelwhore
    Participant

    Hi!…

    You sir, are my freakin’ hero!

    I’m gonna try this as soon as I get home from work. Would it be fairly easy to get working with an Xbox 360 controller? (note that I have been unable to get my controller to work 100% in Reicast so far. Using the default driver instead of xboxdrv messes up all my other emulator controls, so it was never a real option for me.)

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    #99104
    Profile photo of free5ty1e
    free5ty1e
    Participant

    I actually dont have an xbox 360 wired controller or a microsoft wireless adapter to try with, but from what I can see in the code it should attempt to detect and map your controller. What does your controller name show up as in your es_input.cfg? (see a couple posts up for how to check)

    Also, since Reicast on the RPi2 is falling back on file allocation on the SD card for memory operations, it stutters horribly sometimes. I’ve been running via the following script to avoid this altogether; Rush 2049 runs consistently smooth now ๐Ÿ˜€

    I saved this script as dreamcast.sh and I run it like dreamcast.sh Rush2049.cdi

    Running just dreamcast.sh without a game will act just like the real Dreamcast would without a CD in it; you will get to the Dreamcast management menu, where you can format your VMUs so you can actually save games ๐Ÿ˜€

    (Note my script also backs up the VMU files to the home folder, you don’t need to do this part but you do need to let it copy the VMU files out of the memory tmpfs and back into the Reicast folder):

    #!/bin/bash
    
    pushd /opt/retropie/emulators/reicast
    
    echo Reading the entire Reicast emulator into memory to execute from there...
    sudo mkdir tmpfs
    sudo mount -t tmpfs none tmpfs/
    sudo cp -a * tmpfs/
    
    echo Reading your user VMUs into memory...
    sudo cp /home/pi/.dcvmu/*.bin .
    
    cd tmpfs
    sudo aoss ./reicast.elf -config config:image="$1"
    cd ..
    echo Updating VMU units from memory...
    sudo cp tmpfs/*.bin .
    
    mkdir /home/pi/.dcvmu
    cp *.bin /home/pi/.dcvmu/
    
    echo Freeing up memory...
    sudo umount tmpfs
    sudo rm -rf tmpfs
    
    popd
    

    Hope this helps!

    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Example usage added
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Fixed bug in script
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Fixed typo unmount instead of umount, info about VMU management
    #99114
    Profile photo of labelwhore
    labelwhore
    Participant

    I didn’t get to try this out last night. However the previous version I tried only works with the kernal driver (for the xbox 360 controller), since I’m not using the kernal driver, using it then breaks the controller for every other emulator.

    What we really need is the same level of customization the other emulators have. We need to be able to specify which controller, and be able to map or remap all the buttons.

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    #99120
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Yeah, external controller configuration via a user file — that’s definitely a goal for me, just not sure how far off it might be. Still have to figure that bit out, and with the resources in front of me I’m not certain how to start that feature yet.

    Short term though, I should be able to map a different controller ID for autodetection relatively easily the way things are currently set up, and have a new build that supports your alternate controller driver too.

    This is the mapping info currently in the source for the XBOX driver. This is also the info I’d eventually bring out to a .CFG file or something. So how would your changes look to these lines, how should your buttons and axes map to the Dreamcast controller?

    
    Name = "Microsoft X-Box 360 pad"
    MapButton = Btn_A,Btn_B,Btn_X,Btn_Y,0,0,0,Btn_Start,0,0
    MapAxis = Axis_X,Axis_Y,Axis_LT,0,0,Axis_RT,DPad_Left,DPad_Up,0,0
    

    The Btn_A,Btn_B, etc… are Dreamcast controller controls. Their position in the list indicates what mapping index to use (button 0 on xbox controller = Btn_A on Dreamcast, button 1 on xbox controller = Btn_B on Dreamcast, etc…)

    (BTW it looks like the 360 controller doesnt have the d-pad completely mapped as things are, I have no way of testing this but sure looks incomplete to me)

    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Clarification on button mapping syntax
    #99142
    Profile photo of labelwhore
    labelwhore
    Participant

    I’m using the dpad-as-button and trigger-as-button flags when I instantiate the xboxdrv, so the dpad shows up as buttons 0-4, because of that my A,B,X,Y buttons are shifted to buttons 4-7. The bumpers are 8 and 9, so the triggers are 11 and 12. That leaves the xbox button as 13 and the R and L buttons (the analog stick buttons) as buttons 14 and 15.

    That’s all from memory as I’m at work. I’ll confirm that layout as soon as I can.

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    #99155
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Good news, everyone!

    I’ve managed to get mappable information into the controller logic from the emu.cfg… I’m working out the logic to wire it all up, but it should allow for maximum flexibility in mapping any controller once I’m done ๐Ÿ˜€

    The config will look something like this, so we can define a bunch of controllers to match against (individually for each controller once I get multiplayer figured out):

    
    [PLAYSTATION(R)3 Controller]
    button.0=Btn_Z
    axis.0=Axis_X
    quit=16
    

    Any missing mapped buttons or axes will utilize the default mapped buttons and axes. I will also provide a “nothing” map to disable a certain button, and the “quit” item is special since it is handled differently; this means button index 16 will act as the Quit Emulator button.

    Will update the branch I shared above with this once I get it all working. Should be sometime this weekend, methinks ๐Ÿ˜€

    #99160
    Profile photo of labelwhore
    labelwhore
    Participant

    I was off on a couple buttons. This is from my retroarch.cfg. 14 is the xbox button, but it serves another function for the xboxdrv, it’s wise to not use it. A,B,X,Y are all the same on both controllers, I have dreamcast controller in front of me also.

    input_player1_select_btn = "12"
    input_player1_start_btn = "13"
    input_player1_up = "0"
    input_player1_down = "2"
    input_player1_left = "1"
    input_player1_right = "3"
    input_player1_a_btn = "4"
    input_player1_x_btn = "6"
    input_player1_b_btn = "5"
    input_player1_y_btn = "7"
    input_player1_l_btn = "8"
    input_player1_r_btn = "9"
    input_player1_l2_btn = "10"
    input_player1_r2_btn = "11"
    input_player1_l3_btn = "15"
    input_player1_r3_btn = "16"
    input_player1_l_x_plus_axis = "+0"
    input_player1_l_x_minus_axis = "-0"
    input_player1_l_y_plus_axis = "+1"
    input_player1_l_y_minus_axis = "-1"
    input_player1_r_x_plus_axis = "+2"
    input_player1_r_x_minus_axis = "-2"
    input_player1_r_y_plus_axis = "+3"
    input_player1_r_y_minus_axis = "-3"

    also, I have this in my es_input.cfg: Xbox Gamepad (userspace driver)

    …actually, I’ll just paste the whole file, the second instance is what I’m using.

    <?xml version="1.0"?>
    <inputList>
    	<inputConfig type="joystick" deviceName="Microsoft X-Box 360 pad" deviceGUID="030000005e0400008e02000014010000">
    		<input name="a" type="button" id="0" value="1" />
    		<input name="b" type="button" id="1" value="1" />
    		<input name="down" type="hat" id="0" value="4" />
    		<input name="left" type="hat" id="0" value="8" />
    		<input name="pagedown" type="button" id="5" value="1" />
    		<input name="pageup" type="button" id="4" value="1" />
    		<input name="right" type="hat" id="0" value="2" />
    		<input name="select" type="button" id="6" value="1" />
    		<input name="start" type="button" id="7" value="1" />
    		<input name="up" type="hat" id="0" value="1" />
    	</inputConfig>
    	<inputConfig type="joystick" deviceName="Xbox Gamepad (userspace driver)" deviceGUID="0000000058626f782047616d65706100">
    		<input name="a" type="button" id="4" value="1" />
    		<input name="b" type="button" id="5" value="1" />
    		<input name="down" type="button" id="1" value="1" />
    		<input name="left" type="button" id="2" value="1" />
    		<input name="pagedown" type="button" id="9" value="1" />
    		<input name="pageup" type="button" id="8" value="1" />
    		<input name="right" type="button" id="3" value="1" />
    		<input name="select" type="button" id="12" value="1" />
    		<input name="start" type="button" id="13" value="1" />
    		<input name="up" type="button" id="0" value="1" />
    	</inputConfig>
    </inputList>

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    #99167
    Profile photo of dishins
    dishins
    Participant

    Good news, everyone!

    Very good news indeed! looking forward to test the new build ๐Ÿ™‚

    #99169
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Good news fulfilled!!! xD

    Edited to include multiplayer too!

    So, here’s my mapping section for my genuine PS3 controller connected via my CSR 4.0 bluetooth adapter, added to emu.cfg:

    
    [PLAYSTATION(R)3 Controller]
    button.0=Btn_Z
    button.1=Btn_C
    button.2=Btn_D
    button.3=Btn_Start
    button.4=DPad_Up
    button.5=DPad_Right
    button.6=DPad_Down
    button.7=DPad_Left
    button.8=Axis_LT
    button.9=Axis_RT
    button.10=DPad2_Left
    button.11=DPad2_Right
    button.12=Btn_Y
    button.13=Btn_B
    button.14=Btn_A
    button.15=Btn_X
    button.16=Quit
    axis.0=Axis_X
    axis.1=Axis_Y
    axis.2=DPad2_Up
    axis.3=DPad2_Down
    axis.4=DPad2_Left
    axis.5=DPad2_Right
    

    You can add as many of these sections to the emu.cfg as you’d like, and if you have a matching controller name connected during Reicast startup, your custom button maps will be applied (overlaid, actually) to the default map.

    Post your configs! ๐Ÿ˜€

    Oh! Here’s the updated script I’m using to build and install Reicast from my github repo (still piggybacking on the RetroPie script awesomeness), pointing to the new branch free5ty1e/rpi2/multiplayer (it’s been rebased on the upstream master and I have submitted a pull request to get raspberry pi 2 included in the official Reicast repo):

    
    #!/bin/bash
    echo "Temporarily modifying RetroPie module..."
    sed -i '/gitPullOrClone/c\gitPullOrClone "$md_build" https://github.com/free5ty1e/reicast-emulator.git free5ty1e/rpi2/multiplayer' ~/RetroPie-Setup/scriptmodules/emulators/reicast.sh
    
    echo "Requesting a build through official RetroPie calls..."
    sudo ~/RetroPie-Setup/retropie_packages.sh reicast
    
    echo "Restoring original RetroPie-Setup state..."
    pushd ~/RetroPie-Setup
    git reset --hard
    popd
    

    And here is the script — let’s call it /home/pi/dreamcast.sh — that I am using to run Reicast smoothly with no visual stuttering / pausing (uses tmpfs to run in memory and not allocate virtual memory on the SD card. Audio is still not that smooth):

    
    #!/bin/bash
    
    pushd /opt/retropie/emulators/reicast
    
    echo Reading the entire Reicast emulator into memory to execute from there...
    sudo mkdir tmpfs
    sudo mount -t tmpfs none tmpfs/
    sudo cp -a * tmpfs/
    
    echo Reading your user VMUs into memory...
    sudo cp /home/pi/.dcvmu/*.bin .
    
    cd tmpfs
    sudo aoss ./reicast.elf -config config:image="$1"
    cd ..
    echo Updating VMU units from memory...
    sudo cp tmpfs/*.bin .
    
    mkdir /home/pi/.dcvmu
    cp *.bin /home/pi/.dcvmu/
    
    echo Freeing up memory...
    sudo umount /opt/retropie/emulators/reicast/tmpfs
    sudo rm -rf tmpfs
    
    popd
    

    …and here is even the entry for your es_systems.cfg to launch via this script in EmulationStation, for completeness:

    
        <system>
            <fullname>Sega Dreamcast - Reicast</fullname>
            <name>dreamcast</name>
            <path>~/RetroPie/roms/dreamcast</path>
            <extension>.cdi .CDI</extension>
            <command>/opt/retropie/supplementary/runcommand/runcommand.sh 0 "/home/pi/dreamcast.sh %ROM%" "dreamcast"</command>
            <platform>dreamcast</platform>
            <theme>dreamcast</theme>
        </system>
    
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: added links
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: pull request link for upstream added
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: edited to include multiplayer
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: updated other branch reference
    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Updated pull request to reflect multiplayer pull request
    #99172
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Holy crap… I finally got multiplayer to start working! Can map each individual controller (they can be different, will match upon startup to your emu.cfg entries).

    No idea why split screen stuff appears to be screwy (Rush 2049 multiplayer views are not playable), but same-screen stuff works great so far! (Marvel vs Capcom 2 multiplayer is FUN!!)

    Just switch to my new branch free5ty1e/rpi2/multiplayer and run all the same stuffs as above…. enjoy!! ๐Ÿ˜€

    -edited above post to include multiplayer update

    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: indicate multiplayer now included in above post
    #99181
    Profile photo of karloss
    karloss
    Participant

    I have been watching this thread and I must say, I am really happy with what you are doing for us ๐Ÿ™‚

    though, I seem to be having a problem… ๐Ÿ™

    I am trying to use my “DragonRise Inc. Generic USB Joystick ” gamepad, it works for everything else, and start/A/B work in reicast as standard, I just updated to your latest build, and upon running reicast it has pulled out

    [DragonRise Inc.   Generic   USB  Joystick  ]
    button.0=
    axis.0=
    button.1=
    axis.1=
    button.2=
    axis.2=
    button.3=
    axis.3=
    button.4=
    axis.4=
    button.5=
    axis.5=
    button.6=
    axis.6=
    button.7=
    axis.7=
    button.8=
    axis.8=
    button.9=
    axis.9=
    button.10=
    axis.10=
    button.11=
    axis.11=
    button.12=
    axis.12=
    button.13=
    axis.13=
    button.14=
    axis.14=
    button.15=
    axis.15=
    button.16=
    axis.16=
    button.17=
    axis.17=
    button.18=
    axis.18=
    button.19=
    axis.19=
    button.20=
    axis.20=
    button.21=
    axis.21=
    button.22=
    axis.22=
    button.23=
    axis.23=
    button.24=
    axis.24=
    button.25=
    axis.25=
    button.26=
    axis.26=
    button.27=
    axis.27=
    button.28=
    axis.28=
    button.29=
    axis.29=
    button.30=
    axis.30=
    button.31=
    axis.31=
    

    To my emu.cfg file, so up updated it and added some Btn_ to check if it was working (quit seemed the obvious button to set)

    button.1=Btn_A
    button.2=Btn_B
    button.8=Quit
    button.9=Btn_Start

    But when I restart reicast my controller has no default functions than normal and if I check the config again, It has created a new entry for my controller and is not using the config I set..

    This seems to be the issue…

    When it is first created in the config it is called

    [DragonRise Inc. Generic USB Joystick ] (notice the spaces at the end)

    So I make changes to that entry and restart, when I check the config after its been renamed to

    [DragonRise Inc. Generic USB Joystick] (notice no spaces)

    and a new entry is created underneath

    [DragonRise Inc. Generic USB Joystick ] (with spaces again)

    So it seems that the one with spaces is the one I want, but it seems to rename it and create a new one each time…any ideas??

    Thanks

    Karl

    #99182
    Profile photo of free5ty1e
    free5ty1e
    Participant

    That’s strange, you’re saying Reicast is creating these blank fields for you in the emu.cfg? I didn’t write any logic to save any mappings to the emu.cfg, just to read from it. Not sure what’s going on at the moment but I’ll think on it and post back if I can make sense of that ๐Ÿ˜ฎ

    Even after rebuilding and reinstalling Reicast, the emu.cfg I’ve edited hasn’t been touched. I’ve only defined the buttons and axis I posted.

    Not sure if it helps, but I put the controller mapping section just before the [reios] section. Position should not matter, unless you break up one of the sections by accident in the emu.cfg.

    Hope someone other than me is able to have some fun with this soon… I’m going to be experimenting with all my old Dreamcast games tomorrow with a friend and we’re gonna see just how well multiplayer works all around.

    At some point, I’m also going to have to enable Typing of the Dead and emulation for the Dreamcast Keyboard. Because I also have that game. xD

    Gonna work this into a RetroPie pull request tomorrow as well, so everyone who builds the experimental Reicast emulator from RetroPie setup will also get a better Dreamcast experience. DREAMCAST FOR ALL! (you get a Dreamcast, and YOU get a Dreamcast, and YOU get a Dreamcast…)

    #99183
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Oh hey I am digging deeper into the code and I see where this might be happening… will let you know when I figure it out, and also update my branch and pull request ๐Ÿ˜€

    Thanks for testing!!

    #99184
    Profile photo of karloss
    karloss
    Participant

    It seems the controller does have the spaces as in my retorarch config and the es_inputs, they are named with a space..

    “DragonRise Inc. Generic USB Joystick ”

    So it seems the space is correct, but for some reason, its like it loads the config, then removes the blankspace? and then it cant recognize to controller, so it creates a new entry, and it kinda keeps going round and round…if u get me?

    #99198
    Profile photo of free5ty1e
    free5ty1e
    Participant

    I think I have it sorted, although I can’t test it here. I have pushed up a new branch free5ty1e/rpi2/testing that should take care of this issue for your situation, where the controller ends up with trailing whitespace in the Name field.

    Could you try building this branch (replace the branch name in the script I posted above) and seeing if your controller mapping woes are still present?

    If this fixes the thing, I’ll add it to my multiplayer pull request / branch for all to use.

    (You should only need the entry for your controller without spaces at the end, now… there was some trimming going on during the config section name parsing code, so it threw itself for a loop just as you described. I enforced trimming whitespace from all Names so that they should always match up in the logic.)

    Hope this helps!! ๐Ÿ˜€

    • This reply was modified 1 year, 9 months ago by Profile photo of free5ty1e free5ty1e. Reason: Explanation of fix
    #99203
    Profile photo of karloss
    karloss
    Participant

    OK freestyle, thanks so much, I will look at this later tonight..

    I noticed, that without specifying, my left and right is working, it only seems to be on the menu for shenmue that its not working (anyone else see this problem?)

    Will update when played with new branch..

    Thanks for the hard work mate ๐Ÿ™‚

    #99220
    Profile photo of dishins
    dishins
    Participant

    no luck here ๐Ÿ™

    tried to compile using your newest script but it doesn’t compile saying that reicast.elf is missing.

    • This reply was modified 1 year, 9 months ago by Profile photo of dishins dishins.
    #99227
    Profile photo of karloss
    karloss
    Participant

    Freestyle you absolute legend ๐Ÿ™‚ that sorted my controller ๐Ÿ™‚

    I will post my config when all the buttons are mapped ๐Ÿ™‚

    #99229
    Profile photo of free5ty1e
    free5ty1e
    Participant

    Awesome! I’ve just updated my free5ty1e/rpi2/multiplayer branch to reflect this fix, thanks for testing!

    Not sure why it wouldn’t be compiling for you, dishins… works like a charm for me every time. My friend and I have been playing Dreamcast games all day on this emu. It does tend to crash every once in a while after playing for a couple hours, and might necessitate a reboot of the RPi2, but I’m very pleased with how far it’s come recently.

    If only I had the slightest clue how to fix the stuttery audio and the 3d split screen drawing bounds issue….

    #99230
    Profile photo of karloss
    karloss
    Participant

    wicked, so if I repull now using the multiplayer branch, I will have the best of everything?

    Is anyone able to confirm for me that they can navigate the menu (start the game) of Shenmue?

    Thanks, great work mate ๐Ÿ™‚

    #99239
    Profile photo of labelwhore
    labelwhore
    Participant

    Free5style, you are the F@#$ing man! I had to run your install script line by line for some reason, but everything seems to be working. I tested Crazy Taxi 2, which previously I could get everything but the triggers to work, now it’s working great!

    Here’s what I added to emu.cfg:

    [Xbox Gamepad (userspace driver)]
    button.0=DPad_Up
    button.1=DPad_Down
    button.2=DPad_Left
    button.3=DPad_Right
    button.4=Btn_A
    button.5=Btn_B
    button.6=Btn_X
    button.7=Btn_Y
    button.10=Axis_LT
    button.11=Axis_RT
    button.12=Quit
    button.13=Btn_Start
    axis.0=Axis_X
    axis.1=Axis_Y

    There are buttons that I left out, are those the buttons on the memory card?

    Also, the dpad buttons didn’t seem to line up exactly with my other configs, I had to swap down and left on the dpad.

    http://www.th3rdwave.com/tracks/
    ^^ my other hobby

    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    • This reply was modified 1 year, 9 months ago by Profile photo of labelwhore labelwhore.
    #99248
    Profile photo of free5ty1e
    free5ty1e
    Participant

    wicked, so if I repull now using the multiplayer branch, I will have the best of everything?

    Yep!

    I haven’t tested with Shenmue yet, but I’ll bet it works now. Lots of DC games required the D-pad to navigate menus and didn’t bother enabling the analog stick for menus ๐Ÿ˜€

    There are buttons that I left out, are those the buttons on the memory card?

    That’s a good question, and possibly! Since the PS3 had so many controls mappable, I went ahead and set everything available in the Dreamcast controls list to something on the PS3 controller. I haven’t found a need / way to test the C, D, Z, or DPad2 buttons, but I mapped them so I could “find” controls when I test new games ๐Ÿ˜€

    If anyone manages to make use of the C, D, Z, or DPad2 buttons successfully, I’d like to hear about it.

    I left my Rush 2049 on a Single Race on the Civic track all night (there’s a nice hill there the autoresets can’t get past, and == free miles and unlocking stuff), and when I woke up this morning I confirmed there is indeed a memory leak somewhere in the Reicast code (possibly several). My Pi had ran out of memory completely and just crashed.

    I’d already noticed earlier that things in general start to act funny after a couple hours, probably due to these same leaks… so heads up, reboot your Pi after a couple hours of Dreamcast play to keep things running maaaaaad. I’m sure someone intelligent will find and eliminate these memory leaks at some point.

Viewing 35 posts - 1 through 35 (of 111 total)

Forums are currently read only - please visit the new RetroPie forums at https://retropie.org.uk/forums/

Skip to toolbar