Low Cost PCB's Low Cost Components

Author Topic: Software & tips for Rigol DS2072 ( DS2000 / DS4000 / DS6000 UltraVision DSOs )  (Read 173494 times)

0 Members and 1 Guest are viewing this topic.

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Last finished version: v 2.03 (Download link and change log in the second post of the thread) - Supports DS2000 / 2 channels on the DS4000 / DS6000?

Latest alpha version: v 3.00.a05 (Read latest posts in this thread for info on current status/features) - Supports DS1000Z / DS2000 / DS4000 / DS6000?

This documentation is slightly out-of-date for the latest version. Make sure you read this for the latest news and info. and then read below if you haven't used RUU before.

This thread is for user-written software and tips for the Rigol DS2000 (4000/6000) UltraVision scopes. Impressions, reviews, bugs, etc, can be found at this thread. Please post hardware/firmware problems, questions, feelings, etc. at the other thread.

In order to use this software, you will need:
1) Rigol UltraVision DSO
2) Computer  (the software was written with VS 2010 on a Windows7 x64 platform - and tested under Win7 x86 as well - but I would think it would work fine with WindowsXP as well)
3) NI VISA Runtime (this must be installed for the PC to communicate with the Rigol - you can download the latest version for free here - btw, you can fill in any garbage to create an account)

If anyone has a problem installing - or getting it to work on their system - let me know and I'll see what I can do.

My software will connect with the scope using either USB or TCPIP VISA resources. If you're planning to save many recorded frames, it's best to use USB (USB: ~2.5s = ~6s transfer time on TCPIP). The VISA resource locator is not coded with a sniffer for finding TCPIP connections - so it's default behavior is as follows:
a) If only one resource is found (either USB or TCPIP), the software will use that and start automatically.
b) If two (or more) resources are found (both USB and TCPIP - or other instruments), you will get a list box with the available selections to choose from.
c) If no resources are located, you are presented with the opportunity to enter the name yourself - or cancel out. If you know that you're connected via the LAN cable, just type the following string - inserting your own IP address in place of my sample one:
TCPIP::192.168.1.200::INSTR

This utility provides four basic functions:
1) Record / Playback control and quick settings from the PC.
2) Fast screen grab, save, and display in built-in image viewer.
3) Save selected frames as sequentially numbered image files, numbered CSV files, and Animated GIFs (See attached am.gif as an example).
4) Drop markers while using dual timebase zoom window for quick movement in large memory sample depths.

Screen captures and frames can be saved in CSV / PNG / BMP / JPEG / TIFF / GIF formats - and PNG or GIF frame sequences can be automatically compiled into Animated GIFs.

