Disk drives

The place for codemasters or beginners to talk about programming any language for the Spectrum.
Post Reply
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

djnzx48 wrote: Fri Jun 15, 2018 12:21 am
Ast A. Moore wrote: Thu Jun 14, 2018 11:07 am Fuse, for example, supports a broad range of modern storage interfaces:

—DivIDE
—DivMMC
—Simple 8-bit IDE
—ZXATASP
—ZXCF
—ZXMMC

At least in this regard, testing them an emulator is trivial.
That's the problem, there's just so many of them that I don't know which ones would be best to use! If I knew which ones were more popular I'd design for those first and maybe do the others later.
DivIDE and DivMMC are the two most widely used interfaces.
djnzx48 wrote: Fri Jun 15, 2018 12:21 am
Ast A. Moore wrote: Thu Jun 14, 2018 11:07 amSince you seem to be targeting the original Spectrums, your options are automatically limited to (a) the +3’s disk interface (which, obviously, excludes all other machines), (b) modern storage interfaces (one or more), and (c) the good-old tape interface. Everything else is too obscure nowadays. Thus, logically, if you want to include all 128K Spectrums, your only options are (b) and (c). If you want to extend support to most emulators as well, then it’s just (c).
My idea was to have a separate version of the game for each different disk interface, similar to what Sword of Ianna did. So it would be possible to have a +3 version, a modern interface version, and maybe a tape version.
If you’re okay with several different versions, then this sounds like the best course of action.
djnzx48 wrote: Fri Jun 15, 2018 12:21 am I'm just not sure how many people use TR-DOS with the Sinclair/Amstrad machines outside of emulators.
If your guess was zero, you’re not too far off. ;)
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: Disk drives

Post by hikoki »

I suppose it wouldn't be too bad to have multiload. The problem is I'm imagining that the game will involve going back and forth between different sections, which would require a lot of rewinding to get back to earlier bits. With turboloading in emulators it's not so much of a problem, but it could get annoying on real hardware.
I don't have this mp3 car cassette adapter but it's affordable and popular amongst Spectrum users.
It seems to me that could be used like a game interface. Look the remote control, the player seems able to press any number to play any block so you could place a lot of small mp3 audio files.. maybe a .m3u playlist file would suffice to make the process easier.

Image
User avatar
Guesser
Manic Miner
Posts: 639
Joined: Wed Nov 15, 2017 2:35 pm
Contact:

Re: Disk drives

Post by Guesser »

A pox on turbo loaders.

Almost everyone who plays a spectrum game will be using an emulator, or some description of flash/hard disk interface which will both load a tap file more or less instantly. A fancy turbo loader will probably work with the emulator, but is unusable to the real hardware mass storage people.
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

Guesser wrote: Fri Jun 15, 2018 3:37 pm A pox on turbo loaders.

Almost everyone who plays a spectrum game will be using an emulator, or some description of flash/hard disk interface which will both load a tap file more or less instantly. A fancy turbo loader will probably work with the emulator, but is unusable to the real hardware mass storage people.
1. Any emulator worth its salt can handle turbo loaders. That’s the general idea behind, well, emulation.
2. I misplaced the printout of the results of my latest poll in which I asked every Spectrum owner on the planet if he used “some description of flash/hard disk interface,” but going from memory, it wasn’t “almost everyone” by a long shot.
3. It’s trivial to offer both standard and turbo-loader versions of your game. I do. Everybody wins. Yay.
3 ½. (I’ve always frowned upon this “instant loading” nonsense. You can’t even see the loading screen in most cases. Where’s the fun in that?)
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
User avatar
Guesser
Manic Miner
Posts: 639
Joined: Wed Nov 15, 2017 2:35 pm
Contact:

Re: Disk drives

Post by Guesser »

Ast A. Moore wrote: Fri Jun 15, 2018 4:07 pm 1. Any emulator worth its salt can handle turbo loaders. That’s the general idea behind, well, emulation.
They support all the standard turboloaders but if you invent your own, especially if it requires exotic tzx blocks you might hit edge cases. (and you still might end up with it loading slower than if you'd just used tap as it's still got to emulate all your clever tape loading code)
Ast A. Moore wrote: Fri Jun 15, 2018 4:07 pm 3. It’s trivial to offer both standard and turbo-loader versions of your game. I do. Everybody wins. Yay.
good :)
User avatar
Guesser
Manic Miner
Posts: 639
Joined: Wed Nov 15, 2017 2:35 pm
Contact:

Re: Disk drives

Post by Guesser »

Ast A. Moore wrote: Fri Jun 15, 2018 4:07 pm 2. I misplaced the printout of the results of my latest poll in which I asked every Spectrum owner on the planet if he used “some description of flash/hard disk interface,” but going from memory, it wasn’t “almost everyone” by a long shot.
Unless someone out there is filling their house up with Ben's flash interfaces for some reason, a lot of people who use original hardware are using flash interfaces :)
User avatar
Seven.FFF
Manic Miner
Posts: 735
Joined: Sat Nov 25, 2017 10:50 pm
Location: USA

Re: Disk drives

Post by Seven.FFF »

I would guess the vast majority use flash interfaces. The remaining minority are ideological purists, and I would guess the vast submajority of those are so ideologically pure they only load from tape.
Robin Verhagen-Guest
SevenFFF / Threetwosevensixseven / colonel32
NXtel NXTP ESP Update ESP Reset CSpect Plugins
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

