National Instruments NI-VXI Network Card User Manual


 
Chapter 3 Software Overview
NI-VXI User Manual 3-24 © National Instruments Corporation
VXI/VMEbus access functions. You can use both high-level and
low-level VXI/VMEbus access functions at the same time.
The following paragraphs describe the high-level VXI/VMEbus access
functions.
VXIin (accessparms, address, width, value)
VXIin
reads a single byte, word, or longword from a particular
VXI/VME address in one of the VXI address spaces. The parameter
accessparms specifies the VXI/VME address space, the VXI privilege
access, and the byte order to use with the access. The address
parameter specifies the offset within the particular VXI/VME address
space. The width parameter selects either byte, word, or longword
transfers. The value read from the VXI/VMEbus returns in the output
parameter value. If the VXI/VME address selected has no device
residing at the address and a bus error occurs,
VXIin
traps the bus error
condition and indicates the error through the return status.
VXIinReg (la, reg, value)
VXIinReg
reads a single 16-bit value from a particular VXI device’s
VXI registers within the logical address space (the upper 16 KB of VXI
A16 address space). The function sets the VXI access privilege to
Nonprivileged Data and the byte order to Motorola. If the VXI address
selected has no device residing at the address and a bus error occurs,
VXIinReg
traps the bus error condition and indicates the error through
the return status. This function is mainly for convenience and is a layer
on top of
VXIinLR
and
VXIin
. If the la specified is the local CPU
logical address, it calls the
VXIinLR
function. Otherwise, it calculates
the A16 address of the VXI device’s register and calls
VXIin
.
Note:
VXIinReg
is designed to access a VXIbus device configuration register
and therefore is not applicable to VME devices.
VXImove (srcparms, srcaddr, destparms, destaddr, length, width)
VXImove
moves a block of bytes, words, or longwords from a
particular address in one of the available address spaces (local, A16,
A24, A32) to any other address in any one of the address spaces. The
parameters srcparms and destparms specify the address space, the
privilege access, and the byte order used to perform the access for the
source address and the destination address, respectively. The srcaddr
and destaddr parameters specify the offset within the particular