1. For downloading SimTools plugins you need a Download Package. Get it with virtual coins that you receive for forum activity or Buy Download Package - We have a zero Spam tolerance so read our forum rules first.

    Buy Now a Download Plan!
  2. Do not try to cheat our system and do not post an unnecessary amount of useless posts only to earn credits here. We have a zero spam tolerance policy and this will cause a ban of your user account. Otherwise we wish you a pleasant stay here! Read the forum rules
  3. We have a few rules which you need to read and accept before posting anything here! Following these rules will keep the forum clean and your stay pleasant. Do not follow these rules can lead to permanent exclusion from this website: Read the forum rules.
    Are you a company? Read our company rules

A foldable DIY Sim RIG with G-Seat

Discussion in 'DIY Motion Simulator Projects' started by Banfy, Jun 28, 2020.

  1. Banfy

    Banfy FR/AU

    Joined:
    Jun 11, 2020
    Messages:
    21
    Location:
    Australia
    Balance:
    188Coins
    Ratings:
    +12 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino
    Actually yes, i just found out how to set manually the min max values

    let me rephrase what i try to do:
    My servo can rotate from zero (no pressure) to 180 degrees (full pressure)

    currently , i have my servo rotation from 0 to 90 for negative surge( breaking), and 90 to 180 for positive(acceleration)

    i would like the range 0 to 180 to be assigned only to positive acceleration.
    When braking or in still position , the servo rotation should be at zero (no pressure)

    i hope it is more clear ;-)
  2. MarkusB

    MarkusB Active Member Gold Contributor

    Joined:
    Jun 30, 2015
    Messages:
    451
    Location:
    Germany
    Balance:
    3,357Coins
    Ratings:
    +432 / 1 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Arduino, Motion platform
    Hi @Banfy,

    yes, it is clear what you mean.
    When I was using servo motors, I did the modifications in the Arduino code.

    I got the idea (plus the code) from @Spit40, who offers his modified Arduino sketch here for download.


    See also this post, where he explains some more details about clipping the values.
  3. Banfy

    Banfy FR/AU

    Joined:
    Jun 11, 2020
    Messages:
    21
    Location:
    Australia
    Balance:
    188Coins
    Ratings:
    +12 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino
    thank you Markus, i will look at this
  4. Banfy

    Banfy FR/AU

    Joined:
    Jun 11, 2020
    Messages:
    21
    Location:
    Australia
    Balance:
    188Coins
    Ratings:
    +12 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino
    I confirm it works. Doing so seem more suitable for racing whereas having the positive and negative range might be more suitable for flight sims.
    the key code lines are the one below:
    //No -ve on G-seat : 128 = middle
    if (actuatorPosition[currentActuator]<128) actuatorPosition[currentActuator]=128;

    // scale the new position
    // Range is now 128 - 255
    // Maps between min and max
    actuatorPosition[currentActuator] = map(actuatorPosition[currentActuator], 128, 255, kActuatorScale[currentActuator][0], kActuatorScale[currentActuator][1]);
    //
    • Like Like x 2