Attract-Mode Support Forum

Related Stuff => Emulators => Topic started by: Brewski on March 07, 2016, 10:32:59 AM

Title: AM Config for RetroArch on OS X
Post by: Brewski on March 07, 2016, 10:32:59 AM
Hi,
 I have gotten RetroArch on my OS X device running and working.
 I'm trying to start it from within RetroArch without much luck.
 I've tried various command line arguments that I've seen in here as well as the wiki.
 Currently I have the following defined.

executable           $HOME/Applications/retroarch.app
args                      -L $HOME/Applications/retroarch.app/contents/resources/cores/snes9x_libreto.dylib "[romfilename]"
rompath               $HOME/downloads/usa
romext               .zip
 
  Any help would be appreciated.
  Thanks
Title: Re: AM Config for RetroArch on OS X
Post by: omegaman on March 07, 2016, 04:09:02 PM
Hi!

I'm not an os x guy, but have you tried open -a on the cmd line.

open -a ApplicationName /file/to/open 
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 07, 2016, 04:15:08 PM
So I got a little farther...
From terminal the  /applications/retroarch.app/Contents/MacOS/RetroArch line starts RetroArch, however trying to add the core by adding /applications/retroarch.app/Contents/Resources/cores/snes9x_libretro.dylib seems to launch RetroArch, I don't get the GUI just an blank terminal window.
 I applied executable=/applications/retroarch.app/Contents/MacOS/RetroArch
               Arg=/applications/retroarch.app/Contents/Resources/cores/snes9x_libretro.dylib "[RomFileName]"
 However it freezes up AM until I close the blank terminal window.
 :(
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 07, 2016, 04:32:36 PM
And a little farther, however I'm not sure about the terminal output I'm seeing.

From the terminal
 /applications/retroarch.app/Contents/MacOS/RetroArch /applications/retroarch.app/Contents/Resources/cores/snes9x_libretro.dylib ./Documents/Aladdin.zip

I get a black screen until I hit escape and then I get following feedback in the terminal window...
[bsnes]: XML map:
cartridge region=NTSC
  rom name=program.rom size=0x2a5508
  ram name=save.ram size=0x1000
  map id=rom address=00-7f,80-ff:8000-ffff mask=0x8000
  map id=ram address=70-7f,f0-ff:0000-7fff

[bsnes]: [Memory]: ID 7, Request "manifest.bml".
[bsnes]: Complete load request.
[bsnes]: [Memory]: ID 8, Request "program.rom".
[bsnes]: Load ROM.
[bsnes]: Complete load request.
[bsnes]: [Memory]: ID 9, Request "save.ram".
[bsnes]: Complete load request.
[bsnes]: [Memory]: ID 6, Request "".
[bsnes]: Complete load request.
[bsnes]: SRAM memory size: 4096.
[bsnes]: SRAM memory size: 4096.

I'm not sure why I'm seeing a bsnes ? I'd think I'd see [snes9x]:

Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 07, 2016, 06:08:18 PM
Ureka!
Executable =/applications/retroarch.app/Contents/MacOS/RetroArch
Command Arguments = -L /applications/retroarch.app/Contents/Resources/cores/bsnes_balanced_libretro.dylib "[RomFileName]"
Rompath=$HOME/rompath/

Phew!
So I downloaded retroarch from http://buildbot.libretro.com/nightly/apple/osx/x86_64/2016-03-06_RetroArch.dmg
I dropped the Retroarch program in my Mac's Application directory and applied the lines above to a new emulator setting. Hope this helps any other new Mac users.
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 08, 2016, 06:28:17 PM
This is great news!  I'm gonna give it a whirl tonight! :D  Thank you for the putting the work in, brewski!   (http://www.sherv.net/cm/emoticons/friends/cheers-smiley-emoticon.gif)
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 09, 2016, 10:53:17 AM
I couldn't get this to work fully.. any help is super appreciated!! :D
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 10, 2016, 04:12:38 AM
From your description, it sound like some thing might be missing.
Try the following steps, hopefully it helps..
1. make sure you can run you roms from retroarch itself. Retroarch needs to have the core you want to use installed. You can do this directly in retroarch.
2. The retroarch.app like all mac apps? Has it's sub set of directories in the app itself. So after dropping retroarch in your applications directory, right click on the retroarch.app and select "open package" explore the directory structure (I would think it's the same as mine as they are the same program);D. In here this is where you can find the retroarch(exe) and the core you want to use.
 In my case the retroarch(exe) is here /applications/retroarch.app/Contents/MacOS/
 and the cores are located here /applications/retroarch.app/Contents/Resources/cores/
3. Using the above info you can open terminal and build your command line, in my case the following works.

/applications/retroarch.app/Contents/MacOS/RetroArch -L /applications/retroarch.app/Contents/Resources/cores/snes9x_libretro.dylib ./Documents/Aladdin.zip

The -L tells retroarch to ignore the retroarch.cfg and load the core defined in the command line.
The Aladdin.zip is the rom that is in my documents directory.
If this works then you should be able to place it in your emulator config in AM and run it successfully.
BTW my AM is also in my application directory if that makes a difference.

Sorry if this is redundant for you, I'm not an expert with OSX/Terminal myself and am not sure what level of knowledge you have already, hopefully my explanation helps and my assumptions about the operating environment are correct.
 Let me know...
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 08:50:30 AM
Hey Brew.. thanks for the reply..

