HP (Hewlett-Packard) AHA-8940 Network Router User Manual


 
VXI Programming Using the IEEE 1394 Serial Bus 37Chapter 3
The following extended SICL function is unique to the HP E8491A and is
used for block transfers over the bus:
iblockmovex
Additionally, the extended SICL functions shown below must be used when
porting SICL programs to the IEEE 1394 bus from other I/O interfaces:
imapx
iunmapx
ipeekx8, ipeekx16, ipeekx32
ipokex8, ipokex16, ipokex32
These functions are covered in detail in the SICL documentation.
The following examples demonstrate how to set up and perform block
transfers using HP VXIplug&play and HP VISA functions.
Block Transfers using
HP VXIplug&play Drivers
This program performs a block transfer of 2,000 readings using the
HP E1563A digitizer and its VXIplug&play driver.
// 1563VPNP.CPP - This program transfers a block of 2,000 readings from the
// HP E1563 digitizer to the computer using the VXIplug&play driver’s
// hpe1563_fetchAll_Q function. 2,000 readings is the maximum number of
// readings that can be transferred using the function.
#include "hpe1563.h"// include the driver header file
#include <stdio.h>
#include <stdlib.h>
#include <windows.h>
// project files: 1563vpnp.cpp, hpe1563.lib
// Specify the addressing path.
#define E1563 "VXI0::64::INSTR" // VXI addressing
// prototypes
void check(ViSession vi, ViStatus error);
void main(void)
{
ViSession vi;
ViStatus errStatus;
ViInt16 rdgs[2000];
ViInt16 *dataPtr;// pointer to cast readings to 16-bit integers
ViReal64 range;// range variable for reading conversions
int i;
long dataArrayLen=2000;// return 2,000 readings using
// hpe1563_fetchAll_Q
ViInt32 numRdgs;
ViChar err_message[256];
dataPtr = rdgs;// set pointer to rdgs array