Note: the new UltraVision scopes (unlike Rigol's earlier series) have a very handy SCPI command to perform a screen grab. But the data is always transmitted as an 800x480x24 bit file (~1.152MB), so it takes ~2.5 seconds to get it to the PC and save it (using USB). If you want to save 10,000 frames to the computer in order to compile a video, well... you can do the math - it will take ~7 hours. It's not a problem for the software - but the scope will be tied up while it works. Of course, you can always break out at anytime (and even begin again where you left off, assuming you still have the frames in DSO memory).





Documentation (refer to images and notes as mentioned):

I'm just going to cover the less obvious points - if you have questions, post them here or PM me:

When you start the software, it will reflect the current state of the DSO and it's variables, i.e. if you are in Record Open mode, the Open button will be 'On', etc. If you change one of the variables in RUU, it will alter it on the scope, so the settings in RUU will normally override the DSO settings. But sometimes you might want to use, for example, the Navigation Knob on the scope to set the current frame - or set a variable using the Rigol's menus. If you want to have the DSO settings override RUU, click the 'READ' button in either the 'Record' or 'Play' group to have the respective settings of that group loaded from the scope.

In general, all of the buttons and settings function the same as they do on the Rigol - with the following exceptions:


                                     Record group:                                     

READ
Reads the current Record variables from the Rigol.

Loop
Automatically rewinds and restarts the Recording of frames after the End Frame. If AUTO is also checked, the frames will first be saved according to the selected settings. The selected state of Loop is reflected in the name currently displayed on the 'Record' button (see IMAGE #1 and #3).

IMAGE #1:



                                       Stop group:                                       

Off
Turns off Record Mode. Same as choosing Utility->Record->Mode->Off in Rigol menus.


                                       Play group:                                       

READ
Reads the current Playback variables from the Rigol.

Step >> {} Frame(s) Each {}ms
Selects whether frame playback will be via RUU - allowing you to specify the number of frames to step while playing back (or saving) at the speed set via the 'Each {}ms' setting. Checking this box will also affect saving frames and Animated GIFs - allowing you to create animations from every Nth frame recorded. If not checked, the Rigol will control playback in the normal way. at the speed set via the 'Interval' setting.

{UP ARROW / DOWN ARROW} (Keyboard)
Jogs the DSO forward/backward a frame when paused or stopped in Playback mode.

*Hidden Buttons*
If you click on either the "Start Frame" or "End Frame" LABEL, it will set the respective number = the current frame setting (displayed in the box). I added this because it's very handy sometimes to use the Navigation Knob and controls on the Rigol to move within a large span of recorded frames. So if, for example, you moved with the knob to frame 34056 of 65000 frames, and you wanted that to be your 'Start Frame' - just click 'READ' in the Play group - and then click the text: 'Start Frame'.


                                       Save group:                                       

Wavefrm
Selects CH1/CH2 waveform data to be saved.

Frames
Selects recorded frames to be saved - either as sequentially numbered bitmap or CSV (CH1/CH2 waveform data) files.

Display
Selects DSO display to be saved.

1 / 2
Selects whether channel 1 and/or channel 2 data will be saved to CSV files.

Anim GIF
Selects whether an Animated GIF will be compiled from the saved frames. If selected (and frames are being saved as PNGs or GIFs), it will create an Animated GIF (using 'Each {}ms' per frame) in the same location as the saved frames - with the filename entered and the .gif extension. The phrase 'Animating...' will appear as the group title until finished.

AUTO
Automatically names ANY files being saved, creating them in a folder named 'images', inside the application folder (see NOTE #1 below for the conventions used for naming). Also enables auto-saving of frames after recording them. The selected state of AUTO is reflected in the name currently displayed on the 'Record' and 'Save' buttons (see IMAGE #2 and #3).

IMAGE #2:


IMAGE #3:


Save
1) If 'Display' or 'Wavefrm' are checked, will capture the current DSO screen/waveform memory to PC as a single file.
    If 'AUTO' is not selected, a Save File dialogue box will open allowing you to chose the name and location for the file:
        For CSV files the extension is automatic - and the '1' and '2' checkboxes determine which channel data will be saved.
        For bitmap files you can choose image type by the FileType pulldown list or by typing the extension
            (if you don't enter an extension, PNG is the default).
    If you click 'Cancel' in the dialogue box, the file will be saved with the default name 'screen.png' or 'memory.csv' in the images\ directory below where the software resides.
    If 'AUTO' is selected, the file will be saved following the naming conventions listed in NOTE #1.
2) If 'Frames' is checked, will start capturing the range of frames specified with 'Start' and 'End Frame' variables - and 'Step >> {} Frame(s)' if 'Step' is checked.
    If 'AUTO' is not selected, a Save File dialogue box will open allowing you to chose the name and location for the files.
        For CSV files the extension is automatic - and the '1' and '2' checkboxes determine which channel data will be saved.
        For bitmap files you can choose image type by the FileType pulldown list or by typing the extension (if you don't enter an extension, PNG is the default).
    If you click 'Cancel' in the dialogue box, you will exit without saving frames.
    Each frame will be saved with the name you entered + a 5 digit frame number (leading zeroes) + the extension of either .CSV or the image format you've chosen.
    While saving frames, use the blue 'Cancel' button to abort. Click just once and wait - it can take a few milliseconds to break out of the current transfer.
    After saving, will generate an Animated Gif if the 'Animated GIF' box is checked (and frames are being saved as PNGs or GIFs).
    If 'AUTO' is selected, the files will be saved following the naming conventions listed in NOTE #1.

Clr Disp
Clears the current image displayed in the viewer.


                                   Marker Utility:                                   

Zoom Markers
Enters or exits the Zoom (Delayed Sweep) Marker utility. If the Rigol is not already set to Delayed Sweep, RUU will turn it on. Any previously uncleared markers which are within the bounds of the current Main horizontal scale will be visible. Markers may be dropped either manually - or by using a tracking cursor to drop them automatically (see 'Use Tracking' below). In order to speed up the manual dropping, clearing, and moving between markers, there are computer keyboard shortcuts for all of the screen buttons - denoted below with the keyname indicated between {curly braces}.

When the Delay Offset Position (the current position - i.e. the precise center of the smaller timebase) is exactly the same as a marker position, the marker is drawn with a red color - otherwise the markers will be drawn in white.

DROP {D / INSERT}
Drop a marker at the current position.

Left
The number of markers dropped left of the current position.
Shortcut: click the word 'Left' to move window position fully left.

LEFT ARROW {LEFT ARROW}
Move the current position to the next marker to the left (or if Auto-Scroll checked, scroll window left/stop scrolling).

Total
The total number of markers dropped (including the current position).
Shortcut: click the word 'Total' to move window position exactly center.

RIGHT ARROW {RIGHT ARROW}
Move the current position to the next marker to the right  (or if Auto-Scroll checked, scroll window right/stop scrolling).

Right
The number of markers dropped right of the current position.
Shortcut: click the word 'Right' to move window position fully right.

CLEAR {C / DELETE}
Clear the marker at the current position. You must be exactly on the marker position (indicated by red) to clear it.

CLR ALL {A / ENTER}
Clear all dropped markers.

Tracking C. (disables Auto-Scroll)
Turns on/off the use of a tracking cursor to auto-drop markers.
When first selected, RUU will turn on one of the tracking cursors and place it at the current position. If you make sure that the Cursor menu is selected (it can be visible or hidden), the Multi-Function Knob can be used at anytime to adjust the position of the tracking cursor (see IMAGE #4), while using the Navigation Knob and Horizontal Scale Position Knob to adjust the zoom window (or if in Frame Playback mode: Nav.Knob to adjust the frame number and just Hor.Pos.Knob to adjust the window).
The auto-dropping logic expects you to first move the tracking cursor to the position you want the marker (thus 'arming' the 'drop' logic - indicated by the 'DROP' button turning red - see IMAGE #5) - and the Rigol's display grid disappearing), and then moving the zoom window to another portion of the waveform - which automatically saves the last tracking cursor position as a marker. Then you just move the tracking cursor again, re-arming it for the next drop, before moving the window again, etc, etc. If the drop logic is armed (red) and you want to move the window without creating a marker, just reset the logic by clicking 'Clear' or pressing 'C' or 'Delete' on the computer keyboard (this will turn the 'DROP' button back to it's normal color). When done with auto-dropping, uncheck 'Tracking C.'

Using either manual or auto-dropping of markers is easy, once you get used to it. With one hand on the computer keyboard's Num Pad (Insert, Delete, Enter, Left & Right Arrow with Num lock off) and one hand on the Rigol, you can easily move through deep memory waveform samples, dropping and clearing markers and moving between them without having to look at the computer screen.

Auto-Scroll (disables 'Tracking C.' - enables 'No Update' and scroll-speed trackbar)
Turns on/off auto-scroll feature.
Use the Left / Right Arrow buttons (or keyboard keys) to stop and start the scroll. The Arrow buttons will turn green while the Auto-Scroll is active. Use the small trackbar to the right to adjust the amount of Horizontal window movement. If you want super-smooth scrolling on your Rigol's display (and don't care about updates on the RUU screen), just click 'No Update' and RUU won't refresh itself while scrolling the Zoom window. Smoothest scrolling happens with a stopped DSO - if the Rigol is triggering while in Delayed Sweep, any adjustments will cause it to 'blink' as it refreshes the display. Markers can be dropped using the 'D' or 'Insert' keys on the keyboard (make sure the display has focus) while the Zoom Window scrolls - regardless of whether you have 'No Update' checked or not.

IMAGE #4:


IMAGE #5:



NOTE #1:
Because the software can now auto-create quite a large amount of files quickly, the naming convention and placement has been changed from previous versions as follows:

All auto-named/saved files go (in this version) in an images\ folder below the application folder. Auto-named files will be date and time stamped, and the exact format of the stamp is determined by your Region settings in Windows Control Panel. I will add .ini file configuration of the names and default location in a later version.

DD-DD-DD indicates date.
TT.TT.TT indicates time.
FFFFFF indicates frame number.

images\screen.png  Default Display save (Display -> Save -> Cancel)
images\memory.csv  Default Waveform save (Waveform -> Save -> Cancel)
images\screen_DD-DD-DD_TT.TT.TT.png  Auto-name Display save
images\memory_DD-DD-DD_TT.TT.TT.csv  Auto-name Waveform save
images\frame_DD-DD-DD_TT.TT.TT_FFFFFF.png  Auto-name Display Frame save
images\frame_DD-DD-DD_TT.TT.TT_compiled.gif  Auto-name Animated GIF save
images\frame_DD-DD-DD_TT.TT.TT_FFFFFF.csv  Auto-name Waveform Frame save
« Last Edit: May 14, 2014, 03:46:04 AM by marmad »
 
The following users thanked this post: BravoV

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #1 on: December 15, 2012, 07:32:01 PM »
Change Logs:

EDIT (15/12/2012, 01:22:58 PM):  Uploaded v.0.2.
Change log:
1) Added the ability to set the Interval between playing back recorded frames.
2) Changed default behavior when clicking 'Cancel' in Save File dialogue for Screen Capture.
3) Fixed a bug that caused the software to sometimes stop saving frames before the End Frame.

EDIT (17/12/2012, 08:22:58 PM):  Uploaded v.0.3.
Change log:
1) Fixed a bug that caused an array overflow when saving captures or frames over a LAN connection (Thanks to Sparky).
2) Changed default behavior of VISA resource locator.
3) Included latest versions of NI-VISA DLLs.

