ps6000SetTriggerChannelProperties() returned error

Forum for discussing PicoScope version 6 (non-automotive version)
Post Reply
sudhansangeetha
Newbie
Posts: 0
Joined: Thu Jan 26, 2012 6:53 pm

ps6000SetTriggerChannelProperties() returned error

Post by sudhansangeetha » Fri Feb 10, 2012 8:12 pm

Hi,

I am trying to setup picoscope 6000 for external trigger and input channel as A.

The following call is made:

ps6000SetTriggerChannelProperties(handle, &channelproperties,1,0,0);

where channelproperties = {1625/*threshold-high*/,
325/*hysteresis-high*/,
1625/*threshold-high*/,
325/*hysteresis-low*/,
PS5000_MAX_CHANNELS/*channel used*/,
LEVEL/*threshold mode*/
}

The same settings is working for CHANNEL A,B,C,D but not for external channel.

The error code being returned is PICO_TRIGGER_ERROR for which there is no information found in documentation. Kindly help.

Hitesh
Site Admin
Site Admin
Posts: 2793
Joined: Tue May 31, 2011 3:43 pm
Location: St. Neots, Cambridgeshire

Re: ps6000SetTriggerChannelProperties() returned error

Post by Hitesh » Mon Feb 13, 2012 3:13 pm

Hi,

Please could you send in a snippet of your code showing the channel setup and all trigger parameter settings (channel conditions, properties and directions).

Thanks,
Hitesh

Technical Support Engineer

sudhansangeetha
Newbie
Posts: 0
Joined: Thu Jan 26, 2012 6:53 pm

Re: ps6000SetTriggerChannelProperties() returned error

Post by sudhansangeetha » Mon Feb 13, 2012 7:40 pm

When I studied the documentation, it looks like, External trigger (Ext channel) is not there in 6000 series model but there is AUX slot.

Please confirm. if the above statement is Yes, What is the settings for using AUX channel?

I am using the below code:

Code: Select all

 TRIGGER_CONDITIONS conditions = {CONDITION_DONT_CARE ,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_TRUE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE };

 stStatus = ps6000SetTriggerChannelConditions(handlePico,&conditions,1);

trigCha = RISING;

 stStatus = ps6000SetTriggerChannelDirections(handlePico,NONE,NONE,NONE,trigCha,NONE,NONE);

ps6000SetTriggerChannelProperties(handle, &channelproperties,1,0,0);

where channelproperties = {1625/*threshold-high*/,
325/*hysteresis-high*/,
1625/*threshold-high*/,
325/*hysteresis-low*/,
PS5000_MAX_CHANNELS/*channel used*/,
LEVEL/*threshold mode*/
}

Hitesh
Site Admin
Site Admin
Posts: 2793
Joined: Tue May 31, 2011 3:43 pm
Location: St. Neots, Cambridgeshire

Re: ps6000SetTriggerChannelProperties() returned error

Post by Hitesh » Tue Feb 14, 2012 11:44 am

Hi,

The External channel is not used by the PicoScope 6000 series SDK (there is no ext channel on the device). It is the Aux In channel that is used.

Set your Trigger Conditions structure as below:

Code: Select all

TRIGGER_CONDITIONS conditions = {CONDITION_DONT_CARE ,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_DONT_CARE,
                                                             CONDITION_TRUE,
                                                             CONDITION_DONT_CARE };
It looks as though your trigger channel is set for Channel D - if this is correct, please leave it otherwise change it to:

Code: Select all

stStatus = ps6000SetTriggerChannelDirections(handlePico,NONE,NONE,NONE,NONE,NONE,trigCha);
Also, please change your channel and the threshold mode as shown below:

Code: Select all

channelproperties = {1625 /*threshold-high*/,
325 /*hysteresis-high*/,
1625 /*threshold-high*/,
325 /*hysteresis-low*/,
PS6000_TRIGGER_AUX /*channel used*/,
PS6000_LEVEL /*threshold mode*/
Hope this helps,
Hitesh

Technical Support Engineer

sudhansangeetha
Newbie
Posts: 0
Joined: Thu Jan 26, 2012 6:53 pm

Re: ps6000SetTriggerChannelProperties() returned error

Post by sudhansangeetha » Tue Feb 14, 2012 5:20 pm

Hi,

Thank you for the details. I tried the same settings and it still results in the error - 44UL (0x0000002C).

I am not calling ps6000SetChannel for AUX IN Channel. Is that a problem?

Please confirm the situations in which the error 44UL (0x0000002C) can occur.

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

Re: ps6000SetTriggerChannelProperties() returned error

Post by Martyn » Wed Feb 15, 2012 8:30 am

Having read your email ticket to our helpdesk and the response from my colleague explaining the difference between using AUXIN as a trigger source compared with EXT in the 5000 series devices, can I confirm that you are now successfully getting triggers ?
Martyn
Technical Support Manager

Post Reply