DEVICE-FUNCTION: Difference between revisions

From NDWiki
Jump to navigation Jump to search
(created page for the DEVICE-FUNCTION command)
 
(→‎References: added 60.128.03 reference)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
  @DEVICE-FUNCTION <file name> <function name> (<optional parameter 1>) (<optional parameter 2>)
  @DEVICE-FUNCTION <file name> <function name> (<optional parameter 1>) (<optional parameter 2>)
 
Performs operation on magnetic tapes, cassette tapes, Versatec printer / plotter and floppy disk.
; <file name> : is the name of the device unit, as specified in the @[[SET-PERIPHERAL-FILE]] command.
; <file name> : is the name of the device unit, as specified in the @[[SET-PERIPHERAL-FILE]] command.
; <function name> : is the name of the operation to perform on the device.
; <function name> : is the name of the operation to perform on the device.
; <optional parameter 1> :
; <optional parameter 1> :
; <optional parameter 2> : these two parameters are used to specify more information needed by some operations.
; <optional parameter 2> : these two parameters are used to specify more information needed by some operations.
Rules:
#Permitted for all users.
#The functions READ-RECORD and WRITE-RECORD will transfer a specified amount of data to / from the specified address in the user area (background segment) from / to the specified device unit.
#The function UNLOCK-AND-STOP means that the cassette tape will stop and the read / write head will be removed from the tape.The cassette may then be removed from the cassette driver.
#The function LOCK-CASSETTE means that the read / write head will be removed onto the cassette tape, ready for read / write of the c assette tape. The cassette tape cannot be removed from the cassette driver when the cassette is in lock position.
#The function READ-STATUS will read the status register of the specified device unit by means of an [[IOX]] instruction. The function READ-LAST-STATUS will return the status from the last operation of the device without executing any [[IOX]] instructions (the status saved by the driver).
Example:
@DEVICE-FUNCTION MAG-TAPE-1, ADVANCE-TO-EOF, 1


Mag. tape controller 1 will advance its driver through one EOF mark.
== Functions ==
== Functions ==
The following functions can be performed (parameter <function name>) with this command:
The following functions can be performed (parameter <function name>) with this command:
=== advance-records ===
=== advance-records ===
; function code (octal) : 15
; function code (octal) : 16
; optional parameter 1 : number of records to advance.
; optional parameter 1 : number of records to advance.
; allowed on : mag tape, cassette tape, floppy disk
; allowed on : mag tape, cassette tape, floppy disk
Line 30: Line 41:
; allowed on : mag tape, cassette tape, versatec
; allowed on : mag tape, cassette tape, versatec
; not allowed on : floppy disk
; not allowed on : floppy disk
=== clear-selected-unit ===
=== clear-selected-unit ===
=== dump-bootstrap ===
=== dump-bootstrap ===
; function code (octal) : 41
; allowed on : mag tape, cassette tape, versatec
; not allowed on : floppy disk
=== erase-tape ===
=== erase-tape ===
; function code (octal) : 7
; function code (octal) : 7
; allowed on : cassette tape
; allowed on : cassette tape
; not allowed on : mag tape, versatec, floppy disk
; not allowed on : mag tape, versatec, floppy disk
=== format-floppy ===
=== format-floppy ===
; function code (octal) : 41
; function code (octal) : 41
; optional parameter 1 : file name.
; allowed on : floppy disk
; allowed on : floppy disk
; not allowed on : mag tape, cassette tape, versatec
; not allowed on : mag tape, cassette tape, versatec


