A servo is not stopped at a certain degree it is driven to a certain angle by providing a specific duty cycle with the PWM control signal.
On a standard servo the PWM frequency is 50Hz.
An on-time of 1ms is full travel in one direction, 2ms is full travel in the other direction, 1.5ms is mid position. For most servos this is 0°, 90°, 180°.
According to the datasheet of your servo it has a travel of ±60°
Read this:
https://www.arduino.cc/reference/en/libraries/servo/
If your gear train breaks and the motor releases its magic smoke just because the lock is a little stuck you're certainly doing something wrong. At least limit the motor current.
Stall current for this motor is 2.5A at 6V.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…