
102
Agilent VISA User’s Guide
4
Programming via GPIB and VXI
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)
================================================
*/
/* Map into memory space */
viMapAddress (vi, VI_A16_SPACE, 0x00, 0x10,
VI_FALSE,VI_NULL, &address);
Содержание E2094S
Страница 6: ...6 Agilent VISA User s Guide ...
Страница 116: ...116 Agilent VISA User s Guide 4 Programming via GPIB and VXI ...
Страница 126: ...126 Agilent VISA User s Guide 5 Programming via LAN ...
Страница 143: ...Glossary Agilent VISA User s Guide 143 Windows notification area See notification area ...
Страница 144: ...144 Agilent VISA User s Guide Glossary ...