variable delay/phase shift at end of phasor~ ramp


    Jun 19 2013 | 6:31 pm
    Hello, this might be a pretty easy question, but I have searched around for quite awhile and have not been able to figure out a solution. I am trying to find a way to either produce a delay or shift in phase of a phasor~ object exactly when it ends its cycle. I would like to be able to input a number for the amount of delay at anytime and then it would implement the delay after the phasor~ cycle has ended. I have looked at some externals (wait~) this won;t work because the phasor~ cannot wait for itself. I have imagine this would be possible in gen~ but I don't have much experience with it... Can anyone recommend a solution, or even point me in the right direction and I'll try to figure the rest out... Thanks.

    • Jun 20 2013 | 3:49 pm
      Perhaps using sah~ ??
    • Jun 20 2013 | 10:13 pm
      That's the problem though, the signal to the delay~ amount will occur at the original zero point, I need it to delay variably at the delayed signal's zero point.
    • Jun 20 2013 | 10:38 pm
      The other method I have tried, and it works, is triggering a ramp with shot~ external by a train object. So I delay the pulse from train~ before it gets to shot~. The problem with that though, is that shot~ produces an uninterruptible phasor ramp so when I increase the frequency it skips an impulse trigger now and then. Maybe I can't have my cake and eat it too.
    • Jun 21 2013 | 1:11 am
      If you just have a sah~ 0.5, it will trigger at the halfway point not at the end... and you need to initialize the delay~ object with a maximum delay time at least, i think... But either way(whether you change delay using the source or change delay using the delayed(which is probably not fully possible without the history object in gen~ to allow for feedback loop))... you'll create a discontinuity in the ramp at the point of change...
      Slightly improved but still... probably not what you want...(you could also roll your own phasor using the accum object in gen~... or using count~ in regular msp):
    • Jun 21 2013 | 9:46 pm
      Its going to be sent to a wave~ object so I need the ramp to be uninterrupted. I managed a way to do it with zigzag~ but now there is another problem, and it may because I don't fully understand how train~ works. I am delaying a pulse train from train~ with a bandwidth of 0, it is at zero so when I change the delay amount the pulse does occur at the same time, or rather there is less of a chance for the delay to occur exactly where the pulse is. But now that train has a bandwidth of 0, it can only go as fast as 22.6ish milliseconds and then it just shuts off completely, maybe I am missing something but it seems like it should be relatively simple to produce a 1 sample width pulse at any frequency up to the sampling rate... not sure.