f1tenth simulation car navigation

1. Adjust the matrix map according to the rviz map

Convert matrix coordinates to rviz coordinates

x=float(input())
y=float(input())
pixwidth = 52.331  # 10.197194  # 10.2
pixheight = 51.007  # 4.625010  # 4.6
resolution=0.05
x1=pixwidth-x*resolution
y1=y*resolution-pixheight

print(x1,y1)

Starting point (3.757, -0.148)
End point (10.019, 7.164)
insert image description here
Starting point (10.019, 7.164)
End point (-10.555, 8.738)
!](https://img-blog.csdnimg.cn/69228279d17a4fbba0b6c7d7c05165e9.png)

Start (-10.744, 9.085)
End (-13.496, 9.057)
insert image description here

starting point (-13.496

Guess you like

Origin blog.csdn.net/weixin_72050316/article/details/132119320