No Data and ps5000aIsReady taking to much time

Post general discussions on using our drivers to write your own software here
Post Reply
francisco.dutra
Newbie
Posts: 0
Joined: Fri Mar 10, 2023 1:06 pm

No Data and ps5000aIsReady taking to much time

Post by francisco.dutra »

Hello,

I am using a 5242D MSO and I am trying to do this to test my application:

1) Generate a square wave with the ps5000aSetSigGenBuiltInV2 with 1V peak-to-peak ranging from 0-1V

Code: Select all

		ssssssssssssssssssssssssssssssssswavetype = ctypes.c_int32(1)
            sweepType = ctypes.c_int32(0)
            triggertype = ctypes.c_int32(0)
            triggerSource = ctypes.c_int32(0)
            offset = int(1000000*0.5)
            self._status["setSigGenBuiltInV2"] = ps.ps5000aSetSigGenBuiltInV2(self._chandle, offset, 1000000, wavetype, 1, 1, 0, 1, sweepType, 0, 0, 0, triggertype, triggerSource, 0)
            assert_pico_ok(self._status["setSigGenBuiltInV2"])
2) I plug it to channel A

3) I set a simple trigger with a threshold of 500 mV

Code: Select all

		threshold = int(mV2adc(500,chARange, maxADC))
            # direction = PS5000A_RISING = 2
            # delay = 0 s
            # auto Trigger = 1000 ms
            self._status["trigger"] = ps.ps5000aSetSimpleTrigger(self._chandle, 1, source, threshold, 2, 0, 1000)
            assert_pico_ok(self._status["trigger"])
The final goal is to record 5 seconds of data.
The result that I am getting from function ps5000aGetValues is 0 and I do not understand why, because when I start the picoscope I should get data immediately and instead I am waiting for a lot of time and no data was saved in the memory of picoscope.

This is a simple application but I am not getting there.

NeilH
PICO STAFF
PICO STAFF
Posts: 265
Joined: Tue Jul 18, 2017 8:28 am

Re: No Data and ps5000aIsReady taking to much time

Post by NeilH »

Hi

Are you able to post your code file or email it into support@picotech.com as a runnable file so I can have a look at the setup and at what's going on?

Neil
Neil
Technical Support Engineer

francisco.dutra
Newbie
Posts: 0
Joined: Fri Mar 10, 2023 1:06 pm

Re: No Data and ps5000aIsReady taking to much time

Post by francisco.dutra »

Everything is working it was a misunderstanding in the code

Post Reply