EDIT (18/12/2012, 09:22:58 PM):  Uploaded v.0.4.
Change log:
1) Change default image file format to PNG and added many new image formats for saving.
2) Fixed the bug which didn't steer a VISA caught exception to entry dialogue box (Thanks to Sparky).
3) Reverted to the NI-VISA .NET 2.0 DLLs.

EDIT (19/12/2012, 02:22:58 AM):  Uploaded v.0.5.
Change log:
1) Added Animated GIF generator for GIF or PNG frame sequences.

EDIT (19/12/2012, 05:15:58 PM):  Uploaded v.0.6.
Change log:
1) Added the ability to skip frames when playing back or making Animated GIFs.

EDIT (22/12/2012, 01:15:58 AM):  Uploaded v.1.0.
Change log:
1) Major overhaul of interface and underlying code.
2) Added built-in image viewer.

EDIT (26/12/2012, 10:55:58 PM):  Uploaded v.1.1.
Change log:
1) Added CSV file types for writing waveform data/frames.
2) Added OFF button for RECORD mode (same as choosing 'Off' in Rigol Menus).

EDIT (30/12/2012, 08:15:58 PM):  Uploaded v.1.4.
Change log:
1) Added Open/Keep for v.00.01.00.02 compatibility (Thanks to Teneyes).
2) Fixed possible TypeConversion exceptions (Thanks to larsie).
3) Fixed FileType selection box for CSV files (Thanks to Sparky).