=== get-current-disc-address ===
=== get-current-disc-address ===
; function code (octal) : 46
; allowed on : floppy disk
; not allowed on : mag tape, cassette tape, versatec
=== give-form-feed ===
=== give-form-feed ===
; function code (octal) : 31
; function code (octal) : 32
; optional parameter 1 : number of form feeds to give.
; optional parameter 1 : number of form feeds to give.
; allowed on : versatec
; allowed on : versatec
Line 53: Line 76:
; not allowed on : mag tape, versatec, floppy disk
; not allowed on : mag tape, versatec, floppy disk
This function means that the read / write head of the cassette drive will be moved onto the cassette tape, ready for read / write of the tape. The cassette tape cannot be removed from the cassette drive when the cassette is in lock position.
This function means that the read / write head of the cassette drive will be moved onto the cassette tape, ready for read / write of the tape. The cassette tape cannot be removed from the cassette drive when the cassette is in lock position.
=== read-byte-record ===
=== read-byte-record ===
; function code (octal) : 26
; optional parameter 1 : octal address of data buffer in user area.
; optional parameter 2 : octal number of words to read.
; allowed on : mag tape
; not allowed on : cassette tape, floppy disk, versatec
=== read-deleted-record ===
=== read-deleted-record ===
; function code (octal) : 43
; optional parameter 1 : octal address of data buffer in users area.
; optional parameter 2 : octal number of words to read.
; allowed on : floppy disk
; not allowed on : cassette tape, mag tape, versatec
=== read-format ===
=== read-format ===
; function code (octal) : 43
; allowed on : floppy disk
; not allowed on : cassette tape, mag tape, versatec
=== read-last-status ===
=== read-last-status ===
; function code (octal) : 24
; function code (octal) : 24
; allowed on : mag tape, cassette tape, versatec, floppy disk
; allowed on : mag tape, cassette tape, versatec, floppy disk
This function will return the status from the last operation on the device without extending any [[IOX]] instruction (the status is saved by the driver).
This function will return the status from the last operation on the device without extending any [[IOX]] instruction (the status is saved by the driver).
=== read-odd-number-of-bytes ===
 
=== read-odd-byte-numbers ===
; function code (octal) : 2
; optional parameter 1 : octal address of data buffer in user area.
; optional parameter 2 : octal number of words to read.
; allowed on : mag tape
; not allowed on : cassette tape, floppy disk, versatec
 
=== read-record ===
=== read-record ===
; function code (octal) : 0
; function code (octal) : 0
Line 68: Line 115:
; not allowed on : versatec
; not allowed on : versatec
This function will transfer a specified amount of data to the specified address in the user area ([[background segment]]) from the specified device unit.
This function will transfer a specified amount of data to the specified address in the user area ([[background segment]]) from the specified device unit.
=== read-status ===
=== read-status ===
; function code (octal) : 20
; function code (octal) : 20
; allowed on : mag tape, cassette tape, versatec, floppy disk
; allowed on : mag tape, cassette tape, versatec, floppy disk
This function will read the status register of the  specified device unit by means of an [[IOX]] instruction.
This function will read the status register of the  specified device unit by means of an [[IOX]] instruction.
=== read-tape-status ===
=== read-tape-status ===
; function code (octal) : 25
; allowed on : mag tape
; not allowed on : cassette tape, floppy disk, versatec
=== reverse-to-eof ===
=== reverse-to-eof ===
; function code (octal) : 11
; function code (octal) : 11
Line 86: Line 139:


=== select-density ===
=== select-density ===
; function code (octal) : 23
; optional parameter 1 : density / parity value (see Section 9.2.2.1)
; allowed on : mag tape (yes / no)
; not allowed on : cassette tape, versatec, floppy disk
=== select-parity-and-density ===
=== select-parity-and-density ===
; function code (octal) : 23
; function code (octal) : 23
Line 100: Line 158:
; function code (octal) : 40
; function code (octal) : 40
; optional parameter 1 : format number (see Section 9.2). Format 0 - 256 words per sector, 8 sectors per track (this is the standard format used by Norsk Data A.S.). Format 1 - 128 words per sector, 15 sectors per track. Format 2 - 64 words per sector, 26 sectors per track.
; optional parameter 1 : format number (see Section 9.2). Format 0 - 256 words per sector, 8 sectors per track (this is the standard format used by Norsk Data A.S.). Format 1 - 128 words per sector, 15 sectors per track. Format 2 - 64 words per sector, 26 sectors per track.
; allowed on : floppy disk
; allowed on : floppy disk
; not allowed on : mag tape, cassette tape, versatec
; not allowed on : mag tape, cassette tape, versatec
Line 119: Line 176:
; not allowed on : mag tape, versatec, floppy disk
; not allowed on : mag tape, versatec, floppy disk
This function means that the cassette tape will stop and the read / write head will be removed from the tape. The cassette may then be removed from the cassette driver.
This function means that the cassette tape will stop and the read / write head will be removed from the tape. The cassette may then be removed from the cassette driver.
=== write-byte-record ===
=== write-byte-record ===
=== write-eof ===
=== write-eof ===
; function code (octal) : 12
; function code (octal) : 12
Line 134: Line 193:
=== write-record ===
=== write-record ===
; function code (octal) : 1
; function code (octal) : 1
; optional parameter 1 : octal address of data buffer in users area.
; optional parameter 1 : octal address of data buffer in user area.
; optional parameter 2 : octal number of words to write.
; optional parameter 2 : octal number of words to write.
; allowed on : mag tape, cassette tape, versatec, floppy disk
; allowed on : mag tape, cassette tape, versatec, floppy disk
This function will transfer a specified amount of data from the specified address in the user area ([[background segment]]) to the specified device unit.
This function will transfer a specified amount of data from the specified address in the user area ([[background segment]]) to the specified device unit.
== Related commands ==
@[[LIST-DEVICE-FUNCTIONS]]


