Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ iwblockcopy(3) — HP-UX Instrument Control Library G.03.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ipeek(3)

ipushfifo(3)

igeterrno(3)

igeterrstr(3)

imap(3)

IBLOCKCOPY(3)

HP-UX

NAME

ibblockcopy, iwblockcopy, ilblockcopy

SYNOPSIS

 #include <sicl.h>
 int ibblockcopy (id,src,dest,cnt); /* Byte Transfer */
 INST id;
 unsigned char *src;
 unsigned char *dest;
 unsigned long cnt;
 
 int iwblockcopy (id,src,dest,cnt,swap); /* Word Transfer */
 INST id;
 unsigned short *src;
 unsigned short *dest;
 unsigned long cnt;
 int swap;
 
 int ilblockcopy (id,src,dest,cnt,swap); /* Longword Transfer */
 INST id;
 unsigned long *src;
 unsigned long *dest;
 unsigned long cnt;
 int swap;
 

DESCRIPTION

These routines will copy data from memory located at the address pointed to by src to memory located at the address pointed to by dest.  The cnt parameter specifies the number of transfers (bytes, words, or longwords) to perform.  Each element is read from successive memory locations off of src and stored into successive memory locations off of dest.  The id parameter is an INST id for a valid session.  This parameter is normally ignored by these routines, however, these routines may use this parameter to identify which interface is being used and perform the transfer using an interface-specific mechanism (such as DMA).  If this functionality is not desired, the user may pass 0 for the id parameter. 
 
The src and dest parameters must be properly aligned for the appropriate data transfer.  For iwblockcopy, these address parameters must be word aligned.  For ilblockcopy, these address parameters must be longword aligned. 
 
The iwblockcopy and ilblockcopy routines are also passed a swap parameter.  If swap is zero, then no byte swapping is performed.  If it is non-zero, then byte swapping (if necessary) is performed to change byte ordering from the internal format of the computer to/from VXI (MOTOROLA) byte ordering. 
 
These routines should only be used on interfaces which support mapping, (see imap(3)).
 
Note:  If a buserror occurs, unexpected results may occur. 
 

RETURN VALUE

These routines will return 0 on success, or a non-zero error code otherwise. 

ERRORS

These routines fail under the following circumstances, and set the return value to one of the following:

­[I_ERR_BADID] The INST id is invalid. 

­[I_ERR_PARAM] An invalid parameter was specified. 
 

SEE ALSO

ipeek(3), ipushfifo(3), igeterrno(3), igeterrstr(3), imap(3)

AUTHOR

ibblockcopy, iwblockcopy, and ilblockcopy were developed by HP. 
 

Hewlett-Packard Company  —  September 29, 1999

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