Rom Scanning / final solution

That would be amazing hunterk!! Ask me anything. Im like so near the end here I just wanna see it done and feel proud.

This bash script would need to be run inside a linux environment I am guessing? I would have to hit tab in the beggining before liveboot and get into command line… Or something like this correct?

Yes I can load the games manually, but I want to make it foolproof since I am going to be handing it out to friends and family members. My mom can press left+right to start an arcade game, but load content+select and find core+roms+playlist+ etc… might get confusing as she is a simple lady

Okay so I boot the usb, hit tab, edit the cmd “tty retroarch=0” and then hit ctrl+tab+f3… and it pulls up the terminal…

from here where do i go to run this script? I also have acces to the file system using slitaz. It is how I added the roms and bios.

Do I have to have a premade text file and then “invoke it” using the terminal???

Please keep in mind I am no pro at this stuff in the least bit

You’ll need to copy that script to a file, make it executable and then run it, like this (from your playlists directory): nano dumb-scan [copy all of that crap into it, probably best to do the whole thing over ssh from another machine…; exit with ctrl+x and then ‘y’ to save] chmod +x dumb-scan ./dumb-scan

I still haven’t figured out a good way to clean up those names yet :frowning:

http://hyperlist.hyperspin-fe.com , would this help? check the downloadable xml

Ok, I got the script fixed up (edited in the previous post). It only lists the filename now instead of the entire path.

Okay so I have lakka on a usb for pc* and all my roms and settings are on there… it boots live onto any machine with compatible hardware (so far only one machine had no audio, but it was some weird sound card). it is AWESOME

now, I have direct access to files on the usb by booting into a linux environment and then pluggin in the lakka flash drive and reading/writing/browsing filesystem etc

This script you have written Hunterk I am not totally sure how to implement.

In windows autohotkey script (the one floating around) you save the text file… then run it and it creates an lpl…

So I figured I would copy the text you have written… save the file as .sh?? in playlist folder. Then check permissions are good to go and right click and press execute right??

I got a message

““failed to execute child process “/media/disk/playlists/Arcade.sh” (No such file or directory)””

Arcade.sh is what I named the file…

Does any of this sound correct?

You need to run it from a command line, as it will ask you questions there.

So I finally figured out I needed to type in this stuff directly in the command line. it opened up some interface i typed in the stuff… saved it.

opened it with the “chmod etc” then opened the file it asked me the questions. I answered and then it said something about “line 21 error.”

opened lakka and it did create a playlist but the entries had abusrd symbols and letters… Maybe i typed something wrong.

I will try again when I have the will to go at it.

I might just have to wait for the pros to take care of my problems…

Just reading about absolute to relative paths for the last hour has brought me to my mental limits. And I still dont fully understand…haha

Thanks hunterk for all your help. This one might be beyond me.

1 Like

Has anyone else got it working? Can anyone post the first 6 or 12 lines from your arcade playlist… mine is (mame 2003)

Because I cannot even make one game launch ( i mean NO script or anything…) just a normal edited lpl

I make sure the game opens on its own… you know load content with core…

Then I edit the lpl trying to use the format provided by other playlists. but the y are all alittle different.

What the hell is the format of this lpl.

This is getting out of control

GOT IT!!! ITS WORKING!!!

thank you so much hunterk you have made my whole week!

:slight_smile: :slight_smile: :slight_smile: :slight_smile:

you guys are totally awesome

woohoo, glad you got it working :slight_smile:

@hunterk I just modify a little your script, I hope it’s ok with you, I removed extension to be a little clearier, and send parameters to use bash faster instead of writing everytime:

Params of dumping_games.sh:

$1 = Path to core $2 = Path to read content $3 = Path to save list name

sh dump_ra_list.sh /mnt/media/games/emulators/retroarch/libretro/snes9x_libretro.so /mnt/media/games/roms/console/snes /mnt/media/games/emulators/retroarch/playlists/SNES.lpl