Guesser wrote: Fri Jun 15, 2018 6:34 pm They support all the standard turboloaders but if you invent your own, especially if it requires exotic tzx blocks you might hit edge cases. (and you still might end up with it loading slower than if you'd just used tap as it's still got to emulate all your clever tape loading code)
If by “support” you mean “accelerate,” then sure. The only “non-standard” turbo loader I know of is OTLA. It’s a weird beast that uses the undocumented IN (C) instruction and checks the parity flag. It’s insanely fast, but you obviously can’t press any keys while the game is loading. The OTLA utility packs everything as a single Direct Recording block. (In is defense, it wasn’t really meant to create files for emulators.) Some older emulators, indeed, have trouble loading these TZX files. (Fuse is okay with them, though.)

Virtually any other turbo loader out there uses some form of a modified standard ROM routine, fiddling with the timing constants and mucking about with decryption, obfuscation, moving data around in RAM several times, etc. Almost all of them are not very well optimized. (They keep a lot of unnecessary code copied straight from the ROM.) Other than that—nothing out of ordinary.
Guesser wrote: Fri Jun 15, 2018 6:37 pm Unless someone out there is filling their house up with Ben's flash interfaces for some reason, a lot of people who use original hardware are using flash interfaces.
Right before she took her last breath, my grandma made me swear I’d never use one of them infernal contraptions, for they are unholy.
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

Seven.FFF wrote: Fri Jun 15, 2018 6:50 pm and I would guess the vast submajority of those are so ideologically pure they only load from tape.
Just the way Our Good Lord Clive intended. Amen.
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
User avatar
Seven.FFF
Manic Miner
Posts: 735
Joined: Sat Nov 25, 2017 10:50 pm
Location: USA

Re: Disk drives

Post by Seven.FFF »

The number of times thou shalt rewind the tape is three; and three shalt be the number of times, verily.

It's worth mentioning the number of different drive systems Garry's ace +3e ROMs support. If you write for the +3 API, you get all these for free.

http://www.worldofspectrum.org/zxplus3e/p3eroms.html
Robin Verhagen-Guest
SevenFFF / Threetwosevensixseven / colonel32
NXtel NXTP ESP Update ESP Reset CSpect Plugins
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

Seven.FFF wrote: Fri Jun 15, 2018 7:19 pm The number of times thou shalt rewind the tape is three; and three shalt be the number of times, verily.
Truly, the Good Book doth not lie!
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
AndyC
Dynamite Dan
Posts: 1388
Joined: Mon Nov 13, 2017 5:12 am

Re: Disk drives

Post by AndyC »

If you really need a disk system, I'd go with +3DOS - despite it being limited in terms of hardware support. It has a nice and powerful API. On the other hand if all you need is a way of quick loading blocks of data, I'd go with the standard ROM tape loading routines and let people use modern devices that accelerate the whole process.
User avatar
Guesser
Manic Miner
Posts: 639
Joined: Wed Nov 15, 2017 2:35 pm
Contact:

Re: Disk drives

Post by Guesser »

Ast A. Moore wrote: Fri Jun 15, 2018 7:04 pm If by “support” you mean “accelerate,” then sure.
I meant if you wrote something that required one of the "new" tzx blocks that hardly anyone could be bothered to implement to correctly store it or something.
I suppose on a technicality the emulators would still support the loader as you could distribute it as a csw or wav file :lol:
User avatar
Guesser
Manic Miner
Posts: 639
Joined: Wed Nov 15, 2017 2:35 pm
Contact:

Re: Disk drives

Post by Guesser »

If you use the ROM tape format, and give each file a unique name, then it's fairly trivial for anyone to convert it to whatever system they so desire. Working back in the other direction is more awkward :)
User avatar
Ast A. Moore
Rick Dangerous
Posts: 2640
Joined: Mon Nov 13, 2017 3:16 pm

Re: Disk drives

Post by Ast A. Moore »

Guesser wrote: Sat Jun 16, 2018 12:34 am
Ast A. Moore wrote: Fri Jun 15, 2018 7:04 pm If by “support” you mean “accelerate,” then sure.
I meant if you wrote something that required one of the "new" tzx blocks that hardly anyone could be bothered to implement to correctly store it or something.
I use the turbo speed block (ID 11) for the main data and generalized data block (ID 19) for shortening the length of the pilot tone in the initial standard block. This can be easily replaced with a combination of pure tone/pulse sequence/pure data blocks (ID 12–14), or, in fact, a single turbo speed block (using standard lengths/pulses).
Guesser wrote: Sat Jun 16, 2018 12:34 amI suppose on a technicality the emulators would still support the loader as you could distribute it as a csw or wav file :lol:
I do the latter (WAV files). Again, my turbo loader is meant for real hardware rather than emulators. Many people use their phones, PCs, digital music players, etc. to load games, so the WAV files are for them. In addition, there are apps for the PC/mobile that generate audio from TZX files on the fly. Plenty of options, in other words.
Every man should plant a tree, build a house, and write a ZX Spectrum game.

Author of A Yankee in Iraq, a 50 fps shoot-’em-up—the first game to utilize the floating bus on the +2A/+3,
and zasm Z80 Assembler syntax highlighter.
Post Reply