From a8ed177d4845d57bc7e49bc55b9afe076bad47e4 Mon Sep 17 00:00:00 2001
From: Albin Heimerson <albin.heimerson@control.lth.se>
Date: Tue, 19 Apr 2022 11:52:12 +0000
Subject: [PATCH] Update code/track_path.py

---
 code/track_path.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/code/track_path.py b/code/track_path.py
index 3524404..eb058e5 100644
--- a/code/track_path.py
+++ b/code/track_path.py
@@ -168,12 +168,12 @@ class CrazyLogger:
     def x(self):
 		""" Return x-position of robot center"""
 		# Note that the offset of the crazyflie mount position is included
-        return self._state[0] - np.sin(self._state[3])*self._position_offset 
+        return self._state[0] - np.sin(np.deg2rad(self._state[3]))*self._position_offset 
     
     def y(self):
 		""" Return y-position of robot center"""
 		# Note that the offset of the crazyflie mount position is included
-        return self._state[1] + np.cos(self._state[3])*self._position_offset 
+        return self._state[1] + np.cos(np.deg2rad(self._state[3]))*self._position_offset 
     
     def z(self):
 		""" Return z-position of robot center"""
-- 
GitLab