EDIT (10/01/2013, 12:59:58 PM):  Uploaded v.1.5.
Change log:
1) Fixed a bug that didn't use the filename entered for CSV files (Thanks to Teneyes).
2) Tried to eliminate all possible TypeConversion exceptions due to Region settings (Thanks to larsie and EV).
3) Added Up/Down Arrow control for moving forward/backward a frame while in Playback mode (paused or stopped).
4) Added an auto-name/save feature.
5) Added the ability to continually loop normal Recording (usable in combination with the auto-save feature).
6) Added Zoom Marker utility (incomplete - but usable).

EDIT (13/01/2013, 17:45:58 PM):  Uploaded v.1.51 (Minor bug-fix).
Change log:
1) Fixed one Type Conversion error when entering Zoom Marker Utility (Thanks to EV).

EDIT (20/02/2013, 21:09:58 PM):  Uploaded v.2.00 (Major update).
Change log:
1) Many changes: read this.

EDIT (21/02/2013, 22:56:58 PM):  Uploaded v.2.01 (Bug fixes).
Change log:
1) Fixed a bug that hid the Confirm Overwrite File dialog box.
2) Fixed a bug which screwed-up VISA TCPIP connections.
3) Fixed Open / Record bug when trying to record frames at timebases >= 200ms (Rigol won't do it).
4) Altered the text size of groupbox names.
5) Fixed a system.globalization error when converting strings to floating point numbers.
6) Fixed a bug which caused the software to hang when trying to save individual files for frames.
7) Added code which lets RUU terminate the VISA connection gracefully if the DSO is turned off with an active connection.
E) Idiot-proofed the enabling/disabling of buttons to prevent usage during active file saves/plots.
9) Removed all references to VISA .dlls when running standalone - except to the 'Connect' button. If you want to run RUU without VISA, delete the NationalInstruments.dlls from the directory (or just don't press 'Connect' when running the software.

EDIT (27/02/2013, 00:48:58 AM):  Uploaded v.2.02
Change log:
1) Fixed the bug that caused reversed plotting when using Increasing and Frame #.
2) Fixed the gradient routine when plotting when different colors have been selected.
3) In the Frame Array window, you can now choose both the color for drawing waveforms (and the first color in gradients), denoted by the color box with the 'ChanX' text in it - and/or the second color in two-color gradients, which is the smaller colored box after the 'Chan' one.
4) Rigol UltraVision model number now visible in title bar when connected.
5) Added compatibility for DS4000 scopes. RUU is still only two channels - but if I get reports back that it works well with DS4000 scopes, I'll add the extra two channels in a later version.

