Arduino error in light sensor circuit

Thos:
The arduino gives an error and resets after the actuator moved for a couple of seconds.

Since errors come from code and not the Arduino, what is your code?