Converting an arbitrary pulse to logic level
Detecting "something changing" is really easy and, generating a pulse is also easy (based on that detection) but, the hard thing (that is undefined in your question) is the criteria for resetting the pulse: -



As per the graph I kidnapped and defaced, what is it about the signal (red) that prevents the detection pulse (green) resetting at the three points shown by the blue arrows in the picture?

How can you be so certain that as soon as the red trace dies down you can reset the pulse (as you have in your example)?

Why don't you just get into excel and do some fuzzy analogue / digital logical things on a set of samples and see how it shapes up. Excel is really great for stuff like this.