External Trigger Problem

Post your LabVIEW discussions here
Post Reply
jmadsenee
Newbie
Posts: 0
Joined: Fri Jun 03, 2016 2:59 pm

External Trigger Problem

Post by jmadsenee »

Hi,

I have written a LabView VI to work with my 4000 series PicoScope. It works fine as long as I set my Trigger Source to Channel A or Channel B. I found in the "pico4262 trigger" post that the channel number for the external trigger is 4, so I added that to the Trigger Source control. Unfortunately, I keep getting an "Error 5016 occurred at ps4000SetSimpleTrigger," which seems to indicate an invalid channel, when I try to use the external trigger input.

I went into the PS4000 Settings VI and tried to enable the External trigger channel, similarly to the way the other channels were enabled, using 4 for the channel number, but got the same error number at ps4000SetChannel.

What am I doing wrong?

Thanks!

John

Hitesh

Re: External Trigger Problem

Post by Hitesh »

Hi John,

It is possible to set one of two external input voltage ranges for the PicoScope 4262.

Please try calling the ps4000SetExtTriggerRange() function before setting the trigger (refer to the Programmer's Guide for the definition).

You may also wish to refer to this post for information on how to add a Call Function Library Node.

Regards,

jmadsenee
Newbie
Posts: 0
Joined: Fri Jun 03, 2016 2:59 pm

Re: External Trigger Problem

Post by jmadsenee »

Hi Hitesh,

I set up ps4000SetExtTriggerRange per the manual.
Function.PNG
I put it before SetSimpleTrigger.
VI.PNG
I get Error.
Error.PNG
I don't understand why the error says FE Raw Data Record...

I did Highlight Execution and confirmed that the error occurred coming out of my new node.

Any thoughts?

Thanks!
John

Hitesh

Re: External Trigger Problem

Post by Hitesh »

Hi John,

Please change the Calling convention to 'stdcall (WINAPI)' as per the screenshot in the post that I linked to.

Setting it to 'C' tends to cause an error as I've found before.

Regards,

jmadsenee
Newbie
Posts: 0
Joined: Fri Jun 03, 2016 2:59 pm

Re: External Trigger Problem

Post by jmadsenee »

Hi Hitesh,

Sorry, that was a stupid mistake! Anyway, it now gets past that VI, but I have the original problem. The block diagram is still as shown above, but I am getting Error 5016 when I select EXT (4):
Error5016.PNG
John

jmadsenee
Newbie
Posts: 0
Joined: Fri Jun 03, 2016 2:59 pm

Re: External Trigger Problem

Post by jmadsenee »

Hi Hitesh,

My apologies once again; I found the problem. While I added EXT (= 4) to the "Trigger Source" enum in my main VI, I did not add it to the "Trigger Source" enum in the Settings VI. Since the "Allow undefined values at run time" checkbox was not checked, the Settings VI changed EXT to Channel D, which was not supported, and therefore gave the error. :oops:

Thanks for your time!

Best Regards,

John

Hitesh

Re: External Trigger Problem

Post by Hitesh »

Hi John,

Thank you for the update.

It's probably best to update the Settings vi and then add a new control having deleted the old one from the main vi as this will ensure that the settings are mapped across.

I will ask for our examples to be updated here.

Regards,

Post Reply