Omega Speaker Systems VR200 instruction manual 210 ‘ 220 ‘ Open COM11200,N,8,1,LF AS #1

Page 39

7.4Program to Output Measured Data (in ASCII Code) from VR200 and Write to Disk

100

‘************************************************************

110

‘**

RS422A Example Program for IBM PC

**

120

‘**

 

**

130

‘**

To input and save measured data

**

140

‘**

(ASCII code)

**

150

‘**

 

**

160‘************************************************************

170‘**

180

‘**

Baud rate: 1200

Stop bit: 1 bit

190

‘**

Parity: none

Control: OFF/OFF

200

‘**

Data length: 8 bits

Others: LF is sent automatically.

210‘**

220

230OPEN “COM1:1200,N,8,1,LF” AS #1

240OPEN “TEST.DAT” FOR OUTPUT AS #2

250

260 LF$=CHR$(&HA)

:’ Line feed = 0AH

270PRINT #1,CHR$(27)+”O 01"

280PRINT #1,”TS0"

290PRINT #1,CHR$(27)+”T”;

300PRINT #1,”FM0,01,04"

310LINE INPUT #1,D$

320IF LEFT$(D$,1)=LF$ THEN D$=MID$(D$,2) :’ Remove “LF” of head string

330PRINT D$

340PRINT #2,D$

350IF MID$(D$,2,1)<>”E” THEN GOTO 310

360

370PRINT #1,CHR$(27)+”C 01"

380CLOSE

390END

7 - 4

Image 39
Contents User’sGuide Servicing North America Trademarks PrefaceContents Time Chart Initial Status Errors During RS-422-A Output Transmitting FunctionsProgram Examples Interface Specifications Installing the RS-422-A InterfaceCable Termination Interface Terminal Terminal AssignmentData Configuration Communication WiringText Start-stop Asynchronous CommunicationBuffer Overflow Input BufferSetup Procedure Setting up the RS-422-A Communication InterfaceIdentifier ParametersTerminator Example SR01,SKIP List of Program Set CommandsSetting the Range and Scale Format SRp1,modeFormat SRp1, mode, p2 Example SR01, DI,Format SRp1, mode, p2, p3, p4, p5, p6, p7, p8 Setting Alarms Copying the Channel Settings Setting the UnitSetting the Waveform Span Rate TIME/DIV Setting the ClockSetting the Discrete Zone Display Setting the Partial Expanded DisplaySetting the Tag Setting the Data File Name File Setting the Trip LevelSetting the Summer/ Winter Time DST Setting the LCD Brightness and LCD Saver LCDExample MD02, ON, on Format MDp1, p2, p3Initializing the Data Memory List of Program Control CommandsAlarm Acknowledge Standard Screen CallSelecting the Output Format for Measured Data Loading the SET Configuration FileSaving the SET Configuration File Selecting the Output DataMessage Writingfor the VR 200 with style number 2 or higher Execution of Trigger Status OutputRequests for the data to be prepared in the buffer ESC C Crlf Open CommandClose Command ESC O CrlfSequence see also Sections 2.3.7 Introduction to Output Data FormatsOutput Data Formats Output Format of Measured Values in Ascii ModeOutput Format of Measured Values in Binary Mode Output Format of Parameter Settings Output Format of Unit and Decimal Point Information Time Chart Initial Status Output Preventing ErrorsESC S CR LF How to Request Error Message OutputTiming of Resetting the Error Status Environment Program ExamplesOpen TEST.DAT for Input AS #2 Others LF is sent automatically 210 ‘ 220 ‘ Open COM11200,N,8,1,LF AS #1 Print a Appendix 1 Ascii Code Table AppendixSystem-reserved File Names Appendix 2 File Naming RulesFile Name Length Lowercase/Uppercase LettersIndex Index for Command Reference Warrant Y/ Disclaimer Temperature