A library of tap2sna.py recipes

The place for codemasters or beginners to talk about programming any language for the Spectrum.
User avatar
SkoolKid
Manic Miner
Posts: 407
Joined: Wed Nov 15, 2017 3:07 pm

Re: A library of tap2sna.py recipes

Post by SkoolKid »

Status update: There's nothing left TBI (to be investigated)!

https://skoolkit.ca/t2sfiles/
https://skoolkit.ca/t2sfiles/TBI/

That will probably change the next time ZXDB is updated, but let's enjoy this sense of completeness while we can. :dance
SkoolKit - disassemble a game today
Pyskool - a remake of Skool Daze and Back to Skool
User avatar
PeterJ
Site Admin
Posts: 6880
Joined: Thu Nov 09, 2017 7:19 pm
Location: Surrey, UK

Re: A library of tap2sna.py recipes

Post by PeterJ »

@SkoolKid,

Please could I ask what I'm doing wrong:

I download and Unzip...
skoolkit-master.zip
t2sfiles-master.zip

To d:\

Rename d:\skoolkit-master to d:\SkoolKit

Move directories t2s and utils from t2sfiles-master to d:\SkoolKit

Then,

Code: Select all

cd d:\skoolkit\utils

python t2s2sna.py

Code: Select all

D:\SkoolKit\utils>python t2s2sna.py
tap2sna.py not found and SKOOLKIT_HOME is not set.

Either place t2s2sna.py alongside tap2sna.py in the SkoolKit root directory, or
set the SKOOLKIT_HOME environment variable to the full path to the SkoolKit
root directory.
So, copy t2s2sna.py to d:\skoolkit and type python t2s2sna.py moontorc.t2s (as per the example)

Code: Select all

d:\SkoolKit>python t2s2sna.py moontorc.t2s
Downloading https://github.com/skoolkid/t2sfiles/raw/master/t2s/m/moontorc.t2s
usage:
  tap2sna.py [options] INPUT [OUTFILE]
  tap2sna.py @FILE [args]
t2s2sna.py: error: argument --tape-name: expected one argument
Thanks
User avatar
SkoolKid
Manic Miner
Posts: 407
Joined: Wed Nov 15, 2017 3:07 pm

Re: A library of tap2sna.py recipes

Post by SkoolKid »

PeterJ wrote: Thu Nov 02, 2023 1:55 pm Please could I ask what I'm doing wrong...
You're not doing anything wrong: I forgot to update t2s2sna.py after preparing all the t2s files for the (imminent) release of SkoolKit 9.0.

It should be fixed now, so replace your old copy with the latest one:

https://github.com/skoolkid/t2sfiles/ra ... t2s2sna.py
SkoolKit - disassemble a game today
Pyskool - a remake of Skool Daze and Back to Skool
User avatar
PeterJ
Site Admin
Posts: 6880
Joined: Thu Nov 09, 2017 7:19 pm
Location: Surrey, UK

Re: A library of tap2sna.py recipes

Post by PeterJ »

Thanks @SkoolKid!

That works perfectly now.
User avatar
SkoolKid
Manic Miner
Posts: 407
Joined: Wed Nov 15, 2017 3:07 pm

Re: A library of tap2sna.py recipes

Post by SkoolKid »

t2s files for the games in the latest ZXDB update (1.0.176) have been added to the repository.

https://skoolkit.ca/t2sfiles/
SkoolKit - disassemble a game today
Pyskool - a remake of Skool Daze and Back to Skool
User avatar
8BitSC
Microbot
Posts: 129
Joined: Mon Feb 13, 2023 1:23 am

Re: A library of tap2sna.py recipes

Post by 8BitSC »

Fairlight 1 and 2 (128k versions) load and run on emulators but not on real hardware.

Fairlight 1 just corrupts the screen and restarts the AY tune.

Fairlight 2 doesn’t respond to a keypress after loading, so the game cannot begin.

The 48k versions seem to load okay.
User avatar
SkoolKid
Manic Miner
Posts: 407
Joined: Wed Nov 15, 2017 3:07 pm

Re: A library of tap2sna.py recipes

Post by SkoolKid »

8BitSC wrote: Fri Jan 26, 2024 10:32 pm Fairlight 1 and 2 (128k versions) load and run on emulators but not on real hardware.
@8BitSC, presumably you opened an issue on GitHub?

I'm afraid I have no idea how the DIVMMC Enjoy Pro loads Z80 snapshots, so I can't even guess what's going wrong. Perhaps someone who has knowledge of that hardware's inner workings can shed some light.

Edited by PJ
SkoolKit - disassemble a game today
Pyskool - a remake of Skool Daze and Back to Skool
User avatar
TomD
Manic Miner
Posts: 379
Joined: Tue Nov 13, 2018 9:47 am
Location: Leeds UK
Contact:

Re: A library of tap2sna.py recipes

Post by TomD »

8BitSC wrote: Fri Jan 26, 2024 10:32 pm Fairlight 1 and 2 (128k versions) load and run on emulators but not on real hardware.

Fairlight 1 just corrupts the screen and restarts the AY tune.

Fairlight 2 doesn’t respond to a keypress after loading, so the game cannot begin.

The 48k versions seem to load okay.
I've just tested both (created using the t2s) on my Microdrive Emulator using the inbuilt Z80 loader and they work fine on my toastrack 128k. Best guess is they don't load due to the way the DivMMC handles 128k snapshots as @SkoolKid says.

