Hi, I have written a small routine in assembly language to allow STOS to use fopen\fread\fseek and fclose.
This was necessary to write my double buffered sample player in STOS.
Bload is fine, but it doesn't allow partial loading or seeking to a part of the file and reading it into a smaller buffer.
I spent a couple of hours debugging this today. fopen should return the file handle in dreg(0) but I couldn't see it. Then I realised that dreg(0) was being overwritten by interpreter activity or other interrupts. Hence I store the file handle in the code and expose it as a word at offset 32 in the header. FREAD calls $3F in read-only mode.
10 hide : key off : mode 0 : curs off : flash off : click off : move off
get file handle:
reserve as data 5,65535
Hope someone might find it useful.
You do not have the required permissions to view the files attached to this post.
Still got, still working: Atari 4Mb STe, 520STFM, 2.5Mb STF.
Hardware: Cumana CSA 354, Ultimate Ripper, Blitz Turbo, Synchro Express II (US and UK Versions).