Change the number of servos from 0 to 1 and that will turn on the servo code. Then take a look at the bool set_probe_deployed(bool deploy) function in Marlin_main.cpp
That deploys and stows the probe which is very often done with a servo.
In that function block you will see the line of code:
If you have your servo on the connector for servo #0, you could say servo[0].move(45); To get the servo to position at 45 degrees.
That deploys and stows the probe which is very often done with a servo.
In that function block you will see the line of code:
servo[Z_ENDSTOP_SERVO_NR].move(z_servo_angle[deploy ? 0 : 1]);
If you have your servo on the connector for servo #0, you could say servo[0].move(45); To get the servo to position at 45 degrees.