initial release

This commit is contained in:
Peter Ferrie 2018-07-14 12:31:57 -07:00
parent 5aa7486e01
commit 6a787ae229
2 changed files with 2901 additions and 0 deletions

2860
PRORWTS2.S Normal file

File diff suppressed because it is too large Load Diff

41
readme.md Normal file
View File

@ -0,0 +1,41 @@
open/seek/read/write any binary file in ProDOS filesystem.<br>
runs from any directory on floppy or hard disk.<br>
searches the file system for the requested file, can even look inside subdirectories.<br>
can simulate DOS 3.3 RWTS (including format) to allow disk images on the hard disk, and multiple sides in the same file.<br>
can read sparse files, and read and write tree files<br>
<br>
usage:<br>
<br>
jsr init ;one-time call to unhook ProDOS, detect drive type, and relocate code if needed<br>
<br>
;open and read bytes from a file without address override or writing enabled<br>
lda #<file_to_read<br>
sta namlo<br>
lda #>file_to_read<br>
sta namhi<br>
lda #6 ;bytes
sta sizelo
lda #0
sta sizehi
jsr opendir ;open and read file into memory at its load address<br>
<br>
;write to an open file with address override<br>
lda #<file_to_write<br>
sta namlo<br>
lda #>file_to_write<br>
sta namhi<br>
lda #0<br>
sta sizelo<br>
lda #>bytes_to_write<br>
sta sizehi<br>
lda #<place_to_write<br>
sta adrlo<br>
lda #>place_to_write<br>
sta adrhi<br>
lda #cmdwrite<br>
sta reqcmd<br>
jsr rdwrpart ;write bytes from memory to specified load address<br>
<br>
<br>
format of request name is Pascal-style (length, text):<br>
e.g. !raw 5, "MYDIR" or !raw 6, "MYFILE" or !raw 14, "QKUMBAROXURSOX"