Linear Actuator Position Control Reed Sensor

This actuator in this example however uses a potentiometer for positional feedback rather than a reed switch and push buttons rather than the serial monitor.
Here is my full code:

Does your code address this difference ?