Hi,
I modified the python program( see http://ctrlpascal.com/picoscope.htm) for streaming mode. But severals problems exist. One is that the autostop sometimes work, somtimes not. Another problem is that the signal collection is not strictly continuous (see the picture, source is a sine function). Attachment is the python code (python 3).
Hi Hitesh,
Thanks for your reply! I'm not sure the version of ps4000a.dll. I just installed a pico SDK. In my code, I copy the data from buffer to a list after each callback in the application level. I downloaded the Python application you suggested and I'm still working on it. It seems a little difficult for me.
Thanks,
Hongbin
this period I am also trying streaming mode with a PicoScope 4424 and experience troubles. I adopted the code provided by hsun7 for use on a 4424 and tried it with Python 3.5.2
I use ps4000.dll version 1.2.4.41 (dated: 8/6/2015). This is the dll that works correctly, since when using the newer version 1.5.0.6 (8/2/2017), function ps4000OpenUnit() fails when opening the device. (It returns "-1").
Anyway, I don't get the plot: after executing the callback the program jumps to the "finally" section, performs the CloseUnit() functionality and exits with a ValueError, as shown below:
Traceback (most recent call last):
File "F:\Picoscope\ctrlpascal_2\ps4000_Streaming_2.py", line 172, in
data1 = DoStreaming()
File "F:\Picoscope\ctrlpascal_2\ps4000_Streaming_2.py", line 123, in DoStreaming
status = DLL.ps4000GetStreamingLatestValues(handle, call_back, None)
ValueError: Procedure probably called with not enough arguments (20885764 bytes missing)
The callback indicates having acquired 9981 samples, but it seems that it cannot return properly.
Any ideas?
Have you tried our Python application from the GitHub repository?
Is the picoipp.dll with the ps4000.dll (presumanbly taken from the PicoScope 6 installation directory?) and have you tried the dlls from the PicoScope 6.12.9 release?
Hi Hitesh,
I tried with the ps4000.dll from the latest picoscope version. This is v1.5.0.8 and still has the same issue: it returns -1 upon executing ps4000OpenUnit()
To ensure that I have control over the dlls used, I explicitly open them on my application:
The only dll that opens the picoscope is version 1.2.4.41. Below are the details of the picoscope device, as returned when I run the C console example application
as I was a little bit behind schedule I resorted to C which worked without any problem. Therefore I will use C and perform some data post-processing in a seperate python application, which may be a better approach for my application after all.
Anyway, as I found some time to experiment, I tried once again with python and the latest SDK (32bit). However the dll files (ps4000, picoipp) included therein are the same to the ones that come with the latest version of the picoscope application that I had already installed. So no luck with these as well.