HP (Hewlett-Packard) B Network Router User Manual


 
float a24offst;/* A24 offset from A16 offset register */
char rd_addr[80];/* command string variable */
/* Create the command string which reads the A24 base address from the offset register*/
sprintf(rd_addr, "DIAG:PEEK? %ld, %d", base_addr,16);
/* Send DIAG:PEEK? command */
IOOUTPUTS(CMD_MOD, rd_addr, strlen(rd_addr));
/* Read value from offset register */
IOENTER(CMD_MOD, &a24offst);
/* Multiply offset value by 256 for 24-bit address value */
a24offst *= 256.;
return (long)a24offst;
}
Multiplying the value of the offset register (a24offst) by 256 (100
16
)
converts the 16-bit register value to a 24-bit address.
The Data Register
Offset
The offset of the digitizer’s data register is 12 (0C
16
). The offset is added to
the A24 base address to form the complete register address:
00220000
16
+ 0C
16
= 0022000C
16
2,228,224 + 12 = 2,228,236
The offset of the data register can also be read with the SCPI command:
VINStrument[:CONFigure]:VME:SEND:ADDRess:DATA?
This command returns two values: A24,12. A24 indicates that the data
register is in A24 address space and 12 is the offset of the data register.
150 Understanding the HP E1429 Digitizer Chapter 3