www.jupiter-ace.co.uk

Previous Page > Listings Index > HDRMON (Tape Header Reader)


HDRMON
(Tape Header Reader)
By Edwin Blink
Edwin's code for his Tape Header Reader.
You can download the wav, Ace, tap files from the archive

Jupiter Ace Tape Header

An Ace tape header contains 25 bytes and contains the following:

1 byte file type 0 for Dictionary 32* for bytes
10 bytes filename padded with spaces
2 bytes length of file
2 bytes start address. This is 15441 for a dictionary
2 bytes current word. Unused for bytes file.
2 bytes value of system var CURRENT [Address hex 3C31, dec 15409]. Unused* for bytes file.
2 bytes value of system var CONTEXT [Address hex 3C33, dec 15411]. Unused* for bytes file.
2 bytes value of system var VOCLNK [Address hex 3C35, dec 15413]. Unused* for bytes file.
2 bytes value of system var STKBOT [Adress hex 3C37, dec 15415]. Unused* for bytes file.

*Filetype for bytes file may be any non zero value.
*Unused bytes are filled with spaces.

See here for more details of the Tape Header structure.




	
(==============================================================)
(Jupiter Ace Tape header Monitor          Edwin Blink, Jan 2007) 
(==============================================================)

(Ignore (don't type) the remarks while typing the lot in       )

(start the monitor with the GO word                            )

CREATE LTH		(load tape header)
17 c, 25 ,		(LD DE,25    length of header)
33 c, 8986 ,		(LD HL,LDHDR header loaded address)
74 c,			(LD C,D      signal load header)
55 c,			(SCF         signal load block)
205 c, 6311 ,		(CALL LVBLK  Load-verify tape block)
48 c, -13 c,		(JR $-11     retry on loading error)
59901 ,			(JP (IY)     jump to next)
LTH DUP 2- ! 		(change LDHD to executable code)

: XTH			(examine tape header)
." Filetype:" 10010 C@ 
DUP IF
 ." Bytes ( type " DUP . ." )"
ELSE
 ." Dictionary"
THEN
CR
." Filename:" 10011 10 TYPE CR 
." Length:  " (<- 2 SPACEs) 10021 @ . CR 
." Start:   " (<- 3 SPACEs) 10023 @ . CR 
0= IF
." Current: " (<- 1 SPACE) 10025 @ . CR 
THEN
CR
;

; GO CLS BEGIN LTH XTH 0 UNTIL ;

(SAVE hdrmon)