So I'm able to launch from the terminal.  I'm using nestopia as an emulator to test this. 
This is the command I can launch from the terminal:  /applications/retroarch.app/Contents/MacOS/RetroArch -L /applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib /Users/inkagnito/Documents/ROMS/NES/Monopoly.zip

I put the following  info into attract mode in the emulators setup:
For executable: /applications/retroarch.app/Contents/MacOS/RetroArch
Command arguments: /applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
Rom Path: /Users/inkagnito/Documents/ROMS/NES/Monopoly.zip

It will launch retroarch with a blank window but will not proceed further.  What am I doing wrong?   Thanks!
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 10, 2016, 10:40:05 AM
(Sorry Originally I referenced it backwards, the -L should be at the end of the executable line in AM
not the beginning of the Command Arguments line...
It looks like you may have forgotten the -L in the executable in AM? This tells retroarch to ignore it's config
and use the core you are pointing to.
For executable: /applications/retroarch.app/Contents/MacOS/RetroArch -L
Command arguments:/applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
Let me know if it works for you.
 
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 10:47:56 AM
Opps, I was just gonna say I forgot to put the -L in the post, but yes, it's in there.  Weird thing is, without putting the -L in the argument, it opens the emulator in retroarch but not the game.  Hmm..
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 10, 2016, 10:57:52 AM
Darn maybe the -L does go in the front of Command Argument. (Sorry, I don't have my Mac in front of me right now)
Tell you what,
Try it like this...
executable: /applications/retroarch.app/Contents/MacOS/RetroArch -L
Command arguments:/applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
and if that doesn't work try it like this.
For executable: /applications/retroarch.app/Contents/MacOS/RetroArch
Command arguments: -L /applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
Let me know if one of those works.

Also try putting the rom path as
$HOME/Documents/ROMS/NES/Monopoly.zip
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 11:01:58 AM
Command Argument: -L /applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
 
Will definitely launch the blank window, and putting it at the end of .dylib as well.  I tried putting it on the executable and nothing happened.  Damn!
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 10, 2016, 11:11:44 AM
What the heck let's throw the kitchen sink at it..  :)
executable: $HOME/applications/retroarch.app/Contents/MacOS/RetroArch
Command arguments: -L $HOME/applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib
Rom Path: $HOME/Documents/ROMS/NES/Monopoly.zip

 If this doesn't work I'll double check my set-up when I get home :)
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 11:15:45 AM
Nope, no go with the $HOME either.  Let me know when you get home!  I really super appreciate your help!  I feel like it's so close!    Driving me a little batty :)
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 11:32:11 AM
OMG.. I think I got it.

1. I downloaded the latest build of retroarch (I think I had an older build which was causing issues)

2. In retroarch program itself, i did the online update and added the Nestopia core.  I didn't scan for any games.  Then I closed the program.

3.  In Attract mode my configuration is as follows:

Executable: /applications/retroarch.app/Contents/MacOS/RetroArch/
Command Arguments: /applications/retroarch.app/Contents/Resources/cores/nestopia_libretro.dylib "[romfilename]" -L
Rom Path(s):  $HOME/Documents/ROMS/NES/

4. When I launched Monopoly through Attractmode, it launches.  Only thing is, it launches behind Attractmode and not in front, so I need to solve this now without command + Tabbing to retroarch.  Any thoughts on this? 
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 12:11:08 PM
I was able to launch Retroarch in full screen in front of attract mode! 

In Retro arch, under the gear tab, then 'Video,' turn 'use fullscreen mode' to On.     
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 10, 2016, 04:12:04 PM
Alright this time for sure... I left off a very important parameter! ("[RomFileName]")  :o

Executable =/applications/retroarch.app/Contents/MacOS/RetroArch

Command Arguments = -L /applications/retroarch.app/Contents/Resources/cores/reicast_libretro.dylib
"[RomFileName]"

Rompath=$HOME/rompath/

Again, let me know if it works.

(Edit)
I just saw your previous reply.  Congrats! So are you all set now?
(Edit #2)
I think you need to create  a new display that references the new emulator entry for it?
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 10, 2016, 09:53:52 PM
Brewskis.. Thanks man! 

Question for you.. are you able to run multiple systems from within Attractmode using one Retro arch app?  Like SNES, NES, Genesis, Etc?  I haven't gotten further then adding NES so far but will be attempting this this weekend.  :)
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 11, 2016, 02:42:06 AM
Yup, I just created a separate emulator entry and display entry for each. So far I've done snes and dreamcast. (Dreamcast emulation doesn't seem all that great at the moment though, at least on my Mac)
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 13, 2016, 10:43:22 AM
Ok, it's so weird.. I'm able to launch nestopia from attract mode, but I cannot for the life of me get bsnes to launch..   :-[
It will launch retroarch as a blank window, but will not launch the rom.. any suggestions again?
Title: Re: AM Config for RetroArch on OS X
Post by: Brewski on March 14, 2016, 02:34:16 AM
I'd double check your syntax on the command arguments parameter line.

Command Arguments = -L /applications/retroarch.app/Contents/Resources/cores/reicast_libretro.dylib
"[RomFileName]"

Don't forget the -L and the quotes around the romfilename.
Title: Re: AM Config for RetroArch on OS X
Post by: inkagnito on March 14, 2016, 03:25:30 PM
Ok. I solved the issue on my end.. It has to be lowercase for "[romfilename]"

Yay!