I'm still experimenting with stepper motors on this prototype, and I'm quite pleased with the facet alignment of the Darth Vader styled helmet, quite impressive for 3D printing.
To make animating the model easier (for me at least), I wrote a very simplistic programming language. This language includes instructions such as Step, Loop, Goto, Pause, Stop and others that allow me to create the various animations. Here's a runtime sample of a short series of instructions copied from the Arduino environment serial monitor window:
18:40:11.202 -> Step, 0, -820, 0
18:40:12.044 -> Step, 1, 820, 0
18:40:12.856 -> Loop, 2, 2, 2
18:40:12.856 -> Step, 0, -820, 0
18:40:13.680 -> Step, 1, 820, 0
18:40:14.507 -> Step, 3, 0, 820
18:40:15.314 ->Step, 4, 0, -820
18:40:16.149 ->Loop, 5, 2, 2
18:40:16.149 ->Step, 3, 0, 820
18:40:16.956 -> Step, 4, 0, -820
18:40:17.790 -> Step, 6, -410, -410
18:40:18.174 -> Step, 7, 820, 820
18:40:19.017 -> Step, 8, -410, -410
The software for this model was written in the Arduino environment for an Adafruit ESP32 Feather Huzzah board. The ESP32 drives very inexpensive ULN2003 based driver boards which drive very inexpensive stepper motors in micro stepping mode for a 360 degree rotation in 4096 steps. I designed all of the software for this model, including the stepper driver software, thus no external dependancies (libraries) are required.
The software utilizes a 1000 Hz (.001 second) interrupt routine that performs the startup and synchronization of the stepper motors, then executes runtime stepping commands generated by my simplistic programming language from within the Arduino "loop" function. Each slice contains pins and slots allowing a 4 degree rotation prior to movement of adjacent slices, thus allowing a maximum of 72 degrees of rotational separation between the top and bottom slice positions.
One final note, I am truly delighted in the accuracy of the Engineering Profile in Ultimaker Cura 4.8.0 and of course the Ultimaker 3D printers this model was printed on. Considering the alignment of the eighteen slices during animation required no post processing of the individual slices, I am amazed.