Unsolved Traction Control

Discussion in 'Mod Support' started by dumpling, Jan 23, 2022.

  1. dumpling

    dumpling
    Expand Collapse

    Joined:
    Jan 28, 2021
    Messages:
    750
    Hello, does anyone know what variables like "slipThreshold", "kP", "kI", "kD", "integralInCoef", and "integralOutCoef" means? They are located in the tc JBeam files and I'm currently working on improving the traction control of a Land Rover Defender mod: https://www.beamng.com/threads/2020-land-rover-defender-update-20-01.83690/ Any help would be greatly appreciated, thank you
    --- Post updated ---
    I can see improvements when I just increase the values, but I don't want to do this blindly
     
  2. angelo234

    angelo234
    Expand Collapse
    Programmer
    BeamNG Team

    Joined:
    Aug 11, 2017
    Messages:
    540
    The "kP", "kI", "kD" refer to proportional gain, integral gain, and derivative gain values of the PID controller used for the traction control. Although I'm not sure what the "integralInCoef" and "integralOutCoef" mean. Here's a good video on what it is and it'll explain what those three terms are and how they affect the result (video shows controlling the steering angle to get the car to drive on the designated path):


    In this case, the PID controller controls the throttle input to maintain a specific slip ratio (slipThreshold). The slip ratio is the wheel's speed divided by the vehicle's speed all subtracted by 1. A certain amount of slippage gives the best acceleration, and as you can see below it peaks at around 0.2. That's why you see in the JBeam file that slipThreshold is that value. So basically you do have to tinker around with those "kP", "kI", "kD" values. Hope that was somewhat clear :)

     
    #2 angelo234, Jan 25, 2022
    Last edited: Jan 25, 2022
    • Like Like x 1
  3. default0.0player

    default0.0player
    Expand Collapse

    Joined:
    Nov 30, 2018
    Messages:
    1,925
    I did't quite understand the optimal slip ratio. If you are moving at 100km/h(ground speed), 120km/h wheel speed will get you the best acceleration. However, if you are moving at 1km/h, does 1.2km/h wheelspeed still get you the best acceleration?
     
    #3 default0.0player, Jan 25, 2022
    Last edited: Jan 25, 2022
  4. dumpling

    dumpling
    Expand Collapse

    Joined:
    Jan 28, 2021
    Messages:
    750
    Thank you for the detailed explanation :)
     
    • Like Like x 1
  5. angelo234

    angelo234
    Expand Collapse
    Programmer
    BeamNG Team

    Joined:
    Aug 11, 2017
    Messages:
    540
    According to the slip ratio equation, 1.2 km/h wheel speed and 1 km/h vehicle speed would give you the best acceleration. But I'm no expert on why it is the case and why for example it isn't a specific difference in speed between the two that would give the best acceleration :)
     
    • Like Like x 1
  6. dumpling

    dumpling
    Expand Collapse

    Joined:
    Jan 28, 2021
    Messages:
    750
    Ok I'm back again; how do I limit the amount of wheelslip when they are in mid-air? Is it possible to do with traction control or something else? Any useful response will be appreciated :)
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice