Picoscope 3000 triggering

Post your LabVIEW discussions here
Post Reply
BDS
User
User
Posts: 4
Joined: Fri Oct 26, 2007 4:13 pm

Picoscope 3000 triggering

Post by BDS »

I have searched the forum and haven't seen this question asked so I must be doing something wrong?
I am trying to set an internal trigger but I can only trigger on a positive voltage.
I understand that the value needing to be passed is a 16 bit integer that is scaled by the selected range. It appears that the "threshold" value only references the positive half of the range.
example: range=10v | threshold=32768 => trigger=+5v
Passing a negative value int threshold produces the same value as passing a zero which equals zero volts.
Am I doing something wrong or is this the limitation of the picoscope box?

ziko
Advanced User
Advanced User
Posts: 1705
Joined: Fri Dec 01, 2006 10:03 am
Location: St Neots

Post by ziko »

Hi and thank you for your post.

To do the calculation you would need the following formula:

input signal (positive or negative)/input range * 32,767

e.g. -3 V signal in a +/-5 Volt range would be:

-3000/5000 * 32,767 = -19660.2 therefore the count is -19660

Hope this helps.

Kind regards
Ziko

Technical Specialist

BDS
User
User
Posts: 4
Joined: Fri Oct 26, 2007 4:13 pm

Post by BDS »

Ok, that answers the one question of what +/- integer values address what range.
There seems to be something wrong however because no matter what integer value I pass, I cannot get it to trigger on a (-) voltage.
I ran the picoscope6 software and it allows a neg. trigger so it's not the scope box.
I verified that the input to "threshold" is set to 16bit signed integer (pass value) and that the data type wired is 16bit signed.

I have uploaded a slightly modifed copy of the ps3000_runBlock.vi
This should show exactly how I am running the scope.

BDS
Attachments
ps3000_runBlock.vi
VI showing code where negitive trigger does not work.
Labview version 8.0
(43.31 KiB) Downloaded 737 times

ziko
Advanced User
Advanced User
Posts: 1705
Joined: Fri Dec 01, 2006 10:03 am
Location: St Neots

Post by ziko »

Hi after discussing with the software engineers the application seems fine. They did point out the following though:

"The trigger function auto_trigger_ms should be a signed 16 bit value, not a bool. You should set this to zero if you do not want the device to auto trigger.

The second point is that when the device is opened by default the channels are set to active therefore the minimum timebase that can be used on the 4 channel device is time base 2. To use timebase 1 two of the channels need to be switched off before calling run block, and three channels need to be switched off before calling run block with timebase 0. If they are not switched off then run block will fail."

Hope this helps.

Kind regards
Ziko

Technical Specialist

BDS
User
User
Posts: 4
Joined: Fri Oct 26, 2007 4:13 pm

Post by BDS »

I found the problem.
I had two versions of ps3000.dll (3.5.0.0 and 3.5.8.0) and was using the older version. I switched to the newer version and the trigger behaves as expected.

ziko
Advanced User
Advanced User
Posts: 1705
Joined: Fri Dec 01, 2006 10:03 am
Location: St Neots

Post by ziko »

Well I am glad it works now.

Kind regards
Ziko

Technical Specialist

Post Reply