Skip to content

Commit

Permalink
removed duplicate publish_rtk_err.py
Browse files Browse the repository at this point in the history
fixed typo in publish_rtk_err.py variable naming
  • Loading branch information
Jackack committed Mar 5, 2024
1 parent 12fd1cb commit 5acac83
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rb_ws/src/buggy/scripts/auton/publish_rtk_err.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ def update_gnss2(self, msg):

if not (self.odom_msg is None) and not (self.gnss2_msg is None):
odom_pose = World.gps_to_world_pose(Pose.rospose_to_pose(self.odom_msg.pose.pose))
gnss1_pose = World.gps_to_world_pose(Pose.rospose_to_pose(self.gnss2_msg.pose))
gnss2_pose = World.gps_to_world_pose(Pose.rospose_to_pose(self.gnss2_msg.pose))

distance = (odom_pose.x - gnss1_pose.x) ** 2 + (odom_pose.y - gnss1_pose.y) ** 2
distance = (odom_pose.x - gnss2_pose.x) ** 2 + (odom_pose.y - gnss2_pose.y) ** 2
distance = np.sqrt(distance)

self.distance_publisher.publish(Float64(distance))
Expand Down

0 comments on commit 5acac83

Please sign in to comment.