hello. i am new to arduino and i want to control a servo with a toggle switch.
when the switch is in one state say LOW then the servo will be at 0*
and when the switch is HIGH then the servo will sweep over to 180* in one fluid motion.
and when the switch is flipped back it will return to 0*
any suggestions would be great. i have found some code about sweeping at each degree and also some about the position of a pot but i don't know how to take those examples and use them to do what i want.