I think the problem lies in your rotated laser scanner. You have turned the frame of the scanner 90 degrees clockwise around the z-axis and changed the min_ and max_angle of your laserscan message so that the center is still pointing forward.
I am just trying if i am able to fix gmapping to work under that conditions, but i am not sure, if i will succeed.
Is there any reason for that rotated laserframe? I would suggest changing your laserscan driver (btw: which model and driver do you use?) to have the x-axis pointing forward and having the range readings symmetrical to the left and right of the zero yaw-angle.
Edit: I found the real problem: Your scanner reports a field of view of 270 degrees and an angle increment of 0.5 degrees (like you mentioned). So you would expect about 540 rays per scan. But in reality there are 1081 readings in each message! So gmapping tries matching a 540 degrees field of view...
There must be something wrong with your laser driver. The first 540 readings are correct, but there are another 540 zero-readings in each laserscan message.
Try the troubleshooting under section 2.2 here : http://ros.org/wiki/navigation/Tutorials/Navigation%20Tuning%20Guide and make sure your odometry looks good.
Could you provide a bag file of a short drive-around containing only the laser, odometry and tf information?
yep, u can download the bag at http://l3.yunpan.cn/lk/QvjJE3xNW7ABY
Dear Kent, Can you please tell me how did you check the odometry accuracy ? thanks.