I havent really had time to look at the code, but from running the example it looks like it works! Probably needs some fine tuning because it seemed like it skipped a few beats when comparing it to the other BPM example.

Yeah, it does. But that’s why it’s here. I was hoping some people would
help try to make it better and re-post the source code. If we combine all
of our knowledge and techniques, we could make a nice one!