Driver-> Python Expression: Clock Escapement rotation problem


I haven’t post much in here, as I am more of a reader than a writer. I have been Blending (Blendering?) for quite some time (earlest version i could remember is 2.4), learning each section at a time (from familiarizing Blender UI to Modeling to Materials to animations etc etc etc). I could give you full details but that’s for another post in another thread.

Anyway, on to the matter:

Goal: To rotate ‘Timing’ wheel whenever the ‘Escapement’ peg allows it to do so.

Problem: After 4 days of reading, fiddling, thinking outside the box, maths and so forth, clearly I still haven’t got it right. However, I managed to get it almost ‘right’

The picture below may explain better than I could say it in words.

Any thoughts and suggestions is appreciated…