EDIT (27/02/2013, 20:48:58 PM):  Uploaded v.2.03
Change log:
1) Fixed the scaling bug for DS4000 series.
2) Fixed a couple of bugs in the save CSV routine.
3) Slowed down frame array reads a slight bit to prevent glitch frames.


Coming features:

Store/Load/Search sample in Delayed Sweep.
INI file configuration for default filenames, locations, IP address, etc.
WFM file writes.


Download History:

RUU.zip (158.26 kB - downloaded 8 times.)
RUU_0_2.zip (158.58 kB - downloaded 6 times.)
RUU_0_3.zip (163.3 kB - downloaded 6 times.)
RUU_0_4.zip (159.57 kB - downloaded 4 times.)
RUU_0_5.zip (174.77 kB - downloaded 4 times.)
RUU_0_6.zip (172.94 kB - downloaded 6 times.)
RUU_1_0.zip (178.04 kB - downloaded 8 times.)
RUU_1_1.zip (179.67 kB - downloaded 16 times.)
RUU_1_4.zip (183.91 kB - downloaded 29 times.)
RUU_1_5.zip (215.4 kB - downloaded 10 times.)
RUU_1_51.zip (222.98 kB - downloaded 65 times.)
RUU_2_0.zip (853.35 kB - downloaded 15 times.)
RUU_2_01.zip (854.12 kB - downloaded 30 times.)
RUU_2_02.zip (854.6 kB - downloaded 11 times.)
RUU_2_03.zip (854.72 kB - downloaded 431 times.)
« Last Edit: December 28, 2013, 04:41:44 AM by marmad »
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #2 on: December 15, 2012, 11:57:06 PM »
New version of the software uploaded - one new feature, one tweak, and one bug fix. Details in the first post.
 

Offline Sparky

  • Frequent Contributor
  • **
  • Posts: 311
  • Country: us
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #3 on: December 16, 2012, 02:33:21 PM »
Hey marmad!

First, I must say I think this is as awesome beginning of some very handy PC utilities --- great job!!  I look forward to testing these software tools, and I hope I can contribute with some good suggestions, and even some VS 2010 code :)  Are you developing in Visual Basic, C# or Visual C++?  I will look forward to updates, in particular, the feature you plan next (ability to grab actual voltage data) --- am thinking of some nice plotting abilities and signal processing on PC  :D


Moving on, I discovered what might be a new bug today, and thought I would use your software (I'm using LAN interface to the DS2072) for the screen captures and post about it, but unfortunately I encountered a problem with the RUU software. 

When the software started (I'm using v0.2), I just click "Screen Capture or..." button, and then "Cancel", so it should save the file "screen.bmp" in program directory.  About 5 seconds after pressing "Cancel" I get the error "Destination array was not long enough. Check ... " (first attachment).  Then after "OK" button pressed, I get "Screen capture error" (second attachment).

I tried again, this time specifying a file name, but the exact same error occurred.  So, it seems to try and save a file, but is not able to.

Can you look into this?  Let me know if there's something I can test to identify more of the problem.


Also, a suggestion:
1. When press screen capture, would be nice if "Save as type" defaults to .BMP, or can be set to other file type (e.g. .PNG), so that I only have to enter the "base filename", without extension.  This might require incorporating some image conversion program, though.
 

Offline Sparky

  • Frequent Contributor
  • **
  • Posts: 311
  • Country: us
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #4 on: December 16, 2012, 03:16:38 PM »
Update: I turned my DS2072 off tried again after dinner.  This time, when I run the RUU software I get the message "No VISA instrument found" and the utility exits.  I checked the LAN settings on the DS2072 and see that it is assigned an IP address via DHCP.
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #5 on: December 17, 2012, 06:52:35 AM »
First off, Sparky - thanks for the feedback! Even if it was mainly bug reports ;) it's always good to hear something back. Now to address the issues you mentioned:

I'm working in VB.NET - but wouldn't be adverse to doing some code in C if necessary (perhaps for some time critical stuff). But so far, it's all been rather simple software.

First bug: great description and documentation. It sounds like the array which is being used to hold the transmitted bitmap is overflowing. But that seems odd since Rigol is always transmitting the exact same amount of bytes. Have you managed to save any screen frames or captures on your computer with the software? Also, what OS are you running - and how much memory in your machine? I'll try to track the bug down when I'm back at my work computer tomorrow.

Your EXT suggestion: actually, I should have mentioned it in the above documentation, but you never have to type the file extension .BMP - either when doing a screen capture or saving frames. Since the Rigol will only send BMP files with this SCPI command, the software just automatically puts it on when saving a file.

LAN problem: I haven't used the LAN connection much yet (just for testing the software) but I did notice, once or twice,  some odd behavior in terms of being recognized. The first thing you should check, if your scope isn't found, is whether the scope is recognized by another VISA app. Do you have Rigol's Ultra Sigma software installed? If so, test recognition on that and get back to me. If not, install it (then test recognition then get back to me).

EDIT: Also, are you running version 5.2 of the VISA runtime - or a different version?
« Last Edit: December 17, 2012, 06:59:46 AM by marmad »
 

Offline Sparky

  • Frequent Contributor
  • **
  • Posts: 311
  • Country: us
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #6 on: December 17, 2012, 08:47:48 AM »
You're welcome, marmad!  I'm happy to provide feedback :) 

