Private website

Back to Messinstrumente.


Messinstrumente v0.4.x


The Messinstrumente program can address one or more instruments that are connected to the PC via a network or USB interface. Network instruments that have LXI (VXI-11) support can be searched automatically. Instruments with USB support must belong to the USB class 'Test and Measurement', as well as to the subclass USB488.
Windows does not offer driver support for USBTMC devices, but you can use the existing WinUSB driver. The program uses the libusb-1.0 library to access the instruments, which in turn communicates with the installed WinUSB driver.

The program does not work with an existing other USB driver e.g. from R&S or NI.

The program should make it possible to control several instruments simultaneously, to read in, evaluate and display data, and to save it automatically.

I use the program with instruments from Rohde & Schwarz, Rigol, Picotest and with self programmed PIC18F microcontrollers. I do not own other USBTMC devices and can only guess and hope that it works with other instruments.


The program can be copied into any directory, no installation is necessary or provided. To be able to save settings, write permissions in this directory are required.
It is not written to the registry or stored anywhere else data unsolicited, also an Internet connection is not necessary. At the moment, all settings are saved automatically without prompting.

The WinUSB driver must be installed per used USBTMC instrument. Usually a suitable '.inf' file is sufficient for the installation. Because of the different Windows versions and the obligation of the driver signature, it is easiest to use the open source program Zadig.
There is a separate version for Windows XP, and a version for newer Windows versions. 32- and 64-bit systems are supported. The website with the download links and description is:

If the driver is installed correctly, the instrument will appear in the Device Manager. Here is an example from Windows 7:

Windows 7 - GerätemanagerWindows 7 - Gerätemanager

Windows 2000

The program also works with Windows 2000 (Service Pack 4). The processor must be at least a Pentium III, because SSE instructions are used.

For the USBTMC instruments, the libusb-win32 (libusb0) driver must be installed per instrument. With the program Zadig v2.2 for Windows XP, the driver can be installed easily.

Start of the program

The program opens with an empty MDI frame window. MDI stands for 'Multiple Document Interface', and is a method to manage multiple documents or contents in one frame window. You can open another MDI frame window in the 'File' menu at any time.
Except for the selection window for the instruments, all other windows can also be opened separately. If the CTRL key is pressed during opening, or the corresponding menu item or button is pressed. There is also an option in the 'Window' menu to always open the windows separately.


When exiting the program, all open windows are notified individually so that they close. If the program cannot be closed, you can force it to close by pressing the CTRL key while selecting the menu item 'File'->'Exit'.

Command line parameters

You can specify command line parameters to show only the script window at startup, or to have a script loaded and executed.

Connect to an instrument

With the menu 'Instrument'->'Select...' the window with the available instruments opens. Only USBTMC instruments with installed WinUSB driver are displayed, and only instruments that have not been opened yet. If an instrument is opened e.g. with a double click, it disappears from the displayed list. After closing or disconnecting the instrument, it reappears in the list.

Instrument auswählen

Instrument auswählen

USB and LAN connection options

In order for LAN instruments to be found, the appropriate setting must be made in the 'Options' tab.

Instrument Optionen

Add LAN instrument

If an instrument cannot be found automatically, it is possible to enter the IP address and the port used manually. The network or LAN adapter must be selected. To make it easier to recognize which instrument has been added manually, the description is shown in the selection list with square brackets. If the VXI port is not specified, the VXI port is first determined via a request to the RPC port 111. If the RPC port is not accessible, the VXI port must be specified.
In order for the instrument to appear in the selection list, the search for LXI (VXI-11) instruments must be activated in the 'Options for USB and LAN' tab.

LAN-Instrument hinzufügen

Add serial instrument

Serielles Instrument hinzufügen


An instrument can be connected by double-click, context menu, toolbar button or via the 'Instrument' menu. The model is displayed in the title bar of the main window and in the status bar.

Verbundenes Instrument

All other available functions for the connected instrument can be reached in the 'Function' menu.
The window for the function can be opened as MDI window or separately. If the CTRL key is pressed while opening, or if the menu item 'Open Separately' in menu 'Window' has been activated, a separate window will open. The separate window remains connected to the MDI frame window, and the latter must remain open. When the MDI frame window is closed, all connected windows are also closed.


SCPI command

The SCPI command function can be used to send and receive commands. Files can be selected for sending, and the received data can be saved. The SCPI block format can be inserted when sending, or removed when saving.
The commands can be managed in files, and entered in multiple lines or separated by semicolons. All entries are saved automatically. Files with commands can be displayed via the last entry 'Select directory...' in the combination list.

When sending files, the placeholder "|FILE|" must be placed at the end, at the last SCPI command.



The screenshot function can be used to read the screen contents of supported instruments.
A read-in screenshot can be displayed in a separate window. If the Ctrl key is pressed when opening the view window, a separate window is opened instead of an MDI window. The "F11" key can be used to activate a full screen display. With the key "F11" or "Esc" this view is terminated again.
The screenshot can be copied to the clipboard or saved as a file in PNG format. You can create a template for the file name.

With the options "Automatic" and "Save to folder", the screenshots can be read in and saved automatically. The interval is the time that is waited between the reading. To read in as quickly as possible, 1 millisecond can also be specified. For saving to a folder, a storage location must also be selected with the "Select folder..." button. The file name template and the folder are displayed as tooltips above the buttons. Corresponding messages are also output in the log window.
If only the option "Save to folder" is activated, the screenshot will be saved automatically during manual import.

The options in the list depend on the connected instrument. The options are divided into groups and can be activated or deactivated together depending on the group. The group heading is displayed with a colored background.

Bildschirmfoto-Funktion Bildschirmfoto-Optionen


Vorlage für Dateinamen


With the waveform function one can read in the analog and digital channels of supported instruments. The display of the data is not yet possible, the button 'View...' only opens an empty window.
Before reading in, the visible channels for the selection must be updated. The 'Update' button reads in the visible channels from the instrument. For the logic channels, only the visible channels are read in and saved. If the visible channels change on the instrument, the selection list must be updated manually.

For some instruments, the data can be read in from the screen, visible memory or the entire memory. When reading from the memory, the acquisition is stopped beforehand. With the options for the control, the acquisition can be started again automatically. To do this, the corresponding entries in the options list must be activated.

The read-in data can be saved per channel as a CSV or binary file. The individual logic channels are always saved together in one file. The source and the channel name are always added to the file name. It is best to use the template with the 'File name...' button for this. And select only the directory when saving. If you change the file name in the save dialog, the source and channel name will always be added, no matter if they are already present in the file name or not.
The binary file format is the same as the CSV format, except that the data is stored as a double with 64 bits. The counter or sequence number is stored as Long (32 bit). At the beginning of the file, after the text 'DATA OFFSET', there is an indication in integer format (32 bit) for the offset of the data from the beginning of the file.

If only the "Save to folder" option is activated, the trace data is automatically saved when reading in manually.

Messkurve-Funktion Messkurve-Optionen


The script window is still a test window. Script files can be opened as simple text files with the extension '.txt', via drag & drop.

Scripts for controlling the instruments can be executed in a separate window. The menu 'File'->'New script' opens a window for loading, editing and executing a script.

A description of the script instructions can be found here: Script.

The script window remains open when the start window is closed. It is also possible to use instruments that have already been opened in a start window or other script. Since commands for the instruments are executed one after the other, there is no collision of instructions.

No USBTMC instruments are displayed in the selection window that are currently used in scripts. Only when the script window is closed again, the instruments will be displayed in the selection window again after updating.


Example scripts:

Rohde&Schwarz RTB2000 Oscilloscope:


Back to Messinstrumente.