Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Slow communication speed with Hameg 4040

Hello community,

 

I am quite new to the LabVEIW world and would like to ask you for an advice concerning my school project.

 

As a part of my work, I need to communicate via LabVIEW 2014 (using Windows 7) with a power supply (Hameg 4040, USB port) and be continuously setting new values of calculated current to all 4 channels of the power supply. I need to change the current value as least once per 100 ms.

 

I have installed the latest third party driver for the HAMEG (https://www.rohde-schwarz.com/us/driver/hmp4000/) and use the VI’s to set the current/voltage values to the device. The problem I am facing is the speed of the setting of the current. I made a simple counter, which tells me that it takes 3,8 seconds to the VIs to execute (hmp4000 Configure Channel, hmp4000 Configure Combined Voltage And Current). Is there anything I can do to speed it up?

 

Thanks for your patience with a beginner and chemist. 🙂

 

O

0 Kudos
Message 1 of 3
(3,539 Views)

I very recently encountered this problem. My workaround was to issue SCPI commands directly with VISA. HUGE speed improvement.

0 Kudos
Message 2 of 3
(2,285 Views)

The problem in the original poster's VI was that they configured all channels every loop, rather than configure the channels before the loop, and just step the current in the loop.

 

There's no magical speed improvement by using VISA to send SCPI commands directly, that's exactly what the driver VIs are doing.   Using the driver VIs you get a few advantages beyond the role your own solution..

 

1) Multiple people have tested the VIs under multiple use cases. (aka Debugged)

 

2) If the VI needs to issue multiple SCPI commands to instrument, then the those commands are sent in the right order to achieve the VIs purpose.  Sometimes even the manuals don't do a good job of specifying this and you get it for free because the code's been tested.

 

3) They include error handling.

 

0 Kudos
Message 3 of 3
(2,280 Views)