Clock escapement animation with Assembly4 and Python

Show off your FreeCAD projects here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
jackfreecad
Posts: 53
Joined: Sun Oct 25, 2020 4:56 pm

Clock escapement animation with Assembly4 and Python

Post by jackfreecad »

Hi Guys

I made this escapement animation in the Assembly 4 Workbench, using the parts of my 3D printed clock and some Python code to drive the animation. Check out this short clip to see it in action
phpBB [video]

I started with a master sketch to drive the anchor with a rotating rod

sketch master
sketch master
sketchMaster.png (86.01 KiB) Viewed 2760 times

Then added the anchor and the escape wheel
sketchAndParts
sketchAndParts
all.png (184.32 KiB) Viewed 2760 times
Then figured out some Python code to get it moving...

Find all FC files and Macro at this link:
https://github.com/jacprog/clockAnimation
It is certainly not perfect, but managed to get it to work for a while locally about a minute or two
After a while it tends to slow down and start to get unresponsive.
Here are my infos, curious to see if others can make it work, or have suggestion for improvement.
FreeCAD is awesome!
Jacques

The 3D printed clock that use this escapement: https://forum.freecadweb.org/viewtopic. ... &t=55567OS:

macOS Mojave (10.14)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24212 (Git)
Build type: Release
Branch: master
Hash: 3d227cf7179c00e57f2733f947b4b1b0368d219a
Python version: 3.8.8
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: C/Default (C)
Post Reply