Test and Measurement Forum

Reset the PicoTech 4424

Post your LabVIEW discussions here

Reset the PicoTech 4424

Postby kanth_tvs » Wed Jun 23, 2010 2:51 pm

Hello,

I am trying to adapt the ps4000.dll for my application in LabVIEW. To learn more about the scope, I was playing with different options to understand how the scope behaves. During this process, I have entered invalid setup/parameter as a input parameter, the driver provided me an error code informing me the error.

So, if I rerun my code again without modifying anything, the "ps4000OpenUnit" is saying that "No PicoScope 4000 could be found".

I was able to get rid of this error by physically reconnecting the USB cable from the device and run it again.

But, what if this happens during experiment run-time, and would like to programatically reset the scope. what should be done?

I looked at the LabVIEW files provided in the SDK, but it doesn't show the above case, where the "ps4000openunit" has failed to locate the device.

Any programming suggestions in this regard?
kanth_tvs
Newbie
 
Posts: 0
Joined: Wed Jun 23, 2010 2:41 pm

Re: Reset the PicoTech 4424

Postby Robin » Thu Jun 24, 2010 7:18 am

Hi

You need to make sure you call ps4000CloseUnit before you call PS4000OpenUnit again.

Robin
Robin
Zen Master
Zen Master
 
Posts: 558
Joined: Fri Sep 19, 2008 10:17 am

Re: Reset the PicoTech 4424

Postby kanth_tvs » Thu Jun 24, 2010 2:07 pm

Thanks for the clue.

"ps4000closeunit" was already included into the program, I have created. And I have connected the error wire as an input to the system. So, if there is any error in the preceeding vi's, the "closeunit" will be skipped. This is due to the fact that when there is an error in the "error in" control, the function will not execute, and it would just pass on the error to the error out indicator

To solve, I have left the input error wire of "ps4000closeunit" unconnected, and it seems to close the unit in a proper way.

Don't select "disable" in the error checking option of the "ps4000closeunit" as this caused labVIEW to become unresponsive.

This is how I have done it.
lv_scope.png
kanth_tvs
Newbie
 
Posts: 0
Joined: Wed Jun 23, 2010 2:41 pm


Return to LabVIEW

Who is online

Users browsing this forum: No registered users and 0 guests