EEVblog Electronics Community Forum

Electronics => Projects, Designs, and Technical Stuff => Topic started by: meretrix on December 04, 2018, 08:14:45 am

Title: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 04, 2018, 08:14:45 am
At work the other day, I was bashing my head against the limited triggering options available on our lab's scope, and I thought how nice it would be if a "pass-through box" type of thing existed that would collect data from your four analog channels and then allow you to create custom, possibly fairly complex triggers based on not just things like rising/falling edge, signal level, serial-decode, etc. but also from the results of math operations and channel measurements. For extra points, allow those results to be chained/combined to create very specific trigger conditions.

My question is, does this kind of thing already exist somewhere? And if not, is there some reason (like, "it's stupid and it won't work")? If it's stupid and it won't work, why not?  :P

And just cos I'm having an insomniac night and I couldn't think of anything better to do, I sketched out the basics of what I'm thinking. (I know, I left out the direct path from the analog inputs to the scope inputs, I'm a slow.) Comments/advice/questions/abuse welcomed! Thanks.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: ogden on December 04, 2018, 08:40:21 am
At work the other day, I was bashing my head against the limited triggering options available on our lab's scope

Which brand and model and options if any?

Quote
and I thought how nice it would be if a "pass-through box" type of thing existed that would collect data from your four analog channels

Your pass-through box shall have all the functions of the scope except display :) Better just get proper scope. Together with zone trigger software (https://www.rohde-schwarz.com/us/product/sw_rtx-k19-productstartpage_63493-504643.html?rusprivacypolicy=1) RTO2000 or better R&S scope would give what you want and more. [disclaimer] I mention R&S just because had been using such. I am sure other manufacturers also offer sophisticated triggering.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: DaJMasta on December 04, 2018, 08:45:12 am
I think the practical option is to just get a new scope... while it's certainly possible to make such a thing (though every new trigger is going to need some new holdoff delay), anything beyond analog triggers is just reinventing the wheel.  The hardware and systems you're describing are basically what's in a digital scope... so you want to make an external trigger box that is basically just a second scope channel for the express purpose of more complicated triggering?


If buying one wasn't an option, your time would probably be better served building a plugin or a hack for your current scope to get the software trigger features you want rather than also building a scope in addition to all the software...
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 04, 2018, 09:02:22 am
Quote
Which brand and model and options if any?

LeCroy Teledyne T3DSO1204 (I think I have that right). So far the triggering has been my only complaint. I had to MacGyver up this horrible monitoring circuit with two transformers and a MCU to observe the signals and to send the trigger pulse (to energize a relay coil and switch between power supplies) at just the right moment. That was when I thought there really must be a better way...

Quote
Your pass-through box shall have all the functions of the scope except display :) Better just get proper scope. Together with zone trigger software RTO2000 or better R&S scope would give what you want and more. [disclaimer] I mention R&S just because had been using such. I am sure other manufacturers also offer sophisticated triggering.

That's sort of what I was thinking -- that I'd basically be making a scope without a display. I dunno -- I might go ahead and do it anyway just because it's caught my interest, but yeah, I guess I would be re-inventing the wheel a bit. Cheers!

... so you want to make an external trigger box that is basically just a second scope channel for the express purpose of more complicated triggering?

Basically... yes.  ;)

Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: ogden on December 04, 2018, 09:14:30 am
I dunno -- I might go ahead and do it anyway just because it's caught my interest, but yeah, I guess I would be re-inventing the wheel a bit.

Just don't. Please listen to advice we are telling you and will not regret it. Spend your efforts/time building something really unique and useful, make sure it is not lab T&M equipment. I don't even want to spend internet ink explaining how outright wrong such scope add-on would be.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: vk6zgo on December 04, 2018, 09:51:21 am
Similar devices did exist in the analog TV days.
Vertical Interval  Test Signals (VITS ) were used to enable testing of various parameters without  the necessity of breaking programme transmission.
To this end, various such test signals appeared in the vertical blanking periods following the vertical syncs.

Ordinary 'scopes could display these signals, but they differed on successive "fields", so it was a bit fiddly.
Special instruments which introduced specific circuitry to do some of the VITS tests usually had either their own dedicated display, or were used to trigger an external 'scope so that it was easy to switch between the different VITS signals without having to reset the 'scope.

They were quite useful if you just wanted to quickly look at any given line, other than these, as they usually had a "variable"  line select as well.

I have also seen dedicated trigger boxes for looking at other special signals.

