You could write a function called home(), where the motor is turned until a sensor of your choosing is triggered. You can call it from setup or from the loop.
You could write a function called home(), where the motor is turned until a sensor of your choosing is triggered. You can call it from setup or from the loop.