Triggering the scope~

    Feb 14 2006 | 2:03 am
    A while back I asked whether anyone has a version of scope~ that accepts
    an external trigger. This is a basic feature of real-world scopes and
    really necessary if you want to see what's happening simultaneously in
    different signals. (I'm building demos for an undergrad acoustics
    course, so accurate visualization is important). The response was
    basically negative, so I assume there is no such object.
    I've tried to work around the problem by extracting triggers manually
    and adding them as large transients to each signal. It's easy enough to
    extract triggers, generate impulses, and add them to the signals. The
    problem is that they can be seen in the waveform. So I'd like to extract
    a trigger and then inhibit the extraction of succeeding triggers for
    some "holdoff" period. I am having a lot of difficulty with this bit. In
    principle, I should be able to generate any signal of the requisite
    holdoff duration, trigger it by the first impulse, and use that to mask
    out (by comparison or multiplication) the nuisance triggers. However, as
    far as I can tell, the only objects that would let me make a one-shot
    holdoff signal are line~, adsr~, etc. and all of these are triggered at
    the event level (i.e. by bangs) rather than the signal level. That means
    that while we wait for the bang to be processed, 2-3 extra trigger
    pulses get through to the waveform.
    I would really appreciate any help that anyone can give me, either with
    collecting the first of a series of triggers or with otherwise
    synchronizing a number of scope~ objects. For the record, I need this to
    run under the MSP Runtime (students use it), so I've been avoiding
    jitter, etc.
    G. Christopher Stecker, Ph.D.
    Assistant Professor - Speech & Hearing Sciences
    Univ. of Washington - 1417 N.E. 42nd St - Seattle WA 98105
    Voice: 206-543-7561

    • Feb 14 2006 | 3:35 am
      After banging my head against this for longer than I'd like to admit, I
      think I've come up with an acceptable workaround.
      I extract triggers from the positive zero crossings (or other suitable
      event) and then use spike~ to compute intervals between triggers. I set
      spike~'s refractory time (right inlet) to just longer than the duration
      my scope~ is set to display; this gives me intervals suitable for
      triggering the display cleanly. From these intervals I compute the
      frequency of a separate triggering waveform, which I synthesize with
      cycle~ or phasor~. Extracting triggers from this waveform (as before)
      and adding them as large-amplitude impulses to the original waveform
      does the trick. The triggering phase of the scope~d waveform is not
      fixed, but that's ok for my purposes. I was more concerned that the
      phase of the triggering waveform would drift relative to the visualized
      signals. It does, but not too much. It actually looks quite steady.
      I'm still interested in hearing of any other solutions, but this is a
      pretty usable solution.
      G. Christopher Stecker, Ph.D.
      Assistant Professor - Speech & Hearing Sciences
      Univ. of Washington - 1417 N.E. 42nd St - Seattle WA 98105
      Voice: 206-543-7561
    • Feb 14 2006 | 3:18 pm
      a different route would be to use the Ircam Gabor and FTM libs:
      Maybe this could help you get going:
      You should be able to do something similar with the new audio to
      jitter objects that are part of Jitter 1.5.
    • Feb 14 2006 | 8:27 pm
      Hi Chris - unless there's some kind of licensing restriction that I am
      forgetting, there's no reason that you can use Jitter with Max/MSP
      runtime. The jit.catch~ object will do exactly what you want.