string asis include 'gsos.equ' include 'minix.equ' include 'records.equ' include 'fst.equ' include 'fst.macros' include 'M16.Debug' entry app_entry entry sys_entry entry sys_startup entry sys_shutdown entry rtl_invalid_fst_op entry rtl_bad_system_call entry rtl_no_error entry rtl_invalid_pcount import judge_name import create import destroy import change_path import set_file_info import get_file_info import volume import open import read import write import flush import close import get_mark import set_mark import get_eof import set_eof import get_dir_entry import get_dev_num import format import erase_disk import disk_inode:v1_inode import disk_super:v1_super import debug header proc ; ; FST attributes ; case-insensitive = $8000 [dispatcher should upper case] ; character device = $4000 ; format = $2000 ; clear high bits = $1000 ; read-only = $0800 ; Upper-case pathnames ; |Character-based FST ; ||Format capable ; |||Strip high bits from pathname characters ; ||||Read-Only FST ; |||||Reserved ; ||||||||||||||Format type ; |||||||||||||||| (00 = Universal) ; |||||||||||||||| (01 = Apple-generic) ; |||||||||||||||| (10 = Non-Apple) ; |||||||||||||||| (11 = Apple-][ specific) fst_attr equ %0010100000000010 ;attributes ;(Format, ReadOnly, Non-Apple) dc.b 'FST ' dc.l app_entry dc.l sys_entry dc.w fst_id dc.w fst_attr ; $2002 ; flags -- format, block device, non-apple format dc.w $8001 ; version 0.1, prototype. dc.w 1024 ; block size dc.l $00010000 ; max blocks/volume dc.l $00000006 ; min blocks/volume dc.l $10081c00 ; max file size dc.l 0 ; reserved str.b 'Minix' ; FST Name str.b 'Minix FST' ; FST Comment dc.w 0 ; credits str.b $0d,'Minix FST by Kelvin W Sherlock, 2014/2025',$0d endp data record export global_buffer global_buffer ds.l 1 endr sys_entry procname phk plb rep #$30 cpx #max_sys_call+1 bge rtl_no_error jmp (@sys_table,x) @sys_table dc.w rtl_no_error dc.w sys_startup dc.w sys_shutdown dc.w rtl_no_error ; remove vcr dc.w rtl_no_error ; deferred flush max_sys_call equ *-@sys_table-2 endp rtl_no_error proc lda #0 clc rtl endp rtl_invalid_fst_op proc lda #invalid_fst_op sec rtl endp rtl_bad_system_call proc lda #bad_system_call sec rtl endp rtl_invalid_pcount proc lda #invalid_pcount sec rtl endp sys_startup procname jsl get_sys_gbuf stx global_buffer sty global_buffer+2 lda #0 clc rtl endp sys_shutdown procname lda #0 clc rtl endp ; x = call number * 2 ; y = class number * 2 app_entry procname with dp with fst_parms ;import min_pcount import max_pcount phk plb rep #$30 ;brk $42 sty >8 phb lda #