Ah, Visual Basic --- good to know --- that is the language I am most familiar with from the Visual Studio suite.

Additional details of my setup: Apple MacPro :o running Windows 7, 64-bit, 16GB RAM.  In my tests, I had downloaded and installed the latest VISA runtime (v5.2) from NI and then run your software.

When RUU starts, and I could use the "Enter" button to begin Record mode; the scope responded exactly as expected.  I then pressed "Exit" button.  I did not try and record any data.  Then I tried the Screen Capture function and had the problems as described below.  I tried again today, after everything has been powered off, and encounter the "No VISA instrument found" message and the program exits.

So, up to this point, I've not been able to save any screen frames or captures to my computer with RUU.

Just now, I've installed Rigol's UltraSigma software.  It is able to detect my DS2072 without problem (VISA address: TCPIP0::10.0.1.12::INSTR) and I am able to do "Print screen" through UltraSigma.  (In fact, UltraSigma saved .BMP (1.09MB), .PNG (15.3kB) and .JPG (50.3kB) files --- see attachments --- BMP and PNG are indistinguishable, JPG has some color issues.  Based on your comment below about the SCPI command for grabbing screen, it seems PNG must be converted from BMP file, but it would be awesome if DS2000 could send PNG data!)

I guess next thing I could try is USB connection and see which issues (detection of DS2072, screen capture) are resolved.
 

Offline Sparky

  • Frequent Contributor
  • **
  • Posts: 311
  • Country: us
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #7 on: December 17, 2012, 09:18:08 AM »
I just did test with USB interface; I have disconnected LAN interface but did not power off/on DS2072.  Everything worked this time!  The RUU software started, and the Screen Capture worked perfectly.  I tried the "Cancel" option when prompted for filename and my image editor started with loaded screen capture, as expected.  Also, when I entered a filename, the file was saved to disk with .bmp extension.

So, perhaps the problem is with correctly recognizing the devices' VISA address, and may be there is a minor difference in how SCPI commands are being sent when selecting "Enter" (which worked via LAN) and "Screen Capture" (which would not work via LAN).

One interesting thing I've noted, is that the devices' VISA address appears different in some places.  On the device and in UltraStudio, I've seen TCPIP::10.0.1.12::INSTR but in the "web interface" accessed via UltraStudio I've seen TCPIP0::10.0.1.12::INSTR  I believe the former one is correct, but I'm not sure which address might be used in RUU.

Hope that helps!
« Last Edit: December 17, 2012, 11:06:26 AM by Sparky »
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #8 on: December 18, 2012, 06:36:33 AM »
New version of the software uploaded - one bug fix, one changed feature, and one tweak. Details are here - and in the first post.

@Sparky - thanks again for all your feedback - it really helps!

1) I fixed the code in my software which caused the array overflow with a screen capture using the TCPIP connection. It appears the Rigol firmware adds an extra CR at the end of transfers using the TCPIP connection as opposed to the USB. I'm not sure why they do that, but I modified my code to accept it. If you find any other bugs while using the TCPIP connection, please let me know - I've only tested heavily using USB.

2) I've done some testing - and realized that a VISA TCPIP connection must be 'searched' for by the software sometimes. Since very few people are likely to use the LAN connection (it's at least 2x slower), I'm not bothering with writing the 'search' code now, but instead I've re-written my VISA resource locator with the following rules:

