[Patch] IBM 5150 cassette loading
Posted: Sat 13 Apr, 2019 11:11 am
This patch adds read-only support for the IBM 5150 cassette port.
I have used PZX as the underlying tape format, with .pzxi as a file extension to indicate it contains IBM rather than Spectrum cassette data. I did this because PZX is a reasonably straightforward file format, the IBM 5150 cassette encoding is very similar to the Spectrum one and there are existing toolchains that can generate and manipulate PZX files. For example, to generate a test file I was able to do this with taptools 1.1.1:
(and then in IBM Cassette BASIC:)
Possible areas for improvement:
I have used PZX as the underlying tape format, with .pzxi as a file extension to indicate it contains IBM rather than Spectrum cassette data. I did this because PZX is a reasonably straightforward file format, the IBM 5150 cassette encoding is very similar to the Spectrum one and there are existing toolchains that can generate and manipulate PZX files. For example, to generate a test file I was able to do this with taptools 1.1.1:
Code: Select all
% cat > hello.bas
10 print "Hello"
20 goto 10
% unix2dos hello.bas
unix2dos: converting file hello.bas to DOS format...
% mkibmtap -a -fpzxi hello.pzxi hello.bas
Appended ASCII Listing: hello [58 bytes]
% ./pcem
Code: Select all
The IBM Personal Computer Basic
Version C1.10 Copyright IBM Corp 1981
62940 Bytes free
Ok
LOAD "CAS1:"
hello .A Found.
Ok
LIST
10 PRINT "Hello"
20 GOTO 10
Ok
- Unlike the real 5150, it doesn't echo the tape input to the speaker while loading
- No save support, load only
- No tape browser, so it isn't possible to wind to a particular block
- Could do with flashloading support (catch the ROM calls to load / save a block, and parse them directly out of the tape file)