This paper presents an efficient implementation of a Kalman filter for tracking objects in underwater robot applications using sonar images. It describes the challenges faced by autonomous underwater vehicles (AUVs) in navigation and object detection, emphasizing the importance of real-time tracking for collision avoidance. The proposed method demonstrates high accuracy and robustness, enabling effective target tracking and trajectory estimation in constrained underwater environments.