National Instruments AT Bedienungsanleitung Seite 122

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 208
  • Inhaltsverzeichnis
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 121
Chapter 6 Using Your Serial Hardware
© National Instruments Corporation 6-5 Serial Hardware and Software for Windows
For example, to set TXRDY two-wire auto control mode, use the
following code:
Windows 2000
ULONG TranceiverMode = 131;
ULONG dummy;
DeviceIoControl(hDevice,
IOCTL_SERIAL_SET_TRANSCEIVER_MODE,(PVOID)
&TransceiverMode,sizeof(ULONG),NULL,0,&dummy,NULL);
Windows NT/Me/9x
ULONG TranceiverMode = 131;
DeviceIoControl(hDevice,
IOCTL_SERIAL_SET_TRANSCEIVER_MODE,(PVOID)
&TransceiverMode,sizeof(ULONG),lpOutBuffer,
nOutBufferSize,lpBytesReturned,lpOverlapped);
Table 6-3.
DeviceIoControl Function Input Values
Transceiver Mode
DeviceIoControl
Function Input Value
Four-wire mode 128
Two-wire mode: DTR with echo 129
Two-wire mode: DTR controlled 130
Two-wire mode: TXRDY auto control 131
Seitenansicht 121
1 2 ... 117 118 119 120 121 122 123 124 125 126 127 ... 207 208

Kommentare zu diesen Handbüchern

Keine Kommentare