If you do want to load via a DivMMC you can always convert the TZX to Z80 and then to a TAP using my Z80onTAP conversion utility (https://tomdalby.com/other/files/Z80onTAP.zip). This uses the same routine as the one for the Microdrive.

TomD
Retro enthusiast and author of Flynn's Adventure in Bombland, The Order of Mazes & Maze Death Rally-X. Check them out at http://tomdalby.com
jamesh
Dizzy
Posts: 83
Joined: Thu Jul 06, 2023 6:36 pm

Re: A library of tap2sna.py recipes

Post by jamesh »

I'll double check it today, but as far as I remember both snapshots were working just fine on grey +2 with DivMMC Future.

Not sure if it's relevant, but those 128k snapshots definitely work fine on Next and Sifiz-512. Neither one has "real" DivMMC, though. Looks like we need someone with real hardware and enjoy pro.

However, the part "Fairlight 1 just corrupts the screen and restarts the AY tune." seems to be the normal behaviour I can see. It starts with a beeper tune, switches to AY after a key press with some "corrupted" graphics which is quickly recovered, and works fine after that. Those screen "updates"/glitches happen on all machines I have, so I guess it's a part of memory init for 128.
User avatar
8BitSC
Microbot
Posts: 129
Joined: Mon Feb 13, 2023 1:23 am

Re: A library of tap2sna.py recipes

Post by 8BitSC »

jamesh wrote: Tue Feb 06, 2024 11:02 am
I’ve seen this with tap images. This conversion corrupts the screen even more with each key press until the spectrum resets.
User avatar
TomD
Manic Miner
Posts: 379
Joined: Tue Nov 13, 2018 9:47 am
Location: Leeds UK
Contact:

Re: A library of tap2sna.py recipes

Post by TomD »

jamesh wrote: Tue Feb 06, 2024 11:02 am I'll double check it today, but as far as I remember both snapshots were working just fine on grey +2 with DivMMC Future.

Not sure if it's relevant, but those 128k snapshots definitely work fine on Next and Sifiz-512. Neither one has "real" DivMMC, though. Looks like we need someone with real hardware and enjoy pro.

However, the part "Fairlight 1 just corrupts the screen and restarts the AY tune." seems to be the normal behaviour I can see. It starts with a beeper tune, switches to AY after a key press with some "corrupted" graphics which is quickly recovered, and works fine after that. Those screen "updates"/glitches happen on all machines I have, so I guess it's a part of memory init for 128.
I'm not seeing that corruption on real hardware? Screen flashes very briefly after you press a key and then the AY tune starts, is that what you mean?
Retro enthusiast and author of Flynn's Adventure in Bombland, The Order of Mazes & Maze Death Rally-X. Check them out at http://tomdalby.com
jamesh
Dizzy
Posts: 83
Joined: Thu Jul 06, 2023 6:36 pm

Re: A library of tap2sna.py recipes

Post by jamesh »

TomD wrote: Tue Feb 06, 2024 2:01 pm I'm not seeing that corruption on real hardware? Screen flashes very briefly after you press a key and then the AY tune starts, is that what you mean?
Yes, nothing really bad, just some colour attributes change. I have captured a video fragment and that’s how it looks like. It only lasts about 3 real frames, captured as 30 frames per second. This is each frame captured from a video recording and presented as GIF:
Spoiler
Image
Surprisingly, I found a way to reproduce the crash with MiSTer’s ZX-Spectrum core. “Port #FF” has to be set to “Timex”. Sorry, have no idea what it means (Timex’s ULA extensions?). The other option is “SAA1099” and everything works with that configuration. And somehow Z80 can be loaded fine into the core directly, it only breaks when using esxdos layer. Also, Fairlight 2 has no sound on MiSTer with that “Timex” thing turned on.
User avatar
8BitSC
Microbot
Posts: 129
Joined: Mon Feb 13, 2023 1:23 am

Re: A library of tap2sna.py recipes

Post by 8BitSC »

This is odd.

I just regenerated the 128K versions from scratch using the t2sfiles and now they work from the DIVMC Pro ENJOY on my toastrack 128K as expected (complete with the few frames {flash} of screen corruption as mentioned by @jamesh) in Fairlight 128K.

However from the DIVMMC on the Harlequin 128, They still crash in the same way described earlier.

I've not tried my Grey 128 +2 yet but I'm curious if I can get the original TZX files of the 128K versions to run on my Harlequin now.

Strange, that of the 100+ games I've converted to .z80 using @SkoolKid's t2sfiles, only 2 games from the same author/publisher exhibit issues.

Time to test.

EDIT: Testing, loading from a TZX file on my Harlequin 128 via maxduino, the original version of Fairlight (1) 128K, I get the same increasing on-screen corruption and crash.

However, I HAVE found a 1986 128K Micro-Selection re-release of Fairlight 2 128K, which can be processed by tap2sna.py using "-c machine=128" to produce a .z80 which loads and runs perfecrtly on the Harlequin via the DIVMMC.

Testing continues to finding a TZX file of the first Fairlight 128K I CAN convert to a working .z80 on the Harlequin 128.

@SkoolKid, it looks like you can close the issue on GitHub. this looks to be an issue with the Harlequin 128 at this time, although I suspect Fairlight 2 128K could be made to work directly from your t2sfile, if you could utilise the Micro-Selection re-release instead.
Post Reply