Hang on data read with some timebases on Picoscope 6402A

Post your C and C++ discussions here
Post Reply
gnyfin
Newbie
Posts: 0
Joined: Thu Aug 01, 2013 8:42 pm

Hang on data read with some timebases on Picoscope 6402A

Post by gnyfin »

Hi everyone!

Facts:
Windows 7 64bit
Microsoft Visual Studio 2010 Ultimate
Picoscope 6402A
latest Software Development Kit R10.5.0.19 / C# example
SineWave 100Hz, 1V peak at Chan1


I am new to Picoscope so I checked out the C# example given in the SDK package. I want to use the CollectBlockImmediate(), because it fits for my application.

So the C# example is running and for certain timebases (everything below 10000) it is working properly as I espected. For much higher values the console application freezes @PS6000ConsoleExample.cs (line 218) see below

Code: Select all

     
while (!_ready)
{
        Thread.Sleep(100);
}  
Waiting for data... Press a key to abort

It seems there was a similar problem in this thread http://www.picotech.com/support/topic6823.html so I also tried the compiled *.exe given by Chris, but it hangs at the same spot (it also works with low timebase-values).
Waiting for trigger... Press a key to abort


Regards,

Mark

Martyn
Site Admin
Site Admin
Posts: 4499
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: Hang on data read with some timebases on Picoscope 6402A

Post by Martyn »

Have you made any changes to the code, or compiled as supplied ?

What value is returned in the timeIndisposedMs value from the RunBlock call ?
Martyn
Technical Support Manager

gnyfin
Newbie
Posts: 0
Joined: Thu Aug 01, 2013 8:42 pm

Re: Hang on data read with some timebases on Picoscope 6402A

Post by gnyfin »

Martyn wrote:Have you made any changes to the code, or compiled as supplied ?
Compiled as supplied.


Martyn wrote: What value is returned in the timeIndisposedMs value from the RunBlock call ?
Surprisingly now it doesn´t work at all.

If I start a immediate block measurement with the default timebase=2 it works properly.

Changing the timebase to 3(and higher) causes a (endless)loop at

Code: Select all

      while (Imports.GetTimebase(_handle, _timebase, (int)sampleCount, out timeInterval, _oversample, out maxSamples, 0) != 0)
      {
        _timebase++;
      }
I can only pass through this loop setting a breakpoint at Visual Studio leading to a "data collection aborted"

Martyn
Site Admin
Site Admin
Posts: 4499
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: Hang on data read with some timebases on Picoscope 6402A

Post by Martyn »

What other values are you passing into this function, and are you running with 1 or more channels enabled.
Martyn
Technical Support Manager

Post Reply