VxiIn Procedure

Reads data from a specified VXI address with the specified access mode.

Syntax

[ lStatus = ] VxiIn ( lMode, lAddress, lWidth, plResult )

The VxiIn procedure syntax has the following parts:

 

Name

Type

Description

lStatus

Long

Status

lMode

Val Long

Access mode

lAddress

Val Long

VXI address within the specified space

lWidth

Val Long

Width in bytes of response (1, 2 or 4)

plResult

Var Long

Response value

Comments

This function may be used when a direct read from a VXI bus address is required.

The iMode parameter is specified as follows:

Bits 0,1 - VXI address space:

 

1

A16

2

A24

3

A32

Bits 2,3,4 - Access Privilege:

 

0

Nonprivileged data access

1

Supervisory data access

2

Nonprivileged program access

3

Supervisory program access

4

Nonprivileged block access

5

Supervisory block access

Bit 7 - Byte Order:

 

0

Motorola (MSB first)

1

Intel (LSB first)

All other bits should be 0.

If lStatus is negative, an error has occurred. Otherwise, the function is successful.

Example

The following command reads the ID register of a device at Logical Address 4, and the response is assigned to the variable lResult:

VxiIn (1, 0xC100, 2, lResult)

See Also

VxiMove, VxiOut