From 240d59004242a1075140edfda0aa061e62352f9c Mon Sep 17 00:00:00 2001 From: Ross Brigoli Date: Thu, 24 Nov 2022 00:24:25 +0800 Subject: [PATCH] Bug fix in picarx_control.py example The camera pan and tilt motor got interchanged. Corrected by assigning pas to Servo1 and tilt to Servo2. --- examples/picarx_control.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/picarx_control.py b/examples/picarx_control.py index c3276d5..1cc006e 100644 --- a/examples/picarx_control.py +++ b/examples/picarx_control.py @@ -159,8 +159,8 @@ def main(): # tilt = map(Joystick_Q_Val[1], -100, 100, -35, 75) pan = min(90,max(-90,Joystick_Q_Val[0])) tilt = min(75, max(-35, Joystick_Q_Val[1])) - px.set_camera_servo1_angle(tilt) - px.set_camera_servo2_angle(pan) + px.set_camera_servo1_angle(pan) + px.set_camera_servo2_angle(tilt) def servos_test():