Your suggested device will get complicated fast, as you want it to be very versatile.
One thing I can think of, "up front" is  that it may not be fast enough to be really useful.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 04, 2018, 01:14:18 pm
I dunno -- I might go ahead and do it anyway just because it's caught my interest, but yeah, I guess I would be re-inventing the wheel a bit.

Just don't. Please listen to advice we are telling you and will not regret it. Spend your efforts/time building something really unique and useful, make sure it is not lab T&M equipment. I don't even want to spend internet ink explaining how outright wrong such scope add-on would be.

Well, it was the first idea I'd had in a while that sounded like it would be fun. Also, insomnia.

Similar devices did exist in the analog TV days.
Vertical Interval  Test Signals (VITS ) were used to enable testing of various parameters without  the necessity of breaking programme transmission.
To this end, various such test signals appeared in the vertical blanking periods following the vertical syncs.

Ordinary 'scopes could display these signals, but they differed on successive "fields", so it was a bit fiddly.
Special instruments which introduced specific circuitry to do some of the VITS tests usually had either their own dedicated display, or were used to trigger an external 'scope so that it was easy to switch between the different VITS signals without having to reset the 'scope.

They were quite useful if you just wanted to quickly look at any given line, other than these, as they usually had a "variable"  line select as well.

I have also seen dedicated trigger boxes for looking at other special signals.

Your suggested device will get complicated fast, as you want it to be very versatile.
One thing I can think of, "up front" is  that it may not be fast enough to be really useful.

I actually have a couple of 100Msps LVDS ADCs that I sampled a long time ago in a parts box; I was planning to start there  ;)
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: SiliconWizard on December 04, 2018, 05:59:30 pm
Your design idea sounds almost as complex as a complete scope without UI.

Granted if you can live with a much reduced sampling rate for your triggering needs (such as the 100Msps you just mentioned), it's definitely doable. Anything above that will be much too tricky and costly to design IMO.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: Berni on December 04, 2018, 07:41:39 pm
This seams like it would be a lot of work, probably easier to simply get a better scope.

That being said its rare that a simple edge trigger doesn't do what i need. If i can't trigger on a signal directly i will often be able to use another channel to trigger off something else in the circuit. That being said i do tend to use scopes with decent triggering functionality such as serial debug trigger. On top of it i also have a scope with zone triggering and that can cover some pretty complex cases. The same scope also has 1Gpts of memory so worst case the whole thing can be captures and manually reviewed. If i had a constant issue with it i could even write a script that finds a trigger point in the long capture.

Any examples where the scope simply could not trigger on what you need?

Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: Conrad Hoffman on December 04, 2018, 08:54:21 pm
I like the trigger options on my ancient boat anchor Tek scopes. The idea of a trigger processing box sounded pretty good but on further thought it might be a lot of work for the number of times it's really necessary. A good modern digital scope can do about anything, but some of the older ones, not so much. The problem is really good scopes are out of range for most, even the companies I work for. The things I have the most trouble triggering on aren't usually electrically generated signals, but signals from sensors on real physical objects that vibrate or move.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: donmr on December 04, 2018, 09:50:48 pm
As many have said, building a general purpose trigger box would be hard and you should just get a better scope.

BUT - I have often found it helpful to build custom logic into a circuit to aid in debugging and this could certainly include detecting events that one would like to trigger a scope from.   For example a register whose value is compared to an address bus could output a signal when that address is accessed.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: bd139 on December 04, 2018, 10:07:13 pm
Hewlett Packard 1620A trigger box  :-+

(I saw one of those being used with a digital scope in about 1995 still)
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 05, 2018, 03:08:57 am
Hewlett Packard 1620A trigger box  :-+

(I saw one of those being used with a digital scope in about 1995 still)

Oh neat! I'd never heard of this, but it looks awesome. ::Searches for manual PDF::
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 05, 2018, 03:26:30 am
As many have said, building a general purpose trigger box would be hard and you should just get a better scope.

BUT - I have often found it helpful to build custom logic into a circuit to aid in debugging and this could certainly include detecting events that one would like to trigger a scope from.

That's what I had to do for this thing at work, an experiment to see if the relay contacts in a piece of equipment would arc under worst-case conditions. I had two 277V AC sources, one a programmable supply and the other a variac running off wall current. The two supplies were out of phase with each other: the output of the variac "drifted" along with the wall current frequency (so there wasn't even a reliable phase relationship between the two). And the programmable supply, while its output frequency could be changed in 0.01Hz increments, had no means of simply synchronizing to the mains input frequency. I needed to switch between the two supplies (using a relay) when the two AC sources were 180° out of phase, and at the peak of their waveforms (so there was approximately 800V potential between them: I was trying to cause a failure).

So what I really wanted was this trigger:

