.dsk images containing multiple files

Amstrad CPC and NC systems
Post Reply
iratahack
New member
Posts: 4
Joined: Thu Oct 14, 2021 4:49 pm

.dsk images containing multiple files

Post by iratahack »

I've been playing around with the CPC, as you do... I've been able to create disk images with a single executable file OK but I couldn't find a way, with the standard tools, to add multiple executable files to a disk image. After much searching I found the utility below which can be built on Linux. It seems to work well so I thought I'd share it with everyone.

https://github.com/neuro-sys/sector-cpc

Let me know if there are any better alternatives.
IH.
User avatar
dom
Well known member
Posts: 1506
Joined: Sun Jul 15, 2007 10:01 pm

Re: .dsk images containing multiple files

Post by dom »

The normal tools for this something like cpmtools combined with libdsk.

The disc image generating code with appmake is capable of writing multiple files to a disc image: the +3 generator does it, it's just never really been needed before.

Patches and enhancements are accepted!
iratahack
New member
Posts: 4
Joined: Thu Oct 14, 2021 4:49 pm

Re: .dsk images containing multiple files

Post by iratahack »

Thanks for the info. Let me take a look at how appmake for the +3 does it. Maybe I can port it to the cpc.
IH.
iratahack
New member
Posts: 4
Joined: Thu Oct 14, 2021 4:49 pm

Re: .dsk images containing multiple files

Post by iratahack »

I ported the memory banking support in appmake from the +3 to the CPC. This is what I was after. The changes have been merged to the master branch. Works like a charm for .dsk images and .wav audio files.
IH.
User avatar
dom
Well known member
Posts: 1506
Joined: Sun Jul 15, 2007 10:01 pm

Re: .dsk images containing multiple files

Post by dom »

It’s a great feature. Thank you!

I’ll spend some time in a week or so getting banked programs working for C compilations.
iratahack
New member
Posts: 4
Joined: Thu Oct 14, 2021 4:49 pm

Re: .dsk images containing multiple files

Post by iratahack »

Let me know if I can help. I was a speccy kid so doing 30+ years of catch-up programming the CPC. I'm a big believer is learning by doing.
IH.
User avatar
dom
Well known member
Posts: 1506
Joined: Sun Jul 15, 2007 10:01 pm

Re: .dsk images containing multiple files

Post by dom »

Thanks, your crt file was a big help.

I've got the crt0 loading the banks now (based off your code/ideas) and have banked calling working. It's not an exciting picture, but here's a screenshot of the banked example:
Screenshot 2021-11-02 at 23.39.08.png
In theory the mechanism should also work with RAM expansions (I assume up to 512k just page into segment 1) though there's no placeholders or anything like that here.
You do not have the required permissions to view the files attached to this post.
Post Reply