My robot model is shifting while hector is mapping.
I've searched the forum and tutorials about this but couldn't find an answer. I would be very happy if anyone can help. Before moving on to my question, I would like to talk about the arguments I have. - I drive 2 dc motors with my roboteq driver and they have an encoder. So I have a published odometry data. - I'm using an a2 model lidar. so I have the laser data published - my robot's model is available in a xacro file and I can see it on the map.
My question is:
I want to extract a map using odometry and lidar (using hector_slam). The map looks fine, but I get an image like the picture below. My robot model appears at the other end of the map, I couldn't solve this problem. I think I did the tf conversions wrong but I didn't know how to fix it. Is there anyone who can help me.
here is a view of my tf tree too
I can also share my initialization and settings files if needed.