a) If only one resource is found (either USB or TCPIP), the software will use that and start automatically.
b) If two (or more) resources are found (both USB and TCPIP - or other instruments), you will get a list box with the available selections to choose from.
c) If no resources are located, you are presented with the opportunity to enter the name yourself - or cancel out. If you know that you're connected via the LAN cable, just type the following string - inserting your own IP address in place of my sample one:
TCPIP::192.168.1.200::INSTR

3) I've also included the newest versions of the NI-VISA DLLs.

Quote
Based on your comment below about the SCPI command for grabbing screen, it seems PNG must be converted from BMP file, but it would be awesome if DS2000 could send PNG data!

There is no mention of being able to transfer PNG files in the Rigol Programming Guide, so I have to assume that the Ultra Sigma software is either converting the data itself - or knows some commands that aren't published publicly ;)
« Last Edit: December 20, 2012, 05:44:09 AM by marmad »
 

Offline Sparky

  • Frequent Contributor
  • **
  • Posts: 311
  • Country: us
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #9 on: December 19, 2012, 04:08:35 AM »
Hey marmad!

Thanks for the updated RUU --- I eagerly tried it out last night, but unfortunately had no luck --- I was unable to get past the "No VISA resources found" message when I started the program.  The new version did not prompt me to enter a VISA address as a string.  I confirmed this morning, with my DS2072 unplugged, and the program did not prompt me to input a string.  Is it possible the old .exe is in the .zip file?

For example, when I start Ultra Sigma with the DSO connected via USB - it's recognized the moment the software starts. But for a LAN connection, I have to use the 'search' button every time.

I believe the USB behavior is because a program can receive messages from Windows about a "device change" (WM_DEVICECHANGE: http://msdn.microsoft.com/en-us/library/windows/desktop/aa363480(v=vs.85).aspx).  But this functionality does not exist for LAN topology; devices may be connected to a LAN but not "advertise" themselves.  I too have to use the 'Search' button in UltraSigma when the scope is connected by Ethernet, and this appears to be standard procedure (page 246 of Users Guide).

Quote
Based on your comment below about the SCPI command for grabbing screen, it seems PNG must be converted from BMP file, but it would be awesome if DS2000 could send PNG data!

There is no mention of being able to transfer PNG files in the Rigol Programming Guide, so I have to assume that the Ultra Sigma software is either converting the data itself - or knows some commands that aren't published publicly ;)

I wonder if there are third-party software VISA "sniffer", that can monitor for VISA commands, may be this would let us catch commands UltraSigma is sending?
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #10 on: December 19, 2012, 07:48:03 AM »
New version of the software uploaded - one changed feature, one bug fix, and one tweak. Details are here - and in the first post.

1) You can now save the the screen / frame captures in PNG / BMP / JPEG / TIFF / GIF formats. While this doesn't speed up the transfer from the DSO, it does slice time off the PC side - which adds up if saving many frames. It also saves disk space - and speeds things up considerably when compiling images to video or animated GIFs (see above attached example: am.gif - which was made very quickly with the software). All formats available are visible in the FileType pulldown list in the dialogue box, which you can use to select the extension - or type it after the filename. No extension now defaults to PNG - and a 'Cancel' in screen capture mode saves and displays a file called 'screen.png'

2) Fixed the bug which didn't steer a VISA caught exception to the entry dialogue box (thanks again, Sparky!)

3) Reverted to the NI-VISA .NET 2.0 DLLs after I ran into problems running the last release on an x86 machine.


I'll be including an animated GIF generator in the next minor update.
« Last Edit: December 19, 2012, 09:08:32 AM by marmad »
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #11 on: December 19, 2012, 01:21:04 PM »
New version of the software uploaded - one new feature. Details in the first post.

1) I added an Animated GIF generator after I saw what a handy feature it might be: a really useful way to be able to pass on DSO technical / debug tests and info to other users - much more informative than a simple static screen shot. I've attached another animated GIF created with this version of RUU here.

This will be the last update for awhile - have to get on to other things for a bit.

Enjoy ;)
« Last Edit: December 19, 2012, 02:10:35 PM by marmad »
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #12 on: December 20, 2012, 04:35:15 AM »
New version of the software uploaded - one new feature. Details in the first post.

1) I added the ability to skip frames when playing back or making Animated GIFs - allowing you to create animations from every Nth frame recorded. This really increases the usefulness for creating animated reports - you can test the finished animation using 'Step' mode. I've attached another Animated GIF which illustrates - it was created from every 20th frame starting with frame 15.

This will REALLY be the last update before the holidays (unless someone reports a bug).

