BRINGO(DS-8812) RS-232C Sample Program manual 2001 Feb Iwatsu Electric Co., Ltd. 1. Overview This is sample program under Microsoft Visual Basic 6.0 to control the Iwatsu Digital Storage Oscilloscope DS-8812 via RS-232C interface. DS88RS_Sample.exe shows follows function but not available to edit. Other files show basic programming source list for editing. 1. Transmit the control command. 2. Acquire a new waveform, transfer the data and display the waveform. 3. Save the acquired waveform data as CSV type file. 2. Needed hardware and software DSO : DS-8812 Iwatsu Digital Storage Oscilloscope Soft Ver3.00 or higher Some functions of this sample software as transfer steps, FFT commands are available under follows version of DS-8812. Functions Version of DS-8812 Transfer steps Soft Ver4.00 or higher Transfer steps, FFT commands Soft Ver4.00 Opt2 or higher Procedure to checking software version of your DS-8812 Press [Utility] key on the DS-8812 panel, then [Utility]menu is shown. Select [Config] and [System] by [Function] knob, then the version is displayed at bottom of screen as below. BOOT Ver.:1.01/SOFT Ver.:3.02 PC : Personal Computer IBM PC/AT Compatible OS : Microsoft Windows 95, or 98 Programming software : Microsoft Visual basic Ver6.0 or higher for editing. Note: Microsoft Visual Basic Ver6.0 Learning Edition may not edit this sample program. Professional edition of Visual Basic Ver6.0 is needed for editing. 3. Files This sample program contains 11 files as follows. DS88RS-SV201E.vbp Visual Basic Ver6.0 project file to edit DS88RS-SV201E.vbw Visual Basic Ver6.0 file to edit FormSetup.frm Visual Basic Ver6.0 file to edit FormMain.frm Visual Basic Ver6.0 file to edit FormWave.frm Visual Basic Ver6.0 file to edit FormSetup.frx Visual Basic Ver6.0 file to edit FormWave.frx Visual Basic Ver6.0 file to edit ModuleRS232C.bas Visual Basic Ver6.0 file to edit DS88RS-SV201E.exe Execute file of sample DS88RS-SV201E.txt This document file This sample program needs some components as follows. Microsoft Comm Control 6.0 Microsoft Common Dialog Control 6.0 Preparation Step1 Execute setup.exe Trial Running the DS88RS-SV201E.exe shows full function of this sample program. Step1 Run setup.exe Automatically installed Microsoft Comm Control 6.0, Microsoft Common Dialog Control 6.0 to your PC. Step2 Run DS88RS-SV201E.exe "DS8812 RS-232C Setup form" is shown [SETUP] Set as same as DS-8812 interface setting. Port : Com1( Com2,3,4,5,..) Com port number of your PC. Baud rate : 9600 (2400, 4800, 9600, 19.2k, 38.4k, 57.6k, 115.2k) Receiving buffer : 2048 (3072, 4092) Data bit : 8 bit (7 bit) Delimiter : CR LF (LF) Note: The buffer size is 2048 default, increase this size when "Overflow the Receive buffer" is shown. Click Start then "DS-8812 RS-232C Sample program" form is shown. [SAMPLE PROGRAM] Type any remote command at Input command box as ASET (Autoset). Click Send then sent remote command and response from DS-8812 as are shown at History of command Quit button quits from this program. Click waveform then waveform [WAVEFORM] This form shows waveform and save the data as CSV file. (1) Data transfer setting Click upper button to verify the value when the value is changed. Memory length : SHORT, LONG Format : ASCII, BYTE, WORD Byte order : H/L,L/H (Effective when format is set to WORD) Start address : 0, 120, 2400 or any value Data points : 500, 2000, 5000, 100000 or any value Channel : CH1 or CH2 Transfer steps : 1,2,4,8,16,32,64,128 (Note2) Math : OFF,ADD,SUB,MULT,FFT (Note3) FFT Source : CH1,CH2 (Note3) FFT Points : 1024,4096 (Note3) FFT Window : RECT,HANNING,FLATTOP (Note3) Auto Measure : CH1&2,OFF CH1,TR CH2,TR CH1,TF CH2,TF CH1,VRMS CH2,VRMS CH1,VMEAN CH2,VMEAN CH1,FREQ CH2,FREQ CH1,PERIOD CH2,PERIOD CH1,+PW CH2,+PW CH1,-PW CH2,-PW CH1,DUTY CH2,DUTY CH1,+PEAK CH2,+PEAK CH1,-PEAK CH2,-PEAK CH1,P-P CH2,P-P CH1&2,SKEW Note(1) : The waveform on PC and DS-8812 are different shape at some sweep range because of this program fix the display point as follows. Memory length Display point SHORT 5000 LONG 100000 FFT display (1024word math) 500 FFT display (4096w math) 2000 Note(2) : The function is available for DS-8812(BRINGO) Soft Ver4.00 or higher, the command is not available for Soft Ver3.** or lower. This program set those commands availability by checking the software version of connected DS-8812. Note(3) : The function is available for DS-8812(BRINGO) Soft Ver4.00 or higher, it is not available for Soft Ver3.**. This program set those commands availability by checking the software version of connected DS-8812. The function setting is not available for DS-8812(BRINGO) without FFT option even if Soft Ver4.00 or higher. Note(4) : The FFT waveform on PC is different shape from DS-8812 because of this program shows the waveform in -32768`32767 vertical data range as a full scale. Setting example: Usually the Start address and Data length are set as follows depends on the Memory length. Memory length Start address Data length SHORT 120 5000 LONG 2400 100000 FFT display (1024word math) 0 500 FFT display (4096w math) 0 2000 Poling interval[ms] Checks data transfer completed or not when "Acquire a waveform" setting, Acquired times Shows repeat times when "Repeat acquisition" setting. (2) Acquisition Current waveform : Transfers current shown waveform data. Acquire a waveform : Acquires new waveform and transfer Repeat acquisition : Repeats new waveform acquisition and transfer Stop : Stops new waveform data transferring. Note: It is not effective during data transferring. It stops after the data transferring is completed. (3) Save as CSV Saves transferred data as CSV file. Transferred data are converted to ASCII data depend on transfer format as follows. (A)In case of YT waveform data (A)-1:Transfer format is in ASCII format Transferred data are multiplied 256 times and saved . (A)-2:Transfer format is in BYTE format Transferred binary data (1Data=1Byte) are converted to ASCII data and saved. (A)-3:Transfer format is in WORD format Transferred binary data (1Data=2Byte) are converted to ASCII data with H/L, L/H condition and saved. (B) In case of FFT waveform data (B)-1: Transfer format is in ASCII format Transferred data are saved as it is. Transferred data are in value of multiplied 100 times of dBm value. (B)-2: Transfer format is in BYTE Transferred binary data (1Data=2Byte) are converted to ASCII data with H/L, L/H condition and saved. Transferred data are in value of multiplied 100 times of dBm value. (B)-3: Transfer format is in WORD Same as in BYTE (4) Close Return to Sample program form. 5, History Ver1.00 2000/July Ver2.00 2001/Jan : Applied to FFT option Ver2.01 2001/Feb : Modified that this program hang up by changing Memory length and tranferring wave form data. 6. Grant of License This is sample program to understand how to remote control the DS-8812. You may make any new program by referring this sample program. Transferal You may transfer this program to another person, as long as all copies of the program and documentation are transferred to that person at the same time. You agree that this program remains the property of IWATSU, and is protected by the laws of copyright and trade secrets. Disclaimer of Liability IWATSU disclaims any liability for incidental or consequential damages, arising out of the use or inability to use the program, or arising from the negligence of IWATSU or its employees, consultants, dealers or associates, even if these parties have been advised of the possibility of such damages. By using the program, you indemnify and agree to hold IWATSU harmless from such claims. You assume the entire risk as to the results and performance of the program. Copyright 2001 IWATSU Electric Co., Ltd. All Rights Reserved