== References ==
== References ==
{{ND-doc|60.050.06}} section 9.1
{{ND-doc|60.050.06}} section 9.1
{{ND-doc|60.128.01}} (printed June 1980), pages 1-58 - 1-61
{{ND-doc|60.128.03}} (printed February 1983), page 1-68


{{ND-doc|60.174.Q01}}
{{ND-doc|60.174.Q01}}
{{Stub}}
{{Stub}}
[[Category:Background Commands]]
[[Category:Background Commands]]

Latest revision as of 12:10, 5 October 2017

@DEVICE-FUNCTION <file name> <function name> (<optional parameter 1>) (<optional parameter 2>)

Performs operation on magnetic tapes, cassette tapes, Versatec printer / plotter and floppy disk.

<file name>
is the name of the device unit, as specified in the @SET-PERIPHERAL-FILE command.
<function name>
is the name of the operation to perform on the device.
<optional parameter 1>
<optional parameter 2>
these two parameters are used to specify more information needed by some operations.

Rules:

  1. Permitted for all users.
  2. The functions READ-RECORD and WRITE-RECORD will transfer a specified amount of data to / from the specified address in the user area (background segment) from / to the specified device unit.
  3. The function UNLOCK-AND-STOP means that the cassette tape will stop and the read / write head will be removed from the tape.The cassette may then be removed from the cassette driver.
  4. The function LOCK-CASSETTE means that the read / write head will be removed onto the cassette tape, ready for read / write of the c assette tape. The cassette tape cannot be removed from the cassette driver when the cassette is in lock position.
  5. The function READ-STATUS will read the status register of the specified device unit by means of an IOX instruction. The function READ-LAST-STATUS will return the status from the last operation of the device without executing any IOX instructions (the status saved by the driver).

Example:

@DEVICE-FUNCTION MAG-TAPE-1, ADVANCE-TO-EOF, 1

Mag. tape controller 1 will advance its driver through one EOF mark.

Functions

The following functions can be performed (parameter <function name>) with this command:

advance-records

function code (octal)
16
optional parameter 1
number of records to advance.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

advance-to-eof

function code (octal)
10
optional parameter 1
number of EOF marks to pass over.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

backspace-records

function code (octal)
15
optional parameter 1
number of records to backspace.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

clear-device

function code (octal)
21
allowed on
mag tape, cassette tape, versatec
not allowed on
floppy disk

clear-selected-unit

dump-bootstrap

function code (octal)
41
allowed on
mag tape, cassette tape, versatec
not allowed on
floppy disk

erase-tape

function code (octal)
7
allowed on
cassette tape
not allowed on
mag tape, versatec, floppy disk

format-floppy

function code (octal)
41
optional parameter 1
file name.
allowed on
floppy disk
not allowed on
mag tape, cassette tape, versatec

get-current-disc-address

function code (octal)
46
allowed on
floppy disk
not allowed on
mag tape, cassette tape, versatec

give-form-feed

function code (octal)
32
optional parameter 1
number of form feeds to give.
allowed on
versatec
not allowed on
mag tape, cassette tape, floppy disk

lock-cassette

function code (octal)
6
allowed on
cassette tape
not allowed on
mag tape, versatec, floppy disk

This function means that the read / write head of the cassette drive will be moved onto the cassette tape, ready for read / write of the tape. The cassette tape cannot be removed from the cassette drive when the cassette is in lock position.

