]> rtime.felk.cvut.cz Git - eurobot/public.git/blobdiff - src/robofsm/fsmmove.cc
robofsm: Added estimated position based on odometry
[eurobot/public.git] / src / robofsm / fsmmove.cc
index 1a439d2bd90886385b94ebd66b72d7dfec3885af..bdf4f1d1767fec73e707cb492468499efc0b667c 100644 (file)
@@ -173,11 +173,11 @@ static enum target_status new_trajectory(Trajectory *t)
                printf("ERROR: No trajectory\n");
                return TARGET_ERROR;
        }
-       ROBOT_LOCK(est_pos);
-       pos.x = robot.est_pos.x;
-       pos.y = robot.est_pos.y;
-       pos.phi = robot.est_pos.phi;
-       ROBOT_UNLOCK(est_pos);
+       ROBOT_LOCK(est_pos_uzv);
+       pos.x = robot.est_pos_uzv.x;
+       pos.y = robot.est_pos_uzv.y;
+       pos.phi = robot.est_pos_uzv.phi;
+       ROBOT_UNLOCK(est_pos_uzv);
 
        if (t->prepare(pos)) {
                go(t, 0);