Using lr-puae for Amiga emulation
-
The script has been updated with
- a report at the end of the batch process telling you how it went:
amigatool batch process complete. Total processed: 9 Skipped directories: 1 Skipped files: 2 Didn't contain a WHDload game: 4 File was corrupt: 1 Already compatible files: 0 Converted files: 1 Converted .hdf files are located in the /hdf folder.
- It now handles WHDLoad files with multiple
.slave
files in them. - It now gracefully detects and reports as corrupt files that couldn't be repacked into an hdf.
- Better messaging in general.
- Files are also leaner, and get zipped at the end so they can be scraped.
-
One more update, trapping more ways in which lha files can be corrupt. I processed around 2800 files with this test, so I feel fairly good about it now. Let me know if anyone runs into issues with it.
One question I had is whether I should add [lr-puae] to the filenames, so that people can tell that these have been processed this way. But I don't know if that would affect scraping. Right now, they end up with exactly the same name as the RetroPlay WHDLoad files do.
BTW @muldjord, either Skyscraper or Screenscraper.fr doesn't recognize .hdf as a file extension for Amiga, not sure which.
-
@rkoster It does now from 3.2.0, just released. :)
-
Thank you rkoster for this tool.
Right now I'm not using PUAE, but with the big changes that Retroarch just added to the core, I'm definitely going to be checking it out and your script will be so helpful.
https://www.libretro.com/index.php/core-news-puae-amiga-emulator-and-vice-commodore-64/
-
Hello and thank you for the Scripts.
I run into issues and don't know what i'm doing wrong.
All RetroPlay style .lha end with anCorrupt!
message.Example:
0/28 xxx_game.lha: extracting...../amigatool.sh: line 176: bc: command not found 'create size=M' IOError: can't determine geometry of HDF image file .found game...building...Corrupt! rm: cannot remove '../../hdf/xxx_game.hdf': No such file or directory
amigatool batch process complete. Total processed: 28 Skipped directories: 1 Skipped files: 2 Didn't contain a WHDload game: 0 File was corrupt: 25 Already compatible files: 0 Converted files: 0 Converted .hdf files are located in the /hdf folder.
Maybe you have an idea what i'm doing wrong?
-
@abunille It says
./amigatool.sh: line 176: bc: command not found
That sounds like you are missing the bc package. Try
sudo apt install bc
and try again?
-
looks much better now.
Thank you :) -
Great, glad to hear it.
-
I know it's not the right place to ask but i was never that deep into Amiga emulation but after reading this post i wanted to start.
I have a collection of a few thousand files in .lha format but many games are doubles or triples.
Is there a dat file or a batch script to remove the doubles and only keep one. I can't find anything.
-
Hello i get this errors i don't understand
I'm on archlinux
Cadaver_v2.2_0900.zip: unzipping....Traceback (most recent call last): File "/usr/bin/xdftool", line 11, in <module> load_entry_point('amitools==0.1.0', 'console_scripts', 'xdftool')() File "/usr/lib/python3.7/site-packages/amitools/tools/xdftool.py", line 827, in main code = queue.run() File "/usr/lib/python3.7/site-packages/amitools/tools/xdftool.py", line 100, in run exit_code = CommandQueue.run(self) File "/usr/lib/python3.7/site-packages/amitools/util/CommandQueue.py", line 42, in run exit_code = self.run_first(cmd_line, cmd) File "/usr/lib/python3.7/site-packages/amitools/tools/xdftool.py", line 163, in run_first exit_code = cmd.run(self.blkdev, self.volume) File "/usr/lib/python3.7/site-packages/amitools/tools/xdftool.py", line 58, in run self.blkdev = self.init_blkdev(self.args.image_file) File "/usr/lib/python3.7/site-packages/amitools/tools/xdftool.py", line 209, in init_blkdev return f.create(image_file, options=opts, force=self.args.force) File "/usr/lib/python3.7/site-packages/amitools/fs/blkdev/BlkDevFactory.py", line 161, in create if not geo.setup(options): File "/usr/lib/python3.7/site-packages/amitools/fs/blkdev/DiskGeometry.py", line 56, in setup (c, h, s) = self._parse_chs(options) File "/usr/lib/python3.7/site-packages/amitools/fs/blkdev/DiskGeometry.py", line 85, in _parse_chs if options.has_key('chs'): AttributeError: 'dict' object has no attribute 'has_key' .found game...building...Corrupt!
-
-
I'm trying to play lha games, but games don't work. Do I have to set something?
-
@Chuck_B From the original post:
"It does not support the .lha files used by Amiberry. See the next reply for a script that can convert .lha files for use in lr-puae.'' "The vast majority of WHDLoad format games out there are in .lha format for Amiberry, not in .hdf format. These will not load."
This is because Amiberry-compatible files have been specifically set up to work with that emulator.
See https://retropie.org.uk/forum/post/195052 for a script that will convert these .lha files to something that lr-puae can load.
Alternatively, use Amiberry for them.
-
@rkoster said in Using lr-puae for Amiga emulation:
Then download and install this package.
sudo chmod a+x amigatool*
sudo chown pi:pi amigatool*Hi there. I have a massive collection of Amiga games in .LHA format that I've done a lot of manual scraping on, so was happy to find my way to this post! Thanks for all of your hard work.
I've followed the above (I think) but am now receiving the following:
./amigatool-batch.sh: line 7: syntax error near unexpected token `newline' ./amigatool-batch.sh: line 7: `<!DOCTYPE html>'
Any ideas as to what is happening? I'm assuming it's user error along the way, but another pair of eyes (or opinions) would be great.
-
@FetusSandwich Make sure the file has Unix line endings. If you copy/pasted this on a Windows machine, it might have the wrong line-endings.
-
@mitu Hi, mitu.
First off, longtime lurker, but thanks for all of your contributions to this community. I'm almost done with a yearlong build and I can't tell you how many times a solution to one of RetroPie's infinite little quarks rested somewhere on this forum with your name on it. You have my many thanks.
That's a great thought, but I verified them in notepad++. As a Windows user trying to force fit himself in this Linux world, let's take a further step back and see if it's maybe the user error issue.
As the user here, to run amigatool-batch.sh, I want:
A. To be at /usr/local/lib with the above packages/permissions installed and set.
B. To be at /usr/local/lib with the packages installed and then move and run the scripts from /home/pi/RetroPie/roms/amiga.
C. To be at /usr/local/lib with the above packages/permissions to stage the setup, then move the entirety of the above to /home/pi/RetroPie/roms/amiga and run the script.Additionally, I received the following errors when attempting sudo pip install amitools:
Building wheels for collected packages: amitools Running setup.py bdist_wheel for amitools ... error Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-FS0i4A/amitools/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpv6p5VUpip-wheel- --python-tag cp27: use_cython: False /usr/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'long_description_content_type' warnings.warn(msg) usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help error: invalid command 'bdist_wheel'
To get past this, I used sudo pip install amitools --no-cache-dir, which seemed to work, but here we are.
-
@FetusSandwich said in Using lr-puae for Amiga emulation:
EDIT: Could it possibly be a Python 2.7 EOL thing?
No, it's just because the
wheel
is actually missing - though it's not a fatal error and the installation still works. You can ignore the errors about missingbdist_wheel
. -
@mitu I meticulously went back through, deleted everything away then reinstalled all of the packages. As I monitored for discrepancies keeping note of your original comment, the script practically saved as a completely different file upon using my Windows right click. You were 100% correct about the Unix line endings and copying in the actual data from github and saving over the original info did the trick!
So if you are experiencing a similar issue, the fix is fairly simple:
- Open the amigatool .sh in notepad++.
- Replace the contents with the raw data here.
- Open the amigatool-batch .sh in notepad++.
- Replace the contents with the raw data here.
- Save both files.
Additionally, the original instructions assume that the user knows what to do with these scripts. They simply need to:
- Change their active directory to their Amiga folder : cd /home/pi/RetroPie/roms/amiga
- After the five installation commands above, download the scripts here and place them in your Amiga folder.
- Run sudo chmod a+x amigatool*, as explained originally.
- Run sudo chown pi:pi amigatool*, as explained originally.
- Copy the scripts into your Amiga CD32 folder: cd /home/pi/RetroPie/roms/amigacd32
- Fix the contents (if necessary) by updating the text as explained above.
-
Apologies for necroing this topic, but I just wanted to let you know that I had the same issue with IPFs with lr-puae and Retropie on RPI4.
None of the available precompiled binaries seem to work (I could not get them to work at least).
I managed to solve it by compiling capsimg.so on the Pi itself. I cloned Amiberry sources and compiled the capsimg submodule, then moved the capsimg.so to Retropie/BIOS. After this, lr-puae started working nicely with IPFs.
Thank you
-
@rkoster Sorry to pull this one out of the archive, but I'm late to the show for converting my Amiga library to the Libretro core. Makes sense to just continue on this thread.
First.. wow.. this is great! Thanks. I've got my zipped .ADF's working great in lr-puae.
The issue came up when I wanted to load the amitools to convert my .lha files to use. I loaded the python script and entered the next command to pull-down/load the amitools and I got this... are you still supporting this, or is there something newer. You did an outstanding job on the A800 side.... so I figured I'd follow you for the Amiga.
Thanks!
JamR
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.