Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ iwrite(3) — HP-UX Instrument Control Library C.03.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

igeterrno(3)

igeterrstr(3)

iprintf(3)

iread(3)

iscanf(3)

IWRITE(3)

HP-UX

NAME

iwrite − send a buffer of data to a device

SYNOPSIS

 #include <sicl.h>
 int iwrite (
   INST id,
   char *buf,
   unsigned long datalen,
   int end,
   unsigned long *actualcnt
 );

DESCRIPTION

Iwrite will send datalen bytes to the device specified by id from the buffer pointed to by buf.  If end is set to non-zero the END indicator will be given on the last byte of the data.  If actualcnt is a non-null pointer, the number of actual bytes written to the device will be set in this argument. 
 
If id refers to a device, then the data will be written to the device using standard (interface specific) communication mechanisms.  If id refers to an interface, the data will be written in raw mode to the interface.  It is up to the interface to provide interface-specific commands for controlling the meaning of this raw data. 

RETURN VALUE

The iwrite command returns 0 on success, or a non-zero error number if an error occurred. 

ERRORS

The iwrite fails under the following circumstances, and sets the return value to one of the following:
 

­[I_ERR_BADID] The INST id is invalid

­[I_ERR_LOCKED] Locked by another user

­[I_ERR_TIMEOUT] Timeout occurred

­[I_ERR_NORSRC] Out of system resources

­[I_ERR_IO] Generic I/O error

­[I_ERR_NODEV] Device is not active

 

SEE ALSO

igeterrno(3), igeterrstr(3), iprintf(3), iread(3), iscanf(3)
 

AUTHOR

iwrite was developed by HP. 

Hewlett-Packard Company  —  May 05, 1994

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026