PS4000 closing problem

Post your LabVIEW discussions here
Post Reply
dcf

PS4000 closing problem

Post by dcf »

Hello,
I'm developing a LabView program with a Picoscope 4224.
- the program starts with a call to 'ps4000OpenUnit'
- then it executes configurations and acquisitions
- the program ends with a call to 'ps4000CloseUnit'
Everything works OK but:
If I restart the VI without closing LabView I get an error from 'ps4000OpenUnit' (PICO_STATUS = 3).
If I close Labview, its window closes but its icon stays in the application tray for about 30 seconds.
The same happens if I run and then close the Application.exe made by the builder.
It can be a problem because sometime this application needs to be restarted after a few seconds.
Any helps?
Thanks.

Daniele

Robin
Advanced User
Advanced User
Posts: 558
Joined: Fri Sep 19, 2008 10:17 am

Re: PS4000 closing problem

Post by Robin »

Hi Daniele

You need to make sure that you call ps4000CloseUnit before your application exits. As you have found, you won't be able to re-open it otherwise.

Robin

dcf

Re: PS4000 closing problem

Post by dcf »

As I said in my post, I DO a call to 'ps4000closeUnit' (that doesn't return any error code). That's why I'm looking for help.
Thanks anyway.

Daniele

Robin
Advanced User
Advanced User
Posts: 558
Joined: Fri Sep 19, 2008 10:17 am

Re: PS4000 closing problem

Post by Robin »

Sorry! I misunderstood. Can you post your VI (for LabVIEW 8.2) and I will have a look.

Robin

dcf

Solved: PS4000 closing problem

Post by dcf »

Found my mistake!!
In the 'ps4000CloseUnit' I configured the 'handle' parameter as a pointer instead of a value.
Fixed it, now it's ok.
Thanks & bye.

Daniele

Post Reply