Agilent Technologies FS2010 Podręcznik Użytkownika Strona 120

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 160
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 119
120 Agilent VISA User’s Guide
4 Programming via GPIB and VXI
If the value of VI_ATTR_DEST_INCREMENT is 1 (the
default),viMoveOut does a block write. If the
value of VI_ATTR_DEST_INCREMENT is 0, viMoveOut
does a FIFO write.
============================================= */
/* Demonstrate block read.
Read instrument id register and device type
register into an array.*/
viMoveIn16 (vi, VI_A16_SPACE, 0x00, 2,
memArray);
/* Print results */
printf (" viMoveIn16: ID Register = 0x%4X\n",
memArray[0]);
printf (" viMoveIn16: Device Type Register =
0x%4X\n", memArray[1]);
/* Demonstrate FIFO read.
First set the source increment to 0 so we will
repetitively read from the same memory
location.*/
viSetAttribute( vi, VI_ATTR_SRC_INCREMENT, 0
);
/* Do a FIFO read of the Id Register */
viMoveIn16 (vi, VI_A16_SPACE, 0x00, 2,
memArray);
/* Print results */
printf (" viMoveIn16: 1 ID Register =
0x%4X\n",
memArray[0]);
printf (" viMoveIn16: 2 ID Register =
0x%4X\n",
memArray[1]);
/* Close sessions */
viClose (vi);
viClose (defaultRM); }
Przeglądanie stron 119
1 2 ... 115 116 117 118 119 120 121 122 123 124 125 ... 159 160

Komentarze do niniejszej Instrukcji

Brak uwag