recording short triggers into a data object using gen does not seem to work

twhiston's icon

I'm trying to record some triggers into a data buffer using gen, but it appears that this does not work. I guess it's because the triggers are so short. I've included a trivial example to demonstrate this and it appears you need the pulse width to be at least 0.2 for recording to work accurately. Is there something that I need to do differently in my gen code to make this work for shorter pulses?

Please note that increasing the pulse width is not really a suitable fix, as unlike the trivial example attached my triggers are actually generated in another gen patch which is doing [delta]->[abs]->[> threshold] on another signal to generate the output, so there's no easy way to extend the duration (unless someone can suggest something!)

Max Patch
Copy patch and select New From Clipboard in Max.