Vehicle suspension rest length, travel distance
Posted: Sat Sep 11, 2010 10:39 pm
Hi, I'm playing around with btRaycastVehicle and have some questions about the suspension simulation. My vehicle has the following params:
suspensionStiffness - 60
wheelsDampingRelaxation - .4 * 2 * sqrt(60) (as recommended by Maddock's doc)
wheelsDampingCompression - .3 * 2 * sqrt(60)
suspensionRestLength - .6
maxSuspensionTravelCm 60
suspensionMaxForce - 6000
vehicle mass - 800
When the vehicle is standing still on the ground the suspension length is slightly below .6, i.e. the suspension rest length. The problem is that the next raycast is "wheel.getSuspensionRestLength()+wheel.m_wheelsRadius" long from the hard point. Since the suspension length is .6, this will often end just before the ground when driving around on non-flat terrain. Is there anyway to make the suspension not be at .6 when standing still so that the car can bounce around slightly without losing ground contact? I've tried to lower the suspension force but that results in unwanted effects (like the chassis hitting the ground often).
suspensionStiffness - 60
wheelsDampingRelaxation - .4 * 2 * sqrt(60) (as recommended by Maddock's doc)
wheelsDampingCompression - .3 * 2 * sqrt(60)
suspensionRestLength - .6
maxSuspensionTravelCm 60
suspensionMaxForce - 6000
vehicle mass - 800
When the vehicle is standing still on the ground the suspension length is slightly below .6, i.e. the suspension rest length. The problem is that the next raycast is "wheel.getSuspensionRestLength()+wheel.m_wheelsRadius" long from the hard point. Since the suspension length is .6, this will often end just before the ground when driving around on non-flat terrain. Is there anyway to make the suspension not be at .6 when standing still so that the car can bounce around slightly without losing ground contact? I've tried to lower the suspension force but that results in unwanted effects (like the chassis hitting the ground often).