diff --git a/steer-pid.py b/steer-pid.py index 279c2b2..5811f48 100644 --- a/steer-pid.py +++ b/steer-pid.py @@ -77,9 +77,6 @@ for chunk in stream.iter_content(chunk_size=1024): cv2.circle(frame, center, radius, (255, 0, 0), 2) cv2.circle(frame, center, 5, (0, 0, 255), -1) - # (Opcjonalnie) Wypisz pozycję - cv2.putText(frame, f"X:{int(x)} Y:{int(y)} R:{int(radius)}", (10, 30), - cv2.FONT_HERSHEY_SIMPLEX, 0.6, (0, 255, 0), 2) if int(radius) >= 100: motorL.stop() @@ -114,6 +111,10 @@ for chunk in stream.iter_content(chunk_size=1024): xp = x ip += i + # (Opcjonalnie) Wypisz pozycję + cv2.putText(frame, f"P:{int(p)} I:{int(i)} D:{int(d)}", (10, 30), + cv2.FONT_HERSHEY_SIMPLEX, 0.6, (0, 255, 0), 2) + # ============================ # 👆 KONIEC DETEKCJI PIŁKI 👆 # ============================