added code to retract both pistons