#!/bin/bash
COUNTER=1

for i in $2/*; do
echo "$i" >> $3
echo $i | sed 's/\.[^.]*$//' | sed 's/.*\///' >> $3
echo "$1" >> $3
echo "$1" | sed 's/\.[^.]*$//' | sed 's/.*\///' >> $3
echo "$COUNTER|crc" >> $3
echo "" >> $3
COUNTER=$[$COUNTER +1]
done


@askot Sure, looks good!

There is a similar script in Lakka’s wiki, in the playlist documentation.

I cant get this to work, ive tried the script to make a playlist. It gives me this error on every game: ./mame.sh: line 22: +1]: not found

this is my current script: #!/bin/bash COUNTER=1

echo “Enter the absolute path to your core” read core

echo “Enter the absolute path to the directory you want to scan” echo “(exclude trailing slashes)” read content

echo “Enter the name of the playlist” read name

for i in $content/; do echo “$i” >> $name echo $i | sed 's/.[^.]$//’ | sed ‘s/.///’ >> $name echo “$core” >> $name echo “$core” | sed 's/.[^.]$//’ | sed ‘s/.*///’ >> $name echo “$COUNTER|crc” >> $name echo “” >> $name COUNTER=$[$COUNTER +1] done

this is my current MAME.lpl in /storage/playlists: /storage/roms/mame/contra.zip contra.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/doubledr.zip doubledr.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/mk.zip mk.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/mk2.zip mk2.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/mk3.zip mk3.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/sf1.zip sf1.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

/storage/roms/mame/sf2.zip sf2.zip /tmp/cores/mame2014_libretro.so mame2014_libretro.so 1|crc

the playlist shows in the ui but i cannot run any mame games.

i have tried using both mame2014_libretro.so and mame_libretro.so as my cores for mame.

I had these games working earlier on RetroPie but wanted to test out Lakka, to get some perspective.

It looks like the counter isn’t incrementing but that shouldn’t really matter. Are you able to load the ROMs though the ‘load content’ > ‘select file’ method rather than through a playlist?

I think, it needs an extra line to add playlist-name.lpl to work according to Kivutar’s info and structure:


/storage/roms/n64/Legend of Zelda, The - Ocarina of Time (USA).n64
Legend of Zelda, The - Ocarina of Time (USA)
/tmp/cores/mupen64plus_libretro.so
Nintendo 64 (Mupen64Plus)
EC95702D|crc
Nintendo - Nintendo 64.lpl

No i cant load a game by using the "Load Content " either. When i look in the “Load Core” i cannot se mame either.

I added “MAME.lpl” below the crc in my file but it does nothing for me.

I think it saves the text file in the main folder “/storage” and not in the folder “/storage/playlist” . Also does not add the .lpl extension.

I got the same line 21 error…think it has to do with the crc number

Booted up linux mint as a gui file browser… Moved the file over into the playlist folder and added the .lpl extension.

What version of MAME roms? my 078 are working about 85% I would say.

[QUOTE=Krum11;32685]I think it saves the text file in the main folder “/storage” and not in the folder “/storage/playlist” . Also does not add the .lpl extension.

I got the same line 21 error…think it has to do with the crc number

Booted up linux mint as a gui file browser… Moved the file over into the playlist folder and added the .lpl extension.

What version of MAME roms? my 078 are working about 85% I would say.[/QUOTE]

I went throug some guide and rebuilt my orignial downloded roms to the 0.37b5 romset, they worked fine on retropie (most of them). When i looked at the /storage/playlist folder (the network share) i found my nes playlist there too, it was created through a scan. My mame playlist shows but i cannot start the games. Currently i reinstalled it with the recalbox, wich atleast one of the games (same 8 test games) worked. But i dont like the emulation station frontend. Recalbox felt quite responsive and MK ran good. But on retropie it felt a bit slugish. Want to try running the games on lakka too for comparison.