How to set triggering threshold for EXT

Post your .Net discussions here
Post Reply
Stevo
Newbie
Posts: 0
Joined: Mon Mar 26, 2012 6:12 pm

How to set triggering threshold for EXT

Post by Stevo » Fri Jul 20, 2012 3:42 pm

Hi there,

I am using the picoscope 4226 with channel A ,B and EXT inputs. When combined with the picoscope 6 software, I notice that the trigger threshold is limited to the voltage range of whichever channel is selected for the trigger. However, when the EXT channel is selected as the trigger, the limit used is the maximum voltage range (20V).

My question concerns the programming aspect of this behaviour. In the ps4000SetSimpleTrigger function, the threshold is taken in ADC counts. The ADC counts can be determined by the function mv_to_ADC (just the reverse of the ADC_to_mv function provided in the examples). Now, this function which is as follows:

ADC_count = (mVVal * PS4000_MAX_VALUE) / inputRanges(range)

requires the range to be known. In the case of ChA and ChB, these are known. For EXT however, you cannot set the voltage range using ps4000SetChannel.

Thus, my question is how do I convert my user specified voltage to ADC counts when the user selects the EXT channel?

Thanks once again.

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

Re: How to set triggering threshold for EXT

Post by Martyn » Mon Jul 23, 2012 9:39 am

You need to use the 20V range so inputRanges(range) becomes 20000 as you are using mV values
Martyn
Technical Support Manager

Post Reply