6.1 Preventing Errors

Chapter 6 ERRORS DURING RS-422-

AOUTPUT

6.1Preventing Errors

Do not send an FM or LF command from the host PC until the measured data or set point data in all the channels specified by the last command have been output. If an FM or LF command is sent while the VR200 recorder is outputting data, a communication error may occur.

An LF command sent after the TS0 command, or an FM command sent after the TS1 or TS2 command may also cause a communication error.

If an ESC T command was already sent after the last time TS0 was set, data (even in other formats) in any channel at any time interval can be read by the host PC using FM commands as many times as required. At this time (when the FM command is repeatedly sent), the VR200 recorder also sends the data acquired last time ESC T was received.

Also, if an ESC T command was already sent after the last time TS1 or TS2 was set, the settings (even in other formats) in any channel at any time interval can be read by the host PC using LF commands as many times as required.

Thus, once the ESC T command has been sent, the measured values and set values can be read any number of times, which is a very useful function.

Note

When sending data from the host PC to a recorder, use the ESC S command to avoid buffer overflow:

When the VR200 recorder receives an ESC S request, it saves it in the buffer memory. This request is retrieved from the buffer memory and, after acknowledging the command, the recorder sends the status to the PC. Make sure not to send any other commands between sending the ESC S command to the recorder and reading the status from the recorder. This ensures that commands can be received by the recorder since its input buffer is empty.

Example:

10OPEN ”COM1:N81N” AS #1

20

30PRINT #1,CHR$(&H1B)+”O 01"

40PRINT #1,”SR01,VOLT,20mV,-2000,2000"

50GOSUB *HANDSHAKE

60PRINT #1,”PS0"

70GOSUB *HANDSHAKE

80PRINT #1,”UD0"

90PRINT #1,CHR$(&H1B)+”C 01"

100CLOSE

110END

120*HANDSHAKE

130PRINT #1,CHR$(&H1B)+”S”; (sending ESC S)

140

LINE INPUT #1,STS$

(reading status)

150

RETURN

 

The command length of the input buffer of the VR200 is 256 bytes for a 4-channel model.

6 ERRORS DURING RS-422-A OUTPUT

6 - 1

Page 33
Image 33
Omega Speaker Systems VR200 instruction manual Output, Preventing Errors