24.12.2013 Views

TOPS-10 Monitor Calls Manual Volume 2 AA-K039D ... - Trailing-Edge

TOPS-10 Monitor Calls Manual Volume 2 AA-K039D ... - Trailing-Edge

TOPS-10 Monitor Calls Manual Volume 2 AA-K039D ... - Trailing-Edge

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

OPEN [OPCODE 050]<br />

EXAMPLES<br />

iSubroutine to OPEN the disk in dump mode<br />

iCall with:<br />

PUSHJ P,DMPINI<br />

RETURN HERE<br />

DMPINI: OPEN DSK,OPNBLK iOPEN the disk on channel "DSK"<br />

JRST NOTAVL iDevice is busy<br />

ENTER DSK,FILE iCreate a new file<br />

JRST FILBAD iCannot ENTER file name in<br />

i disk directory.<br />

POPJ P,<br />

iReturn - file is now open for<br />

Dump mode output.<br />

iHere if device DSK: cannot be OPENed<br />

NOTAVL: OUTSTR [ASCIZ n?CANNOT OPEN DSK:<br />

n]<br />

iPrint an error message<br />

EXIT<br />

iReturn to the monitor<br />

iHere if file cannot be created<br />

FILBAD: OUTSTR [ASCIZ n?CANNOT CREATE DSK:DUMP.BIN<br />

n ]<br />

iPrint an error message<br />

iReturn to the monitor<br />

iSelect dump mode<br />

iDevice name<br />

iNo buffers<br />

iFile name<br />

iFile name extension<br />

iDefault protection<br />

iDefault directory<br />

EXIT<br />

OPNBLK: EXP<br />

SIXBIT<br />

EXP<br />

FILE: SIXBIT<br />

SIXBIT<br />

EXP<br />

EXP<br />

iSubroutine<br />

iCall with:<br />

. IODMP<br />

/DSK/<br />

a<br />

/DUMP/<br />

/BIN/<br />

a<br />

to write data in buffer<br />

FILL BUFFER WITH DATA<br />

PUSHJ P,DMPOUT<br />

RETURN HERE<br />

DMPOUT: OUT DSK,OUTLST iWrite data<br />

POPJ P,<br />

iNo errors - Return to caller<br />

OUTSTR [ASCIZ n?OUTPUT ERROR FOR DSK:DUMP.BIN<br />

n ]<br />

iOutput error message<br />

iReturn to monitor<br />

EXIT<br />

iCommand list for output<br />

OUTLST: IOWD BUFSIZ, BUFFER<br />

EXP 0<br />

BUFFER: BLOCK BUFSIZ<br />

iSubroutine to close out file<br />

iCall with:<br />

PUSHJ P,DMPDON<br />

RETURN HERE<br />

iWrite BUFSIZ words from buffer<br />

iEnd of command list<br />

iOutput buffer<br />

DMPDON: CLOSE<br />

STATO<br />

POPJ<br />

OUTSTR<br />

n ]<br />

EXIT<br />

DSK,<br />

iWrite the end of file<br />

DSK,IO.ERR iAre there any errors?<br />

P, i No-return<br />

[ASCIZ n?ERROR CLOSING DSK:DUMP.BIN<br />

iPrint error message<br />

iReturn to the monitor<br />

RELATED CALLS<br />

o<br />

o<br />

FILOP.<br />

INIT<br />

22-276

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!