.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\" @(#)topen.3f 6.1 (Berkeley) 5/15/85
.TH TOPEN 3F "May 15, 1985"
topen, tclose, tread, twrite, trewin, tskipf, tstate \- f77 tape I/O
.B integer function topen
.B integer function tclose
.B integer function tread
.B integer function twrite
.B integer function trewin
.B integer function tskipf
.B integer function tstate
(tlu, fileno, recno, errf, eoff, eotf, tcsr)
These functions provide a simple interface between f77 and magnetic
is ``topen''ed in much the same way as a normal f77 logical unit
All other operations are performed via the
has no relationship at all to any normal f77 logical unit.
associates a device name with a
must be in the range 0 to 3.
should indicate whether the tape includes a tape label.
The normal returned value is 0.
If the value of the function is negative, an error has occured.
closes the tape device channel and removes its association with
The normal returned value is 0.
A negative value indicates an error.
reads the next physical record from tape to
should be large enough to hold the largest physical record to be read.
The actual number of bytes read will be returned as the value of the
If the value is 0, the end-of-file has been detected.
A negative value indicates an error.
writes a physical record to tape from
The physical record length will be the size of
The number of bytes written will be returned.
A value of 0 or negative indicates an error.
rewinds the tape associated with
to the beginning of the first data file.
If the tape is a labelled tape
then the label is skipped over after rewinding.
The normal returned value is 0.
A negative value indicates an error.
allows the user to skip over files and/or records.
end-of-file marks are skipped. If the current file is at
EOF, this counts as 1 file to skip.
(Note: This is the way to reset the EOF status for a
physical records are skipped over.
The normal returned value is 0.
A negative value indicates an error.
allows the user to determine the logical state of the tape I/O channel
and to see the tape drive control status register.
will be returned and indicate the current file and record number.
indicate an error has occurred, the current file is at EOF,
or the tape has reached logical end-of-tape.
End-of-tape (EOT) is indicated by an empty file, often
referred to as a double EOF mark.
It is not allowed to read past EOT although it is allowed to write.
will reflect the tape drive control status register.
.ie \nM /usr/ucb/lib/libU77.a
ht(4), perror(3F), rewind(1)