I am very new to the whole Arduino thing...and very new may be an under statement. I purchased an Arduino Uno and an Arduino motor shield. I also picked up a used window regulator motor out of a car,(Runs on 12 volts.) After I got the motor to spin both ways I tried to add a photocell. The idea is I want the motor to spin one direction half hour after dark, and then the other direction half hour after sunrise. The problem is I can't for the life of me figure out how to do it. I've watched a number of tutorials, read some posts, tried some random ideas, and for whatever reason I can not do it. If someone could set me up with a code for this, and possibly an explanation on how/why it works it would save me from pulling the rest of my hair out. I've also seen people post their codes, but I figured I would save myself the embarrassment and not post what I have...or think I have.