User`s guide
Programming via GPIB and VXI 4
Agilent VISA User’s Guide 117
• They provide the best performance when transferring
large blocks of data.
• They support both block and FIFO mode.
The disadvantage of viMoveIn/viMoveOut calls is that they
have higher initial overhead than viPeek/viPoke.
Sample: Using VXI Memory I/O
This program demonstrates using various types of VXI
memory I/O.
/* memio.c
This example program demonstrates the use of
various memory I/O methods in VISA. */
#include <visa.h>
#include <stdlib.h>
#include <stdio.h>
#define VXI_INST "VXI0::24::INSTR"
void main () {
ViSession defaultRM, vi;
ViAddr address;
ViUInt16 accessMode;
unsigned short *memPtr16;
unsigned short id_reg;
unsigned short devtype_reg;
unsigned short memArray[2];
/*Open default resource manager and session
to instr*/
viOpenDefaultRM (&defaultRM);
viOpen defaultRM, VXI_INST, VI_NULL,VI_NULL,
&vi);
/*
================================================
==
Low level memory I/O = viPeek16 = direct
memory dereference (when allowed)
================================================