Longterm streaming fails

Post general discussions on using our drivers to write your own software here
wiik
Newbie
Posts: 0
Joined: Mon Feb 08, 2010 4:19 pm

Longterm streaming fails

Post by wiik »

I am using PicoScope 4424 and have developed a continuous recording application (4channels, 50kHz sampling for 60 minutes) based on the example c program included in the sdk.

The application runs successfully for around 10 minutes and 33554128 valid samples, but then fails. Stepping through the application, I can see that the callback function is not called anymore after failure. A subsequent call to ps4000Stop also results in the application hanging, also indicating that the picoscope driver hangs.

Is there a maximum number of samples that the picoscope driver can handle?

Any ideas why the application / picoscope driver hangs?

More details of main application calls are given below:
**************************************************
...
status = ps4000RunStreaming(unit->handle, &SAMPLE_INTERVAL_US, PS4000_US,0, 1000000, FALSE, 1, 100000);
...
while(...)
{
...
status = ps4000GetStreamingLatestValues(unit->handle,CallBackStreaming, NULL);
...
// The while loop is stopped when callback function has not been called after a certain time
}
...
ps4000Stop(unit->handle); // The call to this function HANGS.
...
**************************************************
PicoScope® 6 - PC Oscilloscope software version: 6.2.14.0
Driver Version: 1, 0, 5, 7

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

Re: Longterm streaming fails

Post by Robin »

Hi

It looks like there is a bug somewhere that is causing this. We will investigate this further and get a fix released as soon as possible.

Robin

Guest

Re: Longterm streaming fails

Post by Guest »

Thank you. I will be waiting for the fix:)

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

I am seeing a similar problem using the picoscope 2203. After grabbing data for about 70 minutes, the callback function is not called anymore and ps2000_get_streaming_last_values returns always zero.

I start streaming using

Code: Select all

ps2000_run_streaming_ns (handle, 1, PS2000_US, 1024 * 1024, 0, 1, 512*512)
and in a loop i call

Code: Select all

short numValuesRead =  ps2000_get_streaming_last_values(handle, ps2000FastStreamingReady);
to retrieve the data. ps2000FastStreamingReady is my callback function which only copies the data to my buffer.

I am wondering if i set up something wrong, because i can run the PicoScope 6 application for hours without any problems.

Thanks in advance for hints that could solve my problem.

bye,
Stefan

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

Re: Longterm streaming fails

Post by Robin »

Hi Stefan

I tried this myself today by disabling autostop in the example (ps2000con.c). I left a 2203 fast streaming continuously for eight hours.

I'm not sure why you are having problems, but you might want to look at the example and try doing the same.

Robin

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

Hi Robin,

thanks for your quick answer. I tried the example today with one modification. I changed the parameters.

Code: Select all

ps2000_run_streaming_ns ( unitOpened.handle, 1, PS2000_US, BUFFER_SIZE_STREAMING, 0, 1, 50000 )
I set the sampling interval to 1 micro second and i don't aggregate the samples.

The example application was also running for 70 minutes and then blocked. I have the same problem like in my application.

I will now try the original sampling interval of 10 micro seconds and see what happens. i suspect it to block after 700 minutes.

Here is the version of the driver i am using:
Driver Version: 2, 0, 7, 5
USB Version: 2.0
Hardware Version: 16
Variant Info: 2203

Thanks for your help,

regards,
Stefan

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

I tried it again with a sampling interval of 2 micro seconds and the application stopped working after 140 minutes.

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

Re: Longterm streaming fails

Post by Robin »

I have attached the latest driver release, which is the version I used. Can you see what happens using this version?

Robin
Attachments
PS2000.zip
(346.25 KiB) Downloaded 516 times

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

I have the same behavior using the new driver. the application stalls after 70 minutes.

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

Re: Longterm streaming fails

Post by Robin »

Hi Stefan

I will try this again using the same settings as you have used.

Robin

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

Re: Longterm streaming fails

Post by Robin »

Hi

There does appear to be a problem with the device locking up after very long periods of fast streaming. We will investigate further.

Robin

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

are there any news regarding that problem?

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

Re: Longterm streaming fails

Post by Robin »

Not yet, I'm afraid. I will chase it up for you.

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

Re: Longterm streaming fails

Post by Robin »

Hi Stefan

We have managed to track down and fix this bug.

The updated driver will be included in the next release of PicoScope 6.

I will also post it here as soon as it is available.

Robin

stefanwiesner
Newbie
Posts: 0
Joined: Sat Feb 27, 2010 1:51 pm

Re: Longterm streaming fails

Post by stefanwiesner »

Hi Robin,

I am glad to hear that you could find the problem. I am looking forward to getting the new driver.

regards,
Stefan

Post Reply