Features to come:
Much better control of the Recording - including setting the recording start/stop frames and interval - and initiating a Trigger/Start Recording pulse.
Grab screen/frames as WFM or CVS data - and save individually or as a group.

Happy Holidays  ;)
« Last Edit: December 22, 2012, 11:42:02 AM by marmad »
 

Offline EV

  • Frequent Contributor
  • **
  • Posts: 469
  • Country: fi
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #13 on: December 20, 2012, 04:51:06 AM »
Thanks for the program! I am going to try it when I have time. ;D
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Re: Software, tips, and tricks for Rigol DS2000/4000/6000 UltraVision DSOs
« Reply #14 on: December 20, 2012, 04:53:45 AM »
Thanks for the program! I am going to try it when I have time. ;D

Great, EV! Let me know what you think - if you find any bugs - or if you have any suggestions for added features.
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
New version of the software uploaded -  with a major overhaul of interface and underlying code - and now with a built-in image viewer.

This is the last release (unless a bug-fix is needed) focusing on bitmapped files. The next release will start retrieving DSO memory/frames as waveform data - with plotting to screen - and saving as WFM or CSV files.


Merry Xmas, everyone  ;)
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
New version of the software uploaded - two new features added. Details in the first post.
 

Offline larsie

  • Contributor
  • Posts: 18
Seems to work partly on my scope, but I get an exception when doing some operations. But for example capturing the screen works. Sorry about the Norwegian text. 

Se slutten av denne meldingen for detaljert informasjon om aktivering av
JIT-feilsøking (Just In Time) i stedet for denne dialogboksen.

************** Unntakstekst **************
System.InvalidCastException: Konvertering fra strengen 1.000000e-07 til typen Double er ikke gyldig. ---> System.FormatException: Inndatastrengen hadde ugyldig format.
   ved Microsoft.VisualBasic.CompilerServices.Conversions.ParseDouble(String Value, NumberFormatInfo NumberFormat)
   ved Microsoft.VisualBasic.CompilerServices.Conversions.ToDouble(String Value, NumberFormatInfo NumberFormat)
   --- Slutten på sporingen av intern unntaksstakk ---
   ved Microsoft.VisualBasic.CompilerServices.Conversions.ToDouble(String Value, NumberFormatInfo NumberFormat)
   ved Microsoft.VisualBasic.CompilerServices.Conversions.ToDouble(String Value)
   ved Rigol_UtraVision_Utilities.Utilities.readRecParams()
   ved Rigol_UtraVision_Utilities.Utilities.readParams()

When getting data from the scope in CSV format, it starts off like the following. Seems the exception might be in reading that low value...

X,CH1,Start,Increment,
Sequence,Volt,-7.000000e-07,1.000000e-09,
0,7.520e000,
1,7.440e000,
2,7.520e000,
« Last Edit: December 28, 2012, 10:12:11 AM by larsie »
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Seems to work partly on my scope, but I get an exception when doing some operations. But for example capturing the screen works. Sorry about the Norwegian text. 

Thanks for the feedback! It's really appreciated - since I need it to nail down bugs. Can you be a bit more specific about when exactly you get the exception(s)? Is it only when you try to save as CSV?

EDIT: Fixed (I think ;D) in v.1.4.
« Last Edit: December 31, 2012, 06:29:08 AM by marmad »
 

Offline larsie

  • Contributor
  • Posts: 18
Thanks. Will test tonight. The exception came on startup and on various other buttonpresses. Not when getting csv. No error then.
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Thanks. Will test tonight. The exception came on startup and on various other buttonpresses. Not when getting csv. No error then.

Good. The exception notice you posted pointed me towards conversion error caused when reading the Record/Playback Intervals from DSO (and forgetting to do a fixed conversion from ASCII to floating point number). I will post the bug fix (with a couple of new features) later today - please download that version tonight for testing. And thanks again for the feedback  :)
 

Offline larsie

  • Contributor
  • Posts: 18
Screenshot in the other thread looks really great! Let me know when it's ready to test.
 

Offline marmad

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: aq
    • DaysAlive
Screenshot in the other thread looks really great! Let me know when it's ready to test.

It's ready to go - the problem is documentation :o I was hoping to post a short video for usage instead of writing - but I don't think I can get that finished before tomorrow.
 

studio25

  • Guest
 

Offline Teneyes

  • Frequent Contributor
  • **
  • Posts: 495
  • Country: ca
01.00.05 Firmware

Same File as I got (hex compared Identical)
IiIiIiIiIi  --  curiosity killed the cat but, satisfaction brought it back
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf