5444D External vs Signal Channel Trigger Timing

Post your .Net discussions here
Post Reply
eric14
Newbie
Posts: 0
Joined: Wed Oct 24, 2018 2:35 am

5444D External vs Signal Channel Trigger Timing

Post by eric14 »

I am seeing some differences in trigger timing on the 5444D depending on whether I trigger from a signal channel or the external trigger port.

I am using PicoSDK_32_10.7.18.140 in VB.NET with Visual Studio 2019. Not quite the current version on anything, but this is all stable for me.

My basic approach is to use rapid block mode to acquire n scans at a rate r using the external trigger port. In the past I was running at r=2 kHz and everything seemed reasonable in terms of the time taken to acquire n scans. Recently I moved to r = 15 kHz and it was taking approximately twice as long to acquire the n scans as it should have. When I changed code to instead trigger off a signal channel, the timing was all as it should be.

To explore this, I hooked up a signal generator using a 10% duty cycle 0 to 0.5 V square wave to have a clean trigger signal. I then ran experiments from 1 kHz to 15 kHz trigger rate with the trigger signal running into the external trigger port. For all experiments, it should have taken about 1 second to acquire data. Repeated scans all produce similar results, I didn't attempt to get statistics on this general behavior. Below are the results:

EXT Trigger
rate (kHz), n (scans),Time for scans (ms)
1,1000,1101
2,2000,1168
3,3000,1252
4,4000,1335
5,5000,1420
6,6000,1452
7,7000,1532
8.8000,1744
9,9000,1702
10,10000,1776
11,11000,1976
12,12000,1905
13,13000,2086
14,14000,2351
15,15000,2450

Varying the number of scans makes no difference.
Trigger level makes no difference so long as within range
Duty cycle (varied 1% to 50 %) makes no difference

With all settings the same, using a signal channel instead of the external trigger port, 15K scans at 15 kHz takes 1095 ms, which is what I want to achieve. For what it is worth, I am only interested in going to 15 kHz.

Is there an explanation for this trigger behavior when using the external trigger port?

I don't see a reason to paste a lot of code in here at this point. Since triggering from a signal channel shows different behavior, I'm thinking this is a hardware thing that I just can't find documented. Below are the lines of code I use to set the trigger.

delay = 0
autoTriggerMs = 0

For external trigger use:
status = ps5000aSetSimpleTrigger(phandle, CShort(1), Channel.PS5000A_EXTERNAL, threshold, ThresholdDirection.PS5000A_RISING, delay, autoTriggerMs)

For signal channel trigger use:
status = ps5000aSetSimpleTrigger(phandle, CShort(1), Channel.PS5000A_CHANNEL_A, threshold, ThresholdDirection.PS5000A_RISING, delay, autoTriggerMs)

The reason I can't just solve this by switching to a signal channel for triggering is because I am rapidly taking a lot of data. I currently only use 1 signal channel for data and trigger using the external trigger port so that I can use the full scope memory. By taking a second signal channel for just triggering, I now cut in half the memory available for the channel I care about. In many cases this leads to needing a second data transfer for the same number n of scans. I'm often using the full scope memory for captures so this is a problem. If there was a way to only transfer the data from the channel I want (instead of both signal and trigger) then I could probably work with that but I don't see a way to do that.

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

Re: 5444D External vs Signal Channel Trigger Timing

Post by Martyn »

We would need to see how you have setup the Channels, and the RunBlock section of the code to see the number of samples buffer and the sampling rate.
Martyn
Technical Support Manager

Post Reply