TRIGGER = (PHASE(CH1, CH2)==180) & (CH1 >= 390V) & (CH2 <= -390V))

Which, it seemed to me, I should be able to generate using my oscilloscope's measure/math functions.

In the end, I built a little detector board out of two transformers, some diodes, voltage dividers and a quad op amp, and a little Microchip 8-bit MCU with ADC to generate the trigger. It worked perfectly, but... yeah, I guess I wished I had a really low-latency "general purpose" piece of equipment that I could just program to do this.

Oh, and even with all this effort, I still wasn't able to make the relay fail...  :-\
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: rhb on December 05, 2018, 03:45:11 am
I'm a little surprised a LeCroy wouldn't do what you wanted, but likely it's an option.

However, rather than try to capture this on a scope, it seems to me more appropriate to deliberately create worst case conditions, abuse a relay for a large number of cycles and then examine the contacts.

Also for this case a spectrum analyzer would tell you if it were arcing.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 05, 2018, 04:06:27 am
I'm a little surprised a LeCroy wouldn't do what you wanted, but likely it's an option.

However, rather than try to capture this on a scope, it seems to me more appropriate to deliberately create worst case conditions, abuse a relay for a large number of cycles and then examine the contacts.

Also for this case a spectrum analyzer would tell you if it were arcing.

Yeah, that was another part of the test. The 180° out of phase 277VAC supplies switching at peak was one part, and then it repeated itself every 30s or so for an hour. No arcing, not even damage to the fusible resistor. One theory out the window...
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: boB on December 05, 2018, 06:02:02 am
I have needed something like this on and off once in a while for many years.  Thought about making a trigger box too a few times.

Never did except for a couple times with very simple external combining of filtering or whatever. Can't even remember now.

Sometimes you're debugging a circuit and a condition comes up so rarely but you just need to catch it and usually multiple channels are needed for trigger.  At least in my work.  Usually it's just some combination of logic of pulse conditions that need to be triggered  from more than one channel.  My Rigol and Pico Scope have pretty advanced trigger functions but every once in a while I wish I had another way to trigger.

One of our older Rigol scopes with pulse trigger had/has a bug in one of the modes.  I think the newer scopes work though.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: David Hess on December 05, 2018, 01:55:58 pm
In the past I have used a word recognizer as part of a solution to do this.  Several analog signal conditioning circuits drive the word recognizer which is configured by the oscilloscope to trigger on a specific set of inputs.  A modern implementation would use the oscilloscope's logic analyser inputs in place of the external word recognizer.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: rhb on December 05, 2018, 02:48:23 pm
For use with a scope that lacks an LA, the pod set from one that does feeding a small FPGA would do quite nicely.  A cheap Zynq or Cyclone V dev board with USB and ethernet would be especially easy to setup with the desired trigger conditions.

The GW Instek GTL-16E pods are a set of adjustable reference levels and ADCMP581 comparators with input buffers to withstand +- 40 V and output line drivers.  I'm sure all of the decent ones are some variant of that.  The connector that plugs into the MSO-2000E is just a connector.  All the electronics are in the pods.

They seem over priced until you  lookup the parts on Digikey.  The 180 pS delay doesn't come cheap.

The Digilent Discovery line are just bare 3.3 V FPGA pins without any protection.  I think that a rather cruel prank to play on a novice.
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: meretrix on December 06, 2018, 02:31:22 am
My Rigol and Pico Scope have pretty advanced trigger functions but every once in a while I wish I had another way to trigger.

One of our older Rigol scopes with pulse trigger had/has a bug in one of the modes.  I think the newer scopes work though.

Heh, I tried to get the guy in charge of purchasing to get one of the higher-end Rigol scopes, but he was adamantly opposed to getting a scope from any company he didn't know about, so it had to be either Agilent, Tektronix or Lecroy. Joke's on him cos we could have gotten a much more powerful and flexible scope for the same amount of money... except, as it turns out, the joke is actually on me because I'm the one who ends up using the thing most often.  :-\
Title: Re: "Trigger box" for advanced/complex scope triggering?
Post by: Berni on December 06, 2018, 06:47:39 am
Yeah you do pay a premium for a brand name scope, but there are benifit a to it. Guess he goes by the moto "Nobody got fired for buying an IBM"

I did sort of use an FPGA to do serial decode for MIPI DSI video. I had a 16 bit bus out of the dev board run into the logic analyzer of the scope. The bottom 8 bits got displayed as raw bytes in hex while the top ones got used for trigger signals or to bring out debug signals in the FPGA. The scope didn't have MIPI decode nor was the 300MHz scope fast enough for a 800Mbit serial stream.