Syntax:    DEVINFO (Ldev, item [,status])

Defn: A CI evaluator function that returns information about
the specified device.

Type: String, integer, or Boolean depending upon item.


Ldev: Required. Integer or string identifying the target
device, logical device number (LDEV)
Item: Required. String label specifying which information is to
be returned.
Status: Optional. CI variable name where a DEVINFO error number
can be returned. Zero indicates success. Non-zero indicates a
failure. Error values returned in 'status' are the same as
the CIERROR value when an error occurs. If the 'status'
parm is passed the CI will not set CIERROR and will not
report an error message. If 'status' is not specified the
CI performs its normal error handling.

Example: :calc DEVINFO(20, "ownership")
Result: OWNED
Example: :calc DEVLINFO(0, "DiskDevList")
Result: 6/1 2 3 5 190 191
Example: :calc DEVINFO(hpldevin, "Interactive")
Result: TRUE

The following table summarizes the items of the DEVINFO function. The
description includes the item string, one or more aliases, the data type,
and a brief description of the item.

Item String Type Description
------------ ---- --------------------------------------------
AllPrinterDevList string List of printer Ldevs separated by a space. Format
"Total/ldev1 ldev2 ... ldevN" (1)

AllTermDevList string List of terminal Ldevs separated by a space. Format
"Total/ldev1 ldev2 ... ldevN" (1)

AltOwnerPin int Device's alternate owner PIN

AutoReply bool True means device automatically replies to tape requests

BackSpaceErase bool True means backspace erases the character, false
means the cursor backspaces without erasing

BlockModeType int 7=both line and DTC style block mode, 15=PAD
terminal supporting page block mode

BOT bool True means tape device is at beginning of tape mark

CommDevList string List of data comm devices. Format: "Total/ldev1
ldev2 ... ldevN" (1)

DataAccepting bool True if device accepts DATA logons

DevClass string IO Device Class: "NOT CONFIG","DISK","TAPE",

DevName string Device name as used in the "adev" SYSGEN command

DevSubType int Device subtype. See IODEFAULT.PUB.SYS

DevType string Device type: "DISK","TERM","TAPE","PRINTER"

DiscDevList string List of disk Ldevs separated by a space. Format:
DiskDevList "Total/ldev1 ldev2 ... ldevN"

DiskSizeMB int Disk size in megabytes

DiskSizePages int Disk size in 2k pages (8 sectors per physical page)

Down bool True if device is down or has a down pending

DSPrinterDevList string List of DS printer Ldevs separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

DSTermDevList string List of DS terminal Ldevs separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

Duplicative bool True all input operations are automatically echoed

EOT bool True if tape is positioned at the end of tape

Exists bool True if the device is configured

FileName string Formal device file designator, eg $STDIN

FormsMounted bool True if special forms are mounted for this device

HasPassword bool True if the terminal device has a password (2)

HeaderDisabled bool True if the header pages are suppressed in printing

IntDevClass int 0=not config,1=disk,2=tape,3=terminal,4=CIPER
printer,5=printer(non-ciper),6=spooled,7=data comm,
8=DS teminal,9=DS printer,10=user-defined

IntDevType int 0-7=disk, 16=terminal, 24=tape, 32=printer

Interactive bool True if device requires human intervention for all
input operations

IntParitySetting int 0=forced to zero, 1=forced to one, 2=even, 3=odd,

IntSpoolerState int Spooler process state for Ldev: 0=initializing,
1=release, 2=start, 3=stop, 4=stop pending,
5=suspend, 6=suspend pending, 7=resume, 8=active,
9=shut pending, 10=idle

IntSubClass int Device subclass: 0=unknown,1=connected to TMUX,
2=terminal,3=printer,4=virtual terminal,5=virtual
printer,6=PAD terminal,7=PAD printer,12=null
terminal,13=DHCF terminal,14=pseudo terminal,
15=pseudo null terminal. For tape: 1=tape. For
disk: 1=disk

IntTapeError int Fatal tape error value: 0=No fatal error, 1=tape
runaway, 2=multiple tracks in error, 3=timing
error, 4=command reject, 5=unit failure, 6=data
parity error, 7=command parity error

IntTermType int Terminal Type: 10=TT10, 18=TT18, 21=TT21, 22=TT22,
24=TT24, 26=TT26

InvalidLogonCnt int Invalid logon counts for interactive device (2)

JobAccepting bool True if device accepts HELLO or JOB logons

LineSpeed int Terminal line speed setting: 30,120, 480, 960,
19200, 38400

NotConfigDevList string List of unconfigured Ldevs separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

Opened bool True means device exists and is opened/owned

OwnerPIN int PIN for device's owner process, which is a JSMAIN process

Ownership string Device's ownership state: "OWNED"=owned by a
process, "OS"=temporarily owned by the operating
system, ""=not owned by a process

ParityEnabled bool True means the terminal's parity setting defines
the parity checking in effect; false means all 8
bits of each character are passed unchecked to driver

ParitySetting string ""ZEROES", "ONES", "EVEN, "ODD", "NONE"

PrinterDevList string List of printers which are not DS nor serial.
Format: "Total/Ldev1 Ldev2 ... LdevN" (1)

ReadTimeOut int Number of seconds for next (timed) read, 0 or
negative means timeout is disabled

RecWidth int Device record width in bytes

SecurityDown bool True if the device is downed by HP Security
Monitor (2)

SerialPrinterDevList str List of serial printers separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

SpoolerDevList string List of spooler device separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

SpoolerOutfence int Current outfence for the output spooler device, 0..14

SpoolerState string Spooler process state for Ldev: "INIT","RELEASE",

SpoolFileID string "Onnn" ID of the spoolfile currently being printed
on the device

SpoolingEnabled bool True if spooling has been enabled for this device

SpoolType string Device's spooler type: "INSP"=owned by input
spooler, "OUTSP"=owned by output spooler, ""=not
owned by a spooler process

SubClass string Device subclass. "UNKNOWN","TMUX","TERM","PRINTER",

TapeBuffering bool True means tape device is operating in "immediate
report mode", meaning the device buffers data until
it has enough to flush to tape

TapeDensity int 0=unknown, 800 (BPI), 1600 (BPI), 6250 (BPI)

TapeDevList string List of all tape devices separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

TapeEOF bool True when tape is positioned at the end-of-file marker

TapeError string Fatal tape error: "NON-FATAL","RUNAWAY","MULTI-

TapeOnline bool True means the tape drive in online

TapeTrackError bool True means a single track error was found

TapeWriteProtect bool True means tape is write protected

TermDevList string List of all terminal device separated by a space.
Format: "Total/ldev1 ldev2 ... ldevN" (1)

TermType string Terminal Type: "TT10","TT18","TT21","TT22","TT24","TT26"

TrailerDisabled bool True if the trailer pages are suppressed in printing

TypeAhead bool True means typeahead is enabled

Up bool True if the device is up (not DOWN'd)

XON/XOFF bool True means XON/XOFF is enabled, thus the controller
stops sending data to the device when it receives
XOFF and resumes when it receives XON. False means
XON/XOFF is disabled and thus XON and XOFF are sent
to the device as data

1) A CI string variable cannot exceed 1024 characters and thus the result
could be truncated. Truncation is evident by checking wordcnt() < total. Eg.
if wordcnt(x) < ![word(x,'/')] then # truncated list

2) Requires HP Security Monitor/iX