protect servo from stall current

So do you guys have any idea to do that?

Yes. I'm surprised that you would not.

One of many possibilities:

if (servo_command > lower_limit && servo_command < upper_limit) servo.write(servo_command);