The room employing this particular device is un-ish-viewable during the day light tho highly visible at night with interior lights, alight. Due to these parameters, the curtains automatically (photoresistor) open-close relative. Amended is a wifi (lower-case) channel to permit a voice activated command (url submit) to open-close the curtains, shd the moment arise, mmm-hmm.
1. Timing is every thing .. preferring servos as opposed to steppers, this code requires a precise timing-per-rotation for the width of the curtain draw.
2. Patience .. just bcz it runs at 16mhz doesn't mean you shd. Averaging sensor reads .. delays .. give 'er a rest other wise the curtains will be flappin' back and forth like a chicken raised by geese tryin' to head south.