Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Notices © Keysight Technologies, Inc. 2005-2013 Manual Part Number No part of this manual may be reproduced in any form or by any means (including electronic storage and retrieval or translation into a foreign language) without prior agreement and written consent from Keysight Technologies, Inc. as governed by United States and international copyright laws. Version 02.30.0000 Ed ition April 5, 2013 Available in electronic format only Published by: Keysight Technologies, Inc.
In This Book This book is your guide to programming the 2000 X-Series oscilloscopes: Table 1 InfiniiVision 2000 X-Series Oscilloscope Models Channels Input Band wid th 70 MHz 100 MHz 200 MHz 4 analog + 8 digital (mixed signal) MSO-X 2004A MSO-X 2014A MSO-X 2024A 2 analog + 8 digital (mixed signal) MSO-X 2002A MSO-X 2012A MSO-X 2022A 4 analog DSO-X 2004A DSO-X 2014A DSO-X 2024A 2 analog DSO-X 2002A DSO-X 2012A DSO-X 2022A The first few chapters describe how to set up and get started: •
• Chapter 10, “:CHANnel Commands,” starting on page 217, describes commands that control all oscilloscope functions associated with individual analog channels or groups of channels. • Chapter 11, “:DEMO Commands,” starting on page 237, describes commands that control the education kit (Option EDU) demonstration signals that can be output on the oscilloscope's Demo 1 and Demo 2 terminals.
• Chapter 26, “:SEARch Commands,” starting on page 531, describes commands that control oscilloscope functions associated with searching for waveform events. • Chapter 27, “:SYSTem Commands,” starting on page 563, describes commands that control basic system functions of the oscilloscope. • Chapter 28, “:TIMebase Commands,” starting on page 577, describes commands that control all horizontal sweep functions.
See Also 6 • For more information on using the SICL, VISA, and VISA COM libraries in general, see the documentation that comes with the Keysight IO Libraries Suite. • For information on controller PC interface configuration, see the documentation for the interface card used (for example, the Keysight 82350A GPIB interface). • For information on oscilloscope front-panel operation, see the User's Guide.
Contents In This Book / 3 1 What's New What's New in Version 2.30 / 26 What's New in Version 2.20 / 28 What's New in Version 2.10 / 30 What's New in Version 2.00 / 31 What's New in Version 1.20 / 32 What's New in Version 1.10 / 33 Version 1.00 at Introduction / 34 Command Differences From 7000B Series Oscilloscopes / 35 2 Setting Up Step 1. Install Keysight IO Libraries Suite software / 40 Step 2.
Programming the Oscilloscope / 52 Referencing the IO Library / 52 Opening the Oscilloscope Connection via the IO Library / 53 Initializing the Interface and the Oscilloscope / 53 Using :AUToscale to Automate Oscilloscope Setup / 54 Using Other Oscilloscope Setup Commands / 54 Capturing Data with the :DIGitize Command / 55 Reading Query Responses from the Oscilloscope / 57 Reading Query Results into String Variables / 58 Reading Query Results into Numeric Variables / 58 Reading Definite-Length Block Query Re
*RCL (Recall) / 135 *RST (Reset) / 136 *SAV (Save) / 139 *SRE (Service Request Enable) / 140 *STB (Read Status Byte) / 142 *TRG (Trigger) / 144 *TST (Self Test) / 145 *WAI (Wait To Continue) / 146 6 Root (:) Commands :ACTivity / 151 :AER (Arm Event Register) / 152 :AUToscale / 153 :AUToscale:AMODE / 155 :AUToscale:CHANnels / 156 :AUToscale:FDEBug / 157 :BLANk / 158 :DIGitize / 159 :MTEenable (Mask Test Event Enable Register) / 161 :MTERegister[:EVENt] (Mask Test Event Event Register) / 163 :OPEE (Operation
:ACQuire:SEGMented:INDex / 191 :ACQuire:SRATe / 194 :ACQuire:TYPE / 195 8 :BUS Commands :BUS:BIT / 199 :BUS:BITS / 200 :BUS:CLEar / 202 :BUS:DISPlay / 203 :BUS:LABel / 204 :BUS:MASK / 205 9 :CALibrate Commands :CALibrate:DATE / 209 :CALibrate:LABel / 210 :CALibrate:OUTPut / 211 :CALibrate:PROTected / 212 :CALibrate:STARt / 213 :CALibrate:STATus / 214 :CALibrate:TEMPerature / 215 :CALibrate:TIME / 216 10 :CHANnel Commands :CHANnel:BWLimit / 220 :CHANnel:COUPling / 221 :CHA
:DEMO Commands :DEMO:FUNCtion / 238 :DEMO:FUNCtion:PHASe:PHASe / 240 :DEMO:OUTPut / 241 12 :DIGital Commands :DIGital:DISPlay / 245 :DIGital:LABel / 246 :DIGital:POSition / 247 :DIGital:SIZE / 248 :DIGital:THReshold / 249 13 :DISPlay Commands :DISPlay:ANNotation / 253 :DISPlay:ANNotation:BACKground / 254 :DISPlay:ANNotation:COLor / 255 :DISPlay:ANNotation:TEXT / 256 :DISPlay:CLEar / 257 :DISPlay:DATA / 258 :DISPlay:LABel / 259 :DISPlay:LABList / 260 :DISPlay:PERSistence / 261 :DISPlay
:FUNCtion[:FFT]:SPAN / 282 :FUNCtion[:FFT]:VTYPe / 283 :FUNCtion[:FFT]:WINDow / 284 :FUNCtion:GOFT:OPERation / 285 :FUNCtion:GOFT:SOURce1 / 286 :FUNCtion:GOFT:SOURce2 / 287 :FUNCtion:OFFSet / 288 :FUNCtion:OPERation / 289 :FUNCtion:RANGe / 290 :FUNCtion:REFerence / 291 :FUNCtion:SCALe / 292 :FUNCtion:SOURce1 / 293 :FUNCtion:SOURce2 / 294 17 :HARDcopy Commands :HARDcopy:AREA / 297 :HARDcopy:APRinter / 298 :HARDcopy:FACTors / 299 :HARDcopy:FFEed / 300 :HARDcopy:INKSaver / 301 :HARDcopy:LAYout / 302 :HARDcopy
:MARKer:X2Y2source / 323 :MARKer:XDELta / 324 :MARKer:XUNits / 325 :MARKer:XUNits:USE / 326 :MARKer:Y1Position / 327 :MARKer:Y2Position / 328 :MARKer:YDELta / 329 :MARKer:YUNits / 330 :MARKer:YUNits:USE / 331 20 :MEASure Commands :MEASure:ALL / 342 :MEASure:CLEar / 343 :MEASure:DEFine / 344 :MEASure:DELay / 347 :MEASure:DUTYcycle / 349 :MEASure:FALLtime / 350 :MEASure:FREQuency / 351 :MEASure:NWIDth / 352 :MEASure:OVERshoot / 353 :MEASure:PERiod / 355 :MEASure:PHASe / 356 :MEASure:PREShoot / 357 :MEASure:P
21 :MTESt Commands :MTESt:ALL / 382 :MTESt:AMASk:CREate / 383 :MTESt:AMASk:SOURce / 384 :MTESt:AMASk:UNITs / 385 :MTESt:AMASk:XDELta / 386 :MTESt:AMASk:YDELta / 387 :MTESt:COUNt:FWAVeforms / 388 :MTESt:COUNt:RESet / 389 :MTESt:COUNt:TIME / 390 :MTESt:COUNt:WAVeforms / 391 :MTESt:DATA / 392 :MTESt:DELete / 393 :MTESt:ENABle / 394 :MTESt:LOCK / 395 :MTESt:RMODe / 396 :MTESt:RMODe:FACTion:MEASure / 397 :MTESt:RMODe:FACTion:PRINt / 398 :MTESt:RMODe:FACTion:SAVE / 399 :MTESt:RMODe:FACTion:STOP / 400 :MTESt:RMODe
:RECall:WMEMory[:STARt] / 423 24 :SAVE Commands :SAVE:FILename / 428 :SAVE:IMAGe[:STARt] / 429 :SAVE:IMAGe:FACTors / 430 :SAVE:IMAGe:FORMat / 431 :SAVE:IMAGe:INKSaver / 432 :SAVE:IMAGe:PALette / 433 :SAVE:LISTer[:STARt] / 434 :SAVE:MASK[:STARt] / 435 :SAVE:MULTi[:STARt] / 436 :SAVE:PWD / 437 :SAVE:SETup[:STARt] / 438 :SAVE:WAVeform[:STARt] / 439 :SAVE:WAVeform:FORMat / 440 :SAVE:WAVeform:LENGth / 441 :SAVE:WAVeform:LENGth:MAX / 442 :SAVE:WAVeform:SEGMented / 443 :SAVE:WMEMory:SOURce / 444 :SAVE:WMEMory[
:SBUS:IIC Commands / 469 :SBUS:IIC:ASIZe / 470 :SBUS:IIC[:SOURce]:CLOCk / 471 :SBUS:IIC[:SOURce]:DATA / 472 :SBUS:IIC:TRIGger:PATTern:ADDRess / 473 :SBUS:IIC:TRIGger:PATTern:DATA / 474 :SBUS:IIC:TRIGger:PATTern:DATa2 / 475 :SBUS:IIC:TRIGger:QUALifier / 476 :SBUS:IIC:TRIGger[:TYPE] / 477 :SBUS:LIN Commands / 479 :SBUS:LIN:PARity / 481 :SBUS:LIN:SAMPlepoint / 482 :SBUS:LIN:SIGNal:BAUDrate / 483 :SBUS:LIN:SOURce / 484 :SBUS:LIN:STANdard / 485 :SBUS:LIN:SYNCbreak
:SBUS:UART:COUNt:ERRor / 515 :SBUS:UART:COUNt:RESet / 516 :SBUS:UART:COUNt:RXFRames / 517 :SBUS:UART:COUNt:TXFRames / 518 :SBUS:UART:FRAMing / 519 :SBUS:UART:PARity / 520 :SBUS:UART:POLarity / 521 :SBUS:UART:SOURce:RX / 522 :SBUS:UART:SOURce:TX / 523 :SBUS:UART:TRIGger:BASE / 524 :SBUS:UART:TRIGger:BURSt / 525 :SBUS:UART:TRIGger:DATA / 526 :SBUS:UART:TRIGger:IDLE / 527 :SBUS:UART:TRIGger:QUALifier / 528 :SBUS:UART:TRIGger:TYPE / 529 :SBUS:UART:WIDTh / 530 26
:SEARch:SERial:SPI Commands / 555 :SEARch:SERial:SPI:MODE / 556 :SEARch:SERial:SPI:PATTern:DATA / 557 :SEARch:SERial:SPI:PATTern:WIDTh / 558 :SEARch:SERial:UART Commands / 559 :SEARch:SERial:UART:DATA / 560 :SEARch:SERial:UART:MODE / 561 :SEARch:SERial:UART:QUALifier / 562 27 :SYSTem Commands :SYSTem:DATE / 565 :SYSTem:DSP / 566 :SYSTem:ERRor / 567 :SYSTem:LOCK / 568 :SYSTem:MENU / 569 :SYSTem:PRESet / 570 :SYSTem:PROTection:LOCK / 573 :SYSTem:SETup / 574 :SYSTem:TIME / 576 28 :TIMebase Commands :TIMebase
:TRIGger:SWEep / 600 :TRIGger[:EDGE] Commands / 601 :TRIGger[:EDGE]:COUPling / 602 :TRIGger[:EDGE]:LEVel / 603 :TRIGger[:EDGE]:REJect / 604 :TRIGger[:EDGE]:SLOPe / 605 :TRIGger[:EDGE]:SOURce / 606 :TRIGger:GLITch Commands / 607 :TRIGger:GLITch:GREaterthan / 609 :TRIGger:GLITch:LESSthan / 610 :TRIGger:GLITch:LEVel / 611 :TRIGger:GLITch:POLarity / 612 :TRIGger:GLITch:QUALifier / 613 :TRIGger:GLITch:RANGe / 614 :TRIGger:GLITch:SOURce / 615 :TRIGger:PATTern Commands / 616 :TRIGger:PATTern / 617 :TRIGger:PATTern
:WAVeform:VIEW / 656 :WAVeform:XINCrement / 657 :WAVeform:XORigin / 658 :WAVeform:XREFerence / 659 :WAVeform:YINCrement / 660 :WAVeform:YORigin / 661 :WAVeform:YREFerence / 662 31 :WGEN Commands :WGEN:FREQuency / 666 :WGEN:FUNCtion / 667 :WGEN:FUNCtion:PULSe:WIDTh / 669 :WGEN:FUNCtion:RAMP:SYMMetry / 670 :WGEN:FUNCtion:SQUare:DCYCle / 671 :WGEN:MODulation:AM:DEPTh / 672 :WGEN:MODulation:AM:FREQuency / 673 :WGEN:MODulation:FM:DEViation / 674 :WGEN:MODulation:FM:FREQuency / 675 :WGEN:MODulation:FSKey:FREQuen
:WMEMory:YRANge / 701 :WMEMory:YSCale / 702 33 Obsolete and Discontinued Commands :CHANnel:ACTivity / 708 :CHANnel:LABel / 709 :CHANnel:THReshold / 710 :CHANnel2:SKEW / 711 :CHANnel:INPut / 712 :CHANnel:PMODe / 713 :DISPlay:CONNect / 714 :DISPlay:ORDer / 715 :ERASe / 716 :EXTernal:PMODe / 717 :FUNCtion:SOURce / 718 :FUNCtion:VIEW / 719 :HARDcopy:DESTination / 720 :HARDcopy:FILename / 721 :HARDcopy:GRAYscale / 722 :HARDcopy:IGColors / 723 :HARDcopy:PDRiver / 724 :MEASure:LOWer / 725 :MEASure:SCR
:SAVE:IMAGe:AREA / 746 :TIMebase:DELay / 747 :TRIGger:THReshold / 748 :TRIGger:TV:TVMode / 749 34 Error Messages 35 Status Reporting Status Reporting Data Structures / 761 Status Byte Register (STB) / 764 Service Request Enable Register (SRE) / 766 Trigger Event Register (TER) / 767 Output Queue / 768 Message Queue / 769 (Standard) Event Status Register (ESR) / 770 (Standard) Event Status Enable Register (ESE) / 771 Error Queue / 772 Operation Status Event Register (:OPERegister[:EVENt]) / 773 Operation St
37 More About Oscilloscope Commands Command Classifications / 792 Core Commands / 792 Non-Core Commands / 792 Obsolete Commands / 792 Valid Command/Query Strings / 793 Program Message Syntax / 793 Duplicate Mnemonics / 797 Tree Traversal Rules and Multiple Commands / 797 Query Return Values / 799 All Oscilloscope Commands Are Sequential / 800 38 Programming Examples VISA COM Examples / 802 VISA COM Example in Visual Basic / 802 VISA COM Example in C# / 811 VISA COM Example in Visual Basic .
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 1 What's New What's New in Version 2.30 / 26 What's New in Version 2.20 / 28 What's New in Version 2.10 / 30 What's New in Version 2.00 / 31 What's New in Version 1.20 / 32 What's New in Version 1.10 / 33 Version 1.
1 What's New What's New in Version 2.30 New features in version 2.30 of the InfiniiVision 2000 X-Series oscilloscope software are: • Support for CAN/LIN, I2C/SPI, and UART/RS232 serial triggering and decode. • Saving Multi Channel Waveform data (*.h5) format files that can be opened by the N8900A InfiniiView oscilloscope analysis software. More detailed descriptions of the new and changed commands appear below.
What's New Changed Commands Command Differences :SEARch:SERial:LIN Commands (see page 549) Commands for finding LIN events in the captured data. :SEARch:SERial:SPI Commands (see page 555) Commands for finding SPI events in the captured data. :SEARch:SERial:UART Commands (see page 559) Commands for finding UART/RS232 events in the captured data. :SEARch:STATe (see page 535) Enables or disables the search feature.
1 What's New What's New in Version 2.20 New features in version 2.20 of the InfiniiVision 2000 X-Series oscilloscope software are: • Support for modulation of the waveform generator output. • Support for controlling the optional DSOXDVM digital voltmeter analysis feature • Ability to turn reference waveform locations on or off and view their status using the :VIEW, :BLANk, and :STATus commands. More detailed descriptions of the new and changed commands appear below.
What's New Changed Commands Command Differences :BLANk (see page 158) You can now use the WMEMory source parameter to turn off the display of a reference waveform location. :STATus (see page 179) You can now use the WMEMory source parameter to view the display status of a reference waveform location. :VIEW (see page 182) You can now use the WMEMory source parameter to turn on the display of a reference waveform location.
1 What's New What's New in Version 2.10 New features in version 2.10 of the InfiniiVision 2000 X-Series oscilloscope software are: • Support for adding an annotation to the display. More detailed descriptions of the new and changed commands appear below. New Commands 30 Command Description :DISPlay:ANNotation (see page 253) Turns screen annotation on or off. :DISPlay:ANNotation:BACKground (see page 254) Specifies the background of the annotation to be either opaque, inverted, or transparent.
What's New 1 What's New in Version 2.00 New features in version 2.00 of the InfiniiVision 2000 X-Series oscilloscope software are: • Ability to add noise to the waveform generator's output signal. More detailed descriptions of the new and changed commands appear below. New Commands Command Description :WGEN:MODulation:NOISe (see page 680) Adds noise to the waveform generator's output signal.
1 What's New What's New in Version 1.20 New features in version 1.20 of the InfiniiVision 2000 X-Series oscilloscope software are: • X cursor units that let you measure time (seconds), frequency (Hertz), phase (degrees), and ratio (percent), and Y cursor units that let you measure the channel units (base) or ratio (percent). • Option for specifying FFT vertical units as V RMS as well as decibels. • Option for saving the maximum number of waveform data points.
What's New 1 What's New in Version 1.10 New command descriptions for Version 1.10 of the InfiniiVision 2000 X-Series oscilloscope software appear below. • Support for the new extended Video triggering license. More detailed descriptions of the new and changed commands appear below. New Commands Command Description :SYSTem:PRESet (see page 570) Now documented, this command is equivalent to the front panel [Defaul t Setup] key which leaves some user settings, like preferences, unchanged.
1 What's New Version 1.00 at Introduction The Keysight InfiniiVision 2000 X-Series oscilloscopes were introduced with version 1.00 of oscilloscope operating software. The command set is most closely related to the InfiniiVision 7000B Series oscilloscopes (and the 7000A Series, 6000 Series, and 54620/54640 Series oscilloscopes before them). For more information, see “Command Differences From 7000B Series Oscilloscopes" on page 35.
What's New 1 Command Differences From 7000B Series Oscilloscopes The Keysight InfiniiVision 2000 X-Series oscilloscopes command set is most closely related to the InfiniiVision 7000B Series oscilloscopes (and the 7000A Series, 6000 Series, and 54620/54640 Series oscilloscopes before them). The main differences between the version 1.00 programming command set for the InfiniiVision 2000 X-Series oscilloscopes and the 6.
1 What's New Changed Commands Obsolete Commands 36 Command Description :TRIGger:PATTern Commands (see page 616) This subsystem contains commands/functions that are in the 7000B Series oscilloscope's :TRIGger:DURation subsystem. :WGEN Commands (see page 663) Commands for controlling the built-in waveform generator (with Option WGN license). :WMEMory Commands (see page 693) Commands for reference waveforms.
What's New Discontinued Commands Command Description :ACQuire:RSIGnal The 2000 X-Series oscilloscope does not have a 10 MHz REF BNC connector. :CALibrate:SWITch? Replaced by :CALibrate:PROTected? (see page 212). The oscilloscope has a protection button instead of a switch. :DISPlay:SOURce PMEMory (pixel memory) locations are not present. :EXTernal:IMPedance External TRIG IN connector is now fixed at 1 MOhm. :EXTernal:PROBe:ID Not supported on external TRIG IN connector.
1 38 What's New Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 2 Setting Up Step 1. Install Keysight IO Libraries Suite software / 40 Step 2. Connect and set up the oscilloscope / 41 Step 3. Verify the oscilloscope connection / 43 This chapter explains how to install the Keysight IO Libraries Suite software, connect the oscilloscope to the controller PC, set up the oscilloscope, and verify the oscilloscope connection.
2 Setting Up Step 1. Install Keysight IO Libraries Suite software 1 Download the Keysight IO Libraries Suite software from the Keysight web site at: • "http://www.keysight.com/find/iolib" 2 Run the setup file, and follow its installation instructions.
Setting Up 2 Step 2. Connect and set up the oscilloscope The 2000 X-Series oscilloscope has three different interfaces you can use for programming: • USB (device port). • LAN, when the LAN/VGA option module is installed. To configure the LAN interface, press the [Utility] key on the front panel, then press the I/O softkey, then press the Configure softkey. • GPIB, when the GPIB option module is installed. When installed, these interfaces are always active.
2 Setting Up Find out if automatic configuration via DHCP or AutoIP can be used. Also, find out whether your network supports Dynamic DNS or Multicast DNS. If automatic configuration is not supported, get the oscilloscope's network parameters (hostname, domain, IP address, subnet mask, gateway IP, DNS IP, etc.). 3 Connect the oscilloscope to the local area network (LAN) by inserting LAN cable into the "LAN" port on the LAN/VGA option module.
Setting Up 2 Step 3. Verify the oscilloscope connection 1 On the controller PC, click on the Keysight IO Control icon in the taskbar and choose Keysight Connection Expert from the popup menu. 2 In the Keysight Connection Expert application, instruments connected to the controller's USB and GPIB interfaces should automatically appear. (You can click Refresh All to update the list of instruments on these interfaces.
2 Setting Up You must manually add instruments on LAN interfaces: a Right-click on the LAN interface, choose Add Instrument from the popup menu b If the oscilloscope is on the same subnet, select it, and click OK.
Setting Up 2 Otherwise, if the instrument is not on the same subnet, click Add Address. i In the next dialog, select either Hostname or IP address, and enter the oscilloscope's hostname or IP address. ii Click Test Connection.
2 Setting Up iii If the instrument is successfully opened, click OK to close the dialog. If the instrument is not opened successfully, go back and verify the LAN connections and the oscilloscope setup.
2 Setting Up 3 Test some commands on the instrument: a Right-click on the instrument and choose Send Commands To This Instrument from the popup menu. b In the Keysight Interactive IO application, enter commands in the Command field and press Send Command, Read Response, or Send&Read. c Choose Connect>Exit from the menu to exit the Keysight Interactive IO application. 4 In the Keysight Connection Expert application, choose File>Exit from the menu to exit the application.
2 48 Setting Up Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 3 Getting Started Basic Oscilloscope Program Structure / 50 Programming the Oscilloscope / 52 Other Ways of Sending Commands / 61 This chapter gives you an overview of programming the 2000 X-Series oscilloscopes. It describes basic oscilloscope program structure and shows how to program the oscilloscope using a few simple examples.
3 Getting Started Basic Oscilloscope Program Structure The following figure shows the basic structure of every program you will write for the oscilloscope. Initializing To ensure consistent, repeatable performance, you need to start the program, controller, and oscilloscope in a known state. Without correct initialization, your program may run correctly in one instance and not in another.
Getting Started 3 memory in the oscilloscope, or transferred to the controller for further analysis. Any additional commands sent while :DIGitize is working are buffered until :DIGitize is complete. You could also put the oscilloscope into run mode, then use a wait loop in your program to ensure that the oscilloscope has completed at least one acquisition before you make a measurement. Keysight does not recommend this because the needed length of the wait loop may vary, causing your program to fail.
3 Getting Started Programming the Oscilloscope • "Referencing the IO Library" on page 52 • "Opening the Oscilloscope Connection via the IO Library" on page 53 • "Using :AUToscale to Automate Oscilloscope Setup" on page 54 • "Using Other Oscilloscope Setup Commands" on page 54 • "Capturing Data with the :DIGitize Command" on page 55 • "Reading Query Responses from the Oscilloscope" on page 57 • "Reading Query Results into String Variables" on page 58 • "Reading Query Results into Numeric Var
Getting Started 3 3 Click OK. To reference the Keysight VISA COM library in Microsoft Visual Basic 6.0: 1 Choose Project>References... from the main menu. 2 In the References dialog, check the "VISA COM 3.0 Type Library". 3 Click OK. Opening the Oscilloscope Connection via the IO Library PC controllers communicate with the oscilloscope by sending and receiving messages over a remote interface.
3 Getting Started Dim myMgr As VisaComLib.ResourceManager Dim myScope As VisaComLib.FormattedIO488 Set myMgr = New VisaComLib.ResourceManager Set myScope = New VisaComLib.FormattedIO488 ' Open the connection to the oscilloscope. Get the VISA Address from the ' Keysight Connection Expert (installed with Keysight IO Libraries Suite ). Set myScope.IO = myMgr.Open("") ' Clear the interface buffer and set the interface timeout to 10 seconds . myScope.IO.Clear myScope.IO.
Getting Started 3 Vertical is set to 16 V full-scale (2 V/div) with center of screen at 1 V and probe attenuation set to 10. This example sets the time base at 1 ms full-scale (100 ms/div) with a delay of 100 µs. Example Oscilloscope Setup Code This program demonstrates the basic command structure used to program the oscilloscope. ' Initialize the instrument interface to a known state. myScope.IO.Clear myScope.IO.Timeout = 10000 ' Set interface timeout to 10 seconds.
3 Getting Started NOTE Ensure New Data is Collected When you change the oscilloscope configuration, the waveform buffers are cleared. Before doing a measurement, send the :DIGitize command to the oscilloscope to ensure new data has been collected. When you send the :DIGitize command to the oscilloscope, the specified channel signal is digitized with the current :ACQuire parameters.
Getting Started 3 The easiest method of transferring a digitized waveform depends on data structures, formatting available and I/O capabilities. You must scale the integers to determine the voltage value of each point. These integers are passed starting with the left most point on the instrument's display. For more information, see the waveform subsystem commands and corresponding program code examples in Chapter 30, “:WAVeform Commands,” starting on page 627.
3 Getting Started Reading Query Results into String Variables The output of the instrument may be numeric or character data depending on what is queried. Refer to the specific command descriptions for the formats and types of data returned from queries. NOTE Express String Variables Using Exact Syntax In Visual Basic, string variables are case sensitive and must be expressed exactly the same each time they are used. The following example shows numeric data being returned to a string variable: myScope.
3 Getting Started /TLADQ NE %HFHSR 5G@S 'NKKNV "BST@K %@S@ AXSDR NE C@S@ SDQLHM@SNQ /TLADQ NE #XSDR SN AD 5Q@MRLHSSDC Figure 2 Definite-length block response data The "8" states the number of digits that follow, and "00001000" states the number of bytes to be transmitted.
3 Getting Started strResults() = myScope.ReadList(ASCIIType_BSTR) MsgBox "Timebase range: " + strResults(0) + ", delay: " + strResults(1) To read the :TIMebase:RANGe?;DELay? query result into multiple numeric variables, you could use the ReadList method to read the query results into a variant array variable using the commands: myScope.WriteString ":TIMebase:RANGe?;DELay?" Dim varResults() As Variant varResults() = myScope.
3 Getting Started Other Ways of Sending Commands Standard Commands for Programmable Instrumentation (SCPI) can also be sent via a Telnet socket or through the Browser Web Control: • "Telnet Sockets" on page 61 • "Sending SCPI Commands Using Browser Web Control" on page 61 Telnet Sockets The following information is provided for programmers who wish to control the oscilloscope with SCPI commands in a Telnet session.
3 62 Getting Started Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 4 Commands Quick Reference Command Summary / 64 Syntax Elements / 117 63
4 Commands Quick Reference Command Summary 64 • Common (*) Commands Summary (see page 65) • Root (:) Commands Summary (see page 67) • :ACQuire Commands Summary (see page 70) • :BUS Commands Summary (see page 71) • :CALibrate Commands Summary (see page 72) • :CHANnel Commands Summary (see page 73) • :DEMO Commands Summary (see page 75) • :DIGital Commands Summary (see page 75) • :DISPlay Commands Summary (see page 76) • :DVM Commands Summary (see page 77) • :EXTernal Trigger
4 Commands Quick Reference Table 2 • :TIMebase Commands Summary (see page 106) • General :TRIGger Commands Summary (see page 107) • :TRIGger[:EDGE] Commands Summary (see page 108) • :TRIGger:GLITch Commands Summary (see page 109) • :TRIGger:PATTern Commands Summary (see page 110) • :TRIGger:TV Commands Summary (see page 111) • :WAVeform Commands Summary (see page 111) • :WGEN Commands Summary (see page 114) • :WMEMory Commands Summary (see page 115) Common (*) Commands Summary Comma
4 Commands Quick Reference Table 2 Common (*) Commands Summary (continued) Command Query Options and Query Returns n/a *OPT? (see page 133) ::= 0,0, ::= , , , , , , , , , , , , , , , , , , , , , , ,
4 Commands Quick Reference Table 2 Common (*) Commands Summary (continued) Command Query Options and Query Returns n/a *STB? (see page 142) ::= 0 to 255; an integer in NR1 format, as shown in the following: Bit Weight Name "1" Indicates --- ------ ---- --------------7 128 OPER Operation status condition occurred. 6 64 RQS/ Instrument is MSS requesting service. 5 32 ESB Enabled event status condition occurred. 4 16 MAV Message available. 3 8 ---- (Not used.) 2 4 MSG Message displayed.
4 Commands Quick Reference Table 3 Root (:) Commands Summary (continued) Command Query Options and Query Returns :AUToscale [
4 Commands Quick Reference Table 3 Root (:) Commands Summary (continued) Command Query Options and Query Returns :MTEenable (see page 161) :MTEenable? (see page 161) ::= 16-bit integer in NR1 format n/a :MTERegister[:EVENt]? (see page 163) ::= 16-bit integer in NR1 format :OPEE (see page 165) :OPEE? (see page 166) ::= 15-bit integer in NR1 format n/a :OPERregister:CONDiti on? (see page 167) ::= 15-bit integer in NR1 format n/a :OPERegister[:EVENt]? (see page 169)
4 Commands Quick Reference Table 3 Root (:) Commands Summary (continued) Command Query Options and Query Returns n/a :STATus? (see page 179) {0 | 1} ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms) in NR1 format :STOP (see page 180) n/a n/a n/a :TER? (see page 181) {0 | 1} :VIEW
Commands Quick Reference Table 4 :ACQuire Commands Summary (continued) Command Query Options and Query Returns :ACQuire:SEGMented:CO UNt (see page 190) :ACQuire:SEGMented:CO UNt? (see page 190) ::= an integer from 2 to 25 in NR1 format (with Option SGM) :ACQuire:SEGMented:IN Dex (see page 191) :ACQuire:SEGMented:IN Dex? (see page 191) ::= an integer from 1 to 25 in NR1 format (with Option SGM) n/a :ACQuire:SRATe? (see page 194) ::= sample rate (sam
4 Commands Quick Reference Table 5 :BUS Commands Summary (continued) Command Query Options and Query Returns :BUS:LABel (see page 204) :BUS:LABel? (see page 204) ::= quoted ASCII string up to 10 characters ::= 1 or 2; an integer in NR1 format :BUS:MASK (see page 205) :BUS:MASK? (see page 205) ::= 32-bit integer in decimal, , or ::= #Hnn...n where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...
4 Commands Quick Reference Table 6 :CALibrate Commands Summary (continued) Command Query Options and Query Returns n/a :CALibrate:TEMPeratur e? (see page 215) ::= degrees C delta since last cal in NR3 format n/a :CALibrate:TIME? (see page 216) ::= ,,; all in NR1 format Table 7 :CHANnel Commands Summary Command Query Options and Query Returns :CHANnel:BWLimit {{0 | OFF} | {1 | ON}} (see page 220) :CHANnel:BWLimit? (see page 22
4 Commands Quick Reference Table 7 :CHANnel Commands Summary (continued) Command Query Options and Query Returns :CHANnel:PROBe:HEA D[:TYPE] (see page 228) :CHANnel:PROBe:HEA D[:TYPE]? (see page 228) ::= {SEND0 | SEND6 | SEND12 | SEND20 | DIFF0 | DIFF6 | DIFF12 | DIFF20 | NONE} ::= 1 to (# analog channels) in NR1 format n/a :CHANnel:PROBe:ID? (see page 229) ::= unquoted ASCII string up to 11 characters ::= 1 to (# analog channels) in NR1 f
Commands Quick Reference Table 8 :DEMO Commands Summary Command Query Options and Query Returns :DEMO:FUNCtion (see page 238) :DEMO:FUNCtion? (see page 239) ::= {SINusoid | NOISy | PHASe | RINGing | SINGle | AM | CLK | GLITch | BURSt | MSO | RFBurst | LFSine | FMBurst} :DEMO:FUNCtion:PHASe: PHASe (see page 240) :DEMO:FUNCtion:PHASe: PHASe? (see page 240) ::= angle in degrees from 0 to 360 in NR3 format :DEMO:OUTPut {{0 | OFF} | {1 | ON}} (see page 241) :DEMO:OU
4 Commands Quick Reference Table 10 :DISPlay Commands Summary Command Query Options and Query Returns :DISPlay:ANNotation {{0 | OFF} | {1 | ON}} (see page 253) :DISPlay:ANNotation? (see page 253) {0 | 1} :DISPlay:ANNotation:B ACKground (see page 254) :DISPlay:ANNotation:B ACKground? (see page 254) ::= {OPAQue | INVerted | TRANsparent} :DISPlay:ANNotation:C OLor (see page 255) :DISPlay:ANNotation:C OLor? (see page 255) ::= {CH1 | CH2 | CH3 | CH4 | DIG | MATH | REF |
Commands Quick Reference 4 Table 11 :DVM Commands Summary Command Query Options and Query Returns :DVM:ARANge {{0 | OFF} | {1 | ON}} (see page 264) :DVM:ARANge? (see page 264) {0 | 1} n/a :DVM:CURRent? (see page 265) ::= floating-point number in NR3 format :DVM:ENABle {{0 | OFF} | {1 | ON}} (see page 266) :DVM:ENABle? (see page 266) {0 | 1} n/a :DVM:FREQuency? (see page 265) ::= floating-point number in NR3 format :DVM:MODE (see page 268) :DVM:MODE? (see pag
4 Commands Quick Reference Table 13 :FUNCtion Commands Summary Command Query Options and Query Returns :FUNCtion:DISPlay {{0 | OFF} | {1 | ON}} (see page 280) :FUNCtion:DISPlay? (see page 280) {0 | 1} :FUNCtion[:FFT]:CENTe r (see page 281) :FUNCtion[:FFT]:CENTe r? (see page 281) ::= the current center frequency in NR3 format. The range of legal values is from 0 Hz to 25 GHz.
Commands Quick Reference 4 Table 13 :FUNCtion Commands Summary (continued) Command Query Options and Query Returns :FUNCtion:RANGe (see page 290) :FUNCtion:RANGe? (see page 290) ::= the full-scale vertical axis value in NR3 format. The range for ADD, SUBT, MULT is 8E-6 to 800E+3. The range for the FFT function is 8 to 800 dBV. :FUNCtion:REFerence (see page 291) :FUNCtion:REFerence? (see page 291) ::= the value at center screen in NR3 format.
4 Commands Quick Reference Table 14 :HARDcopy Commands Summary (continued) Command Query Options and Query Returns :HARDcopy:FFEed {{0 | OFF} | {1 | ON}} (see page 300) :HARDcopy:FFEed? (see page 300) {0 | 1} :HARDcopy:INKSaver {{0 | OFF} | {1 | ON}} (see page 301) :HARDcopy:INKSaver? (see page 301) {0 | 1} :HARDcopy:LAYout (see page 302) :HARDcopy:LAYout? (see page 302) ::= {LANDscape | PORTrait} :HARDcopy:NETWork:ADD Ress (see page 303) :HARDcopy:NETWork:ADD Ress
Commands Quick Reference 4 Table 15 :LISTer Commands Summary Command Query Options and Query Returns n/a :LISTer:DATA? (see page 314) ::= comma-separated data with newlines at the end of each row :LISTer:DISPlay {{OFF | 0} | {SBUS1 | ON | 1} | ALL} (see page 315) :LISTer:DISPlay? (see page 315) {OFF | SBUS1 | ALL} :LISTer:REFerence (see page 316) :LISTer:REFerence? (see page 316) ::= {TRIGger | PREVious} Table 16 :MARKer Commands Summary Command Query Opt
4 Commands Quick Reference Table 16 :MARKer Commands Summary (continued) Command Query Options and Query Returns n/a :MARKer:XDELta? (see page 324) ::= X cursors delta value in NR3 format :MARKer:XUNits (see page 325) :MARKer:XUNits? (see page 325) ::= {SEConds | HERTz | DEGRees | PERCent} :MARKer:XUNits:USE (see page 326) n/a n/a :MARKer:Y1Position [suffix] (see page 327) :MARKer:Y1Position? (see page 327) ::= Y1 cursor position value in NR
Commands Quick Reference 4 Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:DEFine THResholds, (see page 344) :MEASure:DEFine? THResholds (see page 345) ::= {STANdard} | {,, ,} ::= {PERCent | ABSolute} :MEASure:DELay [] [,] (see page 347) :MEASure:DELay? [] [,] (see page 347) ::= {CHANnel | FUNCtion | MATH | WMEMo
4 Commands Quick Reference Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:FREQuency [
Commands Quick Reference 4 Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:PERiod [] (see page 355) :MEASure:PERiod? [] (see page 355) ::= {CHANnel | FUNCtion | MATH | WMEMory} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= wavef
4 Commands Quick Reference Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:RISetime [] (see page 359) :MEASure:RISetime? [] (see page 359) ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= rise time in seconds in NR3 format :MEASure:SHOW {1 | ON} (see page 360) :MEASure:SHOW? (see page 360) {1} :MEASure:SOURce [,] (se
4 Commands Quick Reference Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns n/a :MEASure:TVALue? , [] [,] (see page 365) ::= voltage level that the waveform must cross. ::= direction of the waveform when is crossed. ::= transitions reported.
4 Commands Quick Reference Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:VMAX [] (see page 370) :MEASure:VMAX? [] (see page 370) ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= maximum voltage of the selected waveform in NR3 format :MEASure:VMIN [] (see page 371) :MEASure:VMIN? [] (see page 371) ::= {CHANnel<
4 Commands Quick Reference Table 17 :MEASure Commands Summary (continued) Command Query Options and Query Returns n/a :MEASure:VTIMe? [,] (see page 374) ::= displayed time from trigger in seconds in NR3 format ::= {CHANnel | FUNCtion | MATH | WMEMory} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in N
4 Commands Quick Reference Table 18 :MTESt Commands Summary (continued) Command Query Options and Query Returns :MTESt:AMASk:YDELta (see page 387) :MTESt:AMASk:YDELta? (see page 387) ::= Y delta value in NR3 format n/a :MTESt:COUNt:FWAVefor ms? [CHANnel] (see page 388) ::= number of failed waveforms in NR1 format :MTESt:COUNt:RESet (see page 389) n/a n/a n/a :MTESt:COUNt:TIME? (see page 390)
Commands Quick Reference 4 Table 18 :MTESt Commands Summary (continued) Command Query Options and Query Returns :MTESt:RMODe:TIME (see page 402) :MTESt:RMODe:TIME? (see page 402) ::= from 1 to 86400 in NR3 format :MTESt:RMODe:WAVeform s (see page 403) :MTESt:RMODe:WAVeform s? (see page 403) ::= number of waveforms in NR1 format :MTESt:SCALe:BIND {{0 | OFF} | {1 | ON}} (see page 404) :MTESt:SCALe:BIND? (see page 404) {0 | 1} :MTESt:SCALe:X1 (see pa
4 Commands Quick Reference Table 19 :POD Commands Summary (continued) Command Query Options and Query Returns :POD:SIZE (see page 414) :POD:SIZE? (see page 414) ::= {SMALl | MEDium | LARGe} :POD:THReshold [suffix] (see page 415) :POD:THReshold? (see page 415) ::= 1 in NR1 format ::= {CMOS | ECL | TTL | } ::= value in NR3 format [suffix] ::= {V | mV | uV } Table 20 :RECall Commands Summary Command Query Opti
4 Commands Quick Reference Table 21 :SAVE Commands Summary Command Query Options and Query Returns :SAVE:FILename (see page 428) :SAVE:FILename? (see page 428) ::= quoted ASCII string :SAVE:IMAGe[:STARt] [] (see page 429) n/a ::= quoted ASCII string :SAVE:IMAGe:FACTors {{0 | OFF} | {1 | ON}} (see page 430) :SAVE:IMAGe:FACTors? (see page 430) {0 | 1} :SAVE:IMAGe:FORMat (see page 431) :SAVE:IMAGe:FORMat? (see page 431) ::= {TIFF
4 Commands Quick Reference Table 21 :SAVE Commands Summary (continued) Command Query Options and Query Returns :SAVE:WAVeform:FORMat (see page 440) :SAVE:WAVeform:FORMat ? (see page 440) ::= {ASCiixy | CSV | BINary | NONE} :SAVE:WAVeform:LENGth (see page 441) :SAVE:WAVeform:LENGth ? (see page 441) ::= 100 to max.
Commands Quick Reference 4 Table 23 :SBUS:CAN Commands Summary Command Query Options and Query Returns n/a :SBUS:CAN:COUNt:ER Ror? (see page 454) ::= integer in NR1 format n/a :SBUS:CAN:COUNt:OV ERload? (see page 455) ::= integer in NR1 format :SBUS:CAN:COUNt:RE Set (see page 456) n/a n/a n/a :SBUS:CAN:COUNt:TO Tal? (see page 457) ::= integer in NR1 format n/a :SBUS:CAN:COUNt:UT ILization? (see page 458) ::= floating-po
4 Commands Quick Reference Table 23 :SBUS:CAN Commands Summary (continued) Command Query Options and Query Returns :SBUS:CAN:TRIGger: PATTern:ID (see page 467) :SBUS:CAN:TRIGger: PATTern:ID? (see page 467) ::= "nn...n" where n ::= {0 | 1 | X | $}
Commands Quick Reference 4 Table 24 :SBUS:IIC Commands Summary (continued) Command Query Options and Query Returns :SBUS:IIC:TRIGger: QUALifier (see page 476) :SBUS:IIC:TRIGger: QUALifier? (see page 476) ::= {EQUal | NOTequal | LESSthan | GREaterthan} :SBUS:IIC:TRIGger[ :TYPE] (see page 477) :SBUS:IIC:TRIGger[ :TYPE]? (see page 477) ::= {STARt | STOP | READ7 | READEprom | WRITe7 | WRITe10 | NACKnowledge | ANACk | R7Data2 | W7Data2 | RESTart} Table 25 :
4 Commands Quick Reference Table 25 :SBUS:LIN Commands Summary (continued) Command Query Options and Query Returns :SBUS:LIN:TRIGger: ID (see page 488) :SBUS:LIN:TRIGger: ID? (see page 488) ::= 7-bit integer in decimal, , or from 0-63 or 0x00-0x3f ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary ::= "0xnn" where n ::= {0,..,9 | A,..
Commands Quick Reference 4 Table 26 :SBUS:SPI Commands Summary (continued) Command Query Options and Query Returns :SBUS:SPI:SOURce:C LOCk (see page 499) :SBUS:SPI:SOURce:C LOCk? (see page 499) ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format :SBUS:SPI:SOURce:F RAMe (see page 500) :SBUS:SPI:SOURce:F RAMe? (
4 Commands Quick Reference Table 26 :SBUS:SPI Commands Summary (continued) Command Query Options and Query Returns :SBUS:SPI:TRIGger: PATTern:MOSI:WIDTh (see page 506) :SBUS:SPI:TRIGger: PATTern:MOSI:WIDTh? (see page 506) ::= integer from 4 to 64 in NR1 format :SBUS:SPI:TRIGger: TYPE (see page 507) :SBUS:SPI:TRIGger: TYPE? (see page 507) ::= {MOSI | MISO} :SBUS:SPI:WIDTh (see page 508) :SBUS:SPI:WIDTh? (see page 508)
4 Commands Quick Reference Table 27 :SBUS:UART Commands Summary (continued) Command Query Options and Query Returns :SBUS:UART:PARity (see page 520) :SBUS:UART:PARity? (see page 520) ::= {EVEN | ODD | NONE} :SBUS:UART:POLarit y (see page 521) :SBUS:UART:POLarit y? (see page 521) ::= {HIGH | LOW} :SBUS:UART:SOURce: RX (see page 522) :SBUS:UART:SOURce: RX? (see page 522) ::= {CHANnel | EXTernal} for DSO models
4 Commands Quick Reference Table 27 :SBUS:UART Commands Summary (continued) Command Query Options and Query Returns :SBUS:UART:TRIGger :QUALifier (see page 528) :SBUS:UART:TRIGger :QUALifier? (see page 528) ::= {EQUal | NOTequal | GREaterthan | LESSthan} :SBUS:UART:TRIGger :TYPE (see page 529) :SBUS:UART:TRIGger :TYPE? (see page 529) ::= RDATa | RD1 PARityerror TDATa | TD1 :SBUS:UART:WIDTh (see page 530) :SBUS:UART:WIDTh? (see page 530
4 Commands Quick Reference Table 30 :SEARch:SERial:IIC Commands Summary Command Query Options and Query Returns :SEARch:SERial:IIC:MO DE (see page 543) :SEARch:SERial:IIC:MO DE? (see page 543) ::= { READ7 | WRITE7 | NACKnowledge | ANACk | R7Data2 | W7Data2 | RESTart | READEprom} :SEARch:SERial:IIC:PA TTern:ADDRess (see page 545) :SEARch:SERial:IIC:PA TTern:ADDRess? (see page 545) ::= integer or ::= "0xnn" n ::= {0,..,9 | A,..
4 Commands Quick Reference Table 31 :SEARch:SERial:LIN Commands Summary (continued) Command Query Options and Query Returns :SEARch:SERial:LIN:PA TTern:DATA (see page 552) :SEARch:SERial:LIN:PA TTern:DATA? (see page 552) When :SEARch:SERial:LIN:PATTern:FORMa t DECimal, ::= "n" where n ::= 32-bit integer in unsigned decimal, returns "$" if data has any don't cares When :SEARch:SERial:LIN:PATTern:FORMa t HEX, ::= "0xnn...n" where n ::= {0,..,9 | A,..
4 Commands Quick Reference Table 33 :SEARch:SERial:UART Commands Summary Command Query Options and Query Returns :SEARch:SERial:UART:D ATA (see page 560) :SEARch:SERial:UART:D ATA? (see page 560) ::= 8-bit integer from 0-255 (0x00-0xff) in decimal, , , or format ::= #Hnn where n ::= {0,..,9| A,..,F} for hexadecimal ::= #Bnn...
4 Commands Quick Reference Table 34 :SYSTem Commands Summary (continued) Command Query Options and Query Returns :SYSTem:PRESet (see page 570) n/a See :SYSTem:PRESet (see page 570) :SYSTem:PROTection:LO CK (see page 573) :SYSTem:PROTection:LO CK? (see page 573) ::= {{1 | ON} | {0 | OFF}} :SYSTem:SETup (see page 574) :SYSTem:SETup? (see page 574) ::= data in IEEE 488.2 # format.
4 Commands Quick Reference Table 36 General :TRIGger Commands Summary Command Query Options and Query Returns :TRIGger:FORCe (see page 592) n/a n/a :TRIGger:HFReject {{0 | OFF} | {1 | ON}} (see page 593) :TRIGger:HFReject? (see page 593) {0 | 1} :TRIGger:HOLDoff (see page 594) :TRIGger:HOLDoff? (see page 594) ::= 60 ns to 10 s in NR3 format :TRIGger:LEVel:ASETup (see page 595) n/a n/a :TRIGger:LEVel:HIGH , (see page 596) :TRIGger:LEVel:HIGH?
4 Commands Quick Reference Table 37 :TRIGger[:EDGE] Commands Summary Command Query Options and Query Returns :TRIGger[:EDGE]:COUPl ing {AC | DC | LFReject} (see page 602) :TRIGger[:EDGE]:COUPl ing? (see page 602) {AC | DC | LFReject} :TRIGger[:EDGE]:LEVel [,] (see page 603) :TRIGger[:EDGE]:LEVel ? [] (see page 603) For internal triggers, ::= .75 x full-scale voltage from center screen in NR3 format.
4 Commands Quick Reference Table 38 :TRIGger:GLITch Commands Summary Command Query Options and Query Returns :TRIGger:GLITch:GREat erthan [s uffix] (see page 609) :TRIGger:GLITch:GREat erthan? (see page 609) ::= floating-point number in NR3 format [suffix] ::= {s | ms | us | ns | ps} :TRIGger:GLITch:LESSt han [suff ix] (see page 610) :TRIGger:GLITch:LESSt han? (see page 610) ::= floating-point number in NR3 format [suffix] ::=
4 Commands Quick Reference Table 38 :TRIGger:GLITch Commands Summary (continued) Command Query Options and Query Returns :TRIGger:GLITch:RANGe [suff ix], [s uffix] (see page 614) :TRIGger:GLITch:RANGe ? (see page 614) ::= 15 ns to 10 seconds in NR3 format ::= 10 ns to 9.
4 Commands Quick Reference Table 40 :TRIGger:TV Commands Summary Command Query Options and Query Returns :TRIGger:TV:LINE (see page 622) :TRIGger:TV:LINE? (see page 622) ::= integer in NR1 format :TRIGger:TV:MODE (see page 623) :TRIGger:TV:MODE? (see page 623) ::= {FIEld1 | FIEld2 | AFIelds | ALINes | LFIeld1 | LFIeld2 | LALTernate} :TRIGger:TV:POLarity (see page 624) :TRIGger:TV:POLarity? (see page 624) ::= {POSitive | NEGat
4 Commands Quick Reference Table 41 :WAVeform Commands Summary (continued) Command Query Options and Query Returns :WAVeform:POINts <# points> (see page 640) :WAVeform:POINts? (see page 640) <# points> ::= {100 | 250 | 500 | 1000 | } if waveform points mode is NORMal <# points> ::= {100 | 250 | 500 | 1000 | 2000 ...
4 Commands Quick Reference Table 41 :WAVeform Commands Summary (continued) Command Query Options and Query Returns :WAVeform:SOURce (see page 649) :WAVeform:SOURce? (see page 649) ::= {CHANnel | FUNCtion | MATH | SBUS1} for DSO models ::= {CHANnel | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1} for MSO models ::= 1 to (# analog channels) in NR1 format :WAVeform:SOURce:SUBS ource (see page 653) :WAVeform:SOURce:SUBS ource? (see page 653)
4 Commands Quick Reference Table 42 :WGEN Commands Summary Command Query Options and Query Returns :WGEN:FREQuency (see page 666) :WGEN:FREQuency? (see page 666) ::= frequency in Hz in NR3 format :WGEN:FUNCtion (see page 667) :WGEN:FUNCtion? (see page 668) ::= {SINusoid | SQUare | RAMP | PULSe | NOISe | DC} :WGEN:FUNCtion:PULSe: WIDTh (see page 669) :WGEN:FUNCtion:PULSe: WIDTh? (see page 669) ::= pulse width in seconds in NR3 format :WG
4 Commands Quick Reference Table 42 :WGEN Commands Summary (continued) Command Query Options and Query Returns :WGEN:MODulation:NOIS e (see page 680) :WGEN:MODulation:NOIS e? (see page 680) ::= 0 to 100 :WGEN:MODulation:STAT e {{0 | OFF} | {1 | ON}} (see page 681) :WGEN:MODulation:STAT e? (see page 681) {0 | 1} :WGEN:MODulation:TYPE (see page 682) :WGEN:MODulation:TYPE ? (see page 682) ::= {AM | FM | FSK} :WGEN:OUTPut {{0 | OFF} | {1 | ON}} (see page 684) :WG
4 Commands Quick Reference Table 43 :WMEMory Commands Summary (continued) Command Query Options and Query Returns :WMEMory:LABel (see page 697) :WMEMory:LABel? (see page 697) ::= 1-2 in NR1 format ::= any series of 10 or less ASCII characters enclosed in quotation marks :WMEMory:SAVE (see page 698) n/a ::= 1-2 in NR1 format ::= {CHANnel | FUNCtion | MATH} ::= 1 to (# analog channels) in NR1 format NOTE: Only ADD or SUBtract math operat
Commands Quick Reference 4 Syntax Elements • "Number Format" on page 117 • " (Line Terminator)" on page 117 • "[ ] (Optional Syntax Terms)" on page 117 • "{ } (Braces)" on page 117 • "::= (Defined As)" on page 117 • "< > (Angle Brackets)" on page 118 • "... (Ellipsis)" on page 118 • "n,..,p (Value Ranges)" on page 118 • "d (Digits)" on page 118 • "Quoted ASCII String" on page 118 • "Definite-Length Block Response Data" on page 118 Number Format NR1 specifies integer data.
4 Commands Quick Reference < > (Angle Brackets) < > Angle brackets enclose words or characters that symbolize a program code parameter or an interface command. ... (Ellipsis) ... An ellipsis (trailing dots) indicates that the preceding element may be repeated one or more times. n,..,p (Value Ranges) n,..,p ::= all integers between n and p inclusive. d (Digits) d ::= A single ASCII numeric character 0 - 9.
Commands Quick Reference 4 <1000 bytes of data> is the actual data Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 119
4 120 Commands Quick Reference Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 5 Common (*) Commands Commands defined by IEEE 488.2 standard that are common to all instruments. See "Introduction to Common (*) Commands" on page 123.
5 Common (*) Commands Table 44 Common (*) Commands Summary (continued) Command Query Options and Query Returns n/a *OPT? (see page 133) ::= 0,0, ::= , , , , , , , , , , , , , , , , , , , , , , ,
5 Common (*) Commands Table 44 Common (*) Commands Summary (continued) Command Query Options and Query Returns n/a *STB? (see page 142) ::= 0 to 255; an integer in NR1 format, as shown in the following: Bit Weight Name "1" Indicates --- ------ ---- --------------7 128 OPER Operation status condition occurred. 6 64 RQS/ Instrument is MSS requesting service. 5 32 ESB Enabled event status condition occurred. 4 16 MAV Message available. 3 8 ---- (Not used.) 2 4 MSG Message displayed.
5 Common (*) Commands NOTE 124 Each of the status registers has an enable (mask) register. By setting the bits in the enable register, you can select the status information you want to use.
5 Common (*) Commands *CLS (Clear Status) (see page 792) Command Syntax *CLS The *CLS common command clears the status data structures, the device-defined error queue, and the Request-for-OPC flag. NOTE See Also If the *CLS command immediately follows a program message terminator, the output queue and the MAV (message available) bit are cleared.
5 Common (*) Commands *ESE (Standard Event Status Enable) (see page 792) Command Syntax *ESE ::= integer from 0 to 255 The *ESE common command sets the bits in the Standard Event Status Enable Register. The Standard Event Status Enable Register contains a mask value for the bits to be enabled in the Standard Event Status Register. A "1" in the Standard Event Status Enable Register enables the corresponding bit in the Standard Event Status Register.
Common (*) Commands Query Syntax 5 *ESE? The *ESE? query returns the current contents of the Standard Event Status Enable Register. Return Format ::= 0,..,255; an integer in NR1 format.
5 Common (*) Commands *ESR (Standard Event Status Register) (see page 792) Query Syntax *ESR? The *ESR? query returns the contents of the Standard Event Status Register. When you read the Event Status Register, the value returned is the total bit weights of all of the bits that are high at the time you read the byte. Reading the register clears the Event Status Register. The following table shows bit weight, name, and condition for each bit.
Common (*) Commands Return Format 5 ::= 0,..,255; an integer in NR1 format. NOTE See Also Reading the Standard Event Status Register clears it. High or 1 indicates the bit is true.
5 Common (*) Commands *IDN (Identification Number) (see page 792) Query Syntax *IDN? The *IDN? query identifies the instrument type and software version. Return Format AGILENT TECHNOLOGIES,,,X.XX.XX ::= the model number of the instrument ::= the serial number of the instrument X.XX.
5 Common (*) Commands *LRN (Learn Device Setup) (see page 792) Query Syntax *LRN? The *LRN? query result contains the current state of the instrument. This query is similar to the :SYSTem:SETup? (see page 574) query, except that it contains ":SYST:SET " before the binary block data. The query result is a valid command that can be used to restore instrument settings at a later time. Return Format ::= :SYST:SET ::= binary block data in IEEE 488.
5 Common (*) Commands *OPC (Operation Complete) (see page 792) Command Syntax *OPC The *OPC command sets the operation complete bit in the Standard Event Status Register when all pending device operations have finished. Query Syntax *OPC? The *OPC? query places an ASCII "1" in the output queue when all pending device operations have completed. The interface hangs until this query returns.
Common (*) Commands 5 *OPT (Option Identification) (see page 792) Query Syntax *OPT? The *OPT? query reports the options installed in the instrument. This query returns a string that identifies the module and its software revision level.
5 Common (*) Commands • 134 "*IDN (Identification Number)" on page 130 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Common (*) Commands 5 *RCL (Recall) (see page 792) Command Syntax *RCL ::= {0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9} The *RCL command restores the state of the instrument from the specified save/recall register.
5 Common (*) Commands *RST (Reset) (see page 792) Command Syntax *RST The *RST command places the instrument in a known state. This is the same as pressing [Save/Recall] > Defaul t/Erase > Factory Defaul t on the front panel. When you perform a factory default setup, there are no user settings that remain unchanged. To perform the equivalent of the front panel's [Defaul t Setup] key, where some user settings (like preferences) remain unchanged, use the :SYSTem:PRESet command.
Common (*) Commands 5 Digital Channel Menu (MSO models only) Channel 0 - 7 Off Labels Off Threshold TTL (1.4 V) Display Menu Persistence Off Grid 20% Quick Meas Menu Source Channel 1 Run Control Scope is running Time Base Menu Main time/division 100 us Main time base delay 0.00 s Delay time/division 500 ns Delay time base delay 0.00 s Reference center Mode main Vernier Off Trigger Menu Type Edge Mode Auto Coupling dc Source Channel 1 Level 0.
5 Common (*) Commands Trigger Menu See Also Example Code HF Reject and noise reject Off Holdoff 40 ns External probe attenuation 10:1 External Units Volts External Impedance 1 M Ohm (cannot be changed) • "Introduction to Common (*) Commands" on page 123 • ":SYSTem:PRESet" on page 570 ' RESET - This command puts the oscilloscope into a known state. ' This statement is very important for programs to work as expected. ' Most of the following initialization commands are initialized by ' *RST.
5 Common (*) Commands *SAV (Save) (see page 792) Command Syntax *SAV ::= {0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9} The *SAV command stores the current state of the instrument in a save register. The data parameter specifies the register where the data will be saved.
5 Common (*) Commands *SRE (Service Request Enable) (see page 792) Command Syntax *SRE ::= integer with values defined in the following table. The *SRE command sets the bits in the Service Request Enable Register. The Service Request Enable Register contains a mask value for the bits to be enabled in the Status Byte Register. A one in the Service Request Enable Register enables the corresponding bit in the Status Byte Register. A zero disables the bit.
5 Common (*) Commands Table 47 Service Request Enable Register (SRE) Query Syntax Bit Name Description When Set (1 = High = True), Enables: 7 OPER Operation Status Register Interrupts when enabled conditions in the Operation Status Register (OPER) occur. 6 --- --- (Not used.) 5 ESB Event Status Bit Interrupts when enabled conditions in the Standard Event Status Register (ESR) occur. 4 MAV Message Available Interrupts when messages are in the Output Queue. 3 --- --- (Not used.
5 Common (*) Commands *STB (Read Status Byte) (see page 792) Query Syntax *STB? The *STB? query returns the current value of the instrument's status byte. The MSS (Master Summary Status) bit is reported on bit 6 instead of the RQS (request service) bit. The MSS indicates whether or not the device has at least one reason for requesting service. Return Format ::= 0,..
5 Common (*) Commands Table 48 Status Byte Register (STB) NOTE See Also Bit Name Description When Set (1 = High = True), Ind icates: 7 OPER Operation Status Register An enabled condition in the Operation Status Register (OPER) has occurred. 6 RQS Request Service When polled, that the device is requesting service. MSS Master Summary Status When read (by *STB?), whether the device has a reason for requesting service.
5 Common (*) Commands *TRG (Trigger) (see page 792) Command Syntax *TRG The *TRG command has the same effect as the :DIGitize command with no parameters.
Common (*) Commands 5 *TST (Self Test) (see page 792) Query Syntax *TST? The *TST? query performs a self-test on the instrument. The result of the test is placed in the output queue. A zero indicates the test passed and a non-zero indicates the test failed. If the test fails, refer to the troubleshooting section of the Service Guide.
5 Common (*) Commands *WAI (Wait To Continue) (see page 792) Command Syntax *WAI The *WAI command has no function in the oscilloscope, but is parsed for compatibility with other instruments.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 6 Root (:) Commands Control many of the basic functions of the oscilloscope and reside at the root level of the command tree. See "Introduction to Root (:) Commands" on page 150.
6 Root (:) Commands Table 49 Root (:) Commands Summary (continued) Command Query Options and Query Returns :BLANk [] (see page 158) n/a ::= {CHANnel} | FUNCtion | MATH | SBUS1 | WMEMory} for DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms) in NR1 format :DIGitize [
6 Root (:) Commands Table 49 Root (:) Commands Summary (continued) Command Query Options and Query Returns :OVLenable (see page 171) :OVLenable? (see page 172) ::= 16-bit integer in NR1 format as shown: Bit Weight Input --- ------ ---------10 1024 Ext Trigger Fault 9 512 Channel 4 Fault 8 256 Channel 3 Fault 7 128 Channel 2 Fault 6 64 Channel 1 Fault 4 16 Ext Trigger OVL 3 8 Channel 4 OVL 2 4 Channel 3 OVL 1 2 Channel 2 OVL 0 1 Channel 1 OVL n/a :OVLRegister? (see page 173) :
6 Root (:) Commands Table 49 Root (:) Commands Summary (continued) Command Query Options and Query Returns n/a :TER? (see page 181) {0 | 1} :VIEW (see page 182) n/a ::= {CHANnel | FUNCtion | MATH | SBUS1 | WMEMory} for DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms)
6 Root (:) Commands :ACTivity (see page 792) Command Syntax :ACTivity The :ACTivity command clears the cumulative edge variables for the next activity query. Query Syntax :ACTivity? The :ACTivity? query returns whether there has been activity (edges) on the digital channels since the last query, and returns the current logic levels.
6 Root (:) Commands :AER (Arm Event Register) (see page 792) Query Syntax :AER? The AER query reads the Arm Event Register. After the Arm Event Register is read, it is cleared. A "1" indicates the trigger system is in the armed state, ready to accept a trigger. The Armed Event Register is summarized in the Wait Trig bit of the Operation Status Event Register.
6 Root (:) Commands :AUToscale (see page 792) Command Syntax :AUToscale :AUToscale [[,..,]] ::= CHANnel for the DSO models ::= {DIGital | POD1 | POD2 | CHANnel} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The parameter may be repeated up to 5 times. The :AUToscale command evaluates all input signals and sets the correct conditions to display the signals.
6 Root (:) Commands See Also Example Code • "Introduction to Root (:) Commands" on page 150 • ":AUToscale:CHANnels" on page 156 • ":AUToscale:AMODE" on page 155 ' AUTOSCALE - This command evaluates all the input signals and sets ' the correct conditions to display all of the active signals. myScope.WriteString ":AUToscale" ' Same as pressing Auto Scale key.
Root (:) Commands 6 :AUToscale:AMODE (see page 792) Command Syntax :AUToscale:AMODE ::= {NORMal | CURRent} The :AUTOscale:AMODE command specifies the acquisition mode that is set by subsequent :AUToscales. • When NORMal is selected, an :AUToscale command sets the NORMal acquisition type and the RTIMe (real-time) acquisition mode. • When CURRent is selected, the current acquisition type and mode are kept on subsequent :AUToscales.
6 Root (:) Commands :AUToscale:CHANnels (see page 792) Command Syntax :AUToscale:CHANnels ::= {ALL | DISPlayed} The :AUTOscale:CHANnels command specifies which channels will be displayed on subsequent :AUToscales. • When ALL is selected, all channels that meet the requirements of :AUToscale will be displayed. • When DISPlayed is selected, only the channels that are turned on are autoscaled. Use the :VIEW or :BLANk root commands to turn channels on or off.
6 Root (:) Commands :AUToscale:FDEBug (see page 792) Command Syntax :AUToscale:FDEBug ::= {{1 | ON} | {0 | OFF}} The :AUToscale:FDEBug command turns fast debug auto scaling on or off. The Fast Debug option changes the behavior of :AUToscale to let you make quick visual comparisons to determine whether the signal being probed is a DC voltage, ground, or an active AC signal. Channel coupling is maintained for easy viewing of oscillating signals.
6 Root (:) Commands :BLANk (see page 792) Command Syntax :BLANk [] ::= {CHANnel | FUNCtion | MATH | SBUS1 | WMEMory} for the DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms) in NR1 format The :BLANk command turns off (stops displaying) the specified channel, digital pod
6 Root (:) Commands :DIGitize (see page 792) Command Syntax :DIGitize [[,..,]] ::= {CHANnel | FUNCtion | MATH | SBUS1} for the DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The parameter may be repeated up to 5 times. The :DIGitize command is a specialized RUN command.
6 Root (:) Commands See complete example programs at: Chapter 38, “Programming Examples,” starting on page 801 160 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Root (:) Commands 6 :MTEenable (Mask Test Event Enable Register) (see page 792) Command Syntax :MTEenable ::= 16-bit integer The :MTEenable command sets a mask in the Mask Test Event Enable register. Set any of the following bits to "1" to enable bit 9 in the Operation Status Condition Register and potentially cause an SRQ (Service Request interrupt to be generated.
6 Root (:) Commands See Also 162 • "Introduction to Root (:) Commands" on page 150 • ":AER (Arm Event Register)" on page 152 • ":CHANnel:PROTection" on page 232 • ":OPERegister[:EVENt] (Operation Status Event Register)" on page 169 • ":OVLenable (Overload Event Enable Register)" on page 171 • ":OVLRegister (Overload Event Register)" on page 173 • "*STB (Read Status Byte)" on page 142 • "*SRE (Service Request Enable)" on page 140 Keysight InfiniiVision 2000 X-Series Oscilloscopes Progr
Root (:) Commands 6 :MTERegister[:EVENt] (Mask Test Event Event Register) (see page 792) Query Syntax :MTERegister[:EVENt]? The :MTERegister[:EVENt]? query returns the integer value contained in the Mask Test Event Event Register and clears the register.
6 164 Root (:) Commands • ":OVLRegister (Overload Event Register)" on page 173 • "*STB (Read Status Byte)" on page 142 • "*SRE (Service Request Enable)" on page 140 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Root (:) Commands 6 :OPEE (Operation Status Enable Register) (see page 792) Command Syntax :OPEE ::= 15-bit integer The :OPEE command sets a mask in the Operation Status Enable register. Set any of the following bits to "1" to enable bit 7 in the Status Byte Register and potentially cause an SRQ (Service Request interrupt to be generated.
6 Root (:) Commands Query Syntax :OPEE? The :OPEE? query returns the current value contained in the Operation Status Enable register as an integer number. Return Format ::= integer in NR1 format.
Root (:) Commands 6 :OPERegister:CONDition (Operation Status Condition Register) (see page 792) Query Syntax :OPERegister:CONDition? The :OPERegister:CONDition? query returns the integer value contained in the Operation Status Condition Register.
6 Root (:) Commands See Also 168 • "Introduction to Root (:) Commands" on page 150 • ":CHANnel:PROTection" on page 232 • ":OPEE (Operation Status Enable Register)" on page 165 • ":OPERegister[:EVENt] (Operation Status Event Register)" on page 169 • ":OVLenable (Overload Event Enable Register)" on page 171 • ":OVLRegister (Overload Event Register)" on page 173 • "*STB (Read Status Byte)" on page 142 • "*SRE (Service Request Enable)" on page 140 • ":MTERegister[:EVENt] (Mask Test Event
6 Root (:) Commands :OPERegister[:EVENt] (Operation Status Event Register) (see page 792) Query Syntax :OPERegister[:EVENt]? The :OPERegister[:EVENt]? query returns the integer value contained in the Operation Status Event Register.
6 Root (:) Commands ::= integer in NR1 format.
6 Root (:) Commands :OVLenable (Overload Event Enable Register) (see page 792) Command Syntax :OVLenable ::= 16-bit integer The overload enable mask is an integer representing an input as described in the following table. The :OVLenable command sets the mask in the Overload Event Enable Register and enables the reporting of the Overload Event Register. If an overvoltage is sensed on a 50Ω input, the input will automatically switch to 1 MΩ input impedance.
6 Root (:) Commands Table 55 Overload Event Enable Register (OVL) (continued) Query Syntax Bit Description When Set (1 = High = True), Enables: 3 Channel 4 OVL Event when overload occurs on Channel 4 input. 2 Channel 3 OVL Event when overload occurs on Channel 3 input. 1 Channel 2 OVL Event when overload occurs on Channel 2 input. 0 Channel 1 OVL Event when overload occurs on Channel 1 input.
6 Root (:) Commands :OVLRegister (Overload Event Register) (see page 792) Query Syntax :OVLRegister? The :OVLRegister query returns the overload protection value stored in the Overload Event Register (OVLR). If an overvoltage is sensed on a 50Ω input, the input will automatically switch to 1 MΩ input impedance. A "1" indicates an overload has occurred. NOTE You can set analog channel input impedance to 50Ω on the 300 MHz, 500 MHz, and 1 GHz bandwidth oscilloscope models.
6 Root (:) Commands Table 56 Overload Event Register (OVLR) (continued) Return Format Bit Description When Set (1 = High = True), Ind icates: 1 Channel 2 OVL Overload has occurred on Channel 2 input. 0 Channel 1 OVL Overload has occurred on Channel 1 input. ::= integer in NR1 format.
Root (:) Commands 6 :PRINt (see page 792) Command Syntax :PRINt [] ::= [][,..,] ::= {COLor | GRAYscale | PRINter0 | PRINter1 | BMP8bit | BMP | PNG | NOFactors | FACTors} The parameter may be repeated up to 5 times. The PRINt command formats the output according to the currently selected format (device). If an option is not specified, the value selected in the Print Config menu is used.
6 Root (:) Commands :RUN (see page 792) Command Syntax :RUN The :RUN command starts repetitive acquisitions. This is the same as pressing the Run key on the front panel. See Also Example Code • "Introduction to Root (:) Commands" on page 150 • ":SINGle" on page 178 • ":STOP" on page 180 ' RUN_STOP - (not executed in this example) ' - RUN starts the data acquisition for the active waveform display. ' - STOP stops the data acquisition and turns off AUTOSTORE. ' myScope.
Root (:) Commands 6 :SERial (see page 792) Query Syntax :SERial? The :SERial? query returns the serial number of the instrument.
6 Root (:) Commands :SINGle (see page 792) Command Syntax :SINGle The :SINGle command causes the instrument to acquire a single trigger of data. This is the same as pressing the Single key on the front panel.
Root (:) Commands 6 :STATus (see page 792) Query Syntax :STATus? ::= {CHANnel | FUNCtion | MATH | SBUS1 | WMEMory} for the DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms) in NR1 format The :STATus? query reports whether the channel, function, or serial decode bus spec
6 Root (:) Commands :STOP (see page 792) Command Syntax :STOP The :STOP command stops the acquisition. This is the same as pressing the Stop key on the front panel.
Root (:) Commands 6 :TER (Trigger Event Register) (see page 792) Query Syntax :TER? The :TER? query reads the Trigger Event Register. After the Trigger Event Register is read, it is cleared. A one indicates a trigger has occurred. A zero indicates a trigger has not occurred. The Trigger Event Register is summarized in the TRG bit of the Status Byte Register (STB).
6 Root (:) Commands :VIEW (see page 792) Command Syntax :VIEW ::= {CHANnel | FUNCtion | MATH | SBUS1 | WMEMory} for DSO models ::= {CHANnel | DIGital | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | SBUS1 | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= 1 to (# ref waveforms) in NR1 format The :VIEW command turns on the specified channel, function, or serial decode bus.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 7 :ACQuire Commands Set the parameters for acquiring and storing data. See "Introduction to :ACQuire Commands" on page 183.
7 :ACQuire Commands The :ACQuire:TYPE NORMal command sets the oscilloscope in the normal acquisition mode. For the majority of user models and signals, NORMal mode yields the best oscilloscope picture of the waveform. Averaging The :ACQuire:TYPE AVERage command sets the oscilloscope in the averaging mode. You can set the count by sending the :ACQuire:COUNt command followed by the number of averages. In this mode, the value for averages is an integer from 2 to 65536.
:ACQuire Commands 7 :ACQuire:COMPlete (see page 792) Command Syntax :ACQuire:COMPlete ::= 100; an integer in NR1 format The :ACQuire:COMPlete command affects the operation of the :DIGitize command. It specifies the minimum completion criteria for an acquisition. The parameter determines the percentage of the time buckets that must be "full" before an acquisition is considered complete.
7 :ACQuire Commands :ACQuire:COUNt (see page 792) Command Syntax :ACQuire:COUNt ::= integer in NR1 format In averaging mode, the :ACQuire:COUNt command specifies the number of values to be averaged for each time bucket before the acquisition is considered to be complete for that time bucket. When :ACQuire:TYPE is set to AVERage, the count can be set to any value from 2 to 65536. NOTE Query Syntax The :ACQuire:COUNt 1 command has been deprecated.
7 :ACQuire Commands :ACQuire:MODE (see page 792) Command Syntax :ACQuire:MODE ::= {RTIMe | SEGMented} The :ACQuire:MODE command sets the acquisition mode of the oscilloscope. • NOTE The obsolete command ACQuire:TYPE:REALtime is functionally equivalent to sending ACQuire:MODE RTIMe; TYPE NORMal. • Query Syntax The :ACQuire:MODE RTIMe command sets the oscilloscope in real time mode. The :ACQuire:MODE SEGMented command sets the oscilloscope in segmented memory mode.
7 :ACQuire Commands :ACQuire:POINts (see page 792) Query Syntax :ACQuire:POINts? The :ACQuire:POINts? query returns the number of data points that the hardware will acquire from the input signal. The number of points acquired is not directly controllable. To set the number of points to be transferred from the oscilloscope, use the command :WAVeform:POINts. The :WAVeform:POINts? query will return the number of points available to be transferred from the oscilloscope.
7 :ACQuire Commands :ACQuire:SEGMented:ANALyze (see page 792) Command Syntax NOTE :ACQuire:SEGMented:ANALyze This command is available when the segmented memory option (Option SGM) is enabled. This command calculates measurement statistics and/or infinite persistence over all segments that have been acquired. It corresponds to the front panel Analyze Segments softkey which appears in both the Measurement Statistics and Segmented Memory Menus.
7 :ACQuire Commands :ACQuire:SEGMented:COUNt (see page 792) Command Syntax :ACQuire:SEGMented:COUNt ::= an integer from 2 to 25 (w/100K memory) in NR1 format NOTE This command is available when the segmented memory option (Option SGM) is enabled. The :ACQuire:SEGMented:COUNt command sets the number of memory segments to acquire. The segmented memory acquisition mode is enabled with the :ACQuire:MODE command, and data is acquired using the :DIGitize, :SINGle, or :RUN commands.
7 :ACQuire Commands :ACQuire:SEGMented:INDex (see page 792) Command Syntax :ACQuire:SEGMented:INDex ::= an integer from 1 to 25 (w/100K memory) in NR1 format NOTE This command is available when the segmented memory option (Option SGM) is enabled. The :ACQuire:SEGMented:INDex command sets the index into the memory segments that have been acquired. The segmented memory acquisition mode is enabled with the :ACQuire:MODE command.
7 :ACQuire Commands Option Explicit Public Public Public Public myMgr As VisaComLib.ResourceManager myScope As VisaComLib.FormattedIO488 varQueryResult As Variant strQueryResult As String Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long) Sub Main() On Error GoTo VisaComError ' Create the VISA COM I/O resource. Set myMgr = New VisaComLib.ResourceManager Set myScope = New VisaComLib.FormattedIO488 Set myScope.IO = _ myMgr.Open("USB0::0x0957::0x17A6::US50210029::0::INSTR") myScope.IO.
:ACQuire Commands 7 For lngI = lngSegments To 1 Step -1 ' Set the segmented memory index. myScope.WriteString ":ACQuire:SEGMented:INDex " + CStr(lngI) myScope.WriteString ":ACQuire:SEGMented:INDex?" strQueryResult = myScope.ReadString Debug.Print "Acquisition memory segment index: " + strQueryResult ' Display the segment time tag. myScope.WriteString ":WAVeform:SEGMented:TTAG?" dblTimeTag = myScope.ReadNumber Debug.
7 :ACQuire Commands :ACQuire:SRATe (see page 792) Query Syntax :ACQuire:SRATe? The :ACQuire:SRATe? query returns the current oscilloscope acquisition sample rate. The sample rate is not directly controllable.
7 :ACQuire Commands :ACQuire:TYPE (see page 792) Command Syntax :ACQuire:TYPE ::= {NORMal | AVERage | HRESolution | PEAK} The :ACQuire:TYPE command selects the type of data acquisition that is to take place. The acquisition types are: • NORMal — sets the oscilloscope in the normal mode. • AVERage — sets the oscilloscope in the averaging mode. You can set the count by sending the :ACQuire:COUNt command followed by the number of averages.
7 :ACQuire Commands Example Code • ":ACQuire:COUNt" on page 186 • ":ACQuire:MODE" on page 187 • ":DIGitize" on page 159 • ":WAVeform:FORMat" on page 639 • ":WAVeform:TYPE" on page 654 • ":WAVeform:PREamble" on page 644 ' AQUIRE_TYPE - Sets the acquisition mode, which can be NORMAL, ' PEAK, or AVERAGE. myScope.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 8 :BUS Commands Control all oscilloscope functions associated with buses made up of digital channels. See "Introduction to :BUS Commands" on page 198.
8 :BUS Commands Table 58 :BUS Commands Summary (continued) Command Query Options and Query Returns :BUS:LABel (see page 204) :BUS:LABel? (see page 204) ::= quoted ASCII string up to 10 characters ::= 1 or 2; an integer in NR1 format :BUS:MASK (see page 205) :BUS:MASK? (see page 205) ::= 32-bit integer in decimal, , or ::= #Hnn...n where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...
:BUS Commands 8 :BUS:BIT (see page 792) Command Syntax :BUS:BIT ::= {{1 | ON} | {0 | OFF}} ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command. ::= An integer, 0,..,7, is attached as a suffix to BIT and defines the digital channel that is affected by the command. The :BUS:BIT command includes or excludes the selected bit as part of the definition for the selected bus.
8 :BUS Commands :BUS:BITS (see page 792) Command Syntax :BUS:BITS , ::= (@,:, ...) where commas separate bits and colons define bit ranges. ::= An integer, 0,..,7, defines a digital channel affected by the command. ::= {{1 | ON} | {0 | OFF}} ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command.
:BUS Commands 8 ' Include digital channels 1 through 3, 5, and 7 in bus 1: myScope.
8 :BUS Commands :BUS:CLEar (see page 792) Command Syntax :BUS:CLEar ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command. The :BUS:CLEar command excludes all of the digital channels from the selected bus definition. NOTE See Also 202 This command is only valid for the MSO models.
:BUS Commands 8 :BUS:DISPlay (see page 792) Command Syntax :BUS:DISplay ::= {{1 | ON} | {0 | OFF}} ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command. The :BUS:DISPlay command enables or disables the view of the selected bus. NOTE Query Syntax This command is only valid for the MSO models. :BUS:DISPlay? The :BUS:DISPlay? query returns the display value of the selected bus.
8 :BUS Commands :BUS:LABel (see page 792) Command Syntax :BUS:LABel ::= any series of 10 or less characters as a quoted ASCII string. ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command. The :BUS:LABel command sets the bus label to the quoted string. Setting a label for a bus will also result in the name being added to the label list. NOTE This command is only valid for the MSO models.
8 :BUS Commands :BUS:MASK (see page 792) Command Syntax :BUS:MASK ::= 32-bit integer in decimal, , or ::= #Hnn...n where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary ::= "0xnn...n" where n ::= {0,..,9 | A,..,F} for hexadecimal ::= An integer, 1 or 2, is attached as a suffix to BUS and defines the bus that is affected by the command.
8 206 :BUS Commands Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 9 :CALibrate Commands Utility commands for viewing calibration status and for starting the user calibration procedure. See "Introduction to :CALibrate Commands" on page 208.
9 :CALibrate Commands Introduction to :CALibrate Commands 208 The CALibrate subsystem provides utility commands for: • Determining the state of the calibration factor protection switch (CAL PROTECT). • Saving and querying the calibration label string. • Reporting the calibration time and date. • Reporting changes in the temperature since the last calibration. • Starting the user calibration procedure.
:CALibrate Commands 9 :CALibrate:DATE (see page 792) Query Syntax :CALibrate:DATE? The :CALibrate:DATE? query returns the date of the last calibration.
9 :CALibrate Commands :CALibrate:LABel (see page 792) Command Syntax :CALibrate:LABel ::= quoted ASCII string of up to 32 characters in length, not including the quotes The CALibrate:LABel command saves a string that is up to 32 characters in length into the instrument's non-volatile memory. The string may be used to record calibration dates or other information as needed. Query Syntax :CALibrate:LABel? The :CALibrate:LABel? query returns the contents of the calibration label string.
9 :CALibrate Commands :CALibrate:OUTPut (see page 792) Command Syntax :CALibrate:OUTPut ::= {TRIGgers | MASK | WAVEgen} The CALibrate:OUTPut command sets the signal that is available on the rear panel TRIG OUT BNC: Query Syntax • TRIGgers — pulse when a trigger event occurs. • MASK — signal from mask test indicating a failure. • WAVEgen — waveform generator sync output signal.
9 :CALibrate Commands :CALibrate:PROTected (see page 792) Query Syntax :CALibrate:PROTected? The :CALibrate:PROTected? query returns the rear-panel calibration protect (CAL PROTECT) button state. The value PROTected indicates calibration is disabled, and UNPRotected indicates calibration is enabled.
:CALibrate Commands 9 :CALibrate:STARt (see page 792) Command Syntax :CALibrate:STARt The CALibrate:STARt command starts the user calibration procedure. NOTE See Also Before starting the user calibration procedure, you must set the rear panel CALIBRATION switch to UNPROTECTED, and you must connect BNC cables from the TRIG OUT connector to the analog channel inputs. See the User's Guide for details.
9 :CALibrate Commands :CALibrate:STATus (see page 792) Query Syntax :CALibrate:STATus? The :CALibrate:STATus? query returns the summary results of the last user calibration procedure.
9 :CALibrate Commands :CALibrate:TEMPerature (see page 792) Query Syntax :CALibrate:TEMPerature? The :CALibrate:TEMPerature? query returns the change in temperature since the last user calibration procedure.
9 :CALibrate Commands :CALibrate:TIME (see page 792) Query Syntax :CALibrate:TIME? The :CALibrate:TIME? query returns the time of the last calibration.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 10 :CHANnel Commands Control all oscilloscope functions associated with individual analog channels or groups of channels. See "Introduction to :CHANnel Commands" on page 218.
10 :CHANnel Commands Table 60 :CHANnel Commands Summary (continued) Command Query Options and Query Returns :CHANnel:PROBe:HEA D[:TYPE] (see page 228) :CHANnel:PROBe:HEA D[:TYPE]? (see page 228) ::= {SEND0 | SEND6 | SEND12 | SEND20 | DIFF0 | DIFF6 | DIFF12 | DIFF20 | NONE} ::= 1 to (# analog channels) in NR1 format n/a :CHANnel:PROBe:ID? (see page 229) ::= unquoted ASCII string up to 11 characters ::= 1 to (# analog channels) in NR1 format
10 :CHANnel Commands The CHANnel subsystem commands control an analog channel (vertical or Y-axis of the oscilloscope). Channels are independently programmable for all offset, probe, coupling, bandwidth limit, inversion, vernier, and range (scale) functions. The channel number (1, 2, 3, or 4) specified in the command selects the analog channel that is affected by the command. A label command provides identifying annotations of up to 10 characters.
10 :CHANnel Commands :CHANnel:BWLimit (see page 792) Command Syntax :CHANnel:BWLimit ::= {{1 | ON} | {0 | OFF} ::= 1 to (# analog channels) in NR1 format The :CHANnel:BWLimit command controls an internal low-pass filter. When the filter is on, the bandwidth of the specified channel is limited to approximately 25 MHz. Query Syntax :CHANnel:BWLimit? The :CHANnel:BWLimit? query returns the current setting of the low-pass filter.
:CHANnel Commands 10 :CHANnel:COUPling (see page 792) Command Syntax :CHANnel:COUPling ::= {AC | DC} ::= 1 to (# analog channels) in NR1 format The :CHANnel:COUPling command selects the input coupling for the specified channel. The coupling for each analog channel can be set to AC or DC. Query Syntax :CHANnel:COUPling? The :CHANnel:COUPling? query returns the current coupling for the specified channel.
10 :CHANnel Commands :CHANnel:DISPlay (see page 792) Command Syntax :CHANnel:DISPlay ::= {{1 | ON} | {0 | OFF}} ::= 1 to (# analog channels) in NR1 format The :CHANnel:DISPlay command turns the display of the specified channel on or off. Query Syntax :CHANnel:DISPlay? The :CHANnel:DISPlay? query returns the current display setting for the specified channel.
:CHANnel Commands 10 :CHANnel:IMPedance (see page 792) Command Syntax :CHANnel:IMPedance ::= ONEMeg ::= 1 to (# analog channels) in NR1 format The :CHANnel:IMPedance command selects the input impedance setting for the specified analog channel. The only legal value for this command is ONEMeg (1 MΩ). Query Syntax :CHANnel:IMPedance? The :CHANnel:IMPedance? query returns the current input impedance setting for the specified channel.
10 :CHANnel Commands :CHANnel:INVert (see page 792) Command Syntax :CHANnel:INVert ::= {{1 | ON} | {0 | OFF} ::= 1 to (# analog channels) in NR1 format The :CHANnel:INVert command selects whether or not to invert the input signal for the specified channel. The inversion may be 1 (ON/inverted) or 0 (OFF/not inverted). Query Syntax :CHANnel:INVert? The :CHANnel:INVert? query returns the current state of the channel inversion.
:CHANnel Commands 10 :CHANnel:LABel (see page 792) Command Syntax :CHANnel:LABel ::= quoted ASCII string ::= 1 to (# analog channels) in NR1 format NOTE Label strings are 10 characters or less, and may contain any commonly used ASCII characters. Labels with more than 10 characters are truncated to 10 characters. Lower case characters are converted to upper case. The :CHANnel:LABel command sets the analog channel label to the string that follows.
10 :CHANnel Commands :CHANnel:OFFSet (see page 792) Command Syntax :CHANnel:OFFSet [] ::= Vertical offset value in NR3 format ::= {V | mV} ::= 1 to (# analog channels) in NR1 format The :CHANnel:OFFSet command sets the value that is represented at center screen for the selected channel. The range of legal values varies with the value set by the :CHANnel:RANGe and :CHANnel:SCALe commands.
:CHANnel Commands 10 :CHANnel:PROBe (see page 792) Command Syntax :CHANnel:PROBe ::= probe attenuation ratio in NR3 format ::= 1 to (# analog channels) in NR1 format The obsolete attenuation values X1, X10, X20, X100 are also supported. The :CHANnel:PROBe command specifies the probe attenuation factor for the selected channel. The probe attenuation factor may be 0.1 to 10000. This command does not change the actual input sensitivity of the oscilloscope.
10 :CHANnel Commands :CHANnel:PROBe:HEAD[:TYPE] (see page 792) Command Syntax NOTE This command is valid only for the 113xA Series probes. :CHANnel:PROBe:HEAD[:TYPE] ::= {SEND0 | SEND6 | SEND12 | SEND20 | DIFF0 | DIFF6 | DIFF12 | DIFF20 | NONE} ::= {1 | 2 | 3 | 4} The :CHANnel:PROBe:HEAD[:TYPE] command sets an analog channel probe head type and dB value. You can choose from: Query Syntax • SEND0 — Single-ended, 0dB. • SEND6 — Single-ended, 6dB.
:CHANnel Commands 10 :CHANnel:PROBe:ID (see page 792) Query Syntax :CHANnel:PROBe:ID? ::= 1 to (# analog channels) in NR1 format The :CHANnel:PROBe:ID? query returns the type of probe attached to the specified oscilloscope channel.
10 :CHANnel Commands :CHANnel:PROBe:SKEW (see page 792) Command Syntax :CHANnel:PROBe:SKEW ::= skew time in NR3 format ::= -100 ns to +100 ns ::= 1 to (# analog channels) in NR1 format The :CHANnel:PROBe:SKEW command sets the channel-to-channel skew factor for the specified channel. Each analog channel can be adjusted + or -100 ns for a total of 200 ns difference between channels.
10 :CHANnel Commands :CHANnel:PROBe:STYPe (see page 792) Command Syntax NOTE This command is valid only for the 113xA Series probes. :CHANnel:PROBe:STYPe ::= {DIFFerential | SINGle} ::= 1 to (# analog channels) in NR1 format The :CHANnel:PROBe:STYPe command sets the channel probe signal type (STYPe) to differential or single-ended when using the 113xA Series probes and determines how offset is applied.
10 :CHANnel Commands :CHANnel:PROTection (see page 792) Command Syntax :CHANnel:PROTection[:CLEar] ::= 1 to (# analog channels) in NR1 format| 4} With the 2000 X-Series oscilloscopes, the analog channel input impedance is always 1 MΩ, so automatic overvoltage protection is not necessary (as it is for channels with 50Ω input impedance). There are no protection settings to clear, so the :CHANnel:PROTection[:CLEar] command does nothing.
10 :CHANnel Commands :CHANnel:RANGe (see page 792) Command Syntax :CHANnel:RANGe [] ::= vertical full-scale range value in NR3 format ::= {V | mV} ::= 1 to (# analog channels) in NR1 format The :CHANnel:RANGe command defines the full-scale vertical axis of the selected channel. When using 1:1 probe attenuation, legal values for the range are from 8 mV to 40 V.
10 :CHANnel Commands :CHANnel:SCALe (see page 792) Command Syntax :CHANnel:SCALe [] ::= vertical units per division in NR3 format ::= {V | mV} ::= 1 to (# analog channels) in NR1 format The :CHANnel:SCALe command sets the vertical scale, or units per division, of the selected channel. If the probe attenuation is changed, the scale value is multiplied by the probe's attenuation factor.
:CHANnel Commands 10 :CHANnel:UNITs (see page 792) Command Syntax :CHANnel:UNITs ::= {VOLT | AMPere} ::= 1 to (# analog channels) in NR1 format The :CHANnel:UNITs command sets the measurement units for the connected probe. Select VOLT for a voltage probe and select AMPere for a current probe. Measurement results, channel sensitivity, and trigger level will reflect the measurement units you select.
10 :CHANnel Commands :CHANnel:VERNier (see page 792) Command Syntax :CHANnel:VERNier ::= {{1 | ON} | {0 | OFF} ::= 1 to (# analog channels) in NR1 format The :CHANnel:VERNier command specifies whether the channel's vernier (fine vertical adjustment) setting is ON (1) or OFF (0). Query Syntax :CHANnel:VERNier? The :CHANnel:VERNier? query returns the current state of the channel's vernier setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 11 :DEMO Commands When the education kit is licensed (Option EDU), you can output demonstration signals on the oscilloscope's Demo 1 and Demo 2 terminals. See "Introduction to :DEMO Commands" on page 237.
11 :DEMO Commands :DEMO:FUNCtion (see page 792) Command Syntax :DEMO:FUNCtion ::= {SINusoid | NOISy | PHASe | RINGing | SINGle | AM | CLK | GLITch | BURSt | MSO | RFBurst | LFSine | FMBurst} The :DEMO:FUNCtion command selects the type of demo signal: 238 Demo Signal Function Demo 1 Terminal Demo 2 Terminal SINusoid 5 MHz sine wave @ ~ 6 Vpp, 0 V offset Off NOISy 1 kHz sine wave @ ~ 2.4 Vpp, 0.0 V offset, with ~ 0.5 Vpp of random noise added Off PHAse 1 kHz sine wave @ 2.
:DEMO Commands Query Syntax 11 Demo Signal Function Demo 1 Terminal Demo 2 Terminal MSO 3.1 kHz stair-step sine wave output of DAC @ ~1.5 Vpp, 0.75 V offset DAC input signals are internally routed to digital channels D0 through D7 ~3.1 kHz sine wave filtered from DAC output @ ~ 600 mVpp, 300 mV offset RFBurst 5-cycle burst of a 10 MHz amplitude modulated sine wave @ ~ 2.6 Vpp, 0 V offset occurring once every 4 ms Off LFSine 30 Hz sine wave @ ~2.
11 :DEMO Commands :DEMO:FUNCtion:PHASe:PHASe (see page 792) Command Syntax :DEMO:FUNCtion:PHASe:PHASe ::= angle in degrees from 0 to 360 in NR3 format For the phase shifted sine demo signals, the :DEMO:FUNCtion:PHASe:PHASe command specifies the phase shift in the second sine waveform. Query Syntax :DEMO:FUNCtion:PHASe:PHASe? The :DEMO:FUNCtion:PHASe:PHASe? query returns the currently set phase shift.
:DEMO Commands 11 :DEMO:OUTPut (see page 792) Command Syntax :DEMO:OUTPut ::= {{1 | ON} | {0 | OFF} The :DEMO:OUTPut command specifies whether the demo signal output is ON (1) or OFF (0). Query Syntax :DEMO:OUTPut? The :DEMO:OUTPut? query returns the current state of the demo signal output setting.
11 :DEMO Commands 242 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 12 :DIGital Commands Control all oscilloscope functions associated with individual digital channels. See "Introduction to :DIGital Commands" on page 244.
12 :DIGital Commands Introduction to :DIGital Commands NOTE ::= 0 to (# digital channels - 1) in NR1 format The DIGital subsystem commands control the viewing, labeling, and positioning of digital channels. They also control threshold settings for groups of digital channels, or pods. These commands are only valid for the MSO models. Reporting the Setup Use :DIGital? to query setup information for the DIGital subsystem.
:DIGital Commands 12 :DIGital:DISPlay (see page 792) Command Syntax :DIGital:DISPlay ::= 0 to (# digital channels - 1) in NR1 format ::= {{1 | ON} | {0 | OFF}} The :DIGital:DISPlay command turns digital display on or off for the specified channel. NOTE Query Syntax This command is only valid for the MSO models. :DIGital:DISPlay? The :DIGital:DISPlay? query returns the current digital display setting for the specified channel.
12 :DIGital Commands :DIGital:LABel (see page 792) Command Syntax :DIGital:LABel ::= 0 to (# digital channels - 1) in NR1 format ::= any series of 10 or less characters as quoted ASCII string. The :DIGital:LABel command sets the channel label to the string that follows. Setting a label for a channel also adds the name to the label list in non-volatile memory (replacing the oldest label in the list). NOTE This command is only valid for the MSO models.
:DIGital Commands 12 :DIGital:POSition (see page 792) Command Syntax :DIGital:POSition ::= 0 to (# digital channels - 1) in NR1 format ::= integer in NR1 format. Channel Size Position Top Bottom Large 0-7 7 0 Medium 0-15 15 0 Small 0-31 31 0 The :DIGital:POSition command sets the position of the specified channel.
12 :DIGital Commands :DIGital:SIZE (see page 792) Command Syntax :DIGital:SIZE ::= 0 to (# digital channels - 1) in NR1 format ::= {SMALl | MEDium | LARGe} The :DIGital:SIZE command specifies the size of digital channels on the display. Sizes are set for all digital channels. Therefore, if you set the size on digital channel 0 (for example), the same size is set on all other as well. NOTE Query Syntax This command is only valid for the MSO models.
:DIGital Commands 12 :DIGital:THReshold (see page 792) Command Syntax :DIGital:THReshold ::= 0 to (# digital channels - 1) in NR1 format ::= {CMOS | ECL | TTL | []} ::= -8.00 to +8.00 in NR3 format ::= {V | mV | uV} • TTL = 1.4V • CMOS = 2.5V • ECL = -1.3V The :DIGital:THReshold command sets the logic threshold value for all channels in the same pod as the specified channel.
12 :DIGital Commands 250 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 13 :DISPlay Commands Control how waveforms, graticule, and text are displayed and written on the screen. See "Introduction to :DISPlay Commands" on page 252.
13 :DISPlay Commands Table 63 :DISPlay Commands Summary (continued) Command Query Options and Query Returns :DISPlay:PERSistence (see page 261) :DISPlay:PERSistence? (see page 261) ::= {MINimum | INFinite |
:DISPlay Commands 13 :DISPlay:ANNotation (see page 792) Command Syntax :DISPlay:ANNotation ::= {{1 | ON} | {0 | OFF}} The :DISPlay:ANNotation command turns the annotation on and off. When on, the annotation appears in the upper left corner of the oscilloscope's display. The annotation is useful for documentation purposes, to add notes before capturing screens. Query Syntax :DISPlay:ANNotation? The :DISPlay:ANNotation? query returns the annotation setting.
13 :DISPlay Commands :DISPlay:ANNotation:BACKground (see page 792) Command Syntax :DISPlay:ANNotation:BACKground ::= {OPAQue | INVerted | TRANsparent} The :DISPlay:ANNotation:BACKground command specifies the background of the annotation: Query Syntax • OPAQue — the annotation has a solid background. • INVerted — the annotation's foreground and background colors are switched. • TRANsparent — the annotation has a transparent background.
:DISPlay Commands 13 :DISPlay:ANNotation:COLor (see page 792) Command Syntax :DISPlay:ANNotation:COLor ::= {CH1 | CH2 | CH3 | CH4 | DIG | MATH | REF | MARKer | WHITe | RED} The :DISPlay:ANNotation:COLor command specifies the annotation color. You can choose white, red, or colors that match analog channels, digital channels, math waveforms, reference waveforms, or markers.
13 :DISPlay Commands :DISPlay:ANNotation:TEXT (see page 792) Command Syntax :DISPlay:ANNotation:TEXT ::= quoted ASCII string (up to 254 characters) The :DISPlay:ANNotation:TEXT command specifies the annotation string. The annotation string can contain as many characters as will fit in the Edit Annotation box on the oscilloscope's screen, up to 254 characters. You can include a carriage return in the annotation string using the characters "\ n".
:DISPlay Commands 13 :DISPlay:CLEar (see page 792) Command Syntax :DISPlay:CLEar The :DISPlay:CLEar command clears the display and resets all associated measurements. If the oscilloscope is stopped, all currently displayed data is erased. If the oscilloscope is running, all of the data for active channels and functions is erased; however, new data is displayed on the next acquisition.
13 :DISPlay Commands :DISPlay:DATA (see page 792) Query Syntax :DISPlay:DATA? [][,][] ::= {BMP | BMP8bit | PNG} ::= {COLor | GRAYscale} The :DISPlay:DATA? query reads screen image data. You can choose 24-bit BMP, 8-bit BMP8bit, or 24-bit PNG formats in color or grayscale. If no format or palette option is specified, the screen image is returned in BMP, COLor format. Screen image data is returned in the IEEE-488.2 # binary block data format.
:DISPlay Commands 13 :DISPlay:LABel (see page 792) Command Syntax :DISPlay:LABel ::= {{1 | ON} | {0 | OFF}} The :DISPlay:LABel command turns the analog and digital channel labels on and off. Query Syntax :DISPlay:LABel? The :DISPlay:LABel? query returns the display mode of the analog and digital labels.
13 :DISPlay Commands :DISPlay:LABList (see page 792) Command Syntax :DISPlay:LABList ::= an ordered list of up to 75 labels, a maximum of 10 characters each, separated by newline characters. The :DISPlay:LABList command adds labels to the label list. Labels are added in alphabetical order. NOTE Query Syntax Labels that begin with the same alphabetic base string followed by decimal digits are considered duplicate labels.
:DISPlay Commands 13 :DISPlay:PERSistence (see page 792) Command Syntax :DISPlay:PERSistence ::= {MINimum | INFinite | } ::= seconds in in NR3 format from 100E-3 to 60E0 The :DISPlay:PERSistence command specifies the persistence setting: • MINimum — indicates zero persistence. • INFinite — indicates infinite persistence. • — for variable persistence, that is, you can specify how long acquisitions remain on the screen.
13 :DISPlay Commands :DISPlay:VECTors (see page 792) Command Syntax :DISPlay:VECTors ::= {1 | ON} The only legal value for the :DISPlay:VECTors command is ON (or 1). This specifies that lines are drawn between acquired data points on the screen. Query Syntax :DISPlay:VECTors? The :DISPlay:VECTors? query returns the vectors setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 14 :DVM Commands When the optional DSOXDVM digital voltmeter analysis feature is licensed, these commands control the digital voltmeter (DVM) feature.
14 :DVM Commands :DVM:ARANge (see page 792) Command Syntax :DVM:ARANge ::= {{OFF | 0} | {ON | 1}} If the selected digital voltmeter (DVM) source channel is not used in oscilloscope triggering, the :DVM:ARANge command turns the digital voltmeter's Auto Range capability on or off. • When on, the DVM channel's vertical scale, vertical (ground level) position, and trigger (threshold voltage) level (used for the counter frequency measurement) are automatically adjusted.
:DVM Commands 14 :DVM:CURRent (see page 792) Query Syntax :DVM:CURRent? The :DVM:CURRent? query returns the displayed 3-digit DVM value based on the current mode.
14 :DVM Commands :DVM:ENABle (see page 792) Command Syntax :DVM:ENABle ::= {{OFF | 0} | {ON | 1}} The :DVM:ENABle command turns the digital voltmeter (DVM) analysis feature on or off. Query Syntax :DVM:ENABle? The :DVM:ENABle? query returns a flag indicating whether the digital voltmeter (DVM) analysis feature is on or off.
:DVM Commands 14 :DVM:FREQuency (see page 792) Query Syntax :DVM:FREQuency? The :DVM:FREQuency? query returns the displayed 5-digit frequency value that is displayed below the main DVM value.
14 :DVM Commands :DVM:MODE (see page 792) Command Syntax :DVM:MODE ::= {ACRMs | DC | DCRMs | FREQuency} The :DVM:MODE command sets the digital voltmenter (DVM) mode: Query Syntax • ACRMs — displays the root-mean-square value of the acquired data, with the DC component removed. • DC — displays the DC value of the acquired data. • DCRMs — displays the root-mean-square value of the acquired data. • FREQuency — displays the frequency counter measurement.
:DVM Commands 14 :DVM:SOURce (see page 792) Command Syntax :DVM:SOURce ::= {CHANnel} ::= 1-2 or 1-4 in NR1 format The :DVM:SOURce command sets the select the analog channel on which digital voltmeter (DVM) measurements are made. The selected channel does not have to be on (displaying a waveform) in order for DVM measurements to be made. Query Syntax :DVM:SOURce? The :DVM:SOURce? query returns the selected DVM input source.
14 :DVM Commands 270 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 15 :EXTernal Trigger Commands Control the input characteristics of the external trigger input. See "Introduction to :EXTernal Trigger Commands" on page 271.
15 :EXTernal Trigger Commands :EXTernal:BWLimit (see page 792) Command Syntax :EXTernal:BWLimit ::= {0 | OFF} The :EXTernal:BWLimit command is provided for product compatibility. The only legal value is 0 or OFF. Use the :TRIGger:HFReject command to limit bandwidth on the external trigger input. Query Syntax :EXTernal:BWLimit? The :EXTernal:BWLimit? query returns the current setting of the low-pass filter (always 0).
:EXTernal Trigger Commands 15 :EXTernal:PROBe (see page 792) Command Syntax :EXTernal:PROBe ::= probe attenuation ratio in NR3 format The :EXTernal:PROBe command specifies the probe attenuation factor for the external trigger. The probe attenuation factor may be 0.1 to 10000. This command does not change the actual input sensitivity of the oscilloscope. It changes the reference constants for scaling the display factors and for setting trigger levels.
15 :EXTernal Trigger Commands :EXTernal:RANGe (see page 792) Command Syntax :EXTernal:RANGe [] ::= vertical full-scale range value in NR3 format ::= {V | mV} The :EXTernal:RANGe command is provided for product compatibility. When using 1:1 probe attenuation, the range can only be set to 8.0 V. If the probe attenuation is changed, the range value is multiplied by the probe attenuation factor.
:EXTernal Trigger Commands 15 :EXTernal:UNITs (see page 792) Command Syntax :EXTernal:UNITs ::= {VOLT | AMPere} The :EXTernal:UNITs command sets the measurement units for the probe connected to the external trigger input. Select VOLT for a voltage probe and select AMPere for a current probe. Measurement results, channel sensitivity, and trigger level will reflect the measurement units you select.
15 :EXTernal Trigger Commands 276 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 16 :FUNCtion Commands Control functions in the measurement/storage module. See "Introduction to :FUNCtion Commands" on page 278.
16 :FUNCtion Commands Table 66 :FUNCtion Commands Summary (continued) Command Query Options and Query Returns :FUNCtion:OFFSet (see page 288) :FUNCtion:OFFSet? (see page 288) ::= the value at center screen in NR3 format. The range of legal values is +/-10 times the current sensitivity of the selected function.
:FUNCtion Commands 16 The SPAN, CENTer, VTYPe, and WINDow commands are only useful for FFT functions. When FFT is selected, the horizontal cursors change from time to frequency (Hz), and the vertical cursors change from volts to decibel (dB). Reporting the Setup Use :FUNCtion? to query setup information for the FUNCtion subsystem. Return Format The following is a sample response from the :FUNCtion? queries. In this case, the query was issued following a *RST command.
16 :FUNCtion Commands :FUNCtion:DISPlay (see page 792) Command Syntax :FUNCtion:DISPlay ::= {{1 | ON} | {0 | OFF}} The :FUNCtion:DISPlay command turns the display of the function on or off. When ON is selected, the function performs as specified using the other FUNCtion commands. When OFF is selected, function is neither calculated nor displayed. Query Syntax :FUNCtion:DISPlay? The :FUNCtion:DISPlay? query returns whether the function display is on or off.
:FUNCtion Commands 16 :FUNCtion[:FFT]:CENTer (see page 792) Command Syntax :FUNCtion[:FFT]:CENTer ::= the current center frequency in NR3 format. of legal values is from 0 Hz to 25 GHz. The range The :FUNCtion[:FFT]:CENTer command sets the center frequency when FFT (Fast Fourier Transform) is selected. Query Syntax :FUNCtion[:FFT]:CENTer? The :FUNCtion[:FFT]:CENTer? query returns the current center frequency in Hertz.
16 :FUNCtion Commands :FUNCtion[:FFT]:SPAN (see page 792) Command Syntax :FUNCtion[:FFT]:SPAN ::= the current frequency span in NR3 format. Legal values are 1 Hz to 100 GHz. If you set the frequency span to a value outside of the legal range, the step size is automatically set to the nearest legal value. The :FUNCtion[:FFT]:SPAN command sets the frequency span of the display (left graticule to right graticule) when FFT (Fast Fourier Transform) is selected.
:FUNCtion Commands 16 :FUNCtion[:FFT]:VTYPe (see page 792) Command Syntax :FUNCtion[:FFT]:VTYPe ::= {DECibel | VRMS} The :FUNCtion[:FFT]:VTYPe command specifies FFT vertical units as DECibel or VRMS. Query Syntax :FUNCtion[:FFT]:VTYPe? The :FUNCtion[:FFT]:VTYPe? query returns the current FFT vertical units.
16 :FUNCtion Commands :FUNCtion[:FFT]:WINDow (see page 792) Command Syntax :FUNCtion[:FFT]:WINDow ::= {RECTangular | HANNing | FLATtop | BHARris} The :FUNCtion[:FFT]:WINDow command allows the selection of four different windowing transforms or operations for the FFT (Fast Fourier Transform) function. The FFT operation assumes that the time record repeats.
:FUNCtion Commands 16 :FUNCtion:GOFT:OPERation (see page 792) Command Syntax :FUNCtion:GOFT:OPERation ::= {ADD | SUBTract | MULTiply} The :FUNCtion:GOFT:OPERation command sets the math operation for the g(t) source that can be used as the input to the FFT function: • ADD — Source1 + source2. • SUBTract — Source1 - source2. • MULTiply — Source1 * source2. The :FUNCtion:GOFT:SOURce1 and :FUNCtion:GOFT:SOURce2 commands are used to select source1 and source2.
16 :FUNCtion Commands :FUNCtion:GOFT:SOURce1 (see page 792) Command Syntax :FUNCtion:GOFT:SOURce1 ::= CHANnel ::= {1 | 2 | 3 | 4} for 4ch models ::= {1 | 2} for 2ch models The :FUNCtion:GOFT:SOURce1 command selects the first input channel for the g(t) source that can be used as the input to the FFT function. Query Syntax :FUNCtion:GOFT:SOURce1? The :FUNCtion:GOFT:SOURce1? query returns the current selection for the first input channel for the g(t) source.
:FUNCtion Commands 16 :FUNCtion:GOFT:SOURce2 (see page 792) Command Syntax :FUNCtion:GOFT:SOURce2 ::= CHANnel ::= {1 | 2 | 3 | 4} for 4ch models ::= {1 | 2} for 2ch models The :FUNCtion:GOFT:SOURce2 command selects the second input channel for the g(t) source that can be used as the input to the FFT function. Query Syntax :FUNCtion:GOFT:SOURce2? The :FUNCtion:GOFT:SOURce2? query returns the current selection for the second input channel for the g(t) source.
16 :FUNCtion Commands :FUNCtion:OFFSet (see page 792) Command Syntax :FUNCtion:OFFSet ::= the value at center screen in NR3 format. The :FUNCtion:OFFSet command sets the voltage or vertical value represented at center screen for the selected function. The range of legal values is generally +/-10 times the current scale of the selected function, but will vary by function.
:FUNCtion Commands 16 :FUNCtion:OPERation (see page 792) Command Syntax :FUNCtion:OPERation ::= {ADD | SUBTract | MULTiply | FFT} The :FUNCtion:OPERation command sets the desired waveform math operation: • ADD — Source1 + source2. • SUBTract — Source1 - source2. • MULTiply — Source1 * source2. • FFT — Fast Fourier Transform on the selected waveform source.
16 :FUNCtion Commands :FUNCtion:RANGe (see page 792) Command Syntax :FUNCtion:RANGe ::= the full-scale vertical axis value in NR3 format. The :FUNCtion:RANGe command defines the full-scale vertical axis for the selected function. Query Syntax :FUNCtion:RANGe? The :FUNCtion:RANGe? query returns the current full-scale range value for the selected function. Return Format ::= the full-scale vertical axis value in NR3 format.
:FUNCtion Commands 16 :FUNCtion:REFerence (see page 792) Command Syntax :FUNCtion:REFerence ::= the current reference level in NR3 format. The :FUNCtion:REFerence command sets the voltage or vertical value represented at center screen for the selected function. The range of legal values is generally +/-10 times the current scale of the selected function, but will vary by function.
16 :FUNCtion Commands :FUNCtion:SCALe (see page 792) Command Syntax :FUNCtion:SCALe [] ::= integer in NR1 format ::= {V | dB} The :FUNCtion:SCALe command sets the vertical scale, or units per division, of the selected function. Legal values for the scale depend on the selected function. Query Syntax :FUNCtion:SCALe? The :FUNCtion:SCALe? query returns the current scale value for the selected function.
16 :FUNCtion Commands :FUNCtion:SOURce1 (see page 792) Command Syntax :FUNCtion:SOURce1 ::= {CHANnel | GOFT} ::= {1 | 2 | 3 | 4} for 4ch models ::= {1 | 2} for 2ch models The :FUNCtion:SOURce1 command is used for any :FUNCtion:OPERation selection (including the ADD, SUBTract, or MULTiply channel math operations and the FFT transform). This command selects the first source for channel math operations or the single source for the transforms.
16 :FUNCtion Commands :FUNCtion:SOURce2 (see page 792) Command Syntax :FUNCtion:SOURce2 ::= {CHANnel | NONE} ::= {{1 | 2} | {3 | 4}} for 4ch models, depending on SOURce1 selection ::= {1 | 2} for 2ch models The :FUNCtion:SOURce2 command specifies the second source for math operations that have two sources (see the :FUNCtion:OPERation command), in other words, ADD, SUBTract, or MULTiply. (The :FUNCtion:SOURce1 command specifies the first source.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 17 :HARDcopy Commands Set and query the selection of hardcopy device and formatting options. See "Introduction to :HARDcopy Commands" on page 296.
17 :HARDcopy Commands Table 67 :HARDcopy Commands Summary (continued) Command Query Options and Query Returns :HARDcopy:NETWork:PAS Sword (see page 306) n/a ::= quoted ASCII string :HARDcopy:NETWork:SLO T (see page 307) :HARDcopy:NETWork:SLO T? (see page 307) ::= {NET0 | NET1} :HARDcopy:NETWork:USE Rname (see page 308) :HARDcopy:NETWork:USE Rname? (see page 308) ::= quoted ASCII string :HARDcopy:PALette (see page 309) :HARDcop
:HARDcopy Commands 17 :HARDcopy:AREA (see page 792) Command Syntax :HARDcopy:AREA ::= SCReen The :HARDcopy:AREA command controls what part of the display area is printed. Currently, the only legal choice is SCReen. Query Syntax :HARDcopy:AREA? The :HARDcopy:AREA? query returns the selected display area.
17 :HARDcopy Commands :HARDcopy:APRinter (see page 792) Command Syntax :HARDcopy:APRinter ::= { | } ::= integer index of printer in list ::= name of printer in list The :HARDcopy:APRinter command sets the active printer. Query Syntax :HARDcopy:APRinter? The :HARDcopy:APRinter? query returns the name of the active printer.
:HARDcopy Commands 17 :HARDcopy:FACTors (see page 792) Command Syntax :HARDcopy:FACTors ::= {{OFF | 0} | {ON | 1}} The HARDcopy:FACTors command controls whether the scale factors are output on the hardcopy dump. Query Syntax :HARDcopy:FACTors? The :HARDcopy:FACTors? query returns a flag indicating whether oscilloscope instrument settings are output on the hardcopy.
17 :HARDcopy Commands :HARDcopy:FFEed (see page 792) Command Syntax :HARDcopy:FFEed ::= {{OFF | 0} | {ON | 1}} The HARDcopy:FFEed command controls whether a formfeed is output between the screen image and factors of a hardcopy dump. Query Syntax :HARDcopy:FFEed? The :HARDcopy:FFEed? query returns a flag indicating whether a formfeed is output at the end of the hardcopy dump.
:HARDcopy Commands 17 :HARDcopy:INKSaver (see page 792) Command Syntax :HARDcopy:INKSaver ::= {{OFF | 0} | {ON | 1}} The HARDcopy:INKSaver command controls whether the graticule colors are inverted or not. Query Syntax :HARDcopy:INKSaver? The :HARDcopy:INKSaver? query returns a flag indicating whether graticule colors are inverted or not.
17 :HARDcopy Commands :HARDcopy:LAYout (see page 792) Command Syntax :HARDcopy:LAYout ::= {LANDscape | PORTrait} The :HARDcopy:LAYout command sets the hardcopy layout mode. Query Syntax :HARDcopy:LAYout? The :HARDcopy:LAYout? query returns the selected hardcopy layout mode.
:HARDcopy Commands 17 :HARDcopy:NETWork:ADDRess (see page 792) Command Syntax :HARDcopy:NETWork:ADDRess
::= quoted ASCII string The :HARDcopy:NETWork:ADDRess command sets the address for a network printer slot. The address is the server/computer name and the printer's share name in the \\server\share format. The network printer slot is selected by the :HARDcopy:NETWork:SLOT command. To apply the entered address, use the :HARDcopy:NETWork:APPLy command.17 :HARDcopy Commands :HARDcopy:NETWork:APPLy (see page 792) Command Syntax :HARDcopy:NETWork:APPLy The :HARDcopy:NETWork:APPLy command applies the network printer settings and makes the printer connection.
:HARDcopy Commands 17 :HARDcopy:NETWork:DOMain (see page 792) Command Syntax :HARDcopy:NETWork:DOMain ::= quoted ASCII string The :HARDcopy:NETWork:DOMain command sets the Windows network domain name. The domain name setting is a common setting for both network printer slots. Query Syntax :HARDcopy:NETWork:DOMain? The :HARDcopy:NETWork:DOMain? query returns the current Windows network domain name.
17 :HARDcopy Commands :HARDcopy:NETWork:PASSword (see page 792) Command Syntax :HARDcopy:NETWork:PASSword ::= quoted ASCII string The :HARDcopy:NETWork:PASSword command sets the password for the specified Windows network domain and user name. The password setting is a common setting for both network printer slots.
17 :HARDcopy Commands :HARDcopy:NETWork:SLOT (see page 792) Command Syntax :HARDcopy:NETWork:SLOT ::= {NET0 | NET1} The :HARDcopy:NETWork:SLOT command selects the network printer slot used for the address and apply commands. There are two network printer slots to choose from. Query Syntax :HARDcopy:NETWork:SLOT? The :HARDcopy:NETWork:SLOT? query returns the currently selected network printer slot.
17 :HARDcopy Commands :HARDcopy:NETWork:USERname (see page 792) Command Syntax :HARDcopy:NETWork:USERname ::= quoted ASCII string The :HARDcopy:NETWork:USERname command sets the user name to use when connecting to the Windows network domain. The user name setting is a common setting for both network printer slots. Query Syntax :HARDcopy:NETWork:USERname? The :HARDcopy:NETWork:USERname? query returns the currently set user name.
:HARDcopy Commands 17 :HARDcopy:PALette (see page 792) Command Syntax :HARDcopy:PALette ::= {COLor | GRAYscale | NONE} The :HARDcopy:PALette command sets the hardcopy palette color. The oscilloscope's print driver cannot print color images to color laser printers, so the COLor option is not available when connected to laser printers. Query Syntax :HARDcopy:PALette? The :HARDcopy:PALette? query returns the selected hardcopy palette color.
17 :HARDcopy Commands :HARDcopy:PRINter:LIST (see page 792) Query Syntax :HARDcopy:PRINter:LIST? The :HARDcopy:PRINter:LIST? query returns a list of available printers. The list can be empty. Return Format ::= [] ...
:HARDcopy Commands 17 :HARDcopy:STARt (see page 792) Command Syntax :HARDcopy:STARt The :HARDcopy:STARt command starts a print job.
17 :HARDcopy Commands 312 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 18 :LISTer Commands Table 68 :LISTer Commands Summary Command Query Options and Query Returns n/a :LISTer:DATA? (see page 314) ::= comma-separated data with newlines at the end of each row :LISTer:DISPlay {{OFF | 0} | {SBUS1 | ON | 1} | ALL} (see page 315) :LISTer:DISPlay? (see page 315) {OFF | SBUS1 | ALL} :LISTer:REFerence (see page 316) :LISTer:REFerence? (see page 316) ::= {TRIGger | P
18 :LISTer Commands :LISTer:DATA (see page 792) Query Syntax :LISTer:DATA? The :LISTer:DATA? query returns the lister data.
18 :LISTer Commands :LISTer:DISPlay (see page 792) Command Syntax :LISTer:DISPlay ::= {{OFF | 0} | {SBUS1 | ON | 1} | ALL} The :LISTer:DISPlay command configures which of the serial buses to display in the Lister, or whether the Lister is off. "ON" or "1" is the same as "SBUS1". When set to "ALL", the decode information for different buses is interleaved in time. Serial bus decode must be on before it can be displayed in the Lister.
18 :LISTer Commands :LISTer:REFerence (see page 792) Command Syntax :LISTer:REFerence ::= {TRIGger | PREVious} The :LISTer:REFerence command selects whether the time value for a Lister row is relative to the trigger ot the previous Lister row. Query Syntax :LISTer:REFerence? The :LISTer:REFerence? query returns the Lister time reference setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 19 :MARKer Commands Set and query the settings of X-axis markers (X1 and X2 cursors) and the Y-axis markers (Y1 and Y2 cursors). See "Introduction to :MARKer Commands" on page 318.
19 :MARKer Commands Table 69 :MARKer Commands Summary (continued) Command Query Options and Query Returns :MARKer:XUNits (see page 325) :MARKer:XUNits? (see page 325) ::= {SEConds | HERTz | DEGRees | PERCent} :MARKer:XUNits:USE (see page 326) n/a n/a :MARKer:Y1Position [suffix] (see page 327) :MARKer:Y1Position? (see page 327) ::= Y1 cursor position value in NR3 format [suffix] ::= {V | mV | dB} ::= Y1 cursor position value in NR3 format :MARKe
:MARKer Commands 19 :MARKer:MODE (see page 792) Command Syntax :MARKer:MODE ::= {OFF | MEASurement | MANual | WAVeform} The :MARKer:MODE command sets the cursors mode: • OFF — removes the cursor information from the display. • MANual — enables manual placement of the X and Y cursors. If the front-panel cursors are off, or are set to the front-panel Hex or Binary mode, setting :MARKer:MODE MANual will put the cursors in the front-panel Normal mode.
19 :MARKer Commands :MARKer:X1Position (see page 792) Command Syntax :MARKer:X1Position [suffix] ::= X1 cursor position in NR3 format ::= {s | ms | us | ns | ps | Hz | kHz | MHz} The :MARKer:X1Position command: • Sets :MARKer:MODE to MANual if it is not currently set to WAVeform (see ":MARKer:MODE" on page 319). • Sets the X1 cursor position to the specified value. X cursor units are set by the :MARKer:XUNits command.
:MARKer Commands 19 :MARKer:X1Y1source (see page 792) Command Syntax :MARKer:X1Y1source ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= {1 | 2} The :MARKer:X1Y1source command sets the source for the cursors. The channel you specify must be enabled for cursors to be displayed. If the channel or function is not on, an error message is issued.
19 :MARKer Commands :MARKer:X2Position (see page 792) Command Syntax :MARKer:X2Position [suffix] ::= X2 cursor position in NR3 format ::= {s | ms | us | ns | ps | Hz | kHz | MHz} The :MARKer:X2Position command: • Sets :MARKer:MODE to MANual if it is not currently set to WAVeform (see ":MARKer:MODE" on page 319). • Sets the X2 cursor position to the specified value. X cursor units are set by the :MARKer:XUNits command.
:MARKer Commands 19 :MARKer:X2Y2source (see page 792) Command Syntax :MARKer:X2Y2source ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= {1 | 2} The :MARKer:X2Y2source command sets the source for the cursors. The channel you specify must be enabled for cursors to be displayed. If the channel or function is not on, an error message is issued.
19 :MARKer Commands :MARKer:XDELta (see page 792) Query Syntax :MARKer:XDELta? The MARKer:XDELta? query returns the value difference between the current X1 and X2 cursor positions. Xdelta = (Value at X2 cursor) - (Value at X1 cursor) X cursor units are set by the :MARKer:XUNits command. NOTE Return Format If the front-panel cursors are off, the marker position values are not defined. Make sure to set :MARKer:MODE to MANual or WAVeform to put the cursors in the front-panel Normal mode.
:MARKer Commands 19 :MARKer:XUNits (see page 792) Command Syntax :MARKer:XUNits ::= {SEConds | HERTz | DEGRees | PERCent} The :MARKer:XUNits command sets the X cursors units: • SEConds — for making time measurements. • HERTz — for making frequency measurements. • DEGRees — for making phase measurements. Use the :MARKer:XUNits:USE command to set the current X1 location as 0 degrees and the current X2 location as 360 degrees. • PERCent — for making ratio measurements.
19 :MARKer Commands :MARKer:XUNits:USE (see page 792) Command Syntax :MARKer:XUNits:USE When DEGRees is selected for :MARKer:XUNits, the :MARKer:XUNits:USE command sets the current X1 location as 0 degrees and the current X2 location as 360 degrees. When PERCent is selected for :MARKer:XUNits, the :MARKer:XUNits:USE command sets the current X1 location as 0 percent and the current X2 location as 100 percent.
:MARKer Commands 19 :MARKer:Y1Position (see page 792) Command Syntax :MARKer:Y1Position [suffix] ::= Y1 cursor position in NR3 format ::= {mV | V | dB} If the :MARKer:MODE is not currently set to WAVeform (see ":MARKer:MODE" on page 319), the :MARKer:Y1Position command: • Sets :MARKer:MODE to MANual. • Sets the Y1 cursor position to the specified value. Y cursor units are set by the :MARKer:YUNits command.
19 :MARKer Commands :MARKer:Y2Position (see page 792) Command Syntax :MARKer:Y2Position [suffix] ::= Y2 cursor position in NR3 format ::= {mV | V | dB} If the :MARKer:MODE is not currently set to WAVeform (see ":MARKer:MODE" on page 319), the :MARKer:Y1Position command: • Sets :MARKer:MODE to MANual. • Sets the Y2 cursor position to the specified value. Y cursor units are set by the :MARKer:YUNits command.
:MARKer Commands 19 :MARKer:YDELta (see page 792) Query Syntax :MARKer:YDELta? The :MARKer:YDELta? query returns the value difference between the current Y1 and Y2 cursor positions. Ydelta = (Value at Y2 cursor) - (Value at Y1 cursor) NOTE If the front-panel cursors are off or are set to Binary or Hex Mode, the marker position values are not defined. Make sure to set :MARKer:MODE to MANual or WAVeform to put the cursors in the front-panel Normal mode.
19 :MARKer Commands :MARKer:YUNits (see page 792) Command Syntax :MARKer:YUNits ::= {BASE | PERCent} The :MARKer:YUNits command sets the Y cursors units: • BASE — for making measurements in the units associated with the cursors source. • PERCent — for making ratio measurements. Use the :MARKer:YUNits:USE command to set the current Y1 location as 0 percent and the current Y2 location as 100 percent.
:MARKer Commands 19 :MARKer:YUNits:USE (see page 792) Command Syntax :MARKer:YUNits:USE When PERCent is selected for :MARKer:YUNits, the :MARKer:YUNits:USE command sets the current Y1 location as 0 percent and the current Y2 location as 100 percent. Once the 0 and 100 percent locations are set, inputs to and outputs from the :MARKer:Y1Position, :MARKer:Y2Position, and :MARKer:YDELta commands/queries are relative to the set locations.
19 :MARKer Commands 332 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 20 :MEASure Commands Select automatic measurements to be made and control time markers. See "Introduction to :MEASure Commands" on page 340.
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:DUTYcycle [] (see page 349) :MEASure:DUTYcycle? [] (see page 349) ::= {CHANnel | FUNCtion | MATH | WMEMory} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= ratio
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:NWIDth [] (see page 352) :MEASure:NWIDth? [] (see page 352) ::= {CHANnel | FUNCtion | MATH | WMEMory} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format ::= negative pu
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:PREShoot [] (see page 357) :MEASure:PREShoot? [] (see page 357) ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= the percent of preshoot of the selected waveform in NR3 format :MEASure:PWIDth [] (see page 358) :MEASure:PWIDth? [] (see page 358)
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:SOURce [,] (see page 361) :MEASure:SOURce? (see page 361) ::= {CHANnel | FUNCtion | MATH | WMEMory | EXTernal} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory | EXTernal} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format <
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns n/a :MEASure:TVALue? , [] [,] (see page 365) ::= voltage level that the waveform must cross. ::= direction of the waveform when is crossed. ::= transitions reported.
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns :MEASure:VMAX [] (see page 370) :MEASure:VMAX? [] (see page 370) ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= maximum voltage of the selected waveform in NR3 format :MEASure:VMIN [] (see page 371) :MEASure:VMIN? [] (see page 371) ::= {CHANnel | F
20 :MEASure Commands Table 70 :MEASure Commands Summary (continued) Command Query Options and Query Returns n/a :MEASure:VTIMe? [,] (see page 374) ::= displayed time from trigger in seconds in NR3 format ::= {CHANnel | FUNCtion | MATH | WMEMory} for DSO models ::= {CHANnel | DIGital | FUNCtion | MATH | WMEMory} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 form
20 :MEASure Commands If a measurement cannot be made (typically because the proper portion of the waveform is not displayed), the value +9.9E+37 is returned for that measurement. Making Measurements If more than one waveform, edge, or pulse is displayed, time measurements are made on the portion of the displayed waveform closest to the trigger reference (left, center, or right).
20 :MEASure Commands :MEASure:ALL (see page 792) Command Syntax :MEASure:ALL This command installs a Snapshot All measurement on the screen.
:MEASure Commands 20 :MEASure:CLEar (see page 792) Command Syntax :MEASure:CLEar This command clears all selected measurements and markers from the screen.
20 :MEASure Commands :MEASure:DEFine (see page 792) Command Syntax :MEASure:DEFine ::= {DELay | THResholds} The :MEASure:DEFine command sets up the definition for measurements by specifying the delta time or threshold values. Changing these values may affect the results of other measure commands. The table below identifies which measurement results that can be affected by redefining the DELay specification or the THResholds values.
:MEASure Commands 20 This command defines the behavior of the :MEASure:DELay? query by specifying the start and stop edge to be used. specifies the slope and edge number on source1. specifies the slope and edge number on source2.
20 :MEASure Commands for = THResholds and = PERCent: THR,PERC,,, , , ::= A number specifying the upper, middle, and lower threshold percentage values between Vbase and Vtop in NR3 format. for = THResholds and = ABSolute: THR,ABS,,, , , ::= A number specifying the upper, middle, and lower threshold voltages in NR3 format.
:MEASure Commands 20 :MEASure:DELay (see page 792) Command Syntax :MEASure:DELay [][,] , ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:DELay command places the instrument in the continuous measurement mode and starts a delay measurement.
20 :MEASure Commands Return Format ::= floating-point number delay time in seconds in NR3 format See Also 348 • "Introduction to :MEASure Commands" on page 340 • ":MEASure:DEFine" on page 344 • ":MEASure:PHASe" on page 356 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:MEASure Commands 20 :MEASure:DUTYcycle (see page 792) Command Syntax :MEASure:DUTYcycle [] ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:DUTYcycle command installs a screen measurement and starts a duty cycle measurement on the current :MEASure:SOURce.
20 :MEASure Commands :MEASure:FALLtime (see page 792) Command Syntax :MEASure:FALLtime [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:FALLtime command installs a screen measurement and starts a fall-time measurement. For highest measurement accuracy, set the sweep speed as fast as possible, while leaving the falling edge of the waveform on the display.
:MEASure Commands 20 :MEASure:FREQuency (see page 792) Command Syntax :MEASure:FREQuency [] ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:FREQuency command installs a screen measurement and starts a frequency measurement.
20 :MEASure Commands :MEASure:NWIDth (see page 792) Command Syntax :MEASure:NWIDth [] ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:NWIDth command installs a screen measurement and starts a negative pulse width measurement.
:MEASure Commands 20 :MEASure:OVERshoot (see page 792) Command Syntax :MEASure:OVERshoot [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:OVERshoot command installs a screen measurement and starts an overshoot measurement. If the optional source parameter is specified, the current source is modified. NOTE Query Syntax This command is not available if the source is FFT (Fast Fourier Transform).
20 :MEASure Commands 354 • ":MEASure:VTOP" on page 375 • ":MEASure:VBASe" on page 369 • ":MEASure:VMIN" on page 371 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:MEASure Commands 20 :MEASure:PERiod (see page 792) Command Syntax :MEASure:PERiod [] ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:PERiod command installs a screen measurement and starts the period measurement.
20 :MEASure Commands :MEASure:PHASe (see page 792) Command Syntax :MEASure:PHASe [][,] , ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:PHASe command places the instrument in the continuous measurement mode and starts a phase measurement. Query Syntax :MEASure:PHASe? [][,] The :MEASure:PHASe? query measures and returns the phase between the specified sources.
:MEASure Commands 20 :MEASure:PREShoot (see page 792) Command Syntax :MEASure:PREShoot [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:PREShoot command installs a screen measurement and starts a preshoot measurement. If the optional source parameter is specified, the current source is modified.
20 :MEASure Commands :MEASure:PWIDth (see page 792) Command Syntax :MEASure:PWIDth [] ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:PWIDth command installs a screen measurement and starts the positive pulse width measurement.
:MEASure Commands 20 :MEASure:RISetime (see page 792) Command Syntax :MEASure: RISetime [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:RISetime command installs a screen measurement and starts a rise-time measurement. If the optional source parameter is specified, the current source is modified. NOTE Query Syntax This command is not available if the source is FFT (Fast Fourier Transform).
20 :MEASure Commands :MEASure:SHOW (see page 792) Command Syntax :MEASure:SHOW ::= {1 | ON} The :MEASure:SHOW command enables markers for tracking measurements on the display. This feature is always on. Query Syntax :MEASure:SHOW? The :MEASure:SHOW? query returns the current state of the markers.
20 :MEASure Commands :MEASure:SOURce (see page 792) Command Syntax :MEASure:SOURce [,] , ::= { | CHANnel | FUNCtion | MATH | WMEMory | EXTernal} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:SOURce command sets the default sources for measurements.
20 :MEASure Commands Example Code ' MEASURE - The commands in the MEASURE subsystem are used to make ' measurements on displayed waveforms. myScope.WriteString ":MEASURE:SOURCE CHANNEL1" ' Source to measure. myScope.WriteString ":MEASURE:FREQUENCY?" ' Query for frequency. varQueryResult = myScope.ReadNumber ' Read frequency. MsgBox "Frequency:" + vbCrLf _ + FormatNumber(varQueryResult / 1000, 4) + " kHz" myScope.WriteString ":MEASURE:DUTYCYCLE?" ' Query for duty cycle. varQueryResult = myScope.
:MEASure Commands 20 :MEASure:TEDGe (see page 792) Query Syntax :MEASure:TEDGe? [,] ::= direction of the waveform. A rising slope is indicated by a space or plus sign (+). A falling edge is indicated by a minus sign (-). ::= the transition to be reported. If the occurrence number is one, the first crossing from the left screen edge is reported. If the number is two, the second crossing is reported, etc.
20 :MEASure Commands NOTE Return Format This query is not available if the source is FFT (Fast Fourier Transform). ::= time in seconds of the specified transition in NR3 format :MEASure:TEDGe Code ' Make a delay measurement between channel 1 and 2. Dim dblChan1Edge1 As Double Dim dblChan2Edge1 As Double Dim dblChan1Edge2 As Double Dim dblDelay As Double Dim dblPeriod As Double Dim dblPhase As Double ' Query time at 1st rising edge on ch1. myScope.
:MEASure Commands 20 :MEASure:TVALue (see page 792) Query Syntax :MEASure:TVALue? , [][,] ::= the vertical value that the waveform must cross. The value can be volts or a math function value such as dB, Vs, or V/s. ::= direction of the waveform. A rising slope is indicated by a plus sign (+). A falling edge is indicated by a minus sign (-). ::= the transition to be reported. If the occurrence number is one, the first crossing is reported.
20 :MEASure Commands See Also 366 • "Introduction to :MEASure Commands" on page 340 • ":MEASure:TEDGe" on page 363 • ":MEASure:VTIMe" on page 374 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:MEASure Commands 20 :MEASure:VAMPlitude (see page 792) Command Syntax :MEASure:VAMPlitude [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VAMPlitude command installs a screen measurement and starts a vertical amplitude measurement. If the optional source parameter is specified, the current source is modified.
20 :MEASure Commands :MEASure:VAVerage (see page 792) Command Syntax :MEASure:VAVerage [][,][] ::= {CYCLe | DISPlay} ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1-2 or 1-4 (# of analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VAVerage command installs a screen measurement and starts an average value measurement. If the optional source parameter is specified, the current source is modified.
:MEASure Commands 20 :MEASure:VBASe (see page 792) Command Syntax :MEASure:VBASe [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VBASe command installs a screen measurement and starts a waveform base value measurement. If the optional source parameter is specified, the current source is modified. NOTE Query Syntax This command is not available if the source is FFT (Fast Fourier Transform).
20 :MEASure Commands :MEASure:VMAX (see page 792) Command Syntax :MEASure:VMAX [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1-2 or 1-4 (# of analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VMAX command installs a screen measurement and starts a maximum vertical value measurement. If the optional source parameter is specified, the current source is modified.
:MEASure Commands 20 :MEASure:VMIN (see page 792) Command Syntax :MEASure:VMIN [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VMIN command installs a screen measurement and starts a minimum vertical value measurement. If the optional source parameter is specified, the current source is modified.
20 :MEASure Commands :MEASure:VPP (see page 792) Command Syntax :MEASure:VPP [] ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VPP command installs a screen measurement and starts a vertical peak-to-peak measurement. If the optional source parameter is specified, the current source is modified.
20 :MEASure Commands :MEASure:VRMS (see page 792) Command Syntax :MEASure:VRMS [][,][][,][] ::= {CYCLe | DISPlay} ::= {AC | DC} ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1-2 or 1-4 (# of analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VRMS command installs a screen measurement and starts an RMS value measurement. If the optional source parameter is specified, the current source is modified.
20 :MEASure Commands :MEASure:VTIMe (see page 792) Query Syntax :MEASure:VTIMe? [,] ::= time from trigger in seconds ::= { | CHANnel | FUNCtion | MATH | WMEMory} ::= DIGital for the MSO models ::= 1 to (# of analog channels) in NR1 format ::= 1-2 in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :MEASure:VTIMe? query returns the value at a specified time on the source specified with
:MEASure Commands 20 :MEASure:VTOP (see page 792) Command Syntax :MEASure:VTOP [] ::= {CHANnel | FUNCtion | MATH} ::= 1-2 or 1-4 (# of analog channels) in NR1 format ::= 1-2 in NR1 format The :MEASure:VTOP command installs a screen measurement and starts a waveform top value measurement. NOTE Query Syntax This query is not available if the source is FFT (Fast Fourier Transform).
20 :MEASure Commands :MEASure:WINDow (see page 792) Command Syntax :MEASure:WINDow ::= {MAIN | ZOOM | AUTO} When the zoomed time base is displayed, the :MEASure:WINDow command lets you specify the measurement window: Query Syntax • MAIN — the measurement window is the upper, Main window. • ZOOM — the measurement window is the lower, Zoom window. • AUTO — the measurement is attempted in the lower, Zoom window; if it cannot be made there, the upper, Main window is used.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 21 :MTESt Commands The MTESt subsystem commands and queries control the mask test features. See "Introduction to :MTESt Commands" on page 379.
21 :MTESt Commands Table 71 :MTESt Commands Summary (continued) Command Query Options and Query Returns :MTESt:DELete (see page 393) n/a n/a :MTESt:ENABle {{0 | OFF} | {1 | ON}} (see page 394) :MTESt:ENABle? (see page 394) {0 | 1} :MTESt:LOCK {{0 | OFF} | {1 | ON}} (see page 395) :MTESt:LOCK? (see page 395) {0 | 1} :MTESt:RMODe (see page 396) :MTESt:RMODe? (see page 396) ::= {FORever | TIME | SIGMa | WAVeforms} :MTESt:RMODe:FACTion: MEASure {{0 | OFF} | {1 | ON}} (see page 39
21 :MTESt Commands Table 71 :MTESt Commands Summary (continued) Command Query Options and Query Returns :MTESt:SCALe:Y1 (see page 407) :MTESt:SCALe:Y1? (see page 407) ::= Y1 value in NR3 format :MTESt:SCALe:Y2 (see page 408) :MTESt:SCALe:Y2? (see page 408) ::= Y2 value in NR3 format :MTESt:SOURce (see page 409) :MTESt:SOURce? (see page 409) ::= {CHANnel | NONE} ::= {1 | 2 | 3 | 4} for 4ch models ::= {1 | 2} for 2ch models
21 :MTESt Commands On Error GoTo VisaComError ' Create the VISA COM I/O resource. Set myMgr = New VisaComLib.ResourceManager Set myScope = New VisaComLib.FormattedIO488 Set myScope.IO = _ myMgr.Open("USB0::0x0957::0x17A6::US50210029::0::INSTR") myScope.IO.Clear ' Clear the interface. ' Make sure oscilloscope is running. myScope.WriteString ":RUN" ' Set mask test termination conditions. myScope.WriteString ":MTESt:RMODe SIGMa" myScope.WriteString ":MTESt:RMODe?" strQueryResult = myScope.ReadString Debug.
:MTESt Commands 21 Dim lngElapsed As Long lngTimeout = 60000 ' 60 seconds. ' Wait until mask is created. lngElapsed = 0 Do While lngElapsed <= lngTimeout myScope.WriteString ":OPERegister:CONDition?" varQueryResult = myScope.ReadNumber ' Operation Status Condition Register MTE bit (bit 9, &H200). If (varQueryResult And &H200) <> 0 Then Exit Do Else Sleep 100 ' Small wait to prevent excessive queries. lngElapsed = lngElapsed + 100 End If Loop ' Look for RUN bit = stopped (mask test termination).
21 :MTESt Commands :MTESt:ALL (see page 792) Command Syntax :MTESt:ALL ::= {{1 | ON} | {0 | OFF}} The :MTESt:ALL command specifies the channel(s) that are included in the mask test: Query Syntax • ON — All displayed analog channels are included in the mask test. • OFF — Just the selected source channel is included in the test. :MTESt:ENABle? The :MTESt:ENABle? query returns the current setting.
:MTESt Commands 21 :MTESt:AMASk:CREate (see page 792) Command Syntax :MTESt:AMASk:CREate The :MTESt:AMASk:CREate command automatically constructs a mask around the current selected channel, using the tolerance parameters defined by the :MTESt:AMASk:XDELta, :MTESt:AMASk:YDELta, and :MTESt:AMASk:UNITs commands. The mask only encompasses the portion of the waveform visible on the display, so you must ensure that the waveform is acquired and displayed consistently to obtain repeatable results.
21 :MTESt Commands :MTESt:AMASk:SOURce (see page 792) Command Syntax :MTESt:AMASk:SOURce ::= CHANnel ::= 1 to (# analog channels) in NR1 format The :MTESt:AMASk:SOURce command selects the source for the interpretation of the :MTESt:AMASk:XDELta and :MTESt:AMASk:YDELta parameters when :MTESt:AMASk:UNITs is set to CURRent.
21 :MTESt Commands :MTESt:AMASk:UNITs (see page 792) Command Syntax :MTESt:AMASk:UNITs ::= {CURRent | DIVisions} The :MTESt:AMASk:UNITs command alters the way the mask test subsystem interprets the tolerance parameters for automasking as defined by :MTESt:AMASk:XDELta and :MTESt:AMASk:YDELta commands. Query Syntax • CURRent — the mask test subsystem uses the units as set by the :CHANnel:UNITs command, usually time for ΔX and voltage for ΔY.
21 :MTESt Commands :MTESt:AMASk:XDELta (see page 792) Command Syntax :MTESt:AMASk:XDELta ::= X delta value in NR3 format The :MTESt:AMASk:XDELta command sets the tolerance in the X direction around the waveform for the automasking feature. The absolute value of the tolerance will be added and subtracted to horizontal values of the waveform to determine the boundaries of the mask.
:MTESt Commands 21 :MTESt:AMASk:YDELta (see page 792) Command Syntax :MTESt:AMASk:YDELta ::= Y delta value in NR3 format The :MTESt:AMASk:YDELta command sets the vertical tolerance around the waveform for the automasking feature. The absolute value of the tolerance will be added and subtracted to vertical values of the waveform to determine the boundaries of the mask.
21 :MTESt Commands :MTESt:COUNt:FWAVeforms (see page 792) Query Syntax :MTESt:COUNt:FWAVeforms? [CHANnel] ::= 1 to (# analog channels) in NR1 format The :MTESt:COUNt:FWAVeforms? query returns the total number of failed waveforms in the current mask test run. This count is for all regions and all waveforms collected on the channel specified by the optional parameter or collected on the currently specified source channel (:MTESt:SOURce) if there is no parameter.
:MTESt Commands 21 :MTESt:COUNt:RESet (see page 792) Command Syntax :MTESt:COUNt:RESet The :MTESt:COUNt:RESet command resets the mask statistics.
21 :MTESt Commands :MTESt:COUNt:TIME (see page 792) Query Syntax :MTESt:COUNt:TIME? The :MTESt:COUNt:TIME? query returns the elapsed time in the current mask test run. Return Format ::= elapsed seconds in NR3 format.
:MTESt Commands 21 :MTESt:COUNt:WAVeforms (see page 792) Query Syntax :MTESt:COUNt:WAVeforms? The :MTESt:COUNt:WAVeforms? query returns the total number of waveforms acquired in the current mask test run. Return Format ::= number of waveforms in NR1 format.
21 :MTESt Commands :MTESt:DATA (see page 792) Command Syntax :MTESt:DATA ::= binary block data in IEEE 488.2 # format. The :MTESt:DATA command loads a mask from binary block data. These are the data bytes found in a *.msk file. Query Syntax :MTESt:DATA? The :MTESt:DATA? query returns a mask in binary block data format. The format for the data transmission is the # definite-length format defined in the IEEE 488.2 specification.
:MTESt Commands 21 :MTESt:DELete (see page 792) Command Syntax :MTESt:DELete The :MTESt:DELete command clears the currently loaded mask.
21 :MTESt Commands :MTESt:ENABle (see page 792) Command Syntax :MTESt:ENABle ::= {{1 | ON} | {0 | OFF}} The :MTESt:ENABle command enables or disables the mask test features. Query Syntax • ON — Enables the mask test features. • OFF — Disables the mask test features. :MTESt:ENABle? The :MTESt:ENABle? query returns the current state of mask test features.
:MTESt Commands 21 :MTESt:LOCK (see page 792) Command Syntax :MTESt:LOCK ::= {{1 | ON} | {0 | OFF}} The :MTESt:LOCK command enables or disables the mask lock feature: Query Syntax • ON — Locks a mask to the SOURce. As the vertical or horizontal scaling or position of the SOURce changes, the mask is redrawn accordingly. • OFF — The mask is static and does not move. :MTESt:LOCK? The :MTESt:LOCK? query returns the current mask lock setting.
21 :MTESt Commands :MTESt:RMODe (see page 792) Command Syntax :MTESt:RMODe ::= {FORever | SIGMa | TIME | WAVeforms} The :MTESt:RMODe command specifies the termination conditions for the mask test: Query Syntax • FORever — the mask test runs until it is turned off. • SIGMa — the mask test runs until the Sigma level is reached. This level is set by the ":MTESt:RMODe:SIGMa" on page 401 command. • TIME — the mask test runs for a fixed amount of time.
:MTESt Commands 21 :MTESt:RMODe:FACTion:MEASure (see page 792) Command Syntax :MTESt:RMODe:FACTion:MEASure ::= {{1 | ON} | {0 | OFF}} The :MTESt:RMODe:FACTion:MEASure command sets measuring only mask failures on or off. When ON, measurements and measurement statistics run only on waveforms that contain a mask violation; passing waveforms do not affect measurements and measurement statistics. This mode is not available when the acquisition mode is set to Averaging.
21 :MTESt Commands :MTESt:RMODe:FACTion:PRINt (see page 792) Command Syntax :MTESt:RMODe:FACTion:PRINt ::= {{1 | ON} | {0 | OFF}} The :MTESt:RMODe:FACTion:PRINt command sets printing on mask failures on or off. NOTE Setting :MTESt:RMODe:FACTion:PRINt ON automatically sets :MTESt:RMODe:FACTion:SAVE OFF. See Chapter 17, “:HARDcopy Commands,” starting on page 295 for more information on setting the hardcopy device and formatting options.
21 :MTESt Commands :MTESt:RMODe:FACTion:SAVE (see page 792) Command Syntax :MTESt:RMODe:FACTion:SAVE ::= {{1 | ON} | {0 | OFF}} The :MTESt:RMODe:FACTion:SAVE command sets saving on mask failures on or off. NOTE Setting :MTESt:RMODe:FACTion:SAVE ON automatically sets :MTESt:RMODe:FACTion:PRINt OFF. See Chapter 24, “:SAVE Commands,” starting on page 425 for more information on save options.
21 :MTESt Commands :MTESt:RMODe:FACTion:STOP (see page 792) Command Syntax :MTESt:RMODe:FACTion:STOP ::= {{1 | ON} | {0 | OFF}} The :MTESt:RMODe:FACTion:STOP command sets stopping on a mask failure on or off. When this setting is ON and a mask violation is detected, the mask test is stopped and the acquisition system is stopped. Query Syntax :MTESt:RMODe:FACTion:STOP? The :MTESt:RMODe:FACTion:STOP? query returns the current mask failure stop setting.
:MTESt Commands 21 :MTESt:RMODe:SIGMa (see page 792) Command Syntax :MTESt:RMODe:SIGMa ::= from 0.1 to 9.3 in NR3 format When the :MTESt:RMODe command is set to SIGMa, the :MTESt:RMODe:SIGMa command sets the test sigma level to which a mask test runs. Test sigma is the best achievable process sigma, assuming no failures. (Process sigma is calculated using the number of failures per test.
21 :MTESt Commands :MTESt:RMODe:TIME (see page 792) Command Syntax :MTESt:RMODe:TIME ::= from 1 to 86400 in NR3 format When the :MTESt:RMODe command is set to TIME, the :MTESt:RMODe:TIME command sets the number of seconds for a mask test to run. Query Syntax :MTESt:RMODe:TIME? The :MTESt:RMODe:TIME? query returns the number of seconds currently set.
:MTESt Commands 21 :MTESt:RMODe:WAVeforms (see page 792) Command Syntax :MTESt:RMODe:WAVeforms ::= number of waveforms in NR1 format from 1 to 2,000,000,000 When the :MTESt:RMODe command is set to WAVeforms, the :MTESt:RMODe:WAVeforms command sets the number of waveform acquisitions that are mask tested. Query Syntax :MTESt:RMODe:WAVeforms? The :MTESt:RMODe:WAVeforms? query returns the number of waveforms currently set.
21 :MTESt Commands :MTESt:SCALe:BIND (see page 792) Command Syntax :MTESt:SCALe:BIND ::= {{1 | ON} | {0 | OFF}} The :MTESt:SCALe:BIND command enables or disables Bind 1 & 0 Levels (Bind -1 & 0 Levels for inverted masks) control: • ON — If the Bind 1 & 0 Levels control is enabled, the 1 Level and the 0 Level controls track each other. Adjusting either the 1 Level or the 0 Level control shifts the position of the mask up or down without changing its size.
:MTESt Commands 21 :MTESt:SCALe:X1 (see page 792) Command Syntax :MTESt:SCALe:X1 ::= X1 value in NR3 format The :MTESt:SCALe:X1 command defines where X=0 in the base coordinate system used for mask testing. The other X-coordinate is defined by the :MTESt:SCALe:XDELta command.
21 :MTESt Commands :MTESt:SCALe:XDELta (see page 792) Command Syntax :MTESt:SCALe:XDELta ::= X delta value in NR3 format The :MTESt:SCALe:XDELta command defines the position of the X2 marker with respect to the X1 marker. In the mask test coordinate system, the X1 marker defines where X=0; thus, the X2 marker defines where X=1.
:MTESt Commands 21 :MTESt:SCALe:Y1 (see page 792) Command Syntax :MTESt:SCALe:Y1 ::= Y1 value in NR3 format The :MTESt:SCALe:Y1 command defines where Y=0 in the coordinate system for mask testing. All Y values of vertices in the coordinate system are defined with respect to the boundaries set by SCALe:Y1 and SCALe:Y2 according to the equation: Y = (Y * (Y2 - Y1)) + Y1 Thus, if you set Y1 to 100 mV, and Y2 to 1 V, a Y value of 0.100 in a vertex is at 190 mV.
21 :MTESt Commands :MTESt:SCALe:Y2 (see page 792) Command Syntax :MTESt:SCALe:Y2 ::= Y2 value in NR3 format The :MTESt:SCALe:Y2 command defines the Y2 marker in the coordinate system for mask testing. All Y values of vertices in the coordinate system are defined with respect to the boundaries defined by SCALe:Y1 and SCALe:Y2 according to the following equation: Y = (Y * (Y2 - Y1)) + Y1 Thus, if you set Y1 to 100 mV, and Y2 to 1 V, a Y value of 0.100 in a vertex is at 190 mV.
:MTESt Commands 21 :MTESt:SOURce (see page 792) Command Syntax :MTESt:SOURce ::= CHANnel ::= 1 to (# analog channels) in NR1 format The :MTESt:SOURce command selects the channel which is configured by the commands contained in a mask file when it is loaded. Query Syntax :MTESt:SOURce? The :MTESt:SOURce? query returns the channel which is configured by the commands contained in the current mask file.
21 :MTESt Commands :MTESt:TITLe (see page 792) Query Syntax :MTESt:TITLe? The :MTESt:TITLe? query returns the mask title which is a string of up to 128 characters. The title is displayed in the mask test dialog box and mask test tab when a mask file is loaded. Return Format
::= a string of up to 128 ASCII characters.Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 22 :POD Commands Control all oscilloscope functions associated with groups of digital channels. See "Introduction to :POD Commands" on page 411.
22 :POD Commands The following is a sample response from the :POD1? query. In this case, the query was issued following a *RST command. :POD1:DISP 0;THR 1.
22 :POD Commands :POD:DISPlay (see page 792) Command Syntax :POD:DISPlay ::= {{1 | ON} | {0 | OFF}} ::= An integer, 1, is attached as a suffix to the command and defines the group of channels that are affected by the command. POD1 ::= D0-D7 The :POD:DISPlay command turns displaying of the specified group of channels on or off. NOTE Query Syntax This command is only valid for the MSO models.
22 :POD Commands :POD:SIZE (see page 792) Command Syntax :POD:SIZE ::= An integer, 1, is attached as a suffix to the command and defines the group of channels that are affected by the command. POD1 ::= D0-D7 ::= {SMALl | MEDium | LARGe} The :POD:SIZE command specifies the size of digital channels on the display. NOTE Query Syntax This command is only valid for the MSO models. :POD:SIZE? The :POD:SIZE? query returns the digital channels size setting.
22 :POD Commands :POD:THReshold (see page 792) Command Syntax :POD:THReshold [] ::= An integer, 1, is attached as a suffix to the command and defines the group of channels that are affected by the command. ::= {CMOS | ECL | TTL | } ::= -8.00 to +8.00 in NR3 format ::= {V | mV | uV} POD1 ::= D0-D7 TTL ::= 1.4V CMOS ::= 2.5V ECL ::= -1.3V The :POD:THReshold command sets the threshold for the specified group of channels.
22 :POD Commands ' Set external channel to TTL threshold (short form). myScope.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 23 :RECall Commands Recall previously saved oscilloscope setups, reference waveforms, and masks.
23 :RECall Commands Return Format The following is a sample response from the :RECall? query. In this case, the query was issued following the *RST command.
23 :RECall Commands :RECall:FILename (see page 792) Command Syntax :RECall:FILename ::= quoted ASCII string The :RECall:FILename command specifies the source for any RECall operations. NOTE Query Syntax This command specifies a file's base name only, without path information or an extension. :RECall:FILename? The :RECall:FILename? query returns the current RECall filename.
23 :RECall Commands :RECall:MASK[:STARt] (see page 792) Command Syntax :RECall:MASK[:STARt] [] ::= { | } ::= 0-3; an integer in NR1 format ::= quoted ASCII string The :RECall:MASK[:STARt] command recalls a mask. NOTE See Also 420 If a file extension is provided as part of a specified , it must be ".msk".
:RECall Commands 23 :RECall:PWD (see page 792) Command Syntax :RECall:PWD ::= quoted ASCII string The :RECall:PWD command sets the present working directory for recall operations. Query Syntax :RECall:PWD? The :RECall:PWD? query returns the currently set working directory for recall operations.
23 :RECall Commands :RECall:SETup[:STARt] (see page 792) Command Syntax :RECall:SETup[:STARt] [] ::= { | } ::= 0-9; an integer in NR1 format ::= quoted ASCII string The :RECall:SETup[:STARt] command recalls an oscilloscope setup. NOTE See Also 422 If a file extension is provided as part of a specified , it must be ".scp".
:RECall Commands 23 :RECall:WMEMory[:STARt] (see page 792) Command Syntax :RECall:WMEMory[:STARt] [] ::= 1-2 in NR1 format ::= quoted ASCII string The :RECall:WMEMory[:STARt] command recalls a reference waveform. NOTE See Also If a file extension is provided as part of a specified , it must be ".h5".
23 :RECall Commands 424 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 24 :SAVE Commands Save oscilloscope setups, screen images, and data. See "Introduction to :SAVE Commands" on page 427.
24 :SAVE Commands Table 74 :SAVE Commands Summary (continued) Command Query Options and Query Returns :SAVE:MULTi[:STARt] [] (see page 436) n/a ::= quoted ASCII string :SAVE:PWD (see page 437) :SAVE:PWD? (see page 437) ::= quoted ASCII string :SAVE:SETup[:STARt] [] (see page 438) n/a ::= { | } ::= 0-9; an integer in NR1 format ::= quoted ASCII string :SAVE:WAVeform[:STARt ]
:SAVE Commands Introduction to :SAVE Commands 24 The :SAVE subsystem provides commands to save oscilloscope setups, screen images, and data. :SAV is an acceptable short form for :SAVE. Reporting the Setup Use :SAVE? to query setup information for the SAVE subsystem. Return Format The following is a sample response from the :SAVE? query. In this case, the query was issued following the *RST command.
24 :SAVE Commands :SAVE:FILename (see page 792) Command Syntax :SAVE:FILename ::= quoted ASCII string The :SAVE:FILename command specifies the source for any SAVE operations. NOTE Query Syntax This command specifies a file's base name only, without path information or an extension. :SAVE:FILename? The :SAVE:FILename? query returns the current SAVE filename.
24 :SAVE Commands :SAVE:IMAGe[:STARt] (see page 792) Command Syntax :SAVE:IMAGe[:STARt] [] ::= quoted ASCII string The :SAVE:IMAGe[:STARt] command saves an image. NOTE Be sure to set the :SAVE:IMAGe:FORMat before saving an image. If the format is NONE, the save image command will not succeed.
24 :SAVE Commands :SAVE:IMAGe:FACTors (see page 792) Command Syntax :SAVE:IMAGe:FACTors ::= {{OFF | 0} | {ON | 1}} The :SAVE:IMAGe:FACTors command controls whether the oscilloscope factors are output along with the image. NOTE Factors are written to a separate file with the same path and base name but with the ".txt" extension. Query Syntax :SAVE:IMAGe:FACTors? The :SAVE:IMAGe:FACTors? query returns a flag indicating whether oscilloscope factors are output along with the image.
:SAVE Commands 24 :SAVE:IMAGe:FORMat (see page 792) Command Syntax :SAVE:IMAGe:FORMat ::= {{BMP | BMP24bit} | BMP8bit | PNG} The :SAVE:IMAGe:FORMat command sets the image format type. Query Syntax :SAVE:IMAGe:FORMat? The :SAVE:IMAGe:FORMat? query returns the selected image format type. Return Format ::= {BMP | BMP8 | PNG | NONE} When NONE is returned, it indicates that a waveform data file format is currently selected.
24 :SAVE Commands :SAVE:IMAGe:INKSaver (see page 792) Command Syntax :SAVE:IMAGe:INKSaver ::= {{OFF | 0} | {ON | 1}} The :SAVE:IMAGe:INKSaver command controls whether the graticule colors are inverted or not. Query Syntax :SAVE:IMAGe:INKSaver? The :SAVE:IMAGe:INKSaver? query returns a flag indicating whether graticule colors are inverted or not.
:SAVE Commands 24 :SAVE:IMAGe:PALette (see page 792) Command Syntax :SAVE:IMAGe:PALette ::= {COLor | GRAYscale} The :SAVE:IMAGe:PALette command sets the image palette color. Query Syntax :SAVE:IMAGe:PALette? The :SAVE:IMAGe:PALette? query returns the selected image palette color.
24 :SAVE Commands :SAVE:LISTer[:STARt] (see page 792) Command Syntax :SAVE:LISTer[:STARt] [] ::= quoted ASCII string The :SAVE:LISTer[:STARt] command saves the Lister display data to a file. NOTE See Also 434 If a file extension is provided as part of a specified , it must be ".csv".
:SAVE Commands 24 :SAVE:MASK[:STARt] (see page 792) Command Syntax :SAVE:MASK[:STARt] [] ::= { | } ::= 0-3; an integer in NR1 format ::= quoted ASCII string The :SAVE:MASK[:STARt] command saves a mask. NOTE See Also If a file extension is provided as part of a specified , it must be ".msk".
24 :SAVE Commands :SAVE:MULTi[:STARt] (see page 792) Command Syntax :SAVE:MULTi[:STARt] [] ::= quoted ASCII string The :SAVE:MULTi[:STARt] command saves multi-channel waveform data to a file. This file can be opened by the N8900A InfiniiView oscilloscope analysis software. NOTE See Also 436 If a file extension is provided as part of a specified , it must be ".h5".
:SAVE Commands 24 :SAVE:PWD (see page 792) Command Syntax :SAVE:PWD ::= quoted ASCII string The :SAVE:PWD command sets the present working directory for save operations. Query Syntax :SAVE:PWD? The :SAVE:PWD? query returns the currently set working directory for save operations.
24 :SAVE Commands :SAVE:SETup[:STARt] (see page 792) Command Syntax :SAVE:SETup[:STARt] [] ::= { | } ::= 0-9; an integer in NR1 format ::= quoted ASCII string The :SAVE:SETup[:STARt] command saves an oscilloscope setup. NOTE See Also 438 If a file extension is provided as part of a specified , it must be ".scp".
24 :SAVE Commands :SAVE:WAVeform[:STARt] (see page 792) Command Syntax :SAVE:WAVeform[:STARt] [] ::= quoted ASCII string The :SAVE:WAVeform[:STARt] command saves oscilloscope waveform data to a file. NOTE Be sure to set the :SAVE:WAVeform:FORMat before saving waveform data. If the format is NONE, the save waveform command will not succeed.
24 :SAVE Commands :SAVE:WAVeform:FORMat (see page 792) Command Syntax :SAVE:WAVeform:FORMat ::= {ASCiixy | CSV | BINary} The :SAVE:WAVeform:FORMat command sets the waveform data format type: Query Syntax • ASCiixy — creates comma-separated value files for each analog channel that is displayed (turned on). The proper file extension for this format is ".csv".
24 :SAVE Commands :SAVE:WAVeform:LENGth (see page 792) Command Syntax :SAVE:WAVeform:LENGth ::= 100 to max. length; an integer in NR1 format When the :SAVE:WAVeform:LENGth:MAX setting is OFF, the :SAVE:WAVeform:LENGth command sets the waveform data length (that is, the number of points saved). When the :SAVE:WAVeform:LENGth:MAX setting is ON, the :SAVE:WAVeform:LENGth setting has no effect.
24 :SAVE Commands :SAVE:WAVeform:LENGth:MAX (see page 792) Command Syntax :SAVE:WAVeform:LENGth:MAX ::= {{OFF | 0} | {ON | 1}} The :SAVE:WAVeform:LENGth:MAX command specifies whether maximum number of waveform data points is saved. When OFF, the :SAVE:WAVeform:LENGth command specifies the number of waveform data points saved. Query Syntax :SAVE:WAVeform:LENGth:MAX? The :SAVE:WAVeform:LENGth:MAX? query returns the current setting.
24 :SAVE Commands :SAVE:WAVeform:SEGMented (see page 792) Command Syntax :SAVE:WAVeform:SEGMented
24 :SAVE Commands :SAVE:WMEMory:SOURce (see page 792) Command Syntax :SAVE:WMEMory:SOURce ::= {CHANnel | FUNCtion | MATH | WMEMory} ::= 1 to (# analog channels) in NR1 format ::= {1 | 2} The :SAVE:WMEMory:SOURce command selects the source to be saved as a reference waveform file. NOTE Only ADD or SUBtract math operations can be saved as reference waveforms. NOTE MATH is an alias for FUNCtion. The query will return FUNC if the source is FUNCtion or MATH.
:SAVE Commands 24 :SAVE:WMEMory[:STARt] (see page 792) Command Syntax :SAVE:WMEMory[:STARt] [] ::= quoted ASCII string The :SAVE:WMEMory[:STARt] command saves oscilloscope waveform data to a reference waveform file. NOTE See Also If a file extension is provided as part of a specified , it must be ".h5".
24 :SAVE Commands 446 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 25 :SBUS Commands Control the modes and parameters for each serial bus decode/trigger type.
25 :SBUS Commands NOTE • SPI (Serial Peripheral Interface) triggering— consists of connecting the oscilloscope to a clock, data (MOSI or MISO), and framing signal. You can then trigger on a data pattern during a specific framing period. The serial data string can be specified to be from 4 to 64 bits long. • UART/RS-232 triggering (with Option 232) — lets you trigger on RS-232 serial data. Two I2S buses or two SPI buses cannot be decoded on both SBUS1 and SBUS2 at the same time.
25 :SBUS Commands General :SBUS Commands Table 75 General :SBUS Commands Summary Command Query Options and Query Returns :SBUS:DISPlay {{0 | OFF} | {1 | ON}} (see page 450) :SBUS:DISPlay? (see page 450) {0 | 1} :SBUS:MODE (see page 451) :SBUS:MODE? (see page 451) ::= {CAN | IIC | LIN | SPI | UART} Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 449
25 :SBUS Commands :SBUS:DISPlay (see page 792) Command Syntax :SBUS:DISPlay ::= {{1 | ON} | {0 | OFF}} The :SBUS:DISPlay command turns displaying of the serial decode bus on or off. NOTE This command is only valid when a serial decode option has been licensed. NOTE Two I2S buses or two SPI buses cannot be decoded on both SBUS1 and SBUS2 at the same time.
:SBUS Commands 25 :SBUS:MODE (see page 792) Command Syntax :SBUS:MODE ::= {CAN | IIC | LIN | SPI | UART} The :SBUS:MODE command determines the decode mode for the serial bus. This command is only valid when a serial decode option has been licensed. NOTE Query Syntax :SBUS:MODE? The :SBUS:MODE? query returns the current serial bus decode mode setting.
25 :SBUS Commands :SBUS:CAN Commands NOTE These commands are valid when the automotive CAN and LIN serial decode option (Option AMS) has been licensed.
25 :SBUS Commands Table 76 :SBUS:CAN Commands Summary (continued) Command Query Options and Query Returns :SBUS:CAN:TRIGger: PATTern:DATA (see page 465) :SBUS:CAN:TRIGger: PATTern:DATA? (see page 465) ::= "nn...n" where n ::= {0 | 1 | X | $}
25 :SBUS Commands :SBUS:CAN:COUNt:ERRor (see page 792) Query Syntax :SBUS:CAN:COUNt:ERRor? Returns the error frame count.
:SBUS Commands 25 :SBUS:CAN:COUNt:OVERload (see page 792) Query Syntax :SBUS:CAN:COUNt:OVERload? Returns the overload frame count.
25 :SBUS Commands :SBUS:CAN:COUNt:RESet (see page 792) Command Syntax :SBUS:CAN:COUNt:RESet Resets the frame counters.
:SBUS Commands 25 :SBUS:CAN:COUNt:TOTal (see page 792) Query Syntax :SBUS:CAN:COUNt:TOTal? Returns the total frame count.
25 :SBUS Commands :SBUS:CAN:COUNt:UTILization (see page 792) Query Syntax :SBUS:CAN:COUNt:UTILization? Returns the percent utilization.
:SBUS Commands 25 :SBUS:CAN:SAMPlepoint (see page 792) Command Syntax :SBUS:CAN:SAMPlepoint ::= {60 | 62.5 | 68 | 70 | 75 | 80 | 87.5} in NR3 format The :SBUS:CAN:SAMPlepoint command sets the point during the bit time where the bit level is sampled to determine whether the bit is dominant or recessive. The sample point represents the percentage of time between the beginning of the bit time to the end of the bit time.
25 :SBUS Commands :SBUS:CAN:SIGNal:BAUDrate (see page 792) Command Syntax :SBUS:CAN:SIGNal:BAUDrate ::= integer from 10000 to 4000000 in 100 b/s increments, or 5000000 The :SBUS:CAN:SIGNal:BAUDrate command sets the standard baud rate of the CAN signal from 10 kb/s to 4 Mb/s in 100 b/s increments. If you enter a baud rate that is not divisible by 100 b/s, the baud rate is set to the nearest baud rate divisible by 100 b/s.
:SBUS Commands 25 :SBUS:CAN:SIGNal:DEFinition (see page 792) Command Syntax :SBUS:CAN:SIGNal:DEFinition ::= {CANH | CANL | RX | TX | DIFFerential | DIFL | DIFH} The :SBUS:CAN:SIGNal:DEFinition command sets the CAN signal type when :SBUS:CAN:TRIGger is set to SOF (start of frame). These signals can be set to: Dominant high signals: • CANH — the actual CAN_H differential bus signal.
25 :SBUS Commands :SBUS:CAN:SOURce (see page 792) Command Syntax :SBUS:CAN:SOURce ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:CAN:SOURce command sets the source for the CAN signal. Query Syntax :SBUS:CAN:SOURce? The :SBUS:CAN:SOURce? query returns the current source for the CAN signal.
25 :SBUS Commands :SBUS:CAN:TRIGger (see page 792) Command Syntax :SBUS:CAN:TRIGger ::= {SOF | DATA | ERRor | IDData | IDEither | IDRemote | ALLerrors | OVERload | ACKerror} The :SBUS:CAN:TRIGger command sets the CAN trigger on condition: • SOF - will trigger on the Start of Frame (SOF) bit of a Data frame, Remote Transfer Request (RTR) frame, or an Overload frame.
25 :SBUS Commands CAN Id specification is set by the :SBUS:CAN:TRIGger:PATTern:ID and:SBUS:CAN:TRIGger:PATTern:ID:MODE commands. CAN Data specification is set by the :SBUS:CAN:TRIGger:PATTern:DATA command. CAN Data Length Code is set by the :SBUS:CAN:TRIGger:PATTern:DATA:LENGth command. Query Syntax :SBUS:CAN:TRIGger? The :SBUS:CAN:TRIGger? query returns the current CAN trigger on condition.
:SBUS Commands 25 :SBUS:CAN:TRIGger:PATTern:DATA (see page 792) Command Syntax :SBUS:CAN:TRIGger:PATTern:DATA ::= "nn...n" where n ::= {0 | 1 | X | $} :CAN:TRIGger:PATTern:DATA command defines the CAN data pattern resource according to the string parameter.
25 :SBUS Commands :SBUS:CAN:TRIGger:PATTern:DATA:LENGth (see page 792) Command Syntax :SBUS:CAN:TRIGger:PATTern:DATA:LENGth ::= integer from 1 to 8 in NR1 format The :SBUS:CAN:TRIGger:PATTern:DATA:LENGth command sets the number of 8-bit bytes in the CAN data string. The number of bytes in the string can be anywhere from 1 bytes to 8 bytes (64 bits). The value for these bytes is set by the :SBUS:CAN:TRIGger:PATTern:DATA command.
:SBUS Commands 25 :SBUS:CAN:TRIGger:PATTern:ID (see page 792) Command Syntax :SBUS:CAN:TRIGger:PATTern:ID ::= "nn...n" where n ::= {0 | 1 | X | $} :CAN:TRIGger:PATTern:ID command defines the CAN identifier pattern resource according to the string parameter.
25 :SBUS Commands :SBUS:CAN:TRIGger:PATTern:ID:MODE (see page 792) Command Syntax :SBUS:CAN:TRIGger:PATTern:ID:MODE ::= {STANdard | EXTended} The :SBUS:CAN:TRIGger:PATTern:ID:MODE command sets the CAN identifier mode. STANdard selects the standard 11-bit identifier. EXTended selects the extended 29-bit identifier. The CAN identifier is set by the :SBUS:CAN:TRIGger:PATTern:ID command.
25 :SBUS Commands :SBUS:IIC Commands NOTE These commands are only valid when the low-speed IIC and SPI serial decode option (Option LSS) has been licensed.
25 :SBUS Commands :SBUS:IIC:ASIZe (see page 792) Command Syntax :SBUS:IIC:ASIZe ::= {BIT7 | BIT8} The :SBUS:IIC:ASIZe command determines whether the Read/Write bit is included as the LSB in the display of the IIC address field of the decode bus. Query Syntax :SBUS:IIC:ASIZe? The :SBUS:IIC:ASIZe? query returns the current IIC address width setting.
:SBUS Commands 25 :SBUS:IIC[:SOURce]:CLOCk (see page 792) Command Syntax :SBUS:IIC:[SOURce:]CLOCk ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:IIC:[SOURce:]CLOCk command sets the source for the IIC serial clock (SCL).
25 :SBUS Commands :SBUS:IIC[:SOURce]:DATA (see page 792) Command Syntax :SBUS:IIC:[SOURce:]DATA ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:IIC:[SOURce:]DATA command sets the source for IIC serial data (SDA).
:SBUS Commands 25 :SBUS:IIC:TRIGger:PATTern:ADDRess (see page 792) Command Syntax :SBUS:IIC:TRIGger:PATTern:ADDRess ::= integer or ::= "0xnn" where n ::= {0,..,9 | A,..,F} The :SBUS:IIC:TRIGger:PATTern:ADDRess command sets the address for IIC data.The address can range from 0x00 to 0x7F (7-bit) or 0x3FF (10-bit) hexadecimal. Use the don't care address (-1 or 0xFFFFFFFF) to ignore the address value.
25 :SBUS Commands :SBUS:IIC:TRIGger:PATTern:DATA (see page 792) Command Syntax :SBUS:IIC:TRIGger:PATTern:DATA ::= integer or ::= "0xnn" where n ::= {0,..,9 | A,..,F} The :SBUS:IIC:TRIGger:PATTern:DATA command sets IIC data. The data value can range from 0x00 to 0x0FF (hexadecimal). Use the don't care data pattern (-1 or 0xFFFFFFFF) to ignore the data value.
:SBUS Commands 25 :SBUS:IIC:TRIGger:PATTern:DATa2 (see page 792) Command Syntax :SBUS:IIC:TRIGger:PATTern:DATa2 ::= integer or ::= "0xnn" where n ::= {0,..,9 | A,..,F} The :SBUS:IIC:TRIGger:PATTern:DATa2 command sets IIC data 2. The data value can range from 0x00 to 0x0FF (hexadecimal). Use the don't care data pattern (-1 or 0xFFFFFFFF) to ignore the data value.
25 :SBUS Commands :SBUS:IIC:TRIGger:QUALifier (see page 792) Command Syntax :SBUS:IIC:TRIGger:QUALifier ::= {EQUal | NOTequal | LESSthan | GREaterthan} The :SBUS:IIC:TRIGger:QUALifier command sets the IIC data qualifier when TRIGger:IIC:TRIGger[:TYPE] is set to READEprom. Query Syntax :SBUS:IIC:TRIGger:QUALifier? The :SBUS:IIC:TRIGger:QUALifier? query returns the current IIC data qualifier value.
:SBUS Commands 25 :SBUS:IIC:TRIGger[:TYPE] (see page 792) Command Syntax :SBUS:IIC:TRIGger[:TYPE] ::= {STARt | STOP | READ7 | READEprom | WRITe7 | WRITe10 | NACKnowledge | ANACk | R7Data2 | W7Data2 | RESTart} The :SBUS:IIC:TRIGger[:TYPE] command sets the IIC trigger type: NOTE Query Syntax • STARt — Start condition. • STOP — Stop condition. • READ7 — 7-bit address frame containing (Start:Address7:Read:Ack:Data). The value READ is also accepted for READ7.
25 :SBUS Commands 478 • ":SBUS:IIC:TRIGger:PATTern:DATa2" on page 475 • ":SBUS:IIC:TRIGger:QUALifier" on page 476 • "Long Form to Short Form Truncation Rules" on page 794 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
25 :SBUS Commands :SBUS:LIN Commands NOTE These commands are valid when the automotive CAN and LIN serial decode option (Option AMS) has been licensed. Table 78 :SBUS:LIN Commands Summary Command Query Options and Query Returns :SBUS:LIN:PARity {{0 | OFF} | {1 | ON}} (see page 481) :SBUS:LIN:PARity? (see page 481) {0 | 1} :SBUS:LIN:SAMPlepo int (see page 482) :SBUS:LIN:SAMPlepo int? (see page 482) ::= {60 | 62.5 | 68 | 70 | 75 | 80 | 87.
25 :SBUS Commands Table 78 :SBUS:LIN Commands Summary (continued) Command Query Options and Query Returns :SBUS:LIN:TRIGger: PATTern:DATA (see page 489) :SBUS:LIN:TRIGger: PATTern:DATA? (see page 489) ::= "n" where n ::= 32-bit integer in unsigned decimal when = DECimal ::= "nn...n" where n ::= {0 | 1 | X | $} when = BINary ::= "0xnn...n" where n ::= {0,..,9 | A,..
:SBUS Commands 25 :SBUS:LIN:PARity (see page 792) Command Syntax :SBUS:LIN:PARity ::= {{1 | ON} | {0 | OFF}} The :SBUS:LIN:PARity command determines whether the parity bits are included as the most significant bits (MSB) in the display of the Frame Id field in the LIN decode bus. Query Syntax :SBUS:LIN:PARity? The :SBUS:LIN:PARity? query returns the current LIN parity bits display setting of the serial decode bus.
25 :SBUS Commands :SBUS:LIN:SAMPlepoint (see page 792) Command Syntax :SBUS:LIN:SAMPlepoint ::= {60 | 62.5 | 68 | 70 | 75 | 80 | 87.5} in NR3 format The :SBUS:LIN:SAMPlepoint command sets the point during the bit time where the bit level is sampled to determine whether the bit is dominant or recessive. The sample point represents the percentage of time between the beginning of the bit time to the end of the bit time.
:SBUS Commands 25 :SBUS:LIN:SIGNal:BAUDrate (see page 792) Command Syntax :SBUS:LIN:SIGNal:BAUDrate ::= integer from 2400 to 625000 in 100 b/s increments The :SBUS:LIN:SIGNal:BAUDrate command sets the standard baud rate of the LIN signal from 2400 b/s to 625 kb/s in 100 b/s increments. If you enter a baud rate that is not divisible by 100 b/s, the baud rate is set to the nearest baud rate divisible by 100 b/s.
25 :SBUS Commands :SBUS:LIN:SOURce (see page 792) Command Syntax :SBUS:LIN:SOURce ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:LIN:SOURce command sets the source for the LIN signal. Query Syntax :SBUS:LIN:SOURce? The :SBUS:LIN:SOURce? query returns the current source for the LIN signal.
:SBUS Commands 25 :SBUS:LIN:STANdard (see page 792) Command Syntax :SBUS:LIN:STANdard ::= {LIN13 | LIN20} The :SBUS:LIN:STANdard command sets the LIN standard in effect for triggering and decoding to be LIN1.3 or LIN2.0. Query Syntax :SBUS:LIN:STANdard? The :SBUS:LIN:STANdard? query returns the current LIN standard setting.
25 :SBUS Commands :SBUS:LIN:SYNCbreak (see page 792) Command Syntax :SBUS:LIN:SYNCbreak ::= integer = {11 | 12 | 13} The :SBUS:LIN:SYNCbreak command sets the length of the LIN sync break to be greater than or equal to 11, 12, or 13 clock lengths. The sync break is the idle period in the bus activity at the beginning of each packet that distinguishes one information packet from the previous one.
:SBUS Commands 25 :SBUS:LIN:TRIGger (see page 792) Command Syntax :SBUS:LIN:TRIGger ::= {SYNCbreak | ID | DATA} The :SBUS:LIN:TRIGger command sets the LIN trigger condition to be: • SYNCbreak — Sync Break. • ID — Frame ID. Use the :SBUS:LIN:TRIGger:ID command to specify the frame ID. • DATA — Frame ID and Data. Use the :SBUS:LIN:TRIGger:ID command to specify the frame ID.
25 :SBUS Commands :SBUS:LIN:TRIGger:ID (see page 792) Command Syntax :SBUS:LIN:TRIGger:ID ::= 7-bit integer in decimal, , or from 0-63 or 0x00-0x3f ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary ::= "0xnn" where n ::= {0,..,9 | A,..
:SBUS Commands 25 :SBUS:LIN:TRIGger:PATTern:DATA (see page 792) Command Syntax :SBUS:LIN:TRIGger:PATTern:DATA ::= "n" where n ::= 32-bit integer in unsigned decimal when = DECimal ::= "nn...n" where n ::= {0 | 1 | X | $} when = BINary ::= "0xnn...n" where n ::= {0,..,9 | A,..,F | X | $} when = HEX NOTE is specified with the :SBUS:LIN:TRIGger:PATTern:FORMat command. The default is BINary.
25 :SBUS Commands See Also 490 • "Introduction to :TRIGger Commands" on page 589 • ":SBUS:LIN:TRIGger:PATTern:FORMat" on page 492 • ":SBUS:LIN:TRIGger" on page 487 • ":SBUS:LIN:TRIGger:PATTern:DATA:LENGth" on page 491 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:SBUS Commands 25 :SBUS:LIN:TRIGger:PATTern:DATA:LENGth (see page 792) Command Syntax :SBUS:LIN:TRIGger:PATTern:DATA:LENGth ::= integer from 1 to 8 in NR1 format The :SBUS:LIN:TRIGger:PATTern:DATA:LENGth command sets the number of 8-bit bytes in the LIN data string. The number of bytes in the string can be anywhere from 1 bytes to 8 bytes (64 bits). The value for these bytes is set by the :SBUS:LIN:TRIGger:PATTern:DATA command.
25 :SBUS Commands :SBUS:LIN:TRIGger:PATTern:FORMat (see page 792) Command Syntax :SBUS:LIN:TRIGger:PATTern:FORMat ::= {BINary | HEX | DECimal} The :SBUS:LIN:TRIGger:PATTern:FORMat command sets the entry (and query) number base used by the :SBUS:LIN:TRIGger:PATTern:DATA command. The default is BINary. Query Syntax :SBUS:LIN:TRIGger:PATTern:FORMat? The :SBUS:LIN:TRIGger:PATTern:FORMat? query returns the currently set number base for LIN pattern data.
25 :SBUS Commands :SBUS:SPI Commands NOTE These commands are only valid when the low-speed IIC and SPI serial decode option (Option LSS) has been licensed.
25 :SBUS Commands Table 79 :SBUS:SPI Commands Summary (continued) Command Query Options and Query Returns :SBUS:SPI:SOURce:M OSI (see page 502) :SBUS:SPI:SOURce:M OSI? (see page 502) ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format :SBUS:SPI:TRIGger: PATTern:MISO:DATA (see page 503) :SBUS:SPI:TRIGger: PAT
:SBUS Commands 25 :SBUS:SPI:BITorder (see page 792) Command Syntax :SBUS:SPI:BITorder ::= {LSBFirst | MSBFirst} The :SBUS:SPI:BITorder command selects the bit order, most significant bit first (MSB) or least significant bit first (LSB), used when displaying data in the serial decode waveform and in the Lister. Query Syntax :SBUS:SPI:BITorder? The :SBUS:SPI:BITorder? query returns the current SPI decode bit order.
25 :SBUS Commands :SBUS:SPI:CLOCk:SLOPe (see page 792) Command Syntax :SBUS:SPI:CLOCk:SLOPe ::= {NEGative | POSitive} The :SBUS:SPI:CLOCk:SLOPe command specifies the rising edge (POSitive) or falling edge (NEGative) of the SPI clock source that will clock in the data. Query Syntax :SBUS:SPI:CLOCk:SLOPe? The :SBUS:SPI:CLOCk:SLOPe? query returns the current SPI clock source slope.
:SBUS Commands 25 :SBUS:SPI:CLOCk:TIMeout (see page 792) Command Syntax :SBUS:SPI:CLOCk:TIMeout ::= time in seconds in NR3 format The :SBUS:SPI:CLOCk:TIMeout command sets the SPI signal clock timeout resource in seconds from 100 ns to 10 s when the :SBUS:SPI:FRAMing command is set to TIMeout. The timer is used to frame a signal by a clock timeout.
25 :SBUS Commands :SBUS:SPI:FRAMing (see page 792) Command Syntax :SBUS:SPI:FRAMing ::= {CHIPselect | {NCHipselect | NOTC} | TIMeout} The :SBUS:SPI:FRAMing command sets the SPI trigger framing value. If TIMeout is selected, the timeout value is set by the :SBUS:SPI:CLOCk:TIMeout command. NOTE Query Syntax The NOTC value is deprecated. It is the same as NCHipselect. :SBUS:SPI:FRAMing? The :SBUS:SPI:FRAMing? query returns the current SPI framing value.
:SBUS Commands 25 :SBUS:SPI:SOURce:CLOCk (see page 792) Command Syntax :SBUS:SPI:SOURce:CLOCk ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:SPI:SOURce:CLOCk command sets the source for the SPI serial clock.
25 :SBUS Commands :SBUS:SPI:SOURce:FRAMe (see page 792) Command Syntax :SBUS:SPI:SOURce:FRAMe ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:SPI:SOURce:FRAMe command sets the frame source when :SBUS:SPI:FRAMing is set to CHIPselect or NOTChipselect.
:SBUS Commands 25 :SBUS:SPI:SOURce:MISO (see page 792) Command Syntax :SBUS:SPI:SOURce:MISO ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:SPI:SOURce:MISO command sets the source for the SPI serial MISO data.
25 :SBUS Commands :SBUS:SPI:SOURce:MOSI (see page 792) Command Syntax :SBUS:SPI:SOURce:MOSI ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:SPI:SOURce:MOSI command sets the source for the SPI serial MOSI data. You can also use the equivalent :SBUS:SPI:SOURce:DATA command to set the MOSI data source.
25 :SBUS Commands :SBUS:SPI:TRIGger:PATTern:MISO:DATA (see page 792) Command Syntax :SBUS:SPI:TRIGger:PATTern:MISO:DATA ::= "nn...n" where n ::= {0 | 1 | X | $} :SPI:TRIGger:PATTern:MISO:DATA command defines the SPI data pattern resource according to the string parameter. This pattern, along with the data width, control the data pattern searched for in the data stream.
25 :SBUS Commands :SBUS:SPI:TRIGger:PATTern:MISO:WIDTh (see page 792) Command Syntax :SBUS:SPI:TRIGger:PATTern:MISO:WIDTh ::= integer from 4 to 64 in NR1 format The :SBUS:SPI:TRIGger:PATTern:MISO:WIDTh command sets the width of the SPI data pattern anywhere from 4 bits to 64 bits. NOTE The :SBUS:SPI:TRIGger:PATTern:MISO:WIDTh should be set before :SBUS:SPI:TRIGger:PATTern:MISO:DATA.
25 :SBUS Commands :SBUS:SPI:TRIGger:PATTern:MOSI:DATA (see page 792) Command Syntax :SBUS:SPI:TRIGger:PATTern:MOSI:DATA ::= "nn...n" where n ::= {0 | 1 | X | $} :SPI:TRIGger:PATTern:MOSI:DATA command defines the SPI data pattern resource according to the string parameter. This pattern, along with the data width, control the data pattern searched for in the data stream.
25 :SBUS Commands :SBUS:SPI:TRIGger:PATTern:MOSI:WIDTh (see page 792) Command Syntax :SBUS:SPI:TRIGger:PATTern:MOSI:WIDTh ::= integer from 4 to 64 in NR1 format The :SBUS:SPI:TRIGger:PATTern:MOSI:WIDTh command sets the width of the SPI data pattern anywhere from 4 bits to 64 bits. NOTE The :SBUS:SPI:TRIGger:PATTern:MOSI:WIDTh should be set before :SBUS:SPI:TRIGger:PATTern:MOSI:DATA.
:SBUS Commands 25 :SBUS:SPI:TRIGger:TYPE (see page 792) Command Syntax :SBUS:SPI:TRIGger:TYPE ::= {MOSI | MISO} The :SBUS:SPI:TRIGger:TYPE command specifies whether the SPI trigger will be on the MOSI data or the MISO data. When triggering on MOSI data, the data value is specified by the :SBUS:SPI:TRIGger:PATTern:MOSI:DATA and :SBUS:SPI:TRIGger:PATTern:MOSI:WIDTh commands.
25 :SBUS Commands :SBUS:SPI:WIDTh (see page 792) Command Syntax :SBUS:SPI:WIDTh ::= integer 4-16 in NR1 format The :SBUS:SPI:WIDTh command determines the number of bits in a word of data for SPI. Query Syntax :SBUS:SPI:WIDTh? The :SBUS:SPI:WIDTh? query returns the current SPI decode word width.
25 :SBUS Commands :SBUS:UART Commands NOTE These commands are only valid when the UART/RS-232 triggering and serial decode option (Option 232) has been licensed.
25 :SBUS Commands Table 80 :SBUS:UART Commands Summary (continued) Command Query Options and Query Returns :SBUS:UART:SOURce: RX (see page 522) :SBUS:UART:SOURce: RX? (see page 522) ::= {CHANnel | EXTernal} for DSO models ::= {CHANnel | DIGital} for MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format :SBUS:UART:SOURce: TX (see page 523) :SBUS:UART:SOURce: TX? (see page 523)
:SBUS Commands 25 Table 80 :SBUS:UART Commands Summary (continued) Command Query Options and Query Returns :SBUS:UART:TRIGger :TYPE (see page 529) :SBUS:UART:TRIGger :TYPE? (see page 529) ::= RDATa | RD1 PARityerror TDATa | TD1 :SBUS:UART:WIDTh (see page 530) :SBUS:UART:WIDTh? (see page 530) ::= {5 | 6 | 7 | 8 | 9} Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide {RSTArt | RSTOp | | RD0 | RDX | | TSTArt | TSTOp | | TD0 | TDX}
25 :SBUS Commands :SBUS:UART:BASE (see page 792) Command Syntax :SBUS:UART:BASE ::= {ASCii | BINary | HEX} The :SBUS:UART:BASE command determines the base to use for the UART decode and Lister display. Query Syntax :SBUS:UART:BASE? The :SBUS:UART:BASE? query returns the current UART decode and Lister base setting.
:SBUS Commands 25 :SBUS:UART:BAUDrate (see page 792) Command Syntax :SBUS:UART:BAUDrate ::= integer from 100 to 8000000 The :SBUS:UART:BAUDrate command selects the bit rate (in bps) for the serial decoder and/or trigger when in UART mode. The baud rate can be set from 100 b/s to 8 Mb/s. If the baud rate you select does not match the system baud rate, false triggers may occur.
25 :SBUS Commands :SBUS:UART:BITorder (see page 792) Command Syntax :SBUS:UART:BITorder ::= {LSBFirst | MSBFirst} The :SBUS:UART:BITorder command specifies the order of transmission used by the physical Tx and Rx input signals for the serial decoder and/or trigger when in UART mode. LSBFirst sets the least significant bit of each message "byte" as transmitted first. MSBFirst sets the most significant bit as transmitted first.
:SBUS Commands 25 :SBUS:UART:COUNt:ERRor (see page 792) Query Syntax :SBUS:UART:COUNt:ERRor? Returns the UART error frame count.
25 :SBUS Commands :SBUS:UART:COUNt:RESet (see page 792) Command Syntax :SBUS:UART:COUNt:RESet Resets the UART frame counters.
:SBUS Commands 25 :SBUS:UART:COUNt:RXFRames (see page 792) Query Syntax :SBUS:UART:COUNt:RXFRames? Returns the UART Rx frame count.
25 :SBUS Commands :SBUS:UART:COUNt:TXFRames (see page 792) Query Syntax :SBUS:UART:COUNt:TXFRames? Returns the UART Tx frame count.
:SBUS Commands 25 :SBUS:UART:FRAMing (see page 792) Command Syntax :SBUS:UART:FRAMing ::= {OFF | | } ::= 8-bit integer in decimal from 0-255 (0x00-0xff) ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary The :SBUS:UART:FRAMing command determines the byte value to use for framing (end of packet) or to turn off framing for UART decode.
25 :SBUS Commands :SBUS:UART:PARity (see page 792) Command Syntax :SBUS:UART:PARity ::= {EVEN | ODD | NONE} The :SBUS:UART:PARity command selects the parity to be used with each message "byte" for the serial decoder and/or trigger when in UART mode. Query Syntax :SBUS:UART:PARity? The :SBUS:UART:PARity? query returns the current UART parity setting.
:SBUS Commands 25 :SBUS:UART:POLarity (see page 792) Command Syntax :SBUS:UART:POLarity ::= {HIGH | LOW} The :SBUS:UART:POLarity command selects the polarity as idle low or idle high for the serial decoder and/or trigger when in UART mode. Query Syntax :SBUS:UART:POLarity? The :SBUS:UART:POLarity? query returns the current UART polarity setting.
25 :SBUS Commands :SBUS:UART:SOURce:RX (see page 792) Command Syntax :SBUS:UART:SOURce:RX ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:UART:SOURce:RX command controls which signal is used as the Rx source by the serial decoder and/or trigger when in UART mode.
:SBUS Commands 25 :SBUS:UART:SOURce:TX (see page 792) Command Syntax :SBUS:UART:SOURce:TX ::= {CHANnel | EXTernal} for the DSO models ::= {CHANnel | DIGital} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :SBUS:UART:SOURce:TX command controls which signal is used as the Tx source by the serial decoder and/or trigger when in UART mode.
25 :SBUS Commands :SBUS:UART:TRIGger:BASE (see page 792) Command Syntax :SBUS:UART:TRIGger:BASE ::= {ASCii | HEX} The :SBUS:UART:TRIGger:BASE command sets the front panel UART/RS232 trigger setup data selection option: • ASCii — front panel data selection is from ASCII values. • HEX — front panel data selection is from hexadecimal values.
:SBUS Commands 25 :SBUS:UART:TRIGger:BURSt (see page 792) Command Syntax :SBUS:UART:TRIGger:BURSt ::= {OFF | 1 to 4096 in NR1 format} The :SBUS:UART:TRIGger:BURSt command selects the burst value (Nth frame after idle period) in the range 1 to 4096 or OFF, for the trigger when in UART mode. Query Syntax :SBUS:UART:TRIGger:BURSt? The :SBUS:UART:TRIGger:BURSt? query returns the current UART trigger burst value.
25 :SBUS Commands :SBUS:UART:TRIGger:DATA (see page 792) Command Syntax :SBUS:UART:TRIGger:DATA ::= 8-bit integer from 0-255 (0x00-0xff) in decimal, , , or format ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...
25 :SBUS Commands :SBUS:UART:TRIGger:IDLE (see page 792) Command Syntax :SBUS:UART:TRIGger:IDLE ::= time from 1 us to 10 s in NR3 format The :SBUS:UART:TRIGger:IDLE command selects the value of the idle period for burst trigger in the range from 1 us to 10 s when in UART mode. Query Syntax :SBUS:UART:TRIGger:IDLE? The :SBUS:UART:TRIGger:IDLE? query returns the current UART trigger idle period time.
25 :SBUS Commands :SBUS:UART:TRIGger:QUALifier (see page 792) Command Syntax :SBUS:UART:TRIGger:QUALifier ::= {EQUal | NOTequal | GREaterthan | LESSthan} The :SBUS:UART:TRIGger:QUALifier command selects the data qualifier when :TYPE is set to RDATa, RD1, RD0, RDX, TDATa, TD1, TD0, or TDX for the trigger when in UART mode. Query Syntax :SBUS:UART:TRIGger:QUALifier? The :SBUS:UART:TRIGger:QUALifier? query returns the current UART trigger qualifier.
25 :SBUS Commands :SBUS:UART:TRIGger:TYPE (see page 792) Command Syntax :SBUS:UART:TRIGger:TYPE ::= {RSTArt | RSTOp | RDATa | RD1 | RD0 | RDX | PARityerror | TSTArt | TSTOp | TDATa | TD1 | TD0 | TDX} The :SBUS:UART:TRIGger:TYPE command selects the UART trigger type. When one of the RD or TD types is selected, the :SBUS:UART:TRIGger:DATA and :SBUS:UART:TRIGger:QUALifier commands are used to specify the data value and comparison operator.
25 :SBUS Commands :SBUS:UART:WIDTh (see page 792) Command Syntax :SBUS:UART:WIDTh ::= {5 | 6 | 7 | 8 | 9} The :SBUS:UART:WIDTh command determines the number of bits (5-9) for each message "byte" for the serial decoder and/or trigger when in UART mode. Query Syntax :SBUS:UART:WIDTh? The :SBUS:UART:WIDTh? query returns the current UART width setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 26 :SEARch Commands Control the event search modes and parameters for each search type.
26 :SEARch Commands General :SEARch Commands Table 81 General :SEARch Commands Summary Command Query Options and Query Returns n/a :SEARch:COUNt? (see page 533) ::= an integer count value :SEARch:MODE (see page 534) :SEARch:MODE? (see page 534) ::= {SERial1} :SEARch:STATe (see page 535) :SEARch:STATe? (see page 535) ::= {{0 | OFF} | {1 | ON}} 532 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:SEARch Commands 26 :SEARch:COUNt (see page 792) Query Syntax :SEARch:COUNt? The :SEARch:COUNt? query returns the number of search events found.
26 :SEARch Commands :SEARch:MODE (see page 792) Command Syntax :SEARch:MODE ::= {SERial1} The :SEARch:MODE command selects the search mode. The command is only valid when the :SEARch:STATe is ON. Query Syntax :SEARch:MODE? The :SEARch:MODE? query returns the currently selected mode or OFF if the :SEARch:STATe is OFF.
:SEARch Commands 26 :SEARch:STATe (see page 792) Command Syntax :SEARch:STATe ::= {{0 | OFF} | {1 | ON}} The :SEARch:STATe command enables or disables the search feature. Query Syntax :SEARch:STATe? The :SEARch:STATe? query returns returns the current setting.
26 :SEARch Commands :SEARch:SERial:CAN Commands Table 82 :SEARch:SERial:CAN Commands Summary Command Query Options and Query Returns :SEARch:SERial:CAN:MO DE (see page 537) :SEARch:SERial:CAN:MO DE? (see page 537) ::= {DATA | IDData | IDEither | IDRemote | ALLerrors | OVERload | ERRor} :SEARch:SERial:CAN:PA TTern:DATA (see page 538) :SEARch:SERial:CAN:PA TTern:DATA? (see page 538) ::= "0xnn...n" where n ::= {0,..,9 | A,..
:SEARch Commands 26 :SEARch:SERial:CAN:MODE (see page 792) Command Syntax :SEARch:SERial:CAN:MODE ::= {DATA | IDData | IDEither | IDRemote | ALLerrors | OVERload | ERRor} The :SEARch:SERial:CAN:MODE command selects the type of CAN information to find in the Lister display: Query Syntax • DATA - searches for CAN Data frames matching the specified ID, Data, and the DLC (Data length code). • IDData - searches for CAN frames matching the specified ID of a Data frame.
26 :SEARch Commands :SEARch:SERial:CAN:PATTern:DATA (see page 792) Command Syntax :SEARch:SERial:CAN:PATTern:DATA ::= "0xnn...n" where n ::= {0,..,9 | A,..,F | X} for hexadecimal The :SEARch:SERial:CAN:PATTern:DATA command specifies the data value when searching for Data Frame ID and Data. The length of the data value is specified using the :SEARch:SERial:CAN:PATTern:DATA:LENGth command.
:SEARch Commands 26 :SEARch:SERial:CAN:PATTern:DATA:LENGth (see page 792) Command Syntax :SEARch:SERial:CAN:PATTern:DATA:LENGth ::= integer from 1 to 8 in NR1 format The :SEARch:SERial:CAN:PATTern:DATA:LENGth command specifies the length of the data value when searching for Data Frame ID and Data. The data value is specified using the :SEARch:SERial:CAN:PATTern:DATA command.
26 :SEARch Commands :SEARch:SERial:CAN:PATTern:ID (see page 792) Command Syntax :SEARch:SERial:CAN:PATTern:ID ::= "0xnn...n" where n ::= {0,..,9 | A,..,F | X} for hexadecimal The :SEARch:SERial:CAN:PATTern:ID command specifies the ID value when searching for a CAN event. The value can be a standard ID or an extended ID, depending on the :SEARch:SERial:CAN:PATTern:ID:MODE command's setting.
:SEARch Commands 26 :SEARch:SERial:CAN:PATTern:ID:MODE (see page 792) Command Syntax :SEARch:SERial:CAN:PATTern:ID:MODE ::= {STANdard | EXTended} The :SEARch:SERial:CAN:PATTern:ID:MODE command specifies whether a standard ID value or an extended ID value is used when searching for a CAN event. The ID value is specified using the :SEARch:SERial:CAN:PATTern:ID command.
26 :SEARch Commands :SEARch:SERial:IIC Commands Table 83 :SEARch:SERial:IIC Commands Summary Command Query Options and Query Returns :SEARch:SERial:IIC:MO DE (see page 543) :SEARch:SERial:IIC:MO DE? (see page 543) ::= { READ7 | WRITE7 | NACKnowledge | ANACk | R7Data2 | W7Data2 | RESTart | READEprom} :SEARch:SERial:IIC:PA TTern:ADDRess (see page 545) :SEARch:SERial:IIC:PA TTern:ADDRess? (see page 545) ::= integer or ::= "0xnn" n ::= {0,..,9 | A,..
:SEARch Commands 26 :SEARch:SERial:IIC:MODE (see page 792) Command Syntax :SEARch:SERial:IIC:MODE ::= {READ7 | WRITE7 | NACKnowledge | ANACk | R7Data2 | W7Data2 | RESTart | READEprom} The :SEARch:SERial:IIC:MODE command selects the type of IIC information to find in the Lister display: NOTE • READ7 — searches for 7-bit address frames containing Start:Address7:Read:Ack:Data. The value READ is also accepted for READ7.
26 :SEARch Commands 544 • ":SEARch:SERial:IIC:PATTern:DATA2" on page 547 • ":SEARch:SERial:IIC:QUALifier" on page 548 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:SEARch Commands 26 :SEARch:SERial:IIC:PATTern:ADDRess (see page 792) Command Syntax :SEARch:SERial:IIC:PATTern:ADDRess ::= integer or ::= "0xnn" n ::= {0,..,9 | A,..,F} The :SEARch:SERial:IIC:PATTern:ADDRess command specifies address values when searching for IIC events. To set don't care values, use the integer -1. Query Syntax :SEARch:SERial:IIC:PATTern:ADDRess? The :SEARch:SERial:IIC:PATTern:ADDRess? query returns the current address value setting.
26 :SEARch Commands :SEARch:SERial:IIC:PATTern:DATA (see page 792) Command Syntax :SEARch:SERial:IIC:PATTern:DATA ::= integer or ::= "0xnn" n ::= {0,..,9 | A,..,F} The :SEARch:SERial:IIC:PATTern:DATA command specifies data values when searching for IIC events. To set don't care values, use the integer -1. When searching for IIC EEPROM data read events, you specify the data value qualifier using the :SEARch:SERial:IIC:QUALifier command.
:SEARch Commands 26 :SEARch:SERial:IIC:PATTern:DATA2 (see page 792) Command Syntax :SEARch:SERial:IIC:PATTern:DATA2 ::= integer or ::= "0xnn" n ::= {0,..,9 | A,..,F} The :SEARch:SERial:IIC:PATTern:DATA2 command specifies the second data value when searching for IIC events with two data values. To set don't care values, use the integer -1.
26 :SEARch Commands :SEARch:SERial:IIC:QUALifier (see page 792) Command Syntax :SEARch:SERial:IIC:QUALifier ::= {EQUal | NOTequal | LESSthan | GREaterthan} The :SEARch:SERial:IIC:QUALifier command specifies the data value qualifier used when searching for IIC EEPROM data read events. Query Syntax :SEARch:SERial:IIC:QUALifier? The :SEARch:SERial:IIC:QUALifier? query returns the current data value qualifier setting.
26 :SEARch Commands :SEARch:SERial:LIN Commands Table 84 :SEARch:SERial:LIN Commands Summary Command Query Options and Query Returns :SEARch:SERial:LIN:ID (see page 550) :SEARch:SERial:LIN:ID ? (see page 550) ::= 7-bit integer in decimal, , or from 0-63 or 0x00-0x3f (with Option AMS) ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary ::= "0xnn" where n ::= {0,..,9 | A,..
26 :SEARch Commands :SEARch:SERial:LIN:ID (see page 792) Command Syntax :SEARch:SERial:LIN:ID ::= 7-bit integer in decimal, , or from 0-63 or 0x00-0x3f (with Option AMS) ::= #Hnn where n ::= {0,..,9 | A,..,F} for hexadecimal ::= #Bnn...n where n ::= {0 | 1} for binary ::= "0xnn" where n ::= {0,..,9 | A,..,F} for hexadecimal The :SEARch:SERial:LIN:ID command specifies the frame ID value when searching for LIN events.
26 :SEARch Commands :SEARch:SERial:LIN:MODE (see page 792) Command Syntax :SEARch:SERial:LIN:MODE ::= {ID | DATA | ERRor} The :SEARch:SERial:LIN:MODE command selects the type of LIN information to find in the Lister display: • ID — searches for a frame ID. • DATA — searches for a frame ID and data. • ERRor — searches for errors. Frame IDs are specified using the :SEARch:SERial:LIN:ID command. Data values are specified using the:SEARch:SERial:LIN:PATTern:DATA command.
26 :SEARch Commands :SEARch:SERial:LIN:PATTern:DATA (see page 792) Command Syntax :SEARch:SERial:LIN:PATTern:DATA When :SEARch:SERial:LIN:PATTern:FORMat DECimal, ::= "n" where n ::= 32-bit integer in unsigned decimal When :SEARch:SERial:LIN:PATTern:FORMat HEX, ::= "0xnn...n" where n ::= {0,..,9 | A,..,F | X } The :SEARch:SERial:LIN:PATTern:DATA command specifies the data value when searching for LIN events.
:SEARch Commands 26 :SEARch:SERial:LIN:PATTern:DATA:LENGth (see page 792) Command Syntax :SEARch:SERial:LIN:PATTern:DATA:LENGth ::= integer from 1 to 8 in NR1 format The :SEARch:SERial:LIN:PATTern:DATA:LENGth command specifies the the length of the data value when searching for LIN events. The data value is specified using the :SEARch:SERial:LIN:PATTern:DATA command.
26 :SEARch Commands :SEARch:SERial:LIN:PATTern:FORMat (see page 792) Command Syntax :SEARch:SERial:LIN:PATTern:FORMat ::= {HEX | DECimal} The :SEARch:SERial:LIN:PATTern:FORMat command specifies the number base used with the :SEARch:SERial:LIN:PATTern:DATA command. Query Syntax :SEARch:SERial:LIN:PATTern:FORMat? The :SEARch:SERial:LIN:PATTern:FORMat? query returns the current number base setting.
26 :SEARch Commands :SEARch:SERial:SPI Commands Table 85 :SEARch:SERial:SPI Commands Summary Command Query Options and Query Returns :SEARch:SERial:SPI:MO DE (see page 556) :SEARch:SERial:SPI:MO DE? (see page 556) ::= {MOSI | MISO} :SEARch:SERial:SPI:PA TTern:DATA (see page 557) :SEARch:SERial:SPI:PA TTern:DATA? (see page 557) ::= "0xnn...n" where n ::= {0,..,9 | A,..
26 :SEARch Commands :SEARch:SERial:SPI:MODE (see page 792) Command Syntax :SEARch:SERial:SPI:MODE ::= {MOSI | MISO} The :SEARch:SERial:SPI:MODE command specifies whether the SPI search will be on the MOSI data or the MISO data. Data values are specified using the :SEARch:SERial:SPI:PATTern:DATA command. Query Syntax :SEARch:SERial:SPI:MODE? The :SEARch:SERial:SPI:MODE? query returns the current SPI search mode setting.
26 :SEARch Commands :SEARch:SERial:SPI:PATTern:DATA (see page 792) Command Syntax :SEARch:SERial:SPI:PATTern:DATA ::= "0xnn...n" where n ::= {0,..,9 | A,..,F | X} The :SEARch:SERial:SPI:PATTern:DATA command specifies the data value when searching for SPI events. The width of the data value is specified using the :SEARch:SERial:SPI:PATTern:WIDTh command. Query Syntax :SEARch:SERial:SPI:PATTern:DATA? The :SEARch:SERial:SPI:PATTern:DATA? query returns the current data value setting.
26 :SEARch Commands :SEARch:SERial:SPI:PATTern:WIDTh (see page 792) Command Syntax :SEARch:SERial:SPI:PATTern:WIDTh ::= integer from 1 to 10 The :SEARch:SERial:SPI:PATTern:WIDTh command specifies the width of the data value (in bytes) when searching for SPI events. The data value is specified using the :SEARch:SERial:SPI:PATTern:DATA command. Query Syntax :SEARch:SERial:SPI:PATTern:WIDTh? The :SEARch:SERial:SPI:PATTern:WIDTh? query returns the current data width setting.
26 :SEARch Commands :SEARch:SERial:UART Commands Table 86 :SEARch:SERial:UART Commands Summary Command Query Options and Query Returns :SEARch:SERial:UART:D ATA (see page 560) :SEARch:SERial:UART:D ATA? (see page 560) ::= 8-bit integer from 0-255 (0x00-0xff) in decimal, , , or format ::= #Hnn where n ::= {0,..,9| A,..,F} for hexadecimal ::= #Bnn...
26 :SEARch Commands :SEARch:SERial:UART:DATA (see page 792) Command Syntax :SEARch:SERial:UART:DATA ::= 8-bit integer from 0-255 (0x00-0xff) in decimal, , , or format ::= #Hnn where n ::= {0,..,9| A,..,F} for hexadecimal ::= #Bnn...
:SEARch Commands 26 :SEARch:SERial:UART:MODE (see page 792) Command Syntax :SEARch:SERial:UART:MODE ::= {RDATa | RD1 | RD0 | RDX | TDATa | TD1 | TD0 | TDX | PARityerror | AERRor} The :SEARch:SERial:UART:MODE command selects the type of UART/RS232 information to find in the Lister display: • RDATa — searches for a receive data value when data words are from 5 to 8 bits long. • RD1 — searches for a receive data value when data words are 9 bits long and the 9th (alert) bit is 1.
26 :SEARch Commands :SEARch:SERial:UART:QUALifier (see page 792) Command Syntax :SEARch:SERial:UART:QUALifier ::= {EQUal | NOTequal | GREaterthan | LESSthan} The :SEARch:SERial:UART:QUALifier command specifies the data value qualifier when searching for UART/RS232 events. Query Syntax :SEARch:SERial:UART:QUALifier? The :SEARch:SERial:UART:QUALifier? query returns the current data value qualifier setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 27 :SYSTem Commands Control basic system functions of the oscilloscope. See "Introduction to :SYSTem Commands" on page 564. Table 87 :SYSTem Commands Summary Command Query Options and Query Returns :SYSTem:DATE (see page 565) :SYSTem:DATE? (see page 565) ::= ,, ::= 4-digit year in NR1 format ::= {1,..
27 :SYSTem Commands Introduction to :SYSTem Commands 564 SYSTem subsystem commands enable writing messages to the display, setting and reading both the time and the date, querying for errors, and saving and recalling setups.
:SYSTem Commands 27 :SYSTem:DATE (see page 792) Command Syntax :SYSTem:DATE ::= ,, ::= 4-digit year in NR1 format ::= {1,..,12 | JANuary | FEBruary | MARch | APRil | MAY | JUNe | JULy | AUGust | SEPtember | OCTober | NOVember | DECember} ::= {1,..,31} The :SYSTem:DATE command sets the date. Validity checking is performed to ensure that the date is valid. Query Syntax :SYSTem:DATE? The SYSTem:DATE? query returns the date.
27 :SYSTem Commands :SYSTem:DSP (see page 792) Command Syntax :SYSTem:DSP ::= quoted ASCII string (up to 75 characters) The :SYSTem:DSP command writes the quoted string (excluding quotation marks) to a text box in the center of the display. Use :SYStem:DSP "" to remotely remove the message from the display. (Two sets of quote marks without a space between them creates a NULL string.) Press any menu key to manually remove the message from the display.
:SYSTem Commands 27 :SYSTem:ERRor (see page 792) Query Syntax :SYSTem:ERRor? The :SYSTem:ERRor? query outputs the next error number and text from the error queue. The instrument has an error queue that is 30 errors deep and operates on a first-in, first-out basis. Repeatedly sending the :SYSTem:ERRor? query returns the errors in the order that they occurred until the queue is empty. Any further queries then return zero until another error occurs.
27 :SYSTem Commands :SYSTem:LOCK (see page 792) Command Syntax :SYSTem:LOCK ::= {{1 | ON} | {0 | OFF}} The :SYSTem:LOCK command disables the front panel. LOCK ON is the equivalent of sending a local lockout message over the programming interface. Query Syntax :SYSTem:LOCK? The :SYSTem:LOCK? query returns the lock status of the front panel.
:SYSTem Commands 27 :SYSTem:MENU (see page 792) Command Syntax :SYSTem:MENU
27 :SYSTem Commands :SYSTem:PRESet (see page 792) Command Syntax :SYSTem:PRESet The :SYSTem:PRESet command places the instrument in a known state. This is the same as pressing the [Defaul t Setup] key or [Save/Recall] > Defaul t/Erase > Defaul t Setup on the front panel. When you perform a default setup, some user settings (like preferences) remain unchanged. To reset all user settings to their factory defaults, use the *RST command.
:SYSTem Commands 27 Digital Channel Menu (MSO models only) Channel 0 - 7 Off Labels Off Threshold TTL (1.4 V) Display Menu Persistence Off Grid 20% Quick Meas Menu Source Channel 1 Run Control Scope is running Time Base Menu Main time/division 100 us Main time base delay 0.00 s Delay time/division 500 ns Delay time base delay 0.00 s Reference center Mode main Vernier Off Trigger Menu Type Edge Mode Auto Coupling dc Source Channel 1 Level 0.
27 :SYSTem Commands Trigger Menu See Also 572 HF Reject and noise reject Off Holdoff 40 ns External probe attenuation 10:1 External Units Volts External Impedance 1 M Ohm (cannot be changed) • "Introduction to Common (*) Commands" on page 123 • "*RST (Reset)" on page 136 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:SYSTem Commands 27 :SYSTem:PROTection:LOCK (see page 792) Command Syntax :SYSTem:PROTection:LOCK ::= {{1 | ON} | {0 | OFF}} The :SYSTem:PROTection:LOCK command disables the fifty ohm impedance setting for all analog channels. Query Syntax :SYSTem:PROTection:LOCK? The :SYSTem:PROTection:LOCK? query returns the analog channel protection lock status.
27 :SYSTem Commands :SYSTem:SETup (see page 792) Command Syntax :SYSTem:SETup ::= binary block data in IEEE 488.2 # format. The :SYSTem:SETup command sets the oscilloscope as defined by the data in the setup (learn) string sent from the controller. The setup string does not change the interface mode or interface address. Query Syntax :SYSTem:SETup? The :SYSTem:SETup? query operates the same as the *LRN? query.
:SYSTem Commands 27 ' command: myScope.
27 :SYSTem Commands :SYSTem:TIME (see page 792) Command Syntax :SYSTem:TIME ::= hours,minutes,seconds in NR1 format The :SYSTem:TIME command sets the system time, using a 24-hour format. Commas are used as separators. Validity checking is performed to ensure that the time is valid. Query Syntax :SYSTem:TIME? The :SYSTem:TIME? query returns the current system time.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 28 :TIMebase Commands Control all horizontal sweep functions. See "Introduction to :TIMebase Commands" on page 578.
28 :TIMebase Commands Introduction to :TIMebase Commands The TIMebase subsystem commands control the horizontal (X-axis) functions and set the oscilloscope to X-Y mode (where channel 1 becomes the X input and channel 2 becomes the Y input). The time per division, delay, vernier control, and reference can be controlled for the main and window (zoomed) time bases. Reporting the Setup Use :TIMebase? to query setup information for the TIMebase subsystem.
28 :TIMebase Commands :TIMebase:MODE (see page 792) Command Syntax :TIMebase:MODE ::= {MAIN | WINDow | XY | ROLL} The :TIMebase:MODE command sets the current time base. There are four time base modes: Query Syntax • MAIN — The normal time base mode is the main time base. It is the default time base mode after the *RST (Reset) command.
28 :TIMebase Commands :TIMebase:POSition (see page 792) Command Syntax :TIMebase:POSition ::= time in seconds from the trigger to the display reference in NR3 format The :TIMebase:POSition command sets the time interval between the trigger event and the display reference point on the screen. The display reference point is either left, right, or center and is set with the :TIMebase:REFerence command. The maximum position value depends on the time/division settings.
:TIMebase Commands 28 :TIMebase:RANGe (see page 792) Command Syntax :TIMebase:RANGe ::= time for 10 div in seconds in NR3 format The :TIMebase:RANGe command sets the full-scale horizontal time in seconds for the main window. The range is 10 times the current time-per-division setting. Query Syntax :TIMebase:RANGe? The :TIMebase:RANGe query returns the current full-scale range value for the main window.
28 :TIMebase Commands :TIMebase:REFerence (see page 792) Command Syntax :TIMebase:REFerence ::= {LEFT | CENTer | RIGHt} The :TIMebase:REFerence command sets the time reference to one division from the left side of the screen, to the center of the screen, or to one division from the right side of the screen. Time reference is the point on the display where the trigger point is referenced.
:TIMebase Commands 28 :TIMebase:SCALe (see page 792) Command Syntax :TIMebase:SCALe ::= time/div in seconds in NR3 format The :TIMebase:SCALe command sets the horizontal scale or units per division for the main window. Query Syntax :TIMebase:SCALe? The :TIMebase:SCALe? query returns the current horizontal scale setting in seconds per division for the main window.
28 :TIMebase Commands :TIMebase:VERNier (see page 792) Command Syntax :TIMebase:VERNier ::= {{1 | ON} | {0 | OFF} The :TIMebase:VERNier command specifies whether the time base control's vernier (fine horizontal adjustment) setting is ON (1) or OFF (0). Query Syntax :TIMebase:VERNier? The :TIMebase:VERNier? query returns the current state of the time base control's vernier setting.
:TIMebase Commands 28 :TIMebase:WINDow:POSition (see page 792) Command Syntax :TIMebase:WINDow:POSition ::= time from the trigger event to the zoomed (delayed) view reference point in NR3 format The :TIMebase:WINDow:POSition command sets the horizontal position in the zoomed (delayed) view of the main sweep. The main sweep range and the main sweep horizontal position determine the range for this command.
28 :TIMebase Commands :TIMebase:WINDow:RANGe (see page 792) Command Syntax :TIMebase:WINDow:RANGe ::= range value in seconds in NR3 format The :TIMebase:WINDow:RANGe command sets the full-scale horizontal time in seconds for the zoomed (delayed) window. The range is 10 times the current zoomed view window seconds per division setting. The main sweep range determines the range for this command. The maximum value is one half of the :TIMebase:RANGe value.
:TIMebase Commands 28 :TIMebase:WINDow:SCALe (see page 792) Command Syntax :TIMebase:WINDow:SCALe ::= scale value in seconds in NR3 format The :TIMebase:WINDow:SCALe command sets the zoomed (delayed) window horizontal scale (seconds/division). The main sweep scale determines the range for this command. The maximum value is one half of the :TIMebase:SCALe value.
28 :TIMebase Commands 588 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 29 :TRIGger Commands Control the trigger modes and parameters for each trigger type.
29 :TRIGger Commands • TV triggering— is used to capture the complicated waveforms of television equipment. The trigger circuitry detects the vertical and horizontal interval of the waveform and produces triggers based on the TV trigger settings you selected. TV triggering requires greater than ¼ division of sync amplitude with any analog channel as the trigger source. Reporting the Setup Use :TRIGger? to query setup information for the TRIGger subsystem.
29 :TRIGger Commands General :TRIGger Commands Table 89 General :TRIGger Commands Summary Command Query Options and Query Returns :TRIGger:FORCe (see page 592) n/a n/a :TRIGger:HFReject {{0 | OFF} | {1 | ON}} (see page 593) :TRIGger:HFReject? (see page 593) {0 | 1} :TRIGger:HOLDoff (see page 594) :TRIGger:HOLDoff? (see page 594) ::= 60 ns to 10 s in NR3 format :TRIGger:LEVel:ASETup (see page 595) n/a n/a :TRIGger:LEVel:HIGH , (see page 596) :TR
29 :TRIGger Commands :TRIGger:FORCe (see page 792) Command Syntax :TRIGger:FORCe The :TRIGger:FORCe command causes an acquisition to be captured even though the trigger condition has not been met. This command is equivalent to the front panel [Force Trigger] key.
:TRIGger Commands 29 :TRIGger:HFReject (see page 792) Command Syntax :TRIGger:HFReject ::= {{0 | OFF} | {1 | ON}} The :TRIGger:HFReject command turns the high frequency reject filter off and on. The high frequency reject filter adds a 50 kHz low-pass filter in the trigger path to remove high frequency components from the trigger waveform. Use this filter to remove high-frequency noise, such as AM or FM broadcast stations, from the trigger path.
29 :TRIGger Commands :TRIGger:HOLDoff (see page 792) Command Syntax :TRIGger:HOLDoff ::= 60 ns to 10 s in NR3 format The :TRIGger:HOLDoff command defines the holdoff time value in seconds. Holdoff keeps a trigger from occurring until after a certain amount of time has passed since the last trigger. This feature is valuable when a waveform crosses the trigger level multiple times during one period of the waveform.
:TRIGger Commands 29 :TRIGger:LEVel:ASETup (see page 792) Command Syntax :TRIGger:LEVel:ASETup The :TRIGger:LEVel:ASETup command automatically sets the trigger levels of all displayed analog channels to their waveforms' 50% values. If AC coupling is used, the trigger levels are set to 0 V. When High and Low (dual) trigger levels are used (as with Rise/Fall Time and Runt triggers, for example), this command has no effect.
29 :TRIGger Commands :TRIGger:LEVel:HIGH (see page 792) Command Syntax :TRIGger:LEVel:HIGH , ::= 0.75 x full-scale voltage from center screen in NR3 format for internal triggers ::= CHANnel ::= 1 to (# analog channels) in NR1 format The :TRIGger:LEVel:HIGH command sets the high trigger voltage level voltage for the specified source.
:TRIGger Commands 29 :TRIGger:LEVel:LOW (see page 792) Command Syntax :TRIGger:LEVel:LOW , ::= 0.75 x full-scale voltage from center screen in NR3 format for internal triggers ::= CHANnel ::= 1 to (# analog channels) in NR1 format The :TRIGger:LEVel:LOW command sets the low trigger voltage level voltage for the specified source. Query Syntax :TRIGger:LEVel:LOW? The :TRIGger:LEVel:LOW? query returns the low trigger voltage level for the specified source.
29 :TRIGger Commands :TRIGger:MODE (see page 792) Command Syntax :TRIGger:MODE ::= {EDGE | GLITch | PATTern | TV} The :TRIGger:MODE command selects the trigger mode (trigger type). Query Syntax :TRIGger:MODE? The :TRIGger:MODE? query returns the current trigger mode. If the :TIMebase:MODE is ROLL or XY, the query returns "NONE".
:TRIGger Commands 29 :TRIGger:NREJect (see page 792) Command Syntax :TRIGger:NREJect ::= {{0 | OFF} | {1 | ON}} The :TRIGger:NREJect command turns the noise reject filter off and on. When the noise reject filter is on, the trigger circuitry is less sensitive to noise but may require a greater amplitude waveform to trigger the oscilloscope. This command is not valid in TV trigger mode.
29 :TRIGger Commands :TRIGger:SWEep (see page 792) Command Syntax :TRIGger:SWEep ::= {AUTO | NORMal} The :TRIGger:SWEep command selects the trigger sweep mode. When AUTO sweep mode is selected, a baseline is displayed in the absence of a signal. If a signal is present but the oscilloscope is not triggered, the unsynchronized signal is displayed instead of a baseline.
29 :TRIGger Commands :TRIGger[:EDGE] Commands Table 90 :TRIGger[:EDGE] Commands Summary Command Query Options and Query Returns :TRIGger[:EDGE]:COUPl ing {AC | DC | LFReject} (see page 602) :TRIGger[:EDGE]:COUPl ing? (see page 602) {AC | DC | LFReject} :TRIGger[:EDGE]:LEVel [,] (see page 603) :TRIGger[:EDGE]:LEVel ? [] (see page 603) For internal triggers, ::= .75 x full-scale voltage from center screen in NR3 format.
29 :TRIGger Commands :TRIGger[:EDGE]:COUPling (see page 792) Command Syntax :TRIGger[:EDGE]:COUPling ::= {AC | DC | LFReject} The :TRIGger[:EDGE]:COUPling command sets the input coupling for the selected trigger sources. The coupling can be set to AC, DC, or LFReject. • AC coupling places a high-pass filter (10 Hz for analog channels, and 3.5 Hz for all External trigger inputs) in the trigger path, removing dc offset voltage from the trigger waveform.
:TRIGger Commands 29 :TRIGger[:EDGE]:LEVel (see page 792) Command Syntax :TRIGger[:EDGE]:LEVel ::= [,] ::= 0.
29 :TRIGger Commands :TRIGger[:EDGE]:REJect (see page 792) Command Syntax :TRIGger[:EDGE]:REJect ::= {OFF | LFReject | HFReject} The :TRIGger[:EDGE]:REJect command turns the low-frequency or high-frequency reject filter on or off. You can turn on one of these filters at a time. • The high frequency reject filter adds a 50 kHz low-pass filter in the trigger path to remove high frequency components from the trigger waveform.
:TRIGger Commands 29 :TRIGger[:EDGE]:SLOPe (see page 792) Command Syntax :TRIGger[:EDGE]:SLOPe ::= {NEGative | POSitive | EITHer | ALTernate} The :TRIGger[:EDGE]:SLOPe command specifies the slope of the edge for the trigger. The SLOPe command is not valid in TV trigger mode. Instead, use :TRIGger:TV:POLarity to set the polarity in TV trigger mode. Query Syntax :TRIGger[:EDGE]:SLOPe? The :TRIGger[:EDGE]:SLOPe? query returns the current trigger slope.
29 :TRIGger Commands :TRIGger[:EDGE]:SOURce (see page 792) Command Syntax :TRIGger[:EDGE]:SOURce ::= {CHANnel | EXTernal | LINE | WGEN} for the DSO models ::= {CHANnel | DIGital | EXTernal | LINE | WGEN} for the MSO models ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :TRIGger[:EDGE]:SOURce command selects the input that produces the trigger.
29 :TRIGger Commands :TRIGger:GLITch Commands Table 91 :TRIGger:GLITch Commands Summary Command Query Options and Query Returns :TRIGger:GLITch:GREat erthan [s uffix] (see page 609) :TRIGger:GLITch:GREat erthan? (see page 609) ::= floating-point number in NR3 format [suffix] ::= {s | ms | us | ns | ps} :TRIGger:GLITch:LESSt han [suff ix] (see page 610) :TRIGger:GLITch:LESSt han? (see page 610) ::= floating-point number in NR3
29 :TRIGger Commands Table 91 :TRIGger:GLITch Commands Summary (continued) Command Query Options and Query Returns :TRIGger:GLITch:RANGe [suff ix], [s uffix] (see page 614) :TRIGger:GLITch:RANGe ? (see page 614) ::= 15 ns to 10 seconds in NR3 format ::= 10 ns to 9.
:TRIGger Commands 29 :TRIGger:GLITch:GREaterthan (see page 792) Command Syntax :TRIGger:GLITch:GREaterthan [] ::= floating-point number in NR3 format ::= {s | ms | us | ns | ps} The :TRIGger:GLITch:GREaterthan command sets the minimum pulse width duration for the selected :TRIGger:GLITch:SOURce.
29 :TRIGger Commands :TRIGger:GLITch:LESSthan (see page 792) Command Syntax :TRIGger:GLITch:LESSthan [] ::= floating-point number in NR3 format ::= {s | ms | us | ns | ps} The :TRIGger:GLITch:LESSthan command sets the maximum pulse width duration for the selected :TRIGger:GLITch:SOURce. Query Syntax :TRIGger:GLITch:LESSthan? The :TRIGger:GLITch:LESSthan? query returns the pulse width duration time for :TRIGger:GLITch:SOURce.
:TRIGger Commands 29 :TRIGger:GLITch:LEVel (see page 792) Command Syntax :TRIGger:GLITch:LEVel ::= [, ] ::= .
29 :TRIGger Commands :TRIGger:GLITch:POLarity (see page 792) Command Syntax :TRIGger:GLITch:POLarity ::= {POSitive | NEGative} The :TRIGger:GLITch:POLarity command sets the polarity for the glitch pulse width trigger. Query Syntax :TRIGger:GLITch:POLarity? The :TRIGger:GLITch:POLarity? query returns the glitch pulse width trigger polarity.
29 :TRIGger Commands :TRIGger:GLITch:QUALifier (see page 792) Command Syntax :TRIGger:GLITch:QUALifier ::= {GREaterthan | LESSthan | RANGe} This command sets the mode of operation of the glitch pulse width trigger. The oscilloscope can trigger on a pulse width that is greater than a time value, less than a time value, or within a range of time values. Query Syntax :TRIGger:GLITch:QUALifier? The :TRIGger:GLITch:QUALifier? query returns the glitch pulse width qualifier.
29 :TRIGger Commands :TRIGger:GLITch:RANGe (see page 792) Command Syntax :TRIGger:GLITch:RANGe [suffix], [suffix] ::= (15 ns - 10 seconds) in NR3 format ::= (10 ns - 9.99 seconds) in NR3 format [suffix] ::= {s | ms | us | ns | ps} The :TRIGger:GLITch:RANGe command sets the pulse width duration for the selected :TRIGger:GLITch:SOURce.
:TRIGger Commands 29 :TRIGger:GLITch:SOURce (see page 792) Command Syntax :TRIGger:GLITch:SOURce ::= {DIGital | CHANnel} ::= 1 to (# analog channels) in NR1 format ::= 0 to (# digital channels - 1) in NR1 format The :TRIGger:GLITch:SOURce command selects the channel that produces the pulse width trigger. Query Syntax :TRIGger:GLITch:SOURce? The :TRIGger:GLITch:SOURce? query returns the current pulse width source. If all channels are off, the query returns "NONE".
29 :TRIGger Commands :TRIGger:PATTern Commands Table 92 :TRIGger:PATTern Commands Summary Command Query Options and Query Returns :TRIGger:PATTern [,,] (see page 617) :TRIGger:PATTern? (see page 618) ::= "nn...n" where n ::= {0 | 1 | X | R | F} when = ASCii ::= "0xnn...n" where n ::= {0,..,9 | A,..
29 :TRIGger Commands :TRIGger:PATTern (see page 792) Command Syntax :TRIGger:PATTern ::= [,,] ::= "nn...n" where n ::= {0 | 1 | X | R | F} when = ASCii ::= "0xnn...n" where n ::= {0,..,9 | A,..
29 :TRIGger Commands NOTE The optional and parameters should be sent together or not at all. The edge can be specified in the ASCII parameter. If the edge source and edge parameters are used, they take precedence. You can only specify an edge on one channel. When an edge is specified, the :TRIGger:PATTern:QUALifier does not apply. Query Syntax :TRIGger:PATTern? The :TRIGger:PATTern? query returns the pattern string, edge source, and edge.
29 :TRIGger Commands :TRIGger:PATTern:FORMat (see page 792) Command Syntax :TRIGger:PATTern:FORMat ::= {ASCii | HEX} The :TRIGger:PATTern:FORMat command sets the entry (and query) number base used by the :TRIGger:PATTern command. The default is ASCii. Query Syntax :TRIGger:PATTern:FORMat? The :TRIGger:PATTern:FORMat? query returns the currently set number base for pattern trigger patterns.
29 :TRIGger Commands :TRIGger:PATTern:QUALifier (see page 792) Command Syntax :TRIGger:PATTern:QUALifier ::= ENTered The :TRIGger:PATTern:QUALifier command qualifies when the trigger occurs. In the InfiniiVision 2000 X-Series oscilloscopes, the trigger always occurs when the pattern is entered. Query Syntax :TRIGger:PATTern:QUALifier? The :TRIGger:PATTern:QUALifier? query returns the trigger duration qualifier.
29 :TRIGger Commands :TRIGger:TV Commands Table 93 :TRIGger:TV Commands Summary Command Query Options and Query Returns :TRIGger:TV:LINE (see page 622) :TRIGger:TV:LINE? (see page 622) ::= integer in NR1 format :TRIGger:TV:MODE (see page 623) :TRIGger:TV:MODE? (see page 623) ::= {FIEld1 | FIEld2 | AFIelds | ALINes | LFIeld1 | LFIeld2 | LALTernate} :TRIGger:TV:POLarity (see page 624) :TRIGger:TV:POLarity? (see page 624) ::= {P
29 :TRIGger Commands :TRIGger:TV:LINE (see page 792) Command Syntax :TRIGger:TV:LINE ::= integer in NR1 format The :TRIGger:TV:LINE command allows triggering on a specific line of video. The line number limits vary with the standard and mode, as shown in the following table.
:TRIGger Commands 29 :TRIGger:TV:MODE (see page 792) Command Syntax :TRIGger:TV:MODE ::= {FIEld1 | FIEld2 | AFIelds | ALINes | LFIeld1 | LFIeld2 | LALTernate} The :TRIGger:TV:MODE command selects the TV trigger mode and field.
29 :TRIGger Commands :TRIGger:TV:POLarity (see page 792) Command Syntax :TRIGger:TV:POLarity ::= {POSitive | NEGative} The :TRIGger:TV:POLarity command sets the polarity for the TV trigger. Query Syntax :TRIGger:TV:POLarity? The :TRIGger:TV:POLarity? query returns the TV trigger polarity.
:TRIGger Commands 29 :TRIGger:TV:SOURce (see page 792) Command Syntax :TRIGger:TV:SOURce ::= {CHANnel} ::= 1 to (# analog channels) in NR1 format The :TRIGger:TV:SOURce command selects the channel used to produce the trigger. Query Syntax :TRIGger:TV:SOURce? The :TRIGger:TV:SOURce? query returns the current TV trigger source.
29 :TRIGger Commands :TRIGger:TV:STANdard (see page 792) Command Syntax :TRIGger:TV:STANdard ::= {NTSC | PALM | PAL | SECam} The :TRIGger:TV:STANdard command selects the video standard: Query Syntax • NTSC • PAL • PAL-M • SECAM :TRIGger:TV:STANdard? The :TRIGger:TV:STANdard? query returns the current TV trigger standard setting.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 30 :WAVeform Commands Provide access to waveform data. See "Introduction to :WAVeform Commands" on page 629.
30 :WAVeform Commands Table 95 :WAVeform Commands Summary (continued) Command Query Options and Query Returns :WAVeform:POINts:MODE (see page 642) :WAVeform:POINts:MODE ? (see page 642) ::= {NORMal | MAXimum | RAW} n/a :WAVeform:PREamble? (see page 644) ::= , ,,, , , ,, , ::= an integer in NR1 format: • 0 for BY
30 :WAVeform Commands Table 95 :WAVeform Commands Summary (continued) Command Query Options and Query Returns :WAVeform:UNSigned {{0 | OFF} | {1 | ON}} (see page 655) :WAVeform:UNSigned? (see page 655) {0 | 1} :WAVeform:VIEW (see page 656) :WAVeform:VIEW? (see page 656) ::= {MAIN} n/a :WAVeform:XINCrement? (see page 657) ::= x-increment in the current preamble in NR3 format n/a :WAVeform:XORigin? (see page 658) ::= x-origin value in the current pre
30 :WAVeform Commands There are four types of waveform acquisitions that can be selected for analog channels with the :ACQuire:TYPE command (see page 195): NORMal, AVERage, PEAK, and HRESolution. Digital channels are always acquired using NORMal. When the data is acquired using the :DIGitize command (see page 159) or :RUN command (see page 176), the data is placed in the channel buffer of the specified source. Once you have acquired data with the :DIGitize command, the instrument is stopped.
:WAVeform Commands 30 next-to-last time bucket on the right side of the screen. Time buckets without data return 0. The time values for each data point correspond to the position of the data point in the data array. These time values are not transmitted. AVERage Data AVERage data consists of the average of the first n hits in a time bucket, where n is the value returned by the :ACQuire:COUNt query (see page 186). Time buckets that have fewer than n hits return the average of the data they do have.
30 :WAVeform Commands If the :WAVeform:FORMat data format is ASCii (see page 639), the data values are converted internally and sent as floating point values separated by commas. In converting a data value to time, the time value of a data point can be determined by the position of the data point.
30 :WAVeform Commands WORD format (see ":WAVeform:FORMat" on page 639) provides 16-bit access to the waveform data. In the WORD format, the number of data bytes is twice the number of data points. The number of data points is the value returned by the :WAVeform:POINts? query (see page 640). If the data intrinsically has less than 16 bits of resolution, the data is left-shifted to provide 16 bits of resolution and the least significant bits are set to 0.
30 :WAVeform Commands If a digital channel is not displayed, its bit value in the pod data byte is not defined. Digital Channel BUS Data Format Digital channel BUS definitions can include any or all of the digital channels. Therefore, data is always returned as 16-bit values. :BUS commands (see page 197) are used to select the digital channels for a bus. Reporting the Setup The following is a sample response from the :WAVeform? query. In this case, the query was issued following a *RST command.
:WAVeform Commands 30 :WAVeform:BYTeorder (see page 792) Command Syntax :WAVeform:BYTeorder ::= {LSBFirst | MSBFirst} The :WAVeform:BYTeorder command sets the output sequence of the WORD data. • MSBFirst — sets the most significant byte to be transmitted first. • LSBFirst — sets the least significant byte to be transmitted first. This command affects the transmitting sequence only when :WAVeform:FORMat WORD is selected. The default setting is MSBFirst.
30 :WAVeform Commands :WAVeform:COUNt (see page 792) Query Syntax :WAVeform:COUNt? The :WAVeform:COUNT? query returns the count used to acquire the current waveform. This may differ from current values if the unit has been stopped and its configuration modified. For all acquisition types except average, this value is 1.
:WAVeform Commands 30 :WAVeform:DATA (see page 792) Query Syntax :WAVeform:DATA? The :WAVeform:DATA query returns the binary block of sampled data points transmitted using the IEEE 488.2 arbitrary block data format. The binary data is formatted according to the settings of the :WAVeform:UNSigned, :WAVeform:BYTeorder, :WAVeform:FORMat, and :WAVeform:SOURce commands. The number of points returned is controlled by the :WAVeform:POINts command.
30 :WAVeform Commands ' The "#8" may be stripped off of the header and the remaining ' numbers are the size, in bytes, of the waveform data block. The ' size can vary depending on the number of points acquired for the ' waveform. You can then read that number of bytes from the ' oscilloscope and the terminating NL character. ' Dim lngI As Long Dim lngDataValue As Long varQueryResult = myScope.ReadIEEEBlock(BinaryType_UI1) ' Unsigned integer bytes.
:WAVeform Commands 30 :WAVeform:FORMat (see page 792) Command Syntax :WAVeform:FORMat ::= {WORD | BYTE | ASCii} The :WAVeform:FORMat command sets the data transmission mode for waveform data points. This command controls how the data is formatted when sent from the oscilloscope. • ASCii formatted data converts the internal integer data values to real Y-axis values. Values are transferred as ASCii digits in floating point notation, separated by commas.
30 :WAVeform Commands :WAVeform:POINts (see page 792) Command Syntax :WAVeform:POINts <# points> <# points> ::= {100 | 250 | 500 | 1000 | } if waveform points mode is NORMal <# points> ::= {100 | 250 | 500 | 1000 | 2000 | 5000 | 10000 | 20000 | 50000 | 100000 | 200000 | 500000 | 1000000 | 2000000 | 4000000 | 8000000 | } if waveform points mode is MAXimum or RAW ::= {NORMal | MAXimum | RAW} NOTE The option is deprecated.
:WAVeform Commands NOTE See Also Example Code 30 If a full screen of data is not displayed, the number of points returned will not be 1000 or an even divisor of it.
30 :WAVeform Commands :WAVeform:POINts:MODE (see page 792) Command Syntax :WAVeform:POINts:MODE ::= {NORMal | MAXimum | RAW} The :WAVeform:POINts:MODE command sets the data record to be transferred with the :WAVeform:DATA? query. For the analog or digital sources, there are two different records that can be transferred: • The first is the raw acquisition record. The maximum number of points available in this record is returned by the :ACQuire:POINts? query.
:WAVeform Commands 30 ::= {NORMal | MAXimum | RAW} See Also • "Introduction to :WAVeform Commands" on page 629 • ":WAVeform:DATA" on page 637 • ":ACQuire:POINts" on page 188 • ":WAVeform:VIEW" on page 656 • ":WAVeform:PREamble" on page 644 • ":WAVeform:POINts" on page 640 • ":TIMebase:MODE" on page 579 • ":ACQuire:TYPE" on page 195 • ":ACQuire:COUNt" on page 186 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 643
30 :WAVeform Commands :WAVeform:PREamble (see page 792) Query Syntax :WAVeform:PREamble? The :WAVeform:PREamble query requests the preamble information for the selected waveform source. The preamble data contains information concerning the vertical and horizontal scaling of the data of the corresponding channel.
:WAVeform Commands Example Code • ":ACQuire:POINts" on page 188 • ":ACQuire:TYPE" on page 195 • ":DIGitize" on page 159 • ":WAVeform:COUNt" on page 636 • ":WAVeform:DATA" on page 637 • ":WAVeform:FORMat" on page 639 • ":WAVeform:POINts" on page 640 • ":WAVeform:TYPE" on page 654 • ":WAVeform:XINCrement" on page 657 • ":WAVeform:XORigin" on page 658 • ":WAVeform:XREFerence" on page 659 • ":WAVeform:YINCrement" on page 660 • ":WAVeform:YORigin" on page 661 • ":WAVeform:YREFerence"
30 :WAVeform Commands lngCount = Preamble(3) dblXIncrement = Preamble(4) dblXOrigin = Preamble(5) lngXReference = Preamble(6) sngYIncrement = Preamble(7) sngYOrigin = Preamble(8) lngYReference = Preamble(9) See complete example programs at: Chapter 38, “Programming Examples,” starting on page 801 646 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
:WAVeform Commands 30 :WAVeform:SEGMented:COUNt (see page 792) Query Syntax NOTE :WAVeform:SEGMented:COUNt? This command is available when the segmented memory option (Option SGM) is enabled. The :WAVeform:SEGMented:COUNt query returns the number of memory segments in the acquired data. You can use the :WAVeform:SEGMented:COUNt? query while segments are being acquired (although :DIGitize blocks subsequent queries until the full segmented acquisition is complete).
30 :WAVeform Commands :WAVeform:SEGMented:TTAG (see page 792) Query Syntax NOTE :WAVeform:SEGMented:TTAG? This command is available when the segmented memory option (Option SGM) is enabled. The :WAVeform:SEGMented:TTAG? query returns the time tag of the currently selected segmented memory index. The index is selected using the :ACQuire:SEGMented:INDex command.
:WAVeform Commands 30 :WAVeform:SOURce (see page 792) Command Syntax :WAVeform:SOURce ::= {CHANnel | FUNCtion | MATH | WMEMory | SBUS1} for DSO models ::= {CHANnel | POD{1 | 2} | BUS{1 | 2} | FUNCtion | MATH | WMEMory | SBUS1} for MSO models ::= 1 to (# analog channels) in NR1 format ::= {1 | 2} The :WAVeform:SOURce command selects the analog channel, function, digital pod, digital bus, reference waveform, or serial decode bus to be used as the source for t
30 :WAVeform Commands Return Format ::= {CHAN | FUNC | WMEM | SBUS1} for DSO models ::= {CHAN | POD{1 | 2} | BUS{1 | 2} | FUNC | WMEM | SBUS1} for MSO models ::= 1 to (# analog channels) in NR1 format ::= {1 | 2} See Also Example Code • "Introduction to :WAVeform Commands" on page 629 • ":DIGitize" on page 159 • ":WAVeform:FORMat" on page 639 • ":WAVeform:BYTeorder" on page 635 • ":WAVeform:DATA" on page 637 • ":WAVeform:PREamble" on page 64
:WAVeform Commands ' ' ' ' ' ' ' Dim Dim Dim Dim Dim Dim Dim Dim Dim Dim Dim Dim XORIGIN XREFERENCE YINCREMENT YORIGIN YREFERENCE 30 : float64 - always the first data point in memory. : int32 - specifies the data point associated with x-origin. : float32 - voltage diff between data points. : float32 - value is the voltage at center screen. : int32 - specifies the data point where y-origin occurs.
30 :WAVeform Commands 1000000) + " us" + vbCrLf strOutput = strOutput + "Delay = " + _ FormatNumber(((lngPoints / 2 - lngXReference) * _ dblXIncrement + dblXOrigin) * 1000000) + " us" + vbCrLf ' QUERY_WAVE_DATA - Outputs waveform data that is stored in a buffer. ' Query the oscilloscope for the waveform data. myScope.WriteString ":WAV:DATA?" ' READ_WAVE_DATA - The wave data consists of two parts: the header, ' and the actual waveform data followed by a new line (NL) character.
30 :WAVeform Commands :WAVeform:SOURce:SUBSource (see page 792) Command Syntax :WAVeform:SOURce:SUBSource ::= {{SUB0 | RX | MOSI} | {SUB1 | TX | MISO}} If the :WAVeform:SOURce is SBUS (serial decode), more than one data set may be available, and this command lets you choose from the available data sets. When using UART serial decode, this option lets you get "TX" data. (TX is an alias for SUB1.) The default, SUB0, specifies "RX" data. (RX is an alias for SUB0.
30 :WAVeform Commands :WAVeform:TYPE (see page 792) Query Syntax :WAVeform:TYPE? The :WAVeform:TYPE? query returns the acquisition mode associated with the currently selected waveform. The acquisition mode is set by the :ACQuire:TYPE command. Return Format ::= {NORM | PEAK | AVER | HRES} NOTE See Also 654 If the :WAVeform:SOURce is POD1 or POD2, the type is always NORM.
:WAVeform Commands 30 :WAVeform:UNSigned (see page 792) Command Syntax :WAVeform:UNSigned ::= {{0 | OFF} | {1 | ON}} The :WAVeform:UNSigned command turns unsigned mode on or off for the currently selected waveform. Use the WAVeform:UNSigned command to control whether data values are sent as unsigned or signed integers. This command can be used to match the instrument's internal data type to the data type used by the programming language.
30 :WAVeform Commands :WAVeform:VIEW (see page 792) Command Syntax :WAVeform:VIEW ::= {MAIN} The :WAVeform:VIEW command sets the view setting associated with the currently selected waveform. Currently, the only legal value for the view setting is MAIN. Query Syntax :WAVeform:VIEW? The :WAVeform:VIEW? query returns the view setting associated with the currently selected waveform.
:WAVeform Commands 30 :WAVeform:XINCrement (see page 792) Query Syntax :WAVeform:XINCrement? The :WAVeform:XINCrement? query returns the x-increment value for the currently specified source. This value is the time difference between consecutive data points in seconds.
30 :WAVeform Commands :WAVeform:XORigin (see page 792) Query Syntax :WAVeform:XORigin? The :WAVeform:XORigin? query returns the x-origin value for the currently specified source. XORigin is the X-axis value of the data point specified by the :WAVeform:XREFerence value. In this product, that is always the X-axis value of the first data point (XREFerence = 0).
:WAVeform Commands 30 :WAVeform:XREFerence (see page 792) Query Syntax :WAVeform:XREFerence? The :WAVeform:XREFerence? query returns the x-reference value for the currently specified source. This value specifies the index of the data point associated with the x-origin data value. In this product, the x-reference point is the first point displayed and XREFerence is always 0.
30 :WAVeform Commands :WAVeform:YINCrement (see page 792) Query Syntax :WAVeform:YINCrement? The :WAVeform:YINCrement? query returns the y-increment value in volts for the currently specified source. This value is the voltage difference between consecutive data values. The y-increment for digital waveforms is always "1".
30 :WAVeform Commands :WAVeform:YORigin (see page 792) Query Syntax :WAVeform:YORigin? The :WAVeform:YORigin? query returns the y-origin value for the currently specified source. This value is the Y-axis value of the data value specified by the :WAVeform:YREFerence value. For this product, this is the Y-axis value of the center of the screen.
30 :WAVeform Commands :WAVeform:YREFerence (see page 792) Query Syntax :WAVeform:YREFerence? The :WAVeform:YREFerence? query returns the y-reference value for the currently specified source. This value specifies the data point value where the y-origin occurs. In this product, this is the data point value of the center of the screen. It is undefined if the format is ASCii.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 31 :WGEN Commands When the built-in waveform generator is licensed (Option WGN), you can use it to output sine, square, ramp, pulse, DC, and noise waveforms. The :WGEN commands are used to select the waveform function and parameters. See "Introduction to :WGEN Commands" on page 665.
31 :WGEN Commands Table 96 :WGEN Commands Summary (continued) Command Query Options and Query Returns :WGEN:MODulation:FM:F REQuency (see page 675) :WGEN:MODulation:FM:F REQuency? (see page 675) ::= modulating waveform frequency in Hz in NR3 format :WGEN:MODulation:FSKe y:FREQuency (see page 676) :WGEN:MODulation:FSKe y:FREQuency? (see page 676) ::= hop frequency in Hz in NR3 format :WGEN:MODulation:FSKe y:RATE (see page 677) :WGEN:MODulation:F
:WGEN Commands 31 Table 96 :WGEN Commands Summary (continued) Command Query Options and Query Returns :WGEN:VOLTage:LOW (see page 690) :WGEN:VOLTage:LOW? (see page 690) ::= low-level voltage in volts, in NR3 format :WGEN:VOLTage:OFFSet (see page 691) :WGEN:VOLTage:OFFSet? (see page 691) ::= offset in volts in NR3 format Introduction to :WGEN Commands The :WGEN subsystem provides commands to select the waveform generator function and parameters.
31 :WGEN Commands :WGEN:FREQuency (see page 792) Command Syntax :WGEN:FREQuency ::= frequency in Hz in NR3 format For all waveforms except Noise and DC, the :WGEN:FREQuency command specifies the frequency of the waveform. You can also specify the frequency indirectly using the :WGEN:PERiod command. Query Syntax :WGEN:FREQuency? The :WGEN:FREQuency? query returns the currently set waveform generator frequency.
:WGEN Commands 31 :WGEN:FUNCtion (see page 792) Command Syntax :WGEN:FUNCtion ::= {SINusoid | SQUare | RAMP | PULSe | NOISe | DC} The :WGEN:FUNCtion command selects the type of waveform: Waveform Type Characteristics SINusoid Use these commands to set the sine signal parameters: • ":WGEN:FREQuency" on page 666 • ":WGEN:PERiod" on page 686 • ":WGEN:VOLTage" on page 688 • ":WGEN:VOLTage:OFFSet" on page 691 • ":WGEN:VOLTage:HIGH" on page 689 • ":WGEN:VOLTage:LOW" on page 690 The freque
31 :WGEN Commands Waveform Type Characteristics PULSe Use these commands to set the pulse signal parameters: • ":WGEN:FREQuency" on page 666 • ":WGEN:PERiod" on page 686 • ":WGEN:VOLTage" on page 688 • ":WGEN:VOLTage:OFFSet" on page 691 • ":WGEN:VOLTage:HIGH" on page 689 • ":WGEN:VOLTage:LOW" on page 690 • ":WGEN:FUNCtion:PULSe:WIDTh" on page 669 The frequency can be adjusted from 100 mHz to 10 MHz. The pulse width can be adjusted from 20 ns to the period minus 20 ns.
:WGEN Commands 31 :WGEN:FUNCtion:PULSe:WIDTh (see page 792) Command Syntax :WGEN:FUNCtion:PULSe:WIDTh ::= pulse width in seconds in NR3 format For Pulse waveforms, the :WGEN:FUNCtion:PULSe:WIDTh command specifies the width of the pulse. The pulse width can be adjusted from 20 ns to the period minus 20 ns. Query Syntax :WGEN:FUNCtion:PULSe:WIDTh? The :WGEN:FUNCtion:PULSe:WIDTh? query returns the currently set pulse width.
31 :WGEN Commands :WGEN:FUNCtion:RAMP:SYMMetry (see page 792) Command Syntax :WGEN:FUNCtion:RAMP:SYMMetry ::= symmetry percentage from 0% to 100% in NR1 format For Ramp waveforms, the :WGEN:FUNCtion:RAMP:SYMMetry command specifies the symmetry of the waveform. Symmetry represents the amount of time per cycle that the ramp waveform is rising. Query Syntax :WGEN:FUNCtion:RAMP:SYMMetry? The :WGEN:FUNCtion:RAMP:SYMMetry? query returns the currently set ramp symmetry.
:WGEN Commands 31 :WGEN:FUNCtion:SQUare:DCYCle (see page 792) Command Syntax :WGEN:FUNCtion:SQUare:DCYCle ::= duty cycle percentage from 20% to 80% in NR1 format For Square waveforms, the :WGEN:FUNCtion:SQUare:DCYCle command specifies the square wave duty cycle. Duty cycle is the percentage of the period that the waveform is high. Query Syntax :WGEN:FUNCtion:SQUare:DCYCle? The :WGEN:FUNCtion:SQUare:DCYCle? query returns the currently set square wave duty cycle.
31 :WGEN Commands :WGEN:MODulation:AM:DEPTh (see page 792) Command Syntax :WGEN:MODulation:AM:DEPTh ::= AM depth percentage from 0% to 100% in NR1 format The :WGEN:MODulation:AM:DEPTh command specifies the amount of amplitude modulation. AM Depth refers to the portion of the amplitude range that will be used by the modulation.
:WGEN Commands 31 :WGEN:MODulation:AM:FREQuency (see page 792) Command Syntax :WGEN:MODulation:AM:FREQuency ::= modulating waveform frequency in Hz in NR3 format The :WGEN:MODulation:AM:FREQuency command specifies the frequency of the modulating signal. Query Syntax :WGEN:MODulation:AM:FREQuency? The :WGEN:MODulation:AM:FREQuency? query returns the frequency of the modulating signal.
31 :WGEN Commands :WGEN:MODulation:FM:DEViation (see page 792) Command Syntax :WGEN:MODulation:FM:DEViation ::= frequency deviation in Hz in NR3 format The :WGEN:MODulation:FM:DEViation command specifies the frequency deviation from the original carrier signal frequency.
:WGEN Commands 31 :WGEN:MODulation:FM:FREQuency (see page 792) Command Syntax :WGEN:MODulation:FM:FREQuency ::= modulating waveform frequency in Hz in NR3 format The :WGEN:MODulation:FM:FREQuency command specifies the frequency of the modulating signal. Query Syntax :WGEN:MODulation:FM:FREQuency? The :WGEN:MODulation:FM:FREQuency? query returns the frequency of the modulating signal.
31 :WGEN Commands :WGEN:MODulation:FSKey:FREQuency (see page 792) Command Syntax :WGEN:MODulation:FSKey:FREQuency ::= hop frequency in Hz in NR3 format The :WGEN:MODulation:FSKey:FREQuency command specifies the "hop frequency". The output frequency "shifts" between the original carrier frequency and this "hop frequency". Query Syntax :WGEN:MODulation:FSKey:FREQuency? The :WGEN:MODulation:FSKey:FREQuency? query returns the "hop frequency" setting.
:WGEN Commands 31 :WGEN:MODulation:FSKey:RATE (see page 792) Command Syntax :WGEN:MODulation:FSKey:RATE ::= FSK modulation rate in Hz in NR3 format The :WGEN:MODulation:FSKey:RATE command specifies the rate at which the output frequency "shifts". The FSK rate specifies a digital square wave modulating signal. Query Syntax :WGEN:MODulation:FSKey:RATE? The :WGEN:MODulation:FSKey:RATE? query returns the FSK rate setting.
31 :WGEN Commands :WGEN:MODulation:FUNCtion (see page 792) Command Syntax :WGEN:MODulation:FUNCtion ::= {SINusoid | SQUare| RAMP} The :WGEN:MODulation:FUNCtion command specifies the shape of the modulating signal. When the RAMP shape is selected, you can specify the amount of time per cycle that the ramp waveform is rising with the :WGEN:MODulation:FUNCtion:RAMP:SYMMetry command. This command applies to AM and FM modulation. (The FSK modulation signal is a square wave shape.
:WGEN Commands 31 :WGEN:MODulation:FUNCtion:RAMP:SYMMetry (see page 792) Command Syntax :WGEN:MODulation:FUNCtion:RAMP:SYMMetry ::= symmetry percentage from 0% to 100% in NR1 format The :WGEN:MODulation:FUNCtion:RAMP:SYMMetry command specifies the amount of time per cycle that the ramp waveform is rising. The ramp modulating waveform shape is specified with the :WGEN:MODulation:FUNCtion command.
31 :WGEN Commands :WGEN:MODulation:NOISe (see page 792) Command Syntax :WGEN:MODulation:NOISe ::= 0 to 100 The :WGEN:MODulation:NOISe command adds noise to the currently selected signal. The sum of the amplitude between the original signal and injected noise is limited to the regular amplitude limit (for example, 5 Vpp in 1 MOhm), so the range for varies according to current amplitude.
:WGEN Commands 31 :WGEN:MODulation:STATe (see page 792) Command Syntax :WGEN:MODulation:STATe ::= {{OFF | 0} | {ON | 1}} The :WGEN:MODulation:STATe command enables or disables modulated waveform generator output. You can enable modulation for all waveform generator function types except pulse, DC, and noise. Query Syntax :WGEN:MODulation:STATe? The :WGEN:MODulation:STATe? query returns whether the modulated waveform generator output is enabled of disabled.
31 :WGEN Commands :WGEN:MODulation:TYPE (see page 792) Command Syntax :WGEN:MODulation:TYPE ::= {AM | FM | FSK} The :WGEN:MODulation:TYPE command selects the modulation type: • AM (amplitude modulation) — the amplitude of the original carrier signal is modified according to the amplitude of the modulating signal. Use the :WGEN:MODulation:AM:FREQuency command to set the modulating signal frequency. Use the :WGEN:MODulation:AM:DEPTh command to specify the amount of amplitude modulation.
:WGEN Commands • ":WGEN:MODulation:FUNCtion" on page 678 • ":WGEN:MODulation:FUNCtion:RAMP:SYMMetry" on page 679 • ":WGEN:MODulation:STATe" on page 681 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 31 683
31 :WGEN Commands :WGEN:OUTPut (see page 792) Command Syntax :WGEN:OUTPut ::= {{1 | ON} | {0 | OFF} The :WGEN:OUTPut command specifies whether the waveform generator signal output is ON (1) or OFF (0). Query Syntax :WGEN:OUTPut? The :WGEN:OUTPut? query returns the current state of the waveform generator output setting.
:WGEN Commands 31 :WGEN:OUTPut:LOAD (see page 792) Command Syntax :WGEN:OUTPut:LOAD ::= {ONEMeg | FIFTy} The :WGEN:OUTPut:LOAD command selects the expected output load impedance. The output impedance of the Gen Out BNC is fixed at 50 ohms. However, the output load selection lets the waveform generator display the correct amplitude and offset levels for the expected output load.
31 :WGEN Commands :WGEN:PERiod (see page 792) Command Syntax :WGEN:PERiod ::= period in seconds in NR3 format For all waveforms except Noise and DC, the :WGEN:PERiod command specifies the period of the waveform. You can also specify the period indirectly using the :WGEN:FREQuency command. Query Syntax :WGEN:PERiod? The :WGEN:PERiod? query returns the currently set waveform generator period.
:WGEN Commands 31 :WGEN:RST (see page 792) Command Syntax :WGEN:RST The :WGEN:RST command restores the waveform generator factory default settings (1 kHz sine wave, 500 mVpp, 0 V offset).
31 :WGEN Commands :WGEN:VOLTage (see page 792) Command Syntax :WGEN:VOLTage ::= amplitude in volts in NR3 format For all waveforms except DC, the :WGEN:VOLTage command specifies the waveform's amplitude. Use the :WGEN:VOLTage:OFFSet command to specify the offset voltage or DC level. You can also specify the amplitude and offset indirectly using the :WGEN:VOLTage:HIGH and :WGEN:VOLTage:LOW commands.
:WGEN Commands 31 :WGEN:VOLTage:HIGH (see page 792) Command Syntax :WGEN:VOLTage:HIGH ::= high-level voltage in volts, in NR3 format For all waveforms except DC, the :WGEN:VOLTage:HIGH command specifies the waveform's high-level voltage. Use the :WGEN:VOLTage:LOW command to specify the low-level voltage. You can also specify the high-level and low-level voltages indirectly using the :WGEN:VOLTage and :WGEN:VOLTage:OFFSet commands.
31 :WGEN Commands :WGEN:VOLTage:LOW (see page 792) Command Syntax :WGEN:VOLTage:LOW ::= low-level voltage in volts, in NR3 format For all waveforms except DC, the :WGEN:VOLTage:LOW command specifies the waveform's low-level voltage. Use the :WGEN:VOLTage:HIGH command to specify the high-level voltage. You can also specify the high-level and low-level voltages indirectly using the :WGEN:VOLTage and :WGEN:VOLTage:OFFSet commands.
:WGEN Commands 31 :WGEN:VOLTage:OFFSet (see page 792) Command Syntax :WGEN:VOLTage:OFFSet ::= offset in volts in NR3 format The :WGEN:VOLTage:OFFSet command specifies the waveform's offset voltage or the DC level. Use the :WGEN:VOLTage command to specify the amplitude. You can also specify the amplitude and offset indirectly using the :WGEN:VOLTage:HIGH and :WGEN:VOLTage:LOW commands.
31 :WGEN Commands 692 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 32 :WMEMory Commands Control reference waveforms.
32 :WMEMory Commands Table 97 :WMEMory Commands Summary (continued) Command Query Options and Query Returns :WMEMory:YRANge [suffix] (see page 701) :WMEMory:YRANge? (see page 701) ::= 1-2 in NR1 format ::= vertical full-scale range value in NR3 format [suffix] ::= {V | mV} :WMEMory:YSCale [suffix] (see page 702) :WMEMory:YSCale? (see page 702) ::= 1-2 in NR1 format ::= vertical units per division value in NR3 format [suffix] ::= {V | mV} 694
:WMEMory Commands 32 :WMEMory:CLEar (see page 792) Command Syntax :WMEMory:CLEar ::= 1-2 in NR1 format The :WMEMory:CLEar command clears the specified reference waveform location.
32 :WMEMory Commands :WMEMory:DISPlay (see page 792) Command Syntax :WMEMory:DISPlay ::= 1-2 in NR1 format ::= {{1 | ON} | {0 | OFF}} The :WMEMory:DISPlay command turns the display of the specified reference waveform on or off. There are two reference waveform locations, but only one reference waveform can be displayed at a time. That means, if :WMEMory1:DISPlay is ON, sending the :WMEMory2:DISPlay ON command will automatically set :WMEMory1:DISPlay OFF.
:WMEMory Commands 32 :WMEMory:LABel (see page 792) Command Syntax :WMEMory:LABel ::= 1-2 in NR1 format ::= quoted ASCII string NOTE Label strings are 10 characters or less, and may contain any commonly used ASCII characters. Labels with more than 10 characters are truncated to 10 characters. Lower case characters are converted to upper case. The :WMEMory:LABel command sets the reference waveform label to the string that follows.
32 :WMEMory Commands :WMEMory:SAVE (see page 792) Command Syntax :WMEMory:SAVE ::= 1-2 in NR1 format ::= {CHANnel | FUNCtion | MATH} ::= 1 to (# analog channels) in NR1 format The :WMEMory:SAVE command copies the analog channel or math function waveform to the specified reference waveform location. NOTE See Also 698 Only ADD or SUBtract math operations can be saved as reference waveforms.
:WMEMory Commands 32 :WMEMory:SKEW (see page 792) Command Syntax :WMEMory:SKEW ::= 1-2 in NR1 format ::= time in seconds in NR3 format The :WMEMory:SKEW command sets the skew factor for the specified reference waveform. Query Syntax :WMEMory:SKEW? The :WMEMory:SKEW? query returns the current skew setting for the selected reference waveform.
32 :WMEMory Commands :WMEMory:YOFFset (see page 792) Command Syntax :WMEMory:YOFFset [] ::= 1-2 in NR1 format ::= vertical offset value in NR3 format ::= {V | mV} The :WMEMory:YOFFset command sets the value that is represented at center screen for the selected reference waveform. The range of legal values varies with the value set by the :WMEMory:YRANge or :WMEMory:YSCale commands.
:WMEMory Commands 32 :WMEMory:YRANge (see page 792) Command Syntax :WMEMory:YRANge [] ::= 1-2 in NR1 format ::= vertical full-scale range value in NR3 format ::= {V | mV} The :WMEMory:YRANge command defines the full-scale vertical axis of the selected reference waveform. Legal values for the range are copied from the original source waveform (that is, the analog channel or math function waveform that was originally saved as a reference waveform).
32 :WMEMory Commands :WMEMory:YSCale (see page 792) Command Syntax :WMEMory:YSCale [] ::= 1-2 in NR1 format ::= vertical units per division in NR3 format ::= {V | mV} The :WMEMory:YSCale command sets the vertical scale, or units per division, of the selected reference waveform. Legal values for the scale are copied from the original source waveform (that is, the analog channel or math function waveform that was originally saved as a reference waveform).
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 33 Obsolete and Discontinued Commands Obsolete commands are older forms of commands that are provided to reduce customer rework for existing systems and programs (see"Obsolete Commands" on page 792).
33 Obsolete and Discontinued Commands 704 Obsolete Command Current Command Equivalent Behavior Differences :CHANnel:THReshold (see page 710) :POD:THReshold (see page 415) or :DIGital:THReshold (see page 249) :CHANnel2:SKEW (see page 711) :CHANnel:PROBe:SKEW (see page 230) :CHANnel:INPut (see page 712) :CHANnel:IMPedance (see page 223) :CHANnel:PMODe (see page 713) none :DISPlay:CONNect (see page 714) :DISPlay:VECTors (see page 262) :DISPlay:ORDer (see page 715) none :ERASe
Obsolete and Discontinued Commands Obsolete Command Current Command Equivalent :MEASure:SCRatch (see page 726) :MEASure:CLEar (see page 343) :MEASure:TDELta (see page 727) :MARKer:XDELta (see page 324) :MEASure:THResholds (see page 728) :MEASure:DEFine:THResholds (see page 344) :MEASure:TSTArt (see page 729) :MARKer:X1Position (see page 320) :MEASure:TSTOp (see page 730) :MARKer:X2Position (see page 322) :MEASure:TVOLt (see page 731) :MEASure:TVALue (see page 365) TVALue measures additional v
33 Obsolete and Discontinued Commands Discontinued Commands 706 Obsolete Command Current Command Equivalent :PRINt? (see page 744) :DISPlay:DATA? (see page 258) :SAVE:IMAGe:AREA (see page 746) none :TIMebase:DELay (see page 747) :TIMebase:POSition (see page 580) or :TIMebase:WINDow:POSition (see page 585) :TRIGger:THReshold (see page 748) :POD:THReshold (see page 415) or :DIGital:THReshold (see page 249) :TRIGger:TV:TVMode (see page 749) :TRIGger:TV:MODE (see page 623) Behavior Differen
Obsolete and Discontinued Commands Discontinued Command Current Command Equivalent DISPlay:POSition none DISPlay:ROW none DISPlay:TEXT none FUNCtion:MOVE none FUNCtion:PEAKs none HARDcopy:ADDRess none Only parallel printer port is supported.
33 Obsolete and Discontinued Commands :CHANnel:ACTivity (see page 792) Command Syntax :CHANnel:ACTivity The :CHANnel:ACTivity command clears the cumulative edge variables for the next activity query. NOTE The :CHANnel:ACTivity command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :ACTivity command (see page 151) instead.
Obsolete and Discontinued Commands 33 :CHANnel:LABel (see page 792) Command Syntax :CHANnel:LABel ::= {CHANnel1 | CHANnel2 | DIGital} ::= 0 to (# digital channels - 1) in NR1 format ::= quoted ASCII string The :CHANnel:LABel command sets the source text to the string that follows. Setting a channel will also result in the name being added to the label list.
33 Obsolete and Discontinued Commands :CHANnel:THReshold (see page 792) Command Syntax :CHANnel:THReshold , [, ] ::= {POD1 | POD2} ::= {CMOS | ECL | TTL | USERdef} ::= voltage for USERdef in NR3 format [volt_type] [volt_type] ::= {V | mV (-3) | uV (-6)} The :CHANnel:THReshold command sets the threshold for a group of channels. The threshold is either set to a predefined value or to a user-defined value.
Obsolete and Discontinued Commands 33 :CHANnel2:SKEW (see page 792) Command Syntax :CHANnel2:SKEW ::= skew time in NR3 format ::= -100 ns to +100 ns The :CHANnel2:SKEW command sets the skew between channels 1 and 2. The maximum skew is +/-100 ns. You can use the oscilloscope's analog probe skew control to remove cable delay errors between channel 1 and channel 2.
33 Obsolete and Discontinued Commands :CHANnel:INPut (see page 792) Command Syntax :CHANnel:INPut ::= {ONEMeg | FIFTy} ::= 1 to (# analog channels) in NR1 format The :CHANnel:INPut command selects the input impedance setting for the specified channel. The legal values for this command are ONEMeg (1 MΩ) and FIFTy (50Ω). NOTE The :CHANnel:INPut command is an obsolete command provided for compatibility to previous oscilloscopes.
Obsolete and Discontinued Commands 33 :CHANnel:PMODe (see page 792) Command Syntax :CHANnel:PMODe ::= {AUTo | MANual} ::= 1 to (# analog channels) in NR1 format The probe sense mode is controlled internally and cannot be set. If a probe with sense is connected to the specified channel, auto sensing is enabled; otherwise, the mode is manual. If the PMODe sent matches the oscilloscope's setting, the command will be accepted.
33 Obsolete and Discontinued Commands :DISPlay:CONNect (see page 792) Command Syntax :DISPlay:CONNect ::= {{ 1 | ON} | {0 | OFF}} The :DISPlay:CONNect command turns vectors on and off. When vectors are turned on, the oscilloscope displays lines connecting sampled data points. When vectors are turned off, only the sampled data is displayed. NOTE The :DISPlay:CONNEct command is an obsolete command provided for compatibility to previous oscilloscopes.
Obsolete and Discontinued Commands 33 :DISPlay:ORDer (see page 792) Query Syntax :DISPlay:ORDer? The :DISPlay:ORDer? query returns a list of digital channel numbers in screen order, from top to bottom, separated by commas. Busing is displayed as digital channels with no separator. For example, in the following list, the bus consists of digital channels 4 and 5: DIG1, DIG4 DIG5, DIG7.
33 Obsolete and Discontinued Commands :ERASe (see page 792) Command Syntax :ERASe The :ERASe command erases the screen. NOTE 716 The :ERASe command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :DISplay:CLEar command (see page 257) instead.
Obsolete and Discontinued Commands 33 :EXTernal:PMODe (see page 792) Command Syntax :EXTernal:PMODe ::= {AUTo | MANual} The probe sense mode is controlled internally and cannot be set. If a probe with sense is connected to the specified channel, auto sensing is enabled; otherwise, the mode is manual. If the pmode sent matches the oscilloscope's setting, the command will be accepted. Otherwise, a setting conflict error is generated.
33 Obsolete and Discontinued Commands :FUNCtion:SOURce (see page 792) Command Syntax :FUNCtion:SOURce ::= {CHANnel | ADD | SUBTract | MULTiply} ::= 1 to (# analog channels) in NR1 format The :FUNCtion:SOURce command is only used when an FFT (Fast Fourier Transform) operation is selected (see the:FUNCtion:OPERation command for more information about selecting an operation). The :FUNCtion:SOURce command selects the source for function operations.
Obsolete and Discontinued Commands 33 :FUNCtion:VIEW (see page 792) Command Syntax :FUNCtion:VIEW ::= {{1 | ON} | (0 | OFF}} The :FUNCtion:VIEW command turns the selected function on or off. When ON is selected, the function performs as specified using the other FUNCtion commands. When OFF is selected, function is neither calculated nor displayed. NOTE The :FUNCtion:VIEW command is provided for backward compatibility to previous oscilloscopes.
33 Obsolete and Discontinued Commands :HARDcopy:DESTination (see page 792) Command Syntax :HARDcopy:DESTination ::= {CENTronics | FLOPpy} The :HARDcopy:DESTination command sets the hardcopy destination. NOTE The :HARDcopy:DESTination command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :HARDcopy:FILename command (see page 721) instead.
33 Obsolete and Discontinued Commands :HARDcopy:FILename (see page 792) Command Syntax :HARDcopy:FILename ::= quoted ASCII string The HARDcopy:FILename command sets the output filename for those print formats whose output is a file. NOTE Query Syntax The :HARDcopy:FILename command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :SAVE:FILename command (see page 428) and :RECall:FILename command (see page 419) instead.
33 Obsolete and Discontinued Commands :HARDcopy:GRAYscale (see page 792) Command Syntax :HARDcopy:GRAYscale ::= {{OFF | 0} | {ON | 1}} The :HARDcopy:GRAYscale command controls whether grayscaling is performed in the hardcopy dump. NOTE Query Syntax The :HARDcopy:GRAYscale command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :HARDcopy:PALette command (see page 309) instead.
Obsolete and Discontinued Commands 33 :HARDcopy:IGColors (see page 792) Command Syntax :HARDcopy:IGColors ::= {{OFF | 0} | {ON | 1}} The HARDcopy:IGColors command controls whether the graticule colors are inverted or not. NOTE The :HARDcopy:IGColors command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :HARDcopy:INKSaver (see page 301) command instead.
33 Obsolete and Discontinued Commands :HARDcopy:PDRiver (see page 792) Command Syntax :HARDcopy:PDRiver ::= {AP2Xxx | AP21xx | {AP2560 | AP25} | {DJ350 | DJ35} | DJ6xx | {DJ630 | DJ63} | DJ6Special | DJ6Photo | DJ8Special | DJ8xx | DJ9Vip | OJPRokx50 | DJ9xx | GVIP | DJ55xx | {PS470 | PS47} {PS100 | PS10} | CLASer | MLASer | LJFastraster | POSTscript} The HARDcopy:PDRiver command sets the hardcopy printer driver used for the selected printer.
Obsolete and Discontinued Commands 33 :MEASure:LOWer (see page 792) Command Syntax :MEASure:LOWer The :MEASure:LOWer command sets the lower measurement threshold value. This value and the UPPer value represent absolute values when the thresholds are ABSolute and percentage when the thresholds are PERCent as defined by the :MEASure:DEFine THResholds command. NOTE Query Syntax The :MEASure:LOWer command is obsolete and is provided for backward compatibility to previous oscilloscopes.
33 Obsolete and Discontinued Commands :MEASure:SCRatch (see page 792) Command Syntax :MEASure:SCRatch The :MEASure:SCRatch command clears all selected measurements and markers from the screen. NOTE 726 The :MEASure:SCRatch command is obsolete and is provided for backward compatibility to previous oscilloscopes. Use the :MEASure:CLEar command (see page 343) instead.
Obsolete and Discontinued Commands 33 :MEASure:TDELta (see page 792) Query Syntax :MEASure:TDELta? The :MEASure:TDELta? query returns the time difference between the Tstop marker (X2 cursor) and the Tstart marker (X1 cursor). Tdelta = Tstop - Tstart Tstart is the time at the start marker (X1 cursor) and Tstop is the time at the stop marker (X2 cursor). No measurement is made when the :MEASure:TDELta? query is received by the oscilloscope. The delta time value that is output is the current value.
33 Obsolete and Discontinued Commands :MEASure:THResholds (see page 792) Command Syntax :MEASure:THResholds {T1090 | T2080 | VOLTage} The :MEASure:THResholds command selects the thresholds used when making time measurements. NOTE Query Syntax The :MEASure:THResholds command is obsolete and is provided for backward compatibility to previous oscilloscopes. Use the :MEASure:DEFine THResholds command (see page 344) instead.
Obsolete and Discontinued Commands 33 :MEASure:TSTArt (see page 792) Command Syntax :MEASure:TSTArt [suffix] ::= time at the start marker in seconds [suffix] ::= {s | ms | us | ns | ps} The :MEASure:TSTArt command moves the start marker (X1 cursor) to the specified time with respect to the trigger time. NOTE The short form of this command, TSTA, does not follow the defined Long Form to Short Form Truncation Rules (see page 794).
33 Obsolete and Discontinued Commands :MEASure:TSTOp (see page 792) Command Syntax :MEASure:TSTOp [suffix] ::= time at the stop marker in seconds [suffix] ::= {s | ms | us | ns | ps} The :MEASure:TSTOp command moves the stop marker (X2 cursor) to the specified time with respect to the trigger time. NOTE The short form of this command, TSTO, does not follow the defined Long Form to Short Form Truncation Rules (see page 794).
Obsolete and Discontinued Commands 33 :MEASure:TVOLt (see page 792) Query Syntax :MEASure:TVOLt? , [][,] ::= the voltage level that the waveform must cross. ::= direction of the waveform. A rising slope is indicated by a plus sign (+). A falling edge is indicated by a minus sign (-). ::= the transition to be reported. If the occurrence number is one, the first crossing is reported. If the number is two, the second crossing is reported, etc.
33 Obsolete and Discontinued Commands :MEASure:UPPer (see page 792) Command Syntax :MEASure:UPPer The :MEASure:UPPer command sets the upper measurement threshold value. This value and the LOWer value represent absolute values when the thresholds are ABSolute and percentage when the thresholds are PERCent as defined by the :MEASure:DEFine THResholds command. NOTE Query Syntax The :MEASure:UPPer command is obsolete and is provided for backward compatibility to previous oscilloscopes.
Obsolete and Discontinued Commands 33 :MEASure:VDELta (see page 792) Query Syntax :MEASure:VDELta? The :MEASure:VDELta? query returns the voltage difference between vertical marker 1 (Y1 cursor) and vertical marker 2 (Y2 cursor). No measurement is made when the :MEASure:VDELta? query is received by the oscilloscope. The delta value that is returned is the current value. This is the same value as the front-panel cursors delta Y value.
33 Obsolete and Discontinued Commands :MEASure:VSTArt (see page 792) Command Syntax :MEASure:VSTArt ::= value for vertical marker 1 The :MEASure:VSTArt command moves the vertical marker (Y1 cursor) to the specified value corresponding to the selected source. The source can be selected by the MARKer:X1Y1source command. NOTE The short form of this command, VSTA, does not follow the defined Long Form to Short Form Truncation Rules (see page 794).
Obsolete and Discontinued Commands 33 :MEASure:VSTOp (see page 792) Command Syntax :MEASure:VSTOp ::= value for Y2 cursor The :MEASure:VSTOp command moves the vertical marker 2 (Y2 cursor) to the specified value corresponding to the selected source. The source can be selected by the MARKer:X2Y2source command. NOTE The short form of this command, VSTO, does not follow the defined Long Form to Short Form Truncation Rules (see page 794).
33 Obsolete and Discontinued Commands :MTESt:AMASk:{SAVE | STORe} (see page 792) Command Syntax :MTESt:AMASk:{SAVE | STORe} "" The :MTESt:AMASk:SAVE command saves the automask generated mask to a file. If an automask has not been generated, an error occurs. The parameter is an MS-DOS compatible name of the file, a maximum of 254 characters long (including the path name, if used). The filename assumes the present working directory if a path does not precede the file name.
33 Obsolete and Discontinued Commands :MTESt:AVERage (see page 792) Command Syntax :MTESt:AVERage ::= {{1 | ON} | {0 | OFF}} The :MTESt:AVERage command enables or disables averaging. When ON, the oscilloscope acquires multiple data values for each time bucket, and averages them. When OFF, averaging is disabled. To set the number of averages, use the :MTESt:AVERage:COUNt command described next.
33 Obsolete and Discontinued Commands :MTESt:AVERage:COUNt (see page 792) Command Syntax :MTESt:AVERage:COUNt ::= an integer from 2 to 65536 in NR1 format The :MTESt:AVERage:COUNt command sets the number of averages for the waveforms. With the AVERage acquisition type, the :MTESt:AVERage:COUNt command specifies the number of data values to be averaged for each time bucket before the acquisition is considered complete for that time bucket.
Obsolete and Discontinued Commands 33 :MTESt:LOAD (see page 792) Command Syntax :MTESt:LOAD "" The :MTESt:LOAD command loads the specified mask file. The parameter is an MS-DOS compatible name of the file, a maximum of 254 characters long (including the path name, if used). NOTE See Also The :MTESt:LOAD command is obsolete and is provided for backward compatibility to previous oscilloscopes. Use the :RECall:MASK[:STARt] command (see page 420) instead.
33 Obsolete and Discontinued Commands :MTESt:RUMode (see page 792) Command Syntax :MTESt:RUMode {FORever | TIME, | {WAVeforms,}} ::= from 1 to 86400 in NR3 format ::= number of waveforms in NR1 format from 1 to 1,000,000,000 The :MTESt:RUMode command determines the termination conditions for the mask test. The choices are FORever, TIME, or WAVeforms. • FORever — runs the Mask Test until the test is turned off.
Obsolete and Discontinued Commands 33 :MTESt:RUMode:SOFailure (see page 792) Command Syntax :MTESt:RUMode:SOFailure ::= {{1 | ON} | {0 | OFF}} The :MTESt:RUMode:SOFailure command enables or disables the Stop On Failure run until criteria. When a mask test is run and a mask violation is detected, the mask test is stopped and the acquisition system is stopped.
33 Obsolete and Discontinued Commands :MTESt:{STARt | STOP} (see page 792) Command Syntax :MTESt:{STARt | STOP} The :MTESt:{STARt | STOP} command starts or stops the acquisition system. NOTE See Also 742 The :MTESt:STARt and :MTESt:STOP commands are obsolete and are provided for backward compatibility to previous oscilloscopes. Use the :RUN command (see page 176) and :STOP command (see page 180) instead.
Obsolete and Discontinued Commands 33 :MTESt:TRIGger:SOURce (see page 792) Command Syntax :MTESt:TRIGger:SOURce ::= CHANnel ::= 1 to (# analog channels) in NR1 format The :MTESt:TRIGger:SOURce command sets the channel to use as the trigger. NOTE The :MTESt:TRIGger:SOURce command is obsolete and is provided for backward compatibility to previous oscilloscopes. Use the trigger source commands (see page 589) instead.
33 Obsolete and Discontinued Commands :PRINt? (see page 792) Query Syntax :PRINt? [] ::= [][,..,] ::= {COLor | GRAYscale | BMP8bit | BMP} The :PRINt? query pulls image data back over the bus for storage. NOTE 744 The :PRINT command is an obsolete command provided for compatibility to previous oscilloscopes. Use the :DISPlay:DATA command (see page 258) instead.
Obsolete and Discontinued Commands NOTE See Also 33 The PRINt? query is not a core command.
33 Obsolete and Discontinued Commands :SAVE:IMAGe:AREA (see page 792) Query Syntax :SAVE:IMAGe:AREA? The :SAVE:IMAGe:AREA? query returns the selected image area. When saving images, this query returns SCR (screen). When saving setups or waveform data, this query returns GRAT (graticule) even though graticule images are not saved.
Obsolete and Discontinued Commands 33 :TIMebase:DELay (see page 792) Command Syntax :TIMebase:DELay ::= time in seconds from trigger to the delay reference point on the screen. The valid range for delay settings depends on the time/division setting for the main time base. The :TIMebase:DELay command sets the main time base delay. This delay is the time between the trigger event and the delay reference point on the screen.
33 Obsolete and Discontinued Commands :TRIGger:THReshold (see page 792) Command Syntax :TRIGger:THReshold , [, ] ::= {POD1 | POD2} ::= {CMOS | ECL | TTL | USERdef} ::= voltage for USERdef (floating-point number) [Volt type] [Volt type] ::= {V | mV | uV} The :TRIGger:THReshold command sets the threshold (trigger level) for a pod of 8 digital channels (either digital channels 0 through 7 or 8 through 15).
Obsolete and Discontinued Commands 33 :TRIGger:TV:TVMode (see page 792) Command Syntax :TRIGger:TV:TVMode ::= {FIEld1 | FIEld2 | AFIelds | ALINes | LINE | VERTical | LFIeld1 | LFIeld2 | LALTernate | LVERtical} The :TRIGger:TV:MODE command selects the TV trigger mode and field. The LVERtical parameter is only available when :TRIGger:TV:STANdard is GENeric. The LALTernate parameter is not available when :TRIGger:TV:STANdard is GENeric (see page 626).
33 Obsolete and Discontinued Commands 750 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 34 Error Messages -440, Query UNTERMINATED after indefinite response -430, Query DEADLOCKED -420, Query UNTERMINATED -410, Query INTERRUPTED -400, Query error -340, Calibration failed -330, Self-test failed -321, Out of memory -320, Storage fault 751
34 Error Messages -315, Configuration memory lost -314, Save/recall memory lost -313, Calibration memory lost -311, Memory error -310, System error -300, Device specific error -278, Macro header not found -277, Macro redefinition not allowed -276, Macro recursion error -273, Illegal macro label -272, Macro execution error -258, Media protected -257, File name error 752 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Error Messages 34 -256, File name not found -255, Directory full -254, Media full -253, Corrupt media -252, Missing media -251, Missing mass storage -250, Mass storage error -241, Hardware missing This message can occur when a feature is unavailable or unlicensed. For example, some serial bus decode commands are only available when the serial decode options are licensed.
34 Error Messages -223, Too much data -222, Data out of range -221, Settings conflict -220, Parameter error -200, Execution error -183, Invalid inside macro definition -181, Invalid outside macro definition -178, Expression data not allowed -171, Invalid expression -170, Expression error -168, Block data not allowed -161, Invalid block data -158, String data not allowed 754 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Error Messages 34 -151, Invalid string data -150, String data error -148, Character data not allowed -138, Suffix not allowed -134, Suffix too long -131, Invalid suffix -128, Numeric data not allowed -124, Too many digits -123, Exponent too large -121, Invalid character in number -120, Numeric data error -114, Header suffix out of range -113, Undefined header Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 755
34 Error Messages -112, Program mnemonic too long -109, Missing parameter -108, Parameter not allowed -105, GET not allowed -104, Data type error -103, Invalid separator -102, Syntax error -101, Invalid character -100, Command error +10, Software Fault Occurred +100, File Exists +101, End-Of-File Found +102, Read Error 756 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Error Messages 34 +103, Write Error +104, Illegal Operation +105, Print Canceled +106, Print Initialization Failed +107, Invalid Trace File +108, Compression Error +109, No Data For Operation A remote operation wants some information, but there is no information available. For example, you may request a stored TIFF image using the :DISPlay:DATA? query, but there may be no image stored.
34 Error Messages 758 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 35 Status Reporting Status Reporting Data Structures / 761 Status Byte Register (STB) / 764 Service Request Enable Register (SRE) / 766 Trigger Event Register (TER) / 767 Output Queue / 768 Message Queue / 769 (Standard) Event Status Register (ESR) / 770 (Standard) Event Status Enable Register (ESE) / 771 Error Queue / 772 Operation Status Event Register (:OPERegister[:EVENt]) / 773 Operation Status Condition Register (:OPERegister:CONDi
35 Status Reporting Trigger Event Register Error Queue Message Queue RUN Bit Output Queue (Mask) Arm Event Register Overload Event Register Overload Event Enable Register (Mask) Standard Event Status Register Standard Event Status Enable Register (Mask) Mask Test Event Register Mask Test Event Enable Register Operation Status Condition/ Event Registers Operation Status Enable Register Status Byte Register Service Request Enable Register Service Request Generation Service Request (SRQ) Inter
35 Status Reporting Status Reporting Data Structures The following figure shows how the status register bits are masked and logically OR'ed to generate service requests (SRQ) on particular events.
35 Status Reporting From Overload Event Registers From Mask Test Event Registers Arm Reg OVLR 15 14 13 12 AER? Run bit set if oscilloscope not stopped Wait Trig MTE 11 9 5 3 OVLR MTE Wait Trig Run 11 10 9 8 7 6 5 :OPERation:CONDition? Operation Status Condition Register Run 4 3 :OPERation[:EVENt]? Operation Status Event Register 2 1 0 :OPEE :OPEE? Operation Status Enable (Mask) Register OR + PON URQ CME EXE DDE QYE RQL OPC 7 6 5 4 3 2 1 0 *ESR? (Standard)
Status Reporting 35 To generate a service request (SRQ) interrupt to an external controller, at least one bit in the Status Byte Register must be enabled. These bits are enabled by using the *SRE common command to set the corresponding bit in the Service Request Enable Register. These enabled bits can then set RQS and MSS (bit 6) in the Status Byte Register.
35 Status Reporting Status Byte Register (STB) The Status Byte Register is the summary-level register in the status reporting structure. It contains summary bits that monitor activity in the other status registers and queues. The Status Byte Register is a live register. That is, its summary bits are set and cleared by the presence and absence of a summary bit from other event registers or queues.
Status Reporting Example 35 The following example uses the resource session object's ReadSTB method to read the contents of the oscilloscope's Status Byte Register. varQueryResult = myScope.IO.ReadSTB MsgBox "Status Byte Register, Serial Poll: 0x" + Hex(varQueryResult) NOTE Use Serial Polling to Read Status Byte Register.
35 Status Reporting Service Request Enable Register (SRE) Setting the Service Request Enable Register bits enable corresponding bits in the Status Byte Register. These enabled bits can then set RQS and MSS (bit 6) in the Status Byte Register. Bits are set in the Service Request Enable Register using the *SRE command and the bits that are set are read with the *SRE? query. Example The following example sets bit 4 (MAV) and bit 5 (ESB) in the Service Request Enable Register. myScope.
Status Reporting 35 Trigger Event Register (TER) This register sets the TRG bit in the status byte when a trigger event occurs. The TER event register stays set until it is cleared by reading the register or using the *CLS command. If your application needs to detect multiple triggers, the TER event register must be cleared after each one. If you are using the Service Request to interrupt a program or controller operation, you must clear the event register each time the trigger bit is set.
35 Status Reporting Output Queue The output queue stores the oscilloscope-to-controller responses that are generated by certain instrument commands and queries. The output queue generates the Message Available summary bit when the output queue contains one or more bytes. This summary bit sets the MAV bit (bit 4) in the Status Byte Register. When using the Keysight VISA COM library, the output queue may be read with the FormattedIO488 object's ReadString, ReadNumber, ReadList, or ReadIEEEBlock methods.
Status Reporting 35 Message Queue The message queue contains the text of the last message written to the advisory line on the screen of the oscilloscope. The length of the oscilloscope's message queue is 1. Note that messages sent with the :SYSTem:DSP command do not set the MSG status bit in the Status Byte Register.
35 Status Reporting (Standard) Event Status Register (ESR) The (Standard) Event Status Register (ESR) monitors the following oscilloscope status events: • PON - Power On • URQ - User Request • CME - Command Error • EXE - Execution Error • DDE - Device Dependent Error • QYE - Query Error • RQC - Request Control • OPC - Operation Complete When one of these events occur, the event sets the corresponding bit in the register.
35 Status Reporting (Standard) Event Status Enable Register (ESE) To allow any of the (Standard) Event Status Register (ESR) bits to generate a summary bit, you must first enable that bit. Enable the bit by using the *ESE (Event Status Enable) common command to set the corresponding bit in the (Standard) Event Status Enable Register (ESE). Set bits are read with the *ESE? query. Example Suppose your application requires an interrupt whenever any type of error occurs.
35 Status Reporting Error Queue As errors are detected, they are placed in an error queue. This queue is first in, first out. If the error queue overflows, the last error in the queue is replaced with error 350, Queue overflow. Any time the queue overflows, the least recent errors remain in the queue, and the most recent error is discarded. The length of the oscilloscope's error queue is 30 (29 positions for the error messages, and 1 position for the Queue overflow message).
Status Reporting 35 Operation Status Event Register (:OPERegister[:EVENt]) The Operation Status Event Register register hosts these bits: Name Location Description RUN bit bit 3 Is set whenever the instrument goes from a stop state to a single or running state. WAIT TRIG bit bit 5 Is set by the Trigger Armed Event Register and indicates that the trigger is armed. MTE bit bit 9 Comes from the Mask Test Event Registers. OVLR bit bit 11 Is set whenever a 50Ω input overload occurs.
35 Status Reporting Operation Status Condition Register (:OPERegister:CONDition) The Operation Status Condition Register register hosts these bits: Name Location Description RUN bit bit 3 Is set whenever the instrument is not stopped. WAIT TRIG bit bit 5 Is set by the Trigger Armed Event Register and indicates that the trigger is armed. MTE bit bit 9 Comes from the Mask Test Event Registers. OVLR bit bit 11 Is set whenever a 50Ω input overload occurs.
Status Reporting 35 Arm Event Register (AER) This register sets bit 5 (Wait Trig bit) in the Operation Status Register and the OPER bit (bit 7) in the Status Byte Register when the instrument becomes armed. The ARM event register stays set until it is cleared by reading the register with the AER? query or using the *CLS command. If your application needs to detect multiple triggers, the ARM event register must be cleared after each one.
35 Status Reporting Overload Event Register (:OVLRegister) The Overload Event Register register hosts these bits: 776 Name Location Description Channel 1 Fault bit 6 Fault has occurred on Channel 1 input. Channel 2 Fault bit 7 Fault has occurred on Channel 2 input. Channel 3 Fault bit 8 Fault has occurred on Channel 3 input. Channel 4 Fault bit 9 Fault has occurred on Channel 4 input. External Trigger Fault bit 10 Fault has occurred on External Trigger input.
Status Reporting 35 Mask Test Event Event Register (:MTERegister[:EVENt]) The Mask Test Event Event Register register hosts these bits: Name Location Description Complete bit 0 Is set when the mask test is complete. Fail bit 1 Is set when there is a mask test failure. Started bit 8 Is set when mask testing is started. Auto Mask bit 10 Is set when auto mask creation is completed. The :MTERegister[:EVENt]? query returns the value of, and clears, the Mask Test Event Event Register.
35 Status Reporting Clearing Registers and Queues The *CLS common command clears all event registers and all queues except the output queue. If *CLS is sent immediately after a program message terminator, the output queue is also cleared.
35 Status Reporting Status Reporting Decision Chart no Do you want to do status reporting? yes Reset the instrument and clear the status registers: myScope.WriteString "*RST" myScope.WriteString "*CLS" Do you want to send a Service Request (SRQ) interrupt to the controller? no (Your programs can read the status registers instead.
35 Status Reporting 780 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 36 Synchronizing Acquisitions Synchronization in the Programming Flow / 782 Blocking Synchronization / 783 Polling Synchronization With Timeout / 784 Synchronizing with a Single-Shot Device Under Test (DUT) / 786 Synchronization with an Averaging Acquisition / 788 When remotely controlling an oscilloscope with programming commands, it is often necessary to know when the oscilloscope has finished the previous operation and is ready for t
36 Synchronizing Acquisitions Synchronization in the Programming Flow Most remote programming follows these three general steps: 1 Set up the oscilloscope and device under test (see page 782). 2 Acquire a waveform (see page 782). 3 Retrieve results (see page 782). Set Up the Oscilloscope Before making changes to the oscilloscope setup, it is best to make sure it is stopped using the :STOP command followed by the *OPC? query.
Synchronizing Acquisitions 36 Blocking Synchronization Use the :DIGitize command to start the acquisition. This blocks subsequent queries until the acquisition and processing is complete. For example: ' ' Synchronizing acquisition using blocking. ' =================================================================== Option Explicit Public Public Public Public myMgr As VisaComLib.ResourceManager myScope As VisaComLib.
36 Synchronizing Acquisitions Polling Synchronization With Timeout This example requires a timeout value so the operation can abort if an acquisition does not occur within the timeout period: ' ' Synchronizing acquisition using polling. ' =================================================================== Option Explicit Public Public Public Public myMgr As VisaComLib.ResourceManager myScope As VisaComLib.
Synchronizing Acquisitions 36 myScope.WriteString ":OPERegister:CONDition?" varQueryResult = myScope.ReadNumber ' Mask RUN bit (bit 3, &H8). If (varQueryResult And &H8) = 0 Then Exit Do Else Sleep 100 ' Small wait to prevent excessive queries. lngElapsed = lngElapsed + 100 End If Loop ' Get results. ' ----------------------------------------------------------------If lngElapsed < lngTimeout Then myScope.WriteString ":MEASure:RISetime" myScope.WriteString ":MEASure:RISetime?" varQueryResult = myScope.
36 Synchronizing Acquisitions Synchronizing with a Single-Shot Device Under Test (DUT) The examples in "Blocking Synchronization" on page 783 and "Polling Synchronization With Timeout" on page 784 assume the DUT is continually running and therefore the oscilloscope will have more than one opportunity to trigger. With a single shot DUT, there is only one opportunity for the oscilloscope to trigger, so it is necessary for the oscilloscope to be armed and ready before the DUT is enabled.
Synchronizing Acquisitions 36 ' ----------------------------------------------------------------' Start a single acquisition. myScope.WriteString ":SINGle" ' Wait until the trigger system is armed. Do Sleep 100 ' Small wait to prevent excessive queries. myScope.WriteString ":AER?" varQueryResult = myScope.ReadNumber Loop Until varQueryResult = 1 ' Oscilloscope is armed and ready, enable DUT here. Debug.Print "Oscilloscope is armed and ready, enable DUT.
36 Synchronizing Acquisitions Synchronization with an Averaging Acquisition When averaging, it is necessary to know when the average count has been reached. The :SINGle command does not average. If it is known that a trigger will occur, a :DIGitize will acquire the complete number of averages, but if the number of averages is large, a timeout on the connection can occur. The example below polls during the :DIGitize to prevent a timeout on the connection. ' ' Synchronizing in averaging acquisition mode.
Synchronizing Acquisitions 36 ' Save *ESE (Standard Event Status Enable register) mask ' (so it can be restored later). Dim varInitialESE As Variant myScope.WriteString "*ESE?" varInitialESE = myScope.ReadNumber ' Set *ESE mask to allow only OPC (Operation Complete) bit. myScope.WriteString "*ESE " + CStr(CInt("&H01")) ' Acquire using :DIGitize. Set up OPC bit to be set when the ' operation is complete. ' ----------------------------------------------------------------myScope.
36 Synchronizing Acquisitions 790 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 37 More About Oscilloscope Commands Command Classifications / 792 Valid Command/Query Strings / 793 Query Return Values / 799 All Oscilloscope Commands Are Sequential / 800 791
37 More About Oscilloscope Commands Command Classifications To help you use existing programs with your oscilloscope, or use current programs with the next generation of Keysight InfiniiVision oscilloscopes, commands are classified by the following categories: • "Core Commands" on page 792 • "Non-Core Commands" on page 792 • "Obsolete Commands" on page 792 Core Commands Core commands are a common set of commands that provide basic oscilloscope functionality on this oscilloscope and future Keysight In
More About Oscilloscope Commands 37 Valid Command/Query Strings • "Program Message Syntax" on page 793 • "Duplicate Mnemonics" on page 797 • "Tree Traversal Rules and Multiple Commands" on page 797 Program Message Syntax To program the instrument remotely, you must understand the command format and structure expected by the instrument. The IEEE 488.
37 More About Oscilloscope Commands not you have included the question mark. The command and query forms of an instruction usually have different program data. Many queries do not use any program data. There are three types of headers: • "Simple Command Headers" on page 795 • "Compound Command Headers" on page 795 • "Common Command Headers" on page 795 White Space (Separator) White space is used to separate the instruction header from the program data.
37 More About Oscilloscope Commands Long Form Short form TIMebase TIM DELay DEL TYPE TYPE In the oscilloscope programmer's documentation, the short form of a command is indicated by uppercase characters. Programs written in long form are easily read and are almost self-documenting. The short form syntax conserves the amount of controller memory needed for program storage and reduces I/O activity. Simple Command Headers Simple command headers contain a single mnemonic.
37 More About Oscilloscope Commands Program Data Syntax Rules Program data is used to convey a parameter information related to the command header. At least one space must separate the command header or query header from the program data. When a program mnemonic or query has multiple program data, a comma separates sequential program data.
37 More About Oscilloscope Commands Duplicate Mnemonics Identical function mnemonics can be used in more than one subsystem. For example, the function mnemonic RANGe may be used to change the vertical range or to change the horizontal range: :CHANnel1:RANGe .4 Sets the vertical range of channel 1 to 0.4 volts full scale. :TIMebase:RANGe 1 Sets the horizontal time base to 1 second full scale. :CHANnel1 and :TIMebase are subsystem selectors and determine which range is being modified.
37 More About Oscilloscope Commands NOTE Example 2: Program Message Terminator Sets Parser Back to Root NOTE The colon between TIMebase and RANGe is necessary because TIMebase:RANGe is a compound command. The semicolon between the RANGe command and the POSition command is the required program message unit separator. The POSition command does not need TIMebase preceding it because the TIMebase:RANGe command sets the parser to the TIMebase node in the tree. myScope.
37 More About Oscilloscope Commands Query Return Values Command headers immediately followed by a question mark (?) are queries. Queries are used to get results of measurements made by the instrument or to find out how the instrument is currently configured. After receiving a query, the instrument interrogates the requested function and places the answer in its output queue. The answer remains in the output queue until it is read or another command is issued.
37 More About Oscilloscope Commands All Oscilloscope Commands Are Sequential IEEE 488.2 makes the distinction between sequential and overlapped commands: • Sequential commands finish their task before the execution of the next command starts. • Overlapped commands run concurrently. Commands following an overlapped command may be started before the overlapped command is completed. All of the oscilloscope commands are sequential.
Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 38 Programming Examples VISA COM Examples / 802 VISA Examples / 835 SICL Examples / 882 SCPI.NET Examples / 902 Example programs are ASCII text files that can be cut from the help file and pasted into your favorite text editor.
38 Programming Examples VISA COM Examples • "VISA COM Example in Visual Basic" on page 802 • "VISA COM Example in C#" on page 811 • "VISA COM Example in Visual Basic .NET" on page 820 • "VISA COM Example in Python" on page 828 VISA COM Example in Visual Basic To run this example in Visual Basic for Applications (VBA): 1 Start the application that provides Visual Basic for Applications (for example, Microsoft Excel). 2 Press ALT+F11 to launch the Visual Basic editor.
Programming Examples 38 On Error GoTo VisaComError ' Create the VISA COM I/O resource. Set myMgr = New VisaComLib.ResourceManager Set myScope = New VisaComLib.FormattedIO488 Set myScope.IO = _ myMgr.Open("USB0::0x0957::0x17A6::US50210029::0::INSTR") myScope.IO.Clear ' Clear the interface. myScope.IO.Timeout = 10000 ' Set I/O communication timeout. ' Initialize - start from a known state. Initialize ' Capture data. Capture ' Analyze the captured waveform.
38 Programming Examples On Error GoTo VisaComError ' Use auto-scale to automatically configure oscilloscope. ' ----------------------------------------------------------------DoCommand ":AUToscale" ' Set trigger mode (EDGE, PULSe, PATTern, etc., and input source. DoCommand ":TRIGger:MODE EDGE" Debug.Print "Trigger mode: " + _ DoQueryString(":TRIGger:MODE?") ' Set EDGE trigger parameters. DoCommand ":TRIGger:EDGE:SOURCe CHANnel1" Debug.
Programming Examples 38 DoQueryString(":TIMebase:POSition?") ' Set the acquisition type (NORMal, PEAK, AVERage, or HRESolution). DoCommand ":ACQuire:TYPE NORMal" Debug.Print "Acquire type: " + _ DoQueryString(":ACQuire:TYPE?") ' Or, configure by loading a previously saved setup. ' ----------------------------------------------------------------Dim varSetupString As Variant strPath = "c:\scope\config\setup.dat" Open strPath For Binary Access Read As hFile ' Open file for input.
38 Programming Examples ' ----------------------------------------------------------------' Get screen image. DoCommand ":HARDcopy:INKSaver OFF" Dim byteData() As Byte byteData = DoQueryIEEEBlock_UI1(":DISPlay:DATA? PNG, COLor") ' Save screen image to a file. Dim strPath As String strPath = "c:\scope\data\screen.png" If Len(Dir(strPath)) Then Kill strPath ' Remove file if it exists.
Programming Examples 38 Preamble() = DoQueryNumbers(":WAVeform:PREamble?") intFormat = Preamble(0) intType = Preamble(1) lngPoints = Preamble(2) lngCount = Preamble(3) dblXIncrement = Preamble(4) dblXOrigin = Preamble(5) lngXReference = Preamble(6) sngYIncrement = Preamble(7) sngYOrigin = Preamble(8) lngYReference = Preamble(9) If intFormat = 0 Then Debug.Print "Waveform format: BYTE" ElseIf intFormat = 1 Then Debug.Print "Waveform format: WORD" ElseIf intFormat = 4 Then Debug.
38 Programming Examples Debug.Print "Number of data values: " + _ CStr(UBound(varQueryResult) + 1) ' Set up output file: strPath = "c:\scope\data\waveform_data.csv" ' Open file for output. Open strPath For Output Access Write Lock Write As hFile ' Output waveform data in CSV format. Dim lngDataValue As Long Dim lngI As Long For lngI = 0 To UBound(varQueryResult) lngDataValue = varQueryResult(lngI) ' Write time value, voltage value.
Programming Examples 38 On Error GoTo VisaComError Dim strErrors As String myScope.WriteIEEEBlock command, data CheckInstrumentErrors Exit Sub VisaComError: MsgBox "VISA COM Error: " + vbCrLf + CStr(Err.Number) + ", " + _ Err.Source + ", " + _ Err.Description, vbExclamation, "VISA COM Error" End End Sub Private Function DoQueryString(query As String) As String On Error GoTo VisaComError myScope.WriteString query DoQueryString = myScope.
38 Programming Examples Dim strErrors As String myScope.WriteString query DoQueryNumbers = myScope.ReadList CheckInstrumentErrors Exit Function VisaComError: MsgBox "VISA COM Error: " + vbCrLf + CStr(Err.Number) + ", " + _ Err.Source + ", " + _ Err.Description, vbExclamation, "VISA COM Error" End End Function Private Function DoQueryIEEEBlock_UI1(query As String) As Variant On Error GoTo VisaComError myScope.WriteString query DoQueryIEEEBlock_UI1 = myScope.
Programming Examples 38 VisaComError: MsgBox "VISA COM Error: " + vbCrLf + Err.Description End Sub VISA COM Example in C# To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual C#, Windows, Console Application project. 3 Cut-and-paste the code that follows into the C# source file. 4 Edit the program to use the VISA address of your oscilloscope. 5 Add a reference to the VISA COM 3.
38 Programming Examples VisaComInstrument("USB0::0x0957::0x17A6::US50210029::0::INSTR" ); myScope.SetTimeoutSeconds(10); // Initialize - start from a known state. Initialize(); // Capture data. Capture(); // Analyze the captured waveform. Analyze(); } catch (System.ApplicationException err) { Console.WriteLine("*** VISA COM Error : " + err.Message); } catch (System.SystemException err) { Console.WriteLine("*** System Error Message : " + err.Message); } catch (System.Exception err) { System.Diagnostics.
Programming Examples 38 // Set trigger mode (EDGE, PULSe, PATTern, etc., and input source. myScope.DoCommand(":TRIGger:MODE EDGE"); Console.WriteLine("Trigger mode: {0}", myScope.DoQueryString(":TRIGger:MODE?")); // Set EDGE trigger parameters. myScope.DoCommand(":TRIGger:EDGE:SOURCe CHANnel1"); Console.WriteLine("Trigger edge source: {0}", myScope.DoQueryString(":TRIGger:EDGE:SOURce?")); myScope.DoCommand(":TRIGger:EDGE:LEVel 1.5"); Console.WriteLine("Trigger edge level: {0}", myScope.
38 Programming Examples myScope.DoCommand(":ACQuire:TYPE NORMal"); Console.WriteLine("Acquire type: {0}", myScope.DoQueryString(":ACQuire:TYPE?")); // Or, configure by loading a previously saved setup. byte[] DataArray; int nBytesWritten; // Read setup string from file. strPath = "c:\\scope\\config\\setup.stp"; DataArray = File.ReadAllBytes(strPath); nBytesWritten = DataArray.Length; // Restore setup string. myScope.DoCommandIEEEBlock(":SYSTem:SETup", DataArray); Console.
Programming Examples 38 FileStream fStream = File.Open(strPath, FileMode.Create); fStream.Write(ResultsArray, 0, nLength); fStream.Close(); Console.WriteLine("Screen image ({0} bytes) written to {1}", nLength, strPath); // Download waveform data. // ----------------------------------------------------------// Set the waveform points mode. myScope.DoCommand(":WAVeform:POINts:MODE RAW"); Console.WriteLine("Waveform points mode: {0}", myScope.
38 Programming Examples Console.WriteLine("Acquire type: AVERage"); } else if (fType == 3.0) { Console.WriteLine("Acquire type: HRESolution"); } double fPoints = fResultsArray[2]; Console.WriteLine("Waveform points: {0:e}", fPoints); double fCount = fResultsArray[3]; Console.WriteLine("Waveform average count: {0:e}", fCount); double fXincrement = fResultsArray[4]; Console.WriteLine("Waveform X increment: {0:e}", fXincrement); double fXorigin = fResultsArray[5]; Console.
Programming Examples 38 class VisaComInstrument { private ResourceManagerClass m_ResourceManager; private FormattedIO488Class m_IoObject; private string m_strVisaAddress; // Constructor. public VisaComInstrument(string strVisaAddress) { // Save VISA addres in member variable. m_strVisaAddress = strVisaAddress; // Open the default VISA COM IO object. OpenIo(); // Clear the interface. m_IoObject.IO.Clear(); } public void DoCommand(string strCommand) { // Send the command. m_IoObject.
38 Programming Examples m_IoObject.WriteString(strQuery, true); // Get the result number. double fResult; fResult = (double)m_IoObject.ReadNumber( IEEEASCIIType.ASCIIType_R8, true); // Check for inst errors. CheckInstrumentErrors(strQuery); // Return result number. return fResult; } public double[] DoQueryNumbers(string strQuery) { // Send the query. m_IoObject.WriteString(strQuery, true); // Get the result numbers. double[] fResultsArray; fResultsArray = (double[])m_IoObject.ReadList( IEEEASCIIType.
Programming Examples 38 m_IoObject.WriteString(":SYSTem:ERRor?", true); strInstrumentError = m_IoObject.ReadString(); if (!strInstrumentError.ToString().StartsWith("+0,")) { if (bFirstError) { Console.WriteLine("ERROR(s) for command '{0}': ", strCommand); bFirstError = false; } Console.Write(strInstrumentError); } } while (!strInstrumentError.ToString().
38 Programming Examples catch { } } } } VISA COM Example in Visual Basic .NET To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual Basic, Windows, Console Application project. 3 Cut-and-paste the code that follows into the C# source file. 4 Edit the program to use the VISA address of your oscilloscope. 5 Add a reference to the VISA COM 3.
Programming Examples 38 ) myScope.SetTimeoutSeconds(10) ' Initialize - start from a known state. Initialize() ' Capture data. Capture() ' Analyze the captured waveform. Analyze() Catch err As System.ApplicationException Console.WriteLine("*** VISA Error Message : " + err.Message) Catch err As System.SystemException Console.WriteLine("*** System Error Message : " + err.Message) Catch err As System.Exception System.Diagnostics.Debug.Fail("Unexpected Error") Console.WriteLine("*** Unexpected Error : " + err.
38 Programming Examples myScope.DoCommand(":TRIGger:EDGE:LEVel 1.5") Console.WriteLine("Trigger edge level: {0}", _ myScope.DoQueryString(":TRIGger:EDGE:LEVel?")) myScope.DoCommand(":TRIGger:EDGE:SLOPe POSitive") Console.WriteLine("Trigger edge slope: {0}", _ myScope.DoQueryString(":TRIGger:EDGE:SLOPe?")) ' Save oscilloscope configuration. Dim ResultsArray As Byte() ' Results array. Dim nLength As Integer ' Number of bytes returned from inst.
Programming Examples 38 strPath = "c:\scope\config\setup.stp" DataArray = File.ReadAllBytes(strPath) nBytesWritten = DataArray.Length ' Restore setup string. myScope.DoCommandIEEEBlock(":SYSTem:SETup", DataArray) Console.WriteLine("Setup bytes restored: {0}", nBytesWritten) ' Capture an acquisition using :DIGitize. myScope.DoCommand(":DIGitize CHANnel1") End Sub ' Analyze the captured waveform.
38 Programming Examples ' Set the waveform points mode. myScope.DoCommand(":WAVeform:POINts:MODE RAW") Console.WriteLine("Waveform points mode: {0}", _ myScope.DoQueryString(":WAVeform:POINts:MODE?")) ' Get the number of waveform points available. Console.WriteLine("Waveform points available: {0}", _ myScope.DoQueryString(":WAVeform:POINts?")) ' Set the waveform source. myScope.DoCommand(":WAVeform:SOURce CHANnel1") Console.WriteLine("Waveform source: {0}", _ myScope.
Programming Examples 38 Console.WriteLine("Waveform X reference: {0:e}", fXreference) Dim fYincrement As Double = fResultsArray(7) Console.WriteLine("Waveform Y increment: {0:e}", fYincrement) Dim fYorigin As Double = fResultsArray(8) Console.WriteLine("Waveform Y origin: {0:e}", fYorigin) Dim fYreference As Double = fResultsArray(9) Console.WriteLine("Waveform Y reference: {0:e}", fYreference) ' Get the waveform data. ResultsArray = myScope.DoQueryIEEEBlock(":WAVeform:DATA?") nLength = ResultsArray.
38 Programming Examples ' Clear the interface. m_IoObject.IO.Clear() End Sub Public Sub DoCommand(ByVal strCommand As String) ' Send the command. m_IoObject.WriteString(strCommand, True) ' Check for inst errors. CheckInstrumentErrors(strCommand) End Sub Public Sub DoCommandIEEEBlock(ByVal strCommand As String, _ ByVal DataArray As Byte()) ' Send the command to the device. m_IoObject.WriteIEEEBlock(strCommand, DataArray, True) ' Check for inst errors.
Programming Examples 38 Public Function DoQueryNumbers(ByVal strQuery As String) As _ Double() ' Send the query. m_IoObject.WriteString(strQuery, True) ' Get the result numbers. Dim fResultsArray As Double() fResultsArray = _ m_IoObject.ReadList(IEEEASCIIType.ASCIIType_R8, ",;") ' Check for inst errors. CheckInstrumentErrors(strQuery) ' Return result numbers. Return fResultsArray End Function Public _ Function DoQueryIEEEBlock(ByVal strQuery As String) As Byte() ' Send the query. m_IoObject.
38 Programming Examples m_IoObject = New FormattedIO488Class() ' Open the default VISA COM IO object. Try m_IoObject.IO = _ DirectCast(m_ResourceManager.Open(m_strVisaAddress, _ AccessMode.NO_LOCK, 0, ""), IMessage) Catch e As Exception Console.WriteLine("An error occurred: {0}", e.Message) End Try End Sub Public Sub SetTimeoutSeconds(ByVal nSeconds As Integer) m_IoObject.IO.Timeout = nSeconds * 1000 End Sub Public Sub Close() Try m_IoObject.IO.Close() Catch End Try Try Marshal.
Programming Examples # # # # # # 38 Keysight VISA COM Example in Python using "comtypes" ********************************************************* This program illustrates a few commonly used programming features of your Keysight oscilloscope. ********************************************************* # Import Python modules. # --------------------------------------------------------import string import time import sys import array from comtypes.client import GetModule from comtypes.
38 Programming Examples do_command(":TRIGger:EDGE:SOURCe CHANnel1") qresult = do_query_string(":TRIGger:EDGE:SOURce?") print "Trigger edge source: %s" % qresult do_command(":TRIGger:EDGE:LEVel 1.5") qresult = do_query_string(":TRIGger:EDGE:LEVel?") print "Trigger edge level: %s" % qresult do_command(":TRIGger:EDGE:SLOPe POSitive") qresult = do_query_string(":TRIGger:EDGE:SLOPe?") print "Trigger edge slope: %s" % qresult # Save oscilloscope setup.
Programming Examples 38 # Analyze: # ========================================================= def analyze(): # Make measurements.
38 Programming Examples acq_type_dict = { 0 : "NORMal", 1 : "PEAK", 2 : "AVERage", 3 : "HRESolution", } ( wav_form, acq_type, wfmpts, avgcnt, x_increment, x_origin, x_reference, y_increment, y_origin, y_reference ) = do_query_numbers(":WAVeform:PREamble?") print print print print print print print print print print "Waveform format: %s" % wav_form_dict[wav_form] "Acquire type: %s" % acq_type_dict[acq_type] "Waveform points desired: %d" % wfmpts "Waveform average count: %d" % avgcnt "Waveform X increment:
Programming Examples 38 # ========================================================= # Send a command and check for errors: # ========================================================= def do_command(command): myScope.WriteString("%s" % command, True) check_instrument_errors(command) # ========================================================= # Send a command and check for errors: # ========================================================= def do_command_ieee_block(command, data): myScope.
38 Programming Examples # ========================================================= # Check for instrument errors: # ========================================================= def check_instrument_errors(command): while True: myScope.WriteString(":SYSTem:ERRor?", True) error_string = myScope.ReadString() if error_string: # If there is an error string value. if error_string.find("+0,", 0, 3) == -1: # Not "No error". print "ERROR: %s, command: '%s'" % (error_string, command) print "Exited because of error.
Programming Examples 38 VISA Examples • "VISA Example in C" on page 835 • "VISA Example in Visual Basic" on page 844 • "VISA Example in C#" on page 854 • "VISA Example in Visual Basic .NET" on page 865 • "VISA Example in Python" on page 875 VISA Example in C To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual C++, Win32, Win32 Console Application project. 3 In the Win32 Application Wizard, click Next >.
38 Programming Examples * This program illustrates a few commonly-used programming * features of your Keysight oscilloscope. */ #include #include #include #include /* /* /* /* For printf(). */ For strcpy(), strcat(). */ For clock(). */ Keysight VISA routines.
Programming Examples 38 /* Analyze the captured waveform. */ analyze(); /* Close the vi session and the resource manager session. */ viClose(vi); viClose(defaultRM); } /* Initialize the oscilloscope to a known state. * --------------------------------------------------------------- */ void initialize (void) { /* Clear the interface. */ err = viClear(vi); if (err != VI_SUCCESS) error_handler(); /* Get and display the device's *IDN? string.
38 Programming Examples printf("Read setup string query (%d bytes).\n", num_bytes); /* Write setup string to file. */ fp = fopen ("c:\\scope\\config\\setup.stp", "wb"); num_bytes = fwrite(ieeeblock_data, sizeof(unsigned char), num_bytes, fp); fclose (fp); printf("Wrote setup string (%d bytes) to ", num_bytes); printf("c:\\scope\\config\\setup.stp.\n"); /* Change settings with individual commands: /* Set vertical scale and offset. */ do_command(":CHANnel1:SCALe 0.
Programming Examples 38 { double double double double double double double double double double wav_format; acq_type; wav_points; avg_count; x_increment; x_origin; x_reference; y_increment; y_origin; y_reference; FILE *fp; int num_bytes; int i; /* Number of bytes returned from instrument. */ /* Make a couple of measurements.
38 Programming Examples /* Set the waveform source. */ do_command(":WAVeform:SOURce CHANnel1"); do_query_string(":WAVeform:SOURce?"); printf("Waveform source: %s\n", str_result); /* Choose the format of the data returned (WORD, BYTE, ASCII): */ do_command(":WAVeform:FORMat BYTE"); do_query_string(":WAVeform:FORMat?"); printf("Waveform format: %s\n", str_result); /* Display the waveform settings: */ do_query_numbers(":WAVeform:PREamble?"); wav_format = dbl_results[0]; if (wav_format == 0.
Programming Examples 38 x_reference = dbl_results[6]; printf("Waveform X reference: %e\n", x_reference); y_increment = dbl_results[7]; printf("Waveform Y increment: %e\n", y_increment); y_origin = dbl_results[8]; printf("Waveform Y origin: %e\n", y_origin); y_reference = dbl_results[9]; printf("Waveform Y reference: %e\n", y_reference); /* Read waveform data. */ num_bytes = do_query_ieeeblock(":WAVeform:DATA?"); printf("Number of data values: %d\n", num_bytes); /* Open file for output.
38 Programming Examples char message[80]; int data_length; strcpy(message, command); strcat(message, " #8%08d"); err = viPrintf(vi, message, num_bytes); if (err != VI_SUCCESS) error_handler(); err = viBufWrite(vi, ieeeblock_data, num_bytes, &data_length); if (err != VI_SUCCESS) error_handler(); check_instrument_errors(); return(data_length); } /* Query for a string result.
Programming Examples 38 char *query; { char message[80]; strcpy(message, query); strcat(message, "\n"); err = viPrintf(vi, message); if (err != VI_SUCCESS) error_handler(); err = viScanf(vi, "%,10lf\n", dbl_results); if (err != VI_SUCCESS) error_handler(); check_instrument_errors(); } /* Query for an IEEE definite-length block result.
38 Programming Examples err = viQueryf(vi, ":SYSTem:ERRor?\n", "%t", str_err_val); if (err != VI_SUCCESS) error_handler(); } if (strcmp(str_out, "") != 0) { printf("INST Error%s\n", str_out); err = viFlush(vi, VI_READ_BUF); if (err != VI_SUCCESS) error_handler(); err = viFlush(vi, VI_WRITE_BUF); if (err != VI_SUCCESS) error_handler(); } } /* Handle VISA errors.
Programming Examples 38 ' features of your Keysight oscilloscope. ' ------------------------------------------------------------------Option Explicit Public err As Long Public drm As Long Public vi As Long ' Error returned by VISA function calls. ' Session to Default Resource Manager. ' Session to instrument. ' Declare variables to hold numeric values returned by ' viVScanf/viVQueryf.
38 Programming Examples End Sub ' ' Initialize the oscilloscope to a known state. ' ------------------------------------------------------------------Private Sub Initialize() ' Clear the interface. err = viClear(vi) If Not (err = VI_SUCCESS) Then HandleVISAError vi ' Get and display the device's *IDN? string. strQueryResult = DoQueryString("*IDN?") MsgBox "*IDN? string: " + strQueryResult, vbOKOnly, "*IDN? Result" ' Clear status and load the default setup.
Programming Examples 38 ' Output setup string to a file: Dim strPath As String strPath = "c:\scope\config\setup.dat" If Len(Dir(strPath)) Then Kill strPath ' Remove file if it exists. End If ' Open file for output. Dim hFile As Long hFile = FreeFile Open strPath For Binary Access Write Lock Write As hFile Dim lngI As Long For lngI = 0 To lngSetupStringSize - 1 Put hFile, , byteArray(lngI) ' Write data. Next lngI Close hFile ' Close file.
38 Programming Examples ' Capture an acquisition using :DIGitize. ' ----------------------------------------------------------------DoCommand ":DIGitize CHANnel1" End Sub ' ' Analyze the captured waveform. ' ------------------------------------------------------------------Private Sub Analyze() ' Make a couple of measurements. ' ----------------------------------------------------------------DoCommand ":MEASure:SOURce CHANnel1" Debug.
Programming Examples 38 ' Set the waveform points mode. DoCommand ":WAVeform:POINts:MODE RAW" Debug.Print "Waveform points mode: " + _ DoQueryString(":WAVeform:POINts:MODE?") ' Get the number of waveform points available. Debug.Print "Waveform points available: " + _ DoQueryString(":WAVeform:POINts?") ' Set the waveform source. DoCommand ":WAVeform:SOURce CHANnel1" Debug.
38 Programming Examples ElseIf intType = 1 Then Debug.Print "Acquisition type: PEAK" ElseIf intType = 2 Then Debug.Print "Acquisition type: AVERage" ElseIf intType = 3 Then Debug.Print "Acquisition type: HRESolution" End If Debug.Print "Waveform points: " + _ FormatNumber(lngPoints, 0) Debug.Print "Waveform average count: " + _ FormatNumber(lngCount, 0) Debug.Print "Waveform X increment: " + _ Format(dblXIncrement, "Scientific") Debug.Print "Waveform X origin: " + _ Format(dblXOrigin, "Scientific") Debug.
Programming Examples 38 ' Close output file. Close hFile ' Close file. MsgBox "Waveform format BYTE data written to " + _ "c:\scope\data\waveform_data.csv.
38 Programming Examples err = viVScanf(vi, "%lf" + vbLf, VarPtr(dblResult)) If (err <> VI_SUCCESS) Then HandleVISAError vi DoQueryNumber = dblResult CheckInstrumentErrors End Function Private Function DoQueryNumbers(query As String) As Long Dim dblResult As Double ' Send query. err = viVPrintf(vi, query + vbLf, 0) If (err <> VI_SUCCESS) Then HandleVISAError vi ' Set up paramsArray for multiple parameter query returning array.
Programming Examples 38 If (err <> VI_SUCCESS) Then HandleVISAError vi ' retCount is now actual number of bytes returned by query. DoQueryIEEEBlock_Bytes = retCount CheckInstrumentErrors End Function Private Sub CheckInstrumentErrors() On Error GoTo ErrorHandler Dim strErrVal As String * 200 Dim strOut As String err = viVPrintf(vi, ":SYSTem:ERRor?" + vbLf, 0) If (err <> VI_SUCCESS) Then HandleVISAError vi ' Query any errors. err = viVScanf(vi, "%t", strErrVal) ' Read: Errnum,"Error String".
38 Programming Examples MsgBox "*** VISA Error : " + strVisaErr, vbExclamation ' If the error is not a warning, close the session. If err < VI_SUCCESS Then If session <> 0 Then Call viClose(session) End End If End Sub VISA Example in C# To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual C#, Windows, Console Application project. 3 Cut-and-paste the code that follows into the C# source file.
Programming Examples 38 { private static VisaInstrument myScope; public static void Main(string[] args) { try { myScope = new VisaInstrument("USB0::0x0957::0x17A6::US50210029::0::INSTR"); myScope.SetTimeoutSeconds(10); // Initialize - start from a known state. Initialize(); // Capture data. Capture(); // Analyze the captured waveform. Analyze(); } catch (System.ApplicationException err) { Console.WriteLine("*** VISA Error Message : " + err.Message); } catch (System.SystemException err) { Console.
38 Programming Examples /* * Capture the waveform. * -------------------------------------------------------------*/ private static void Capture() { // Use auto-scale to automatically configure oscilloscope. myScope.DoCommand(":AUToscale"); // Set trigger mode (EDGE, PULSe, PATTern, etc., and input source. myScope.DoCommand(":TRIGger:MODE EDGE"); Console.WriteLine("Trigger mode: {0}", myScope.DoQueryString(":TRIGger:MODE?")); // Set EDGE trigger parameters. myScope.
Programming Examples 38 myScope.DoQueryString(":TIMebase:SCALe?")); myScope.DoCommand(":TIMebase:POSition 0.0"); Console.WriteLine("Timebase position: {0}", myScope.DoQueryString(":TIMebase:POSition?")); // Set the acquisition type (NORMal, PEAK, AVERage, or HRESolution ). myScope.DoCommand(":ACQuire:TYPE NORMal"); Console.WriteLine("Acquire type: {0}", myScope.DoQueryString(":ACQuire:TYPE?")); // Or, configure by loading a previously saved setup.
38 Programming Examples // Get the screen data. nLength = myScope.DoQueryIEEEBlock(":DISPlay:DATA? PNG, COLor", out ResultsArray); // Store the screen data to a file. strPath = "c:\\scope\\data\\screen.png"; FileStream fStream = File.Open(strPath, FileMode.Create); fStream.Write(ResultsArray, 0, nLength); fStream.Close(); Console.WriteLine("Screen image ({0} bytes) written to {1}", nLength, strPath); // Download waveform data.
Programming Examples Console.WriteLine("Acquire } else if (fType == 1.0) { Console.WriteLine("Acquire } else if (fType == 2.0) { Console.WriteLine("Acquire } else if (fType == 3.0) { Console.WriteLine("Acquire } 38 type: NORMal"); type: PEAK"); type: AVERage"); type: HRESolution"); double fPoints = fResultsArray[2]; Console.WriteLine("Waveform points: {0:e}", fPoints); double fCount = fResultsArray[3]; Console.
38 Programming Examples // Close output file. writer.Close(); Console.WriteLine("Waveform format BYTE data written to {0}", strPath); } } class VisaInstrument { private int m_nResourceManager; private int m_nSession; private string m_strVisaAddress; // Constructor. public VisaInstrument(string strVisaAddress) { // Save VISA addres in member variable. m_strVisaAddress = strVisaAddress; // Open the default VISA resource manager. OpenResourceManager(); // Open a VISA resource session.
Programming Examples 38 nViStatus = visa32.viBufWrite(m_nSession, DataArray, nLength, out nBytesWritten); CheckVisaStatus(nViStatus); // Check for inst errors. CheckInstrumentErrors(strCommand); return nBytesWritten; } public StringBuilder DoQueryString(string strQuery) { // Send the query. VisaSendCommandOrQuery(strQuery); // Get the result string. StringBuilder strResults = new StringBuilder(1000); strResults = VisaGetResultString(); // Check for inst errors.
38 Programming Examples public int DoQueryIEEEBlock(string strQuery, out byte[] ResultsArray) { // Send the query. VisaSendCommandOrQuery(strQuery); // Get the result string. int length; // Number of bytes returned from instrument. length = VisaGetResultIEEEBlock(out ResultsArray); // Check for inst errors. CheckInstrumentErrors(strQuery); // Return string results. return length; } private void VisaSendCommandOrQuery(string strCommandOrQuery) { // Send command or query to the device.
Programming Examples 38 // Read return value string from the device. int nViStatus; nViStatus = visa32.viScanf(m_nSession, "%,10lf\n", fResultsArray); CheckVisaStatus(nViStatus); return fResultsArray; } private int VisaGetResultIEEEBlock(out byte[] ResultsArray) { // Results array, big enough to hold a PNG. ResultsArray = new byte[300000]; int length; // Number of bytes returned from instrument. // Set the default number of bytes that will be contained in // the ResultsArray to 300,000 (300kB).
38 Programming Examples } private void OpenResourceManager() { int nViStatus; nViStatus = visa32.viOpenDefaultRM(out this.m_nResourceManager); if (nViStatus < visa32.VI_SUCCESS) throw new ApplicationException("Failed to open Resource Manager"); } private void OpenSession() { int nViStatus; nViStatus = visa32.viOpen(this.m_nResourceManager, this.m_strVisaAddress, visa32.VI_NO_LOCK, visa32.VI_TMO_IMMEDIATE, out this.
Programming Examples 38 VISA Example in Visual Basic .NET To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual Basic, Windows, Console Application project. 3 Cut-and-paste the code that follows into the Visual Basic .NET source file. 4 Edit the program to use the VISA address of your oscilloscope.
38 Programming Examples ' Initialize - start from a known state. Initialize() ' Capture data. Capture() ' Analyze the captured waveform. Analyze() Catch err As System.ApplicationException Console.WriteLine("*** VISA Error Message : " + err.Message) Catch err As System.SystemException Console.WriteLine("*** System Error Message : " + err.Message) Catch err As System.Exception Debug.Fail("Unexpected Error") Console.WriteLine("*** Unexpected Error : " + err.
Programming Examples 38 myScope.DoQueryString(":TRIGger:EDGE:LEVel?")) myScope.DoCommand(":TRIGger:EDGE:SLOPe POSitive") Console.WriteLine("Trigger edge slope: {0}", _ myScope.DoQueryString(":TRIGger:EDGE:SLOPe?")) ' Save oscilloscope configuration. Dim ResultsArray As Byte() ' Results array. Dim nLength As Integer ' Number of bytes returned from inst. Dim strPath As String Dim fStream As FileStream ' Query and read setup string. nLength = myScope.
38 Programming Examples ' Restore setup string. nBytesWritten = myScope.DoCommandIEEEBlock(":SYSTem:SETup", _ DataArray) Console.WriteLine("Setup bytes restored: {0}", nBytesWritten) ' Capture an acquisition using :DIGitize. myScope.DoCommand(":DIGitize CHANnel1") End Sub ' ' Analyze the captured waveform. ' -------------------------------------------------------------Private Shared Sub Analyze() Dim Dim Dim Dim fResult As Double ResultsArray As Byte() ' Results array.
Programming Examples 38 Console.WriteLine("Waveform points mode: {0}", _ myScope.DoQueryString(":WAVeform:POINts:MODE?")) ' Get the number of waveform points available. myScope.DoCommand(":WAVeform:POINts 10240") Console.WriteLine("Waveform points available: {0}", _ myScope.DoQueryString(":WAVeform:POINts?")) ' Set the waveform source. myScope.DoCommand(":WAVeform:SOURce CHANnel1") Console.WriteLine("Waveform source: {0}", _ myScope.
38 Programming Examples Dim fYincrement As Double = fResultsArray(7) Console.WriteLine("Waveform Y increment: {0:e}", fYincrement) Dim fYorigin As Double = fResultsArray(8) Console.WriteLine("Waveform Y origin: {0:e}", fYorigin) Dim fYreference As Double = fResultsArray(9) Console.WriteLine("Waveform Y reference: {0:e}", fYreference) ' Get the waveform data. nLength = myScope.DoQueryIEEEBlock(":WAVeform:DATA?", _ ResultsArray) Console.
Programming Examples 38 ' Clear the interface. Dim nViStatus As Integer nViStatus = visa32.viClear(m_nSession) End Sub Public Sub DoCommand(ByVal strCommand As String) ' Send the command. VisaSendCommandOrQuery(strCommand) ' Check for inst errors. CheckInstrumentErrors(strCommand) End Sub Public Function DoCommandIEEEBlock(ByVal strCommand As String, _ ByVal DataArray As Byte()) As Integer ' Send the command to the device.
38 Programming Examples Public Function DoQueryNumber(ByVal strQuery As String) As Double ' Send the query. VisaSendCommandOrQuery(strQuery) ' Get the result string. Dim fResults As Double fResults = VisaGetResultNumber() ' Check for inst errors. CheckInstrumentErrors(strQuery) ' Return string results. Return fResults End Function Public Function DoQueryNumbers(ByVal strQuery As String) _ As Double() ' Send the query. VisaSendCommandOrQuery(strQuery) ' Get the result string.
Programming Examples 38 nViStatus = visa32.viPrintf(m_nSession, strWithNewline) CheckVisaStatus(nViStatus) End Sub Private Function VisaGetResultString() As StringBuilder Dim strResults As New StringBuilder(1000) ' Read return value string from the device. Dim nViStatus As Integer nViStatus = visa32.
38 Programming Examples CheckVisaStatus(nViStatus) nViStatus = visa32.viFlush(m_nSession, visa32.VI_READ_BUF) CheckVisaStatus(nViStatus) Return length End Function Private Sub CheckInstrumentErrors(ByVal strCommand As String) ' Check for instrument errors. Dim strInstrumentError As New StringBuilder(1000) Dim bFirstError As Boolean = True Do ' While not "0,No error" VisaSendCommandOrQuery(":SYSTem:ERRor?") strInstrumentError = VisaGetResultString() If Not strInstrumentError.ToString().
38 Programming Examples End If End Sub Public Sub Close() If m_nSession <> 0 Then visa32.viClose(m_nSession) End If If m_nResourceManager <> 0 Then visa32.viClose(m_nResourceManager) End If End Sub End Class End Namespace VISA Example in Python You can use the Python programming language with the PyVISA package to control Keysight oscilloscopes. The Python language and PyVISA package can be downloaded from the web at "http://www.python.org/" and "http://pyvisa.sourceforge.net/", respectively.
38 Programming Examples idn_string = do_query_string("*IDN?") print "Identification string: '%s'" % idn_string # Clear status and load the default setup. do_command("*CLS") do_command("*RST") # ========================================================= # Capture: # ========================================================= def capture(): # Use auto-scale to automatically set up oscilloscope. print "Autoscale." do_command(":AUToscale") # Set trigger mode.
Programming Examples 38 qresult = do_query_string(":TIMebase:SCALe?") print "Timebase scale: %s" % qresult do_command(":TIMebase:POSition 0.0") qresult = do_query_string(":TIMebase:POSition?") print "Timebase position: %s" % qresult # Set the acquisition type. do_command(":ACQuire:TYPE NORMal") qresult = do_query_string(":ACQuire:TYPE?") print "Acquire type: %s" % qresult # Or, set up oscilloscope by loading a previously saved setup. sSetup = "" f = open("setup.stp", "rb") sSetup = f.read() f.
38 Programming Examples # Download waveform data. # -------------------------------------------------------# Set the waveform points mode. do_command(":WAVeform:POINts:MODE RAW") qresult = do_query_string(":WAVeform:POINts:MODE?") print "Waveform points mode: %s" % qresult # Get the number of waveform points available. do_command(":WAVeform:POINts 10240") qresult = do_query_string(":WAVeform:POINts?") print "Waveform points available: %s" % qresult # Set the waveform source.
Programming Examples 38 y_reference = do_query_values(":WAVeform:YREFerence?")[0] # Get the waveform data. sData = do_query_string(":WAVeform:DATA?") sData = get_definite_length_block_data(sData) # Unpack unsigned byte data. values = struct.unpack("%dB" % len(sData), sData) print "Number of data values: %d" % len(values) # Save waveform data values to CSV file. f = open("waveform_data.
38 Programming Examples def do_query_values(query): if debug: print "Qyv = '%s'" % query results = InfiniiVision.ask_for_values("%s\n" % query) check_instrument_errors(query) return results # ========================================================= # Check for instrument errors: # ========================================================= def check_instrument_errors(command): while True: error_string = InfiniiVision.ask(":SYSTem:ERRor?\n") if error_string: # If there is an error string value.
Programming Examples 38 # ========================================================= InfiniiVision = visa.instrument("TCPIP0::130.29.70.139::inst0::INSTR") InfiniiVision.timeout = 15 InfiniiVision.term_chars = "" InfiniiVision.clear() # Initialize the oscilloscope, capture data, and analyze. initialize() capture() analyze() print "End of program.
38 Programming Examples SICL Examples • "SICL Example in C" on page 882 • "SICL Example in Visual Basic" on page 891 SICL Example in C To compile and run this example in Microsoft Visual Studio 2008: 1 Open Visual Studio. 2 Create a new Visual C++, Win32, Win32 Console Application project. 3 In the Win32 Application Wizard, click Next >. Then, check Empty project, and click Finish. 4 Cut-and-paste the code that follows into a file named "example.c" in the project directory.
Programming Examples #include #include #include #define SICL_ADDRESS #define TIMEOUT #define IEEEBLOCK_SPACE 38 /* For strcpy(), strcat(). */ /* For clock(). */ /* Keysight SICL routines. */ "usb0[2391::6054::US50210029::0]" 5000 100000 /* Function prototypes */ void initialize(void); void capture(void); void analyze(void); /* Initialize to known state. */ /* Capture the waveform. */ /* Analyze the captured waveform. */ void do_command(char *command); /* Send command.
38 Programming Examples /* Analyze the captured waveform. */ analyze(); /* Close the device session to the instrument. */ iclose(id); printf ("Program execution is complete...\n"); /* For WIN16 programs, call _siclcleanup before exiting to release * resources allocated by SICL for this application. This call is * a no-op for WIN32 programs. */ _siclcleanup(); } /* Initialize the oscilloscope to a known state.
Programming Examples 38 printf("Trigger edge level: %s\n", str_result); do_command(":TRIGger:EDGE:SLOPe POSitive"); do_query_string(":TRIGger:EDGE:SLOPe?"); printf("Trigger edge slope: %s\n", str_result); /* Save oscilloscope configuration. * ------------------------------------------------------------- */ /* Read system setup. */ num_bytes = do_query_ieeeblock(":SYSTem:SETup?"); printf("Read setup string query (%d bytes).\n", num_bytes); /* Write setup string to file.
38 Programming Examples printf("c:\\scope\\config\\setup.stp.\n"); /* Restore setup string. */ num_bytes = do_command_ieeeblock(":SYSTem:SETup", num_bytes); printf("Restored setup string (%d bytes).\n", num_bytes); /* Capture an acquisition using :DIGitize. * ------------------------------------------------------------- */ do_command(":DIGitize CHANnel1"); } /* Analyze the captured waveform.
Programming Examples 38 printf("Wrote screen image (%d bytes) to ", num_bytes); printf("c:\\scope\\data\\screen.png.\n"); /* Download waveform data. * ------------------------------------------------------------- */ /* Set the waveform points mode. */ do_command(":WAVeform:POINts:MODE RAW"); do_query_string(":WAVeform:POINts:MODE?"); printf("Waveform points mode: %s\n", str_result); /* Get the number of waveform points available.
38 Programming Examples { printf("Acquire type: HRESolution\n"); } wav_points = dbl_results[2]; printf("Waveform points: %e\n", wav_points); avg_count = dbl_results[3]; printf("Waveform average count: %e\n", avg_count); x_increment = dbl_results[4]; printf("Waveform X increment: %e\n", x_increment); x_origin = dbl_results[5]; printf("Waveform X origin: %e\n", x_origin); x_reference = dbl_results[6]; printf("Waveform X reference: %e\n", x_reference); y_increment = dbl_results[7]; printf("Waveform Y incremen
Programming Examples 38 strcpy(message, command); strcat(message, "\n"); iprintf(id, message); check_instrument_errors(); } /* Command with IEEE definite-length block.
38 Programming Examples } /* Query for numbers result. * --------------------------------------------------------------- */ void do_query_numbers(query) char *query; { char message[80]; strcpy(message, query); strcat(message, "\n"); iprintf(id, message); iscanf(id, "%,10lf\n", dbl_results); check_instrument_errors(); } /* Query for an IEEE definite-length block result.
38 Programming Examples } if (strcmp(str_out, "") != 0) { printf("INST Error%s\n", str_out); iflush(id, I_BUF_READ | I_BUF_WRITE); } } SICL Example in Visual Basic To run this example in Visual Basic for Applications: 1 Start the application that provides Visual Basic for Applications (for example, Microsoft Excel). 2 Press ALT+F11 to launch the Visual Basic editor. 3 Add the sicl32.bas file to your project: a Choose File>Import File.... b Navigate to the header file, sicl32.
38 Programming Examples Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long) ' ' Main Program ' ------------------------------------------------------------------Sub Main() On Error GoTo ErrorHandler ' Open a device session using the SICL_ADDRESS. id = iopen("usb0[2391::6054::US50210029::0]") Call itimeout(id, 5000) ' Initialize - start from a known state. Initialize ' Capture data. Capture ' Analyze the captured waveform. Analyze ' Close the vi session and the resource manager session.
Programming Examples 38 MsgBox "*** Error : " + Error, vbExclamation End End Sub ' ' Capture the waveform. ' ------------------------------------------------------------------Private Sub Capture() On Error GoTo ErrorHandler ' Use auto-scale to automatically configure oscilloscope. ' ----------------------------------------------------------------DoCommand ":AUToscale" ' Set trigger mode (EDGE, PULSe, PATTern, etc., and input source. DoCommand ":TRIGger:MODE EDGE" Debug.
38 Programming Examples Close hFile ' Close file. ' Change settings with individual commands: ' ----------------------------------------------------------------' Set vertical scale and offset. DoCommand ":CHANnel1:SCALe 0.05" Debug.Print "Channel 1 vertical scale: " + _ DoQueryString(":CHANnel1:SCALe?") DoCommand ":CHANnel1:OFFSet -1.5" Debug.Print "Channel 1 vertical offset: " + _ DoQueryString(":CHANnel1:OFFSet?") ' Set horizontal scale and position. DoCommand ":TIMebase:SCALe 0.0002" Debug.
Programming Examples 38 ' ------------------------------------------------------------------Private Sub Analyze() On Error GoTo ErrorHandler ' Make a couple of measurements. ' ----------------------------------------------------------------DoCommand ":MEASure:SOURce CHANnel1" Debug.
38 Programming Examples DoCommand ":WAVeform:POINts 10240" Debug.Print "Waveform points available: " + _ DoQueryString(":WAVeform:POINts?") ' Set the waveform source. DoCommand ":WAVeform:SOURce CHANnel1" Debug.Print "Waveform source: " + _ DoQueryString(":WAVeform:SOURce?") ' Choose the format of the data returned (WORD, BYTE, ASCII): DoCommand ":WAVeform:FORMat BYTE" Debug.
Programming Examples 38 Debug.Print "Waveform points: " + _ FormatNumber(lngPoints, 0) Debug.Print "Waveform average count: " + _ FormatNumber(lngCount, 0) Debug.Print "Waveform X increment: " + _ Format(dblXIncrement, "Scientific") Debug.Print "Waveform X origin: " + _ Format(dblXOrigin, "Scientific") Debug.Print "Waveform X reference: " + _ FormatNumber(lngXReference, 0) Debug.Print "Waveform Y increment: " + _ Format(sngYIncrement, "Scientific") Debug.
38 Programming Examples Exit Sub ErrorHandler: MsgBox "*** Error : " + Error, vbExclamation End End Sub Private Sub DoCommand(command As String) On Error GoTo ErrorHandler Call ivprintf(id, command + vbLf) CheckInstrumentErrors Exit Sub ErrorHandler: MsgBox "*** Error : " + Error, vbExclamation End End Sub Private Function DoCommandIEEEBlock(command As String, _ lngBlockSize As Long) On Error GoTo ErrorHandler ' Send command part. Call ivprintf(id, command + " ") ' Write definite-length block bytes.
Programming Examples 38 Dim strResult As String * 200 Call ivprintf(id, query + vbLf) Call ivscanf(id, "%200t", strResult) DoQueryString = strResult CheckInstrumentErrors Exit Function ErrorHandler: MsgBox "*** Error : " + Error, vbExclamation End End Function Private Function DoQueryNumber(query As String) As Double On Error GoTo ErrorHandler Dim dblResult As Double Call ivprintf(id, query + vbLf) Call ivscanf(id, "%lf" + vbLf, dblResult) DoQueryNumber = dblResult CheckInstrumentErrors Exit Function Erro
38 Programming Examples End Function Private Function DoQueryIEEEBlock_Bytes(query As String) As Long On Error GoTo ErrorHandler ' Send query. Call ivprintf(id, query + vbLf) ' Read definite-length block bytes. Sleep 2000 ' Delay before reading data. Call ifread(id, byteArray(), ByteArraySize, vbNull, retCount) ' Get number of block length digits. Dim intLengthDigits As Integer intLengthDigits = CInt(Chr(byteArray(1))) ' Get block length from those digits.
Programming Examples 38 MsgBox strOut, vbExclamation, "INST Error Messages" Call iflush(id, I_BUF_READ Or I_BUF_WRITE) End If Exit Sub ErrorHandler: MsgBox "*** Error : " + Error, vbExclamation End End Sub Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide 901
38 Programming Examples SCPI.NET Examples These programming examples show how to use the SCPI.NET drivers that come with Keysight's free Command Expert software. While you can write code manually using SCPI.NET drivers (as described in this section), you can also use the Command Expert software to: • Connect to instruments and control them interactively using SCPI command sets. • Quickly prototype and test command sequences. • Generate C#, VB.NET, or C/C++ code for command sequences.
Programming Examples 38 • Windows XP: C:\Documents and Settings\All Users\Keysight\Command Expert\ScpiNetDrivers • Windows 7: C:\ProgramData\Keysight\Command Expert\ScpiNetDrivers d Select the .dll file for your oscilloscope, for example AgInfiniiVision2000X_01_20.dll; then, click OK. 7 Build and run the program. For more information, see the SCPI.NET driver help that comes with Keysight Command Expert. /* * Keysight SCPI.
38 Programming Examples catch (System.ApplicationException err) { Console.WriteLine("*** SCPI.NET Error : " + err.Message); } catch (System.SystemException err) { Console.WriteLine("*** System Error Message : " + err.Message); } catch (System.Exception err) { System.Diagnostics.Debug.Fail("Unexpected Error"); Console.WriteLine("*** Unexpected Error : " + err.Message); } finally { //myScope.Dispose(); } } /* * Initialize the oscilloscope to a known state.
Programming Examples 38 Console.WriteLine("Trigger edge source: {0}", strResults); myScope.SCPI.TRIGger.EDGE.LEVel.Command(1.5, "CHANnel1"); myScope.SCPI.TRIGger.EDGE.LEVel.Query("CHANnel1", out fResult); Console.WriteLine("Trigger edge level: {0:F2}", fResult); myScope.SCPI.TRIGger.EDGE.SLOPe.Command("POSitive"); myScope.SCPI.TRIGger.EDGE.SLOPe.Query(out strResults); Console.WriteLine("Trigger edge slope: {0}", strResults); // Save oscilloscope configuration. string[] strResultsArray; // Results array.
38 Programming Examples // Restore setup string. myScope.SCPI.SYSTem.SETup.Command(strResultsArray); Console.WriteLine("Setup bytes restored: {0}", nBytesWritten); // Capture an acquisition using :DIGitize. myScope.SCPI.DIGitize.Command("CHANnel1", null, null, null, null); } /* * Analyze the captured waveform. * -------------------------------------------------------------*/ private static void Analyze() { string strResults, source1, source2; double fResult; // Make a couple of measurements.
Programming Examples 38 myScope.SCPI.WAVeform.POINts.MODE.Command("RAW"); myScope.SCPI.WAVeform.POINts.MODE.Query(out strResults); Console.WriteLine("Waveform points mode: {0}", strResults); // Get the number of waveform points available. myScope.SCPI.WAVeform.POINts.CommandPoints(10240); int nPointsAvail; myScope.SCPI.WAVeform.POINts.Query1(out nPointsAvail); Console.WriteLine("Waveform points available: {0}", nPointsAvail); // Set the waveform source. myScope.SCPI.WAVeform.SOURce.
38 Programming Examples { Console.WriteLine("Acquire type: AVERage"); } else if (nType == 3) { Console.WriteLine("Acquire type: HRESolution"); } Console.WriteLine("Waveform Console.WriteLine("Waveform Console.WriteLine("Waveform Console.WriteLine("Waveform Console.WriteLine("Waveform Console.WriteLine("Waveform Console.WriteLine("Waveform Console.
38 Programming Examples 5 Edit the program to use the VISA address of your oscilloscope. 6 Add a reference to the SCPI.NET 3.0 driver: a Right-click the project you wish to modify (not the solution) in the Solution Explorer window of the Microsoft Visual Studio environment. b Choose Add Reference.... c In the Add Reference dialog, select the Browse tab, and navigate to the ScpiNetDrivers folder.
38 Programming Examples ' Capture data. Capture() ' Analyze the captured waveform. Analyze() Console.WriteLine("Press any key to exit") Console.ReadKey() Catch err As System.ApplicationException Console.WriteLine("*** SCPI.NET Error : " & err.Message) Catch err As System.SystemException Console.WriteLine("*** System Error Message : " & err.Message) Catch err As System.Exception System.Diagnostics.Debug.Fail("Unexpected Error") Console.WriteLine("*** Unexpected Error : " & err.Message) 'myScope.
Programming Examples 38 myScope.SCPI.TRIGger.EDGE.LEVel.Command(1.5, "CHANnel1") myScope.SCPI.TRIGger.EDGE.LEVel.Query("CHANnel1", fResult) Console.WriteLine("Trigger edge level: {0:F2}", fResult) myScope.SCPI.TRIGger.EDGE.SLOPe.Command("POSitive") myScope.SCPI.TRIGger.EDGE.SLOPe.Query(strResults) Console.WriteLine("Trigger edge slope: {0}", strResults) ' Save oscilloscope configuration. Dim strResultsArray As String() ' Results array. Dim nLength As Integer ' Number of bytes returned from instrument.
38 Programming Examples ' Restore setup string. myScope.SCPI.SYSTem.SETup.Command(strResultsArray) Console.WriteLine("Setup bytes restored: {0}", nBytesWritten) ' Capture an acquisition using :DIGitize. myScope.SCPI.DIGitize.Command("CHANnel1", Nothing, Nothing, _ Nothing, Nothing) End Sub ' Analyze the captured waveform.
Programming Examples 38 ' Set the waveform points mode. myScope.SCPI.WAVeform.POINts.MODE.Command("RAW") myScope.SCPI.WAVeform.POINts.MODE.Query(strResults) Console.WriteLine("Waveform points mode: {0}", strResults) ' Get the number of waveform points available. myScope.SCPI.WAVeform.POINts.CommandPoints(10240) Dim nPointsAvail As Integer myScope.SCPI.WAVeform.POINts.Query1(nPointsAvail) Console.WriteLine("Waveform points available: {0}", nPointsAvail) ' Set the waveform source. myScope.SCPI.WAVeform.
38 Programming Examples ' Read waveform data. myScope.SCPI.WAVeform.DATA.QueryBYTE(byteResultsArray) nLength = byteResultsArray.Length Console.WriteLine("Number of data values: {0}", nLength) ' Set up output file: strPath = "c:\scope\data\waveform_data.csv" If File.Exists(strPath) Then File.Delete(strPath) End If ' Open file for output. Dim writer As StreamWriter = File.CreateText(strPath) ' Output waveform data in CSV format. For i As Integer = 0 To nLength - 2 writer.
Programming Examples 38 # This program illustrates a few commonly used programming # features of your Keysight oscilloscope. # ********************************************************* # Import Python modules. # --------------------------------------------------------import sys sys.path.append("C:\Python26\Lib") # Python Standard Library. sys.path.append("C:\ProgramData\Keysight\Command Expert\ScpiNetDrivers") import string # Import .NET modules.
38 Programming Examples print "Trigger edge level: %s" % qresult scope.SCPI.TRIGger.EDGE.SLOPe.Command("POSitive") qresult = scope.SCPI.TRIGger.EDGE.SLOPe.Query() print "Trigger edge slope: %s" % qresult # Save oscilloscope setup. setup_lines = scope.SCPI.SYSTem.SETup.Query() nLength = len(setup_lines) File.WriteAllLines("setup.stp", setup_lines) print "Setup lines saved: %d" % nLength # Change oscilloscope settings with individual commands: # Set vertical scale and offset. scope.SCPI.CHANnel.SCALe.
Programming Examples 38 scope.SCPI.MEASure.FREQuency.Command("CHANnel1") qresult = scope.SCPI.MEASure.FREQuency.Query("CHANnel1") print "Measured frequency on channel 1: %f" % qresult # Use direct command/query when commands not in command set. scope.Transport.Command.Invoke(":MEASure:VAMPlitude CHANnel1") qresult = scope.Transport.Query.Invoke(":MEASure:VAMPlitude? CHANnel1") print "Measured vertical amplitude on channel 1: %s" % qresult # Download the screen image.
38 Programming Examples wav_form, acq_type, wfmpts, avgcnt, x_increment, x_origin, x_reference, y_increment, y_origin, y_reference ) = scope.SCPI.WAVeform.PREamble.
Programming Examples 38 # Wait for a key press before exiting. print "Press any key to exit..." Console.
38 Programming Examples 920 Keysight InfiniiVision 2000 X-Series Oscilloscopes Programmer's Guide
Index Symbols +9.9E+37, infinity representation, 799 +9.
Index byte format for data transfer, 633, 639 BYTeorder, 635 C C, SICL library example, 882 C, VISA library example, 835 C#, SCPI.
Index constants for making automatic measurements, 227 constants for scaling display factors, 227 constants for setting trigger levels, 227 controller initialization, 50 copy display, 175 core commands, 792 count, 636 count values, 186 coupling, 602 coupling for channels, 221 create automask, 383 CSV (Comma Separated Values) waveform data format, 440 cumulative edge activity, 708 current logic levels on digital channels, 151 current oscilloscope configuration, 131, 135, 139, 574 current probe, 235, 275 CUR
Index elapsed time in mask test, 390 ellipsis, 118 enable channel labels, 259 enabling calibration, 212 enabling channel display, 222 enabling status register bits, 126, 140 end of string (EOS) terminator, 794 end of text (EOT) terminator, 794 end or identify (EOI), 794 EOI (end or identify), 794 EOS (end of string) terminator, 794 EOT (end of text) terminator, 794 erase data, 257 erase measurements, 726 erase screen, 716 error frame count (CAN), 454 error frame count (UART), 515 error messages, 567, 751 e
Index groups of digital channels, 411, 413, 415, 710 H HANNing window for frequency resolution, 284 hardcopy, 175, 296 HARDcopy commands, 295 hardcopy factors, 299, 430 hardcopy filename, 721 hardcopy format, 720 hardcopy formfeed, 300 hardcopy grayscale, 722 hardcopy invert graticule colors, 301, 723 hardcopy layout, 302 hardcopy palette, 309 hardcopy print, area, 297 hardcopy printer driver, 724 head type, probe, 228 header, 793 high resolution acquisition type, 631 high trigger level, 596 high-frequenc
Index LIN serial search, data format, 554 LIN serial search, data length, 553 LIN serial search, frame ID, 550 LIN serial search, mode, 551 LIN source, 484 LIN standard, 485 LIN sync break, 486 LIN trigger, 487, 491 LIN trigger commands, 479 LIN triggering, 447 line glitch trigger source, 615 line number for TV trigger, 622 line terminator, 117 LINE trigger level, 603 LINE trigger source, 606 list of channel labels, 260 LISTer commands, 313 lister display, 315 lister time reference, 316 load utilization (C
Index Modify softkey, 42 modulating signal frequency, waveform generator, 673, 675 modulation (waveform generator), enabling/disabling, 681 modulation type, waveform generator, 682 MOSI data pattern width, 506 MOSI data pattern, SPI trigger, 505 MOSI data source, SPI trigger, 502 most significant byte first, 635 move cursors, 729, 730 msbfirst, 635 MSG (Message), 141, 143 MSO models, 5 MSS (Master Summary Status), 143 MTEenable (Mask Test Event Enable Register), 161 MTERegister[:EVENt] (Mask Test Event Eve
Index phase shifted demo signals, 238 PNG format screen image data, 258 pod, 411, 413, 414, 415, 649, 710 POD commands, 411 POD data format, 633 pod, stop displaying, 158 points, 188, 640, 642 points in waveform data, 630 polarity, 521, 624 polarity for glitch trigger, 612 polling synchronization with timeout, 784 polling wait, 782 PON (Power On) status bit, 127, 129 portrait layout for hardcopy, 302 position, 247, 322, 580, 585 position cursors, 729, 730 position in zoomed view, 585 position waveforms, 71
Index returning number of data points, 188 RF burst demo signal, 239 right reference, 582 ringing pulse demo signal, 238 rise time measurement, 340 rise time of positive edge, 359 RMS value measurement, 373 roll time base mode, 579 root (:) commands, 147, 150 root level commands, 3 RQL (Request Control) status bit, 127, 129 RQS (Request Service), 143 RS-232/UART triggering, 448 RST (Reset), 136 rules, tree traversal, 797 rules, truncation, 794 run, 144, 176 Run bit, 167, 169 run mode, mask test, 396 runnin
Index square waveform generator output, 667 SRE (Service Request Enable Register), 141, 766 SRQ (Service Request interrupt), 161, 165 Standard Event Status Enable Register (ESE), 126, 771 Standard Event Status Register (ESR), 128, 770 standard for video, 626 standard, LIN, 485 start acquisition, 144, 159, 176, 178 start and stop edges, 345 start cursor, 729 start measurement, 340 start print job, 311 start time, 614, 729 start time marker, 728 state memory, 139 state of instrument, 131, 574 status, 142, 17
Index trigger, glitch source, 615 trigger, high frequency reject filter, 593 trigger, holdoff, 594 trigger, IIC clock source, 471 trigger, IIC data source, 472 trigger, IIC pattern address, 473 trigger, IIC pattern data, 474 trigger, IIC pattern data 2, 475 trigger, IIC qualifier, 476 trigger, IIC signal baudrate, 483 trigger, IIC type, 477 trigger, LIN, 487 trigger, LIN pattern data, 489 trigger, LIN pattern data length, 491 trigger, LIN pattern format, 492 trigger, LIN sample point, 482 trigger, LIN sour
Index voltage marker used to measure waveform, 734, 735 voltage offset value for channels, 226 voltage probe, 235, 275 voltage ranges for channels, 233 voltage ranges for external trigger, 274 voltage threshold, 345 W WAI (Wait To Continue), 146 wait, 146 wait for operation complete, 132 Wait Trig bit, 167, 169 waveform base value measured, 369 WAVeform command, 51 WAVeform commands, 627 waveform data, 629 waveform data format, 440 waveform data length, 441 waveform data length, maximum, 442 waveform data