read-byte-record

function code (octal)
26
optional parameter 1
octal address of data buffer in user area.
optional parameter 2
octal number of words to read.
allowed on
mag tape
not allowed on
cassette tape, floppy disk, versatec

read-deleted-record

function code (octal)
43
optional parameter 1
octal address of data buffer in users area.
optional parameter 2
octal number of words to read.
allowed on
floppy disk
not allowed on
cassette tape, mag tape, versatec

read-format

function code (octal)
43
allowed on
floppy disk
not allowed on
cassette tape, mag tape, versatec

read-last-status

function code (octal)
24
allowed on
mag tape, cassette tape, versatec, floppy disk

This function will return the status from the last operation on the device without extending any IOX instruction (the status is saved by the driver).

read-odd-byte-numbers

function code (octal)
2
optional parameter 1
octal address of data buffer in user area.
optional parameter 2
octal number of words to read.
allowed on
mag tape
not allowed on
cassette tape, floppy disk, versatec

read-record

function code (octal)
0
optional parameter 1
octal address of data buffer in users area.
optional parameter 2
octal number of words to read.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

This function will transfer a specified amount of data to the specified address in the user area (background segment) from the specified device unit.

read-status

function code (octal)
20
allowed on
mag tape, cassette tape, versatec, floppy disk

This function will read the status register of the specified device unit by means of an IOX instruction.

read-tape-status

function code (octal)
25
allowed on
mag tape
not allowed on
cassette tape, floppy disk, versatec

reverse-to-eof

function code (octal)
11
optional parameter 1
number of EOF marks to pass over.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

rewind

function code (octal)
13
optional parameter 1
to load point or address 0.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

select-density

function code (octal)
23
optional parameter 1
density / parity value (see Section 9.2.2.1)
allowed on
mag tape (yes / no)
not allowed on
cassette tape, versatec, floppy disk

select-parity-and-density

function code (octal)
23
optional parameter 1
density / parity value (see Section 9.2.2.1)
allowed on
mag tape (yes / no)
not allowed on
cassette tape, versatec, floppy disk

set-alphanumeric-mode

function code (octal)
30
allowed on
versatec
not allowed on
mag tape, cassette tape, floppy disk

set-floppy-format

function code (octal)
40
optional parameter 1
format number (see Section 9.2). Format 0 - 256 words per sector, 8 sectors per track (this is the standard format used by Norsk Data A.S.). Format 1 - 128 words per sector, 15 sectors per track. Format 2 - 64 words per sector, 26 sectors per track.
allowed on
floppy disk
not allowed on
mag tape, cassette tape, versatec

set-graphic-mode

function code (octal)
31
allowed on
versatec
not allowed on
mag tape, cassette tape, floppy disk

unload

function code (octal)
17
allowed on
mag tape, cassette tape
not allowed on
versatec, floppy disk

unlock-and-stop

function code (octal)
5
allowed on
cassette tape
not allowed on
mag tape, versatec, floppy disk

This function means that the cassette tape will stop and the read / write head will be removed from the tape. The cassette may then be removed from the cassette driver.

write-byte-record

write-eof

function code (octal)
12
optional parameter 1
number of EOF marks to write.
allowed on
mag tape, cassette tape, floppy disk
not allowed on
versatec

write-erase-gap

function code (octal)
14
optional parameter 1
number of erase gaps to write.
allowed on
mag tape, cassette tape
not allowed on
versatec, floppy disk

write-record

function code (octal)
1
optional parameter 1
octal address of data buffer in user area.
optional parameter 2
octal number of words to write.
allowed on
mag tape, cassette tape, versatec, floppy disk

This function will transfer a specified amount of data from the specified address in the user area (background segment) to the specified device unit.

Related commands

@LIST-DEVICE-FUNCTIONS

References

Norsk Data Document ND–60.050.06 SINTRAN III USERS GUIDE section 9.1

Norsk Data Document ND–60.128.01 SINTRAN III REFERENCE MANUAL (printed June 1980), pages 1-58 - 1-61

Norsk Data Document ND–60.128.03 SINTRAN III REFERENCE MANUAL (printed February 1983), page 1-68

Norsk Data Document ND–60.174.Q01 SINTRAN III QUICK REFERENCE CARD