i put up a little demo in this repo. this is one way to do it.
(weird known issue: slowing down the tempo /speeding up the rate can reveal weird stuff in buffer as it allows the “tape head” to continue farther along the “tape”)