2005-03-30 18:25:04 +00:00
|
|
|
;
|
|
|
|
; Oliver Schmidt, 24.03.2005
|
|
|
|
;
|
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
.export dioprolog, diocommon, dioepilog
|
|
|
|
.import popax
|
2005-03-30 18:25:04 +00:00
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
.include "errno.inc"
|
|
|
|
.include "mli.inc"
|
2005-03-30 18:25:04 +00:00
|
|
|
|
|
|
|
dioprolog:
|
|
|
|
; Set buffer
|
2013-05-09 11:56:54 +00:00
|
|
|
sta mliparam + MLI::RW_BLOCK::DATA_BUFFER
|
|
|
|
stx mliparam + MLI::RW_BLOCK::DATA_BUFFER+1
|
2005-03-30 18:25:04 +00:00
|
|
|
|
|
|
|
; Get and set sect_num
|
2013-05-09 11:56:54 +00:00
|
|
|
jsr popax
|
|
|
|
sta mliparam + MLI::RW_BLOCK::BLOCK_NUM
|
|
|
|
stx mliparam + MLI::RW_BLOCK::BLOCK_NUM+1
|
2005-03-30 18:25:04 +00:00
|
|
|
|
|
|
|
; Get and set handle
|
2013-05-09 11:56:54 +00:00
|
|
|
jsr popax
|
|
|
|
sta mliparam + MLI::RW_BLOCK::UNIT_NUM
|
2005-03-30 18:25:04 +00:00
|
|
|
rts
|
|
|
|
|
|
|
|
diocommon:
|
|
|
|
; Call read_block or write_block
|
2013-05-09 11:56:54 +00:00
|
|
|
ldx #RW_BLOCK_COUNT
|
2018-09-08 21:14:54 +00:00
|
|
|
jsr callmli
|
2005-03-30 18:25:04 +00:00
|
|
|
|
|
|
|
dioepilog:
|
|
|
|
; Return success or error
|
2022-08-28 19:52:53 +00:00
|
|
|
sta ___oserror
|
2013-05-09 11:56:54 +00:00
|
|
|
ldx #$00
|
2005-03-30 18:25:04 +00:00
|
|
|
rts
|