Adaptive digital PID auto-tuning for robotic application