here's a download link for the graph object (called show~). requires pdlua (installable through deken):
... and here's the patch from above so that you don't need to patch it again from the picture if you want to check it out: test-cooldown.pd
vanilla method working like "threshold~" but triggering in between blocks, help needed
here's a download link for the graph object (called show~). requires pdlua (installable through deken):
... and here's the patch from above so that you don't need to patch it again from the picture if you want to check it out: test-cooldown.pd
btw. this rpole~ counter for the cooldown period could possibly be simplified with just a delwrite~/delread~ ... and the whole implementation is rather crappy since it's breaking down when signals or cooldown varies too much. not sure yet how to make this more stable. hopefully might share better approaches.
@ben.wes I ended up writing a few externals for the "gen~" codes I wanted to translate.
Looking for a pd-vanilla way was quite instructive.
I guess some pdlua script would have worked ?
If so, I think a puredata vanilla "scripting" object would be a really nice feature...
@y0g1 said:
pdlua script would have worked ?
yep. that would be an easy option in this case with its signal rate capabilities. currently, there's still a huge PR waiting to be merged into the official pdlua repo which also adds luajit support, increasing signal rate performance quite a bit.
anyway ... i think i ended up successfully implementing this in vanilla now:

... [pd cooldown] looks like this:

... my previous version had the main issue that cooldown reset and first impulse could overlap. it's fixed now by just using 2 consecutive 0s for the reset (and avoiding consecutive impulses for the first trigger).
this might still be way too complicated. but it seems to actually measure the impulses for 4 channels now. 
here's the patch: test-cooldown-share.pd
if you'd want really exact localization, this should probably support subsample-measurements though. or at least a higher samplerate (since 1sp represents 7.15mm at 48kHz).
EDIT: the delay 100 for the snapshot is way too large here. 3ms is enough to cover the 100 samples range.
EDIT2: cleaned up the patch and comments. fixed some stuff and uses fewer objects now by reducing redundancy.
Oops! Looks like something went wrong!