1. Do not share user accounts! Any account that is shared by another person will be blocked and closed. This means: we will close not only the account that is shared, but also the main account of the user who uses another person's account. We have the ability to detect account sharing, so please do not try to cheat the system. This action will take place on 04/18/2023. Read all forum rules.
    Dismiss Notice
  2. 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!
  3. 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
  4. 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

Tutorial SPS - Sabertooth Packet Serial PID motor driver sketch w/SoftStart

Discussion in 'SimTools compatible interfaces' started by BlazinH, Nov 10, 2016.

  1. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Thanks, the reason why I can move the hall sensor is because of the elastic I'm using as transmission belt but if I install a non elastic and toothed belt that union is rock solid but the problem stills so it not seems to be the problem.

    Electrical interference is plausible but I do everything to try to mitigate it with no success, not only it didn't go away nor hsn't improve a little so the problem comes from somewhere else.

    As I showed in my last post I discovered that if I move the hall sensor the movements are completely clean so maybe the problem comes when the commands comes from the PC trough the USB Cable and it is taking interference. I try running SMC utils on another PC but the same problem with the same USB cable.

    I bought a good USB cable that maybe tomorrow will arrive. I'll get a try
  2. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    21,475
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    150,489Coins
    Ratings:
    +11,010 / 55 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    USB can also relate to what else may share a controller: https://www.xsimulator.net/community/faq/simtools-usb-issues-can-cause-crashes.313/
    • Useful Useful x 1
  3. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Well, I'have tried with two new and different shielded 2.0 cables but the problem does not go away. Even if the Arduino is the only thing connected to the PC.

    I also bought a USB 2.0 PCI card but I misunderstood the connection and is not compatible with my motherboard. Another possible solution is connect the arduinos to a powered hub to avoid the MoBo power it (I read something like that in a Arduino forum).

    How it is possible that if I move manually the hall sensor to see how the motor try to correct the position the motor runs well, without noise, smooth, as expected BUT if the commands comes from the PC it starts to run bad as s**t. In one hand I'm happy to see the motors&Sabertooth combo runs well but when the rig have to work with the PC it starts to troll me.

    There must be a solution I'm sure
  4. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Hi again, is there an alternative code to manage the Sabertooth 2x60? I asked to Wanegain to know if his code is good for the 2x60 but without response.

    Yesterday I tested the "manual" moves with some load (55 Kg) to see how it performs and the motors works good, without that weird oscillate movements. The noise is present even if the motor is off (and then when the motor is on and moving the noise magnifies) so EMI from the motor seems not be the problem

    Surely I'll unmount a motor and will do tests in a bench to see how will be its behavior
  5. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    21,475
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    150,489Coins
    Ratings:
    +11,010 / 55 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    Here are the FAQ Sabertooth code options: https://www.xsimulator.net/community/faq/arduino-codes-for-sabertooth-2x25-2x32-etc.137/
  6. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
  7. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Well, I tried all of the codes for Sabertooth less the LCD one because it needs invest in touchscreen and I feel it is a little bit complicated to configure but mostly because I don't think it will solve the problem while the other codes doesn't solved it at all.

    I bought a PCIe USB 2.0 card and checked it is driven by USB 2.0 controller (the built in 2.0 ports are driven by 3.0 controllers) and It didn't help, the problem stills.

    If I move the hall sensor manually the motors drive smooth and silent, If the movement comes from commands from Simtools/FlyPT (meaning from USB) the yellow signal is completely noisy like a mountains.

    Tried all:

    Different USB cables: shielded, with ferrite cores, longer, shorter, 2.0, 3.0.
    Different USB ports: 3.0 and 2.0 built in, and 2.0 dedicated PCIe card.
    Shield and manage all the wires.
    Ferrite cores in all the wires.
    Coaxial cables for serial signals.
    Run it with power supplies and with batteries.
    Run it with and without load
    Configured infinite combination of parameters in SMC utils
    Tested in different PC (even with a Mac running a virtual machine)

    I'm very frustrated
  8. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    21,475
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    150,489Coins
    Ratings:
    +11,010 / 55 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    Can you please post pictures of all of your settings.
  9. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    As I mentioned in these previous posts nothing changes whatever the settings are, in the attachments you can see the settings.


    Do you need to know other settings?
    Last edited: May 7, 2024
  10. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Here an example of the problem:

    smc_settings1.PNG

    No matter what changes I do, the problem does not change. The only way is decreassing Kp to a value so low that the motor can't lift anything
  11. Josh_Possa

    Josh_Possa Active Member

    Joined:
    Jan 25, 2021
    Messages:
    126
    Location:
    Catalunya
    Balance:
    551Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, DC motor, Motion platform
    Hey, finally I found the problem and the solution. The pin from pin 8 to GND to reduce the speed from 500000 to 115000. I tought that I only need to do a pulse signal and few days ago I dicovered the jumper needs to be kept there
  12. _cOdaC_

    _cOdaC_ Member

    Joined:
    Dec 20, 2023
    Messages:
    48
    Balance:
    265Coins
    Ratings:
    +5 / 0 / -0
    My Motion Simulator:
    3DOF, DC motor, Arduino
    What wire size is suggested for the connection between the sabertooth (here 2x32) and the capacitors?
  13. Alvaro George Menendez

    Alvaro George Menendez New Member Gold Contributor

    Joined:
    Aug 7, 2024
    Messages:
    13
    Location:
    Sydney NSW Australia
    Balance:
    63Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino, Motion platform, 4DOF
  14. Alvaro George Menendez

    Alvaro George Menendez New Member Gold Contributor

    Joined:
    Aug 7, 2024
    Messages:
    13
    Location:
    Sydney NSW Australia
    Balance:
    63Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino, Motion platform, 4DOF
    Sorry to ask, but would be very thankful for any advise... but have very very limited experience and exposure working with PCs and Software. I am having difficulty getting pass point 8 "Now use the Arduino programming software to install the SPS sketch attached below on your Arduino. Make sure you choose Uno or Mega and to set the comport number." - how do I do this? - and obviously have not done the next point = Next download and run the Windows SMC3 Utility software attached below and make sure it communicates with your Arduino. - _ How? _ Open the accompanying SMC3Utils.ini with notepad to change the comport if needed (see image below) - _ changed to comport3 _.. any suggestions as to the missing steps i should have made? please talk to me like I'm a 4 year old...
  15. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    21,475
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    150,489Coins
    Ratings:
    +11,010 / 55 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    You need to use the Arduino IDE and make sure it is configured to select your board and comm port, so also check out the Documentation or watch one of the many online Aduino IDE setup tutorials: https://www.arduino.cc/en/software/
    • Like Like x 1
  16. Alvaro George Menendez

    Alvaro George Menendez New Member Gold Contributor

    Joined:
    Aug 7, 2024
    Messages:
    13
    Location:
    Sydney NSW Australia
    Balance:
    63Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino, Motion platform, 4DOF
    Thank you Noorbeast.. I built Kevinski's aka Dr ADHD 4DOF Motion Sim, but I am really struggling with the "software" part of the build. I am finding to many rabbit holes to look into and not understanding. I would gladly pay for someone to hand hold me through the last parts of the process as I just seem completely lost with it. Will keep trying but it may be
    a bridge to far for me.
    Motion Sim Battery Box and Control boards box IMG_8669.jpg
  17. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    21,475
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    150,489Coins
    Ratings:
    +11,010 / 55 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    Take it one step at a time, so install the IDE, configure its setting for your Arduino and comm port, then it is pretty simple after that to write the SMC3 code to the Arduino.

    Once that is done then fire up the SMC3 configuration app and follow each step of the setup.
    • Like Like x 1
  18. Alvaro George Menendez

    Alvaro George Menendez New Member Gold Contributor

    Joined:
    Aug 7, 2024
    Messages:
    13
    Location:
    Sydney NSW Australia
    Balance:
    63Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino, Motion platform, 4DOF
    Thank you.. will try it
    • Like Like x 1
  19. Kevinski

    Kevinski If it doesn't fit, hit it until it does.

    Joined:
    Feb 17, 2023
    Messages:
    187
    Occupation:
    Jack of many trades, mastering some.
    Location:
    Australia
    Balance:
    351Coins
    Ratings:
    +117 / 0 / -0
    My Motion Simulator:
    3DOF, DC motor, Arduino, Motion platform
    @ Alvaro George Menendez Hey George, I'm about to shoot a step by step video on how I set everything up for my rig you have emulated. Great job on that build by the way. The pics you sent me, it looks awesome. I'll cover all the Arduino driver and library setup and how you install the code along with the H bridge changes needed in the Arduino code as well as the SMC3 ini file changes for correct com port communications.

    I have done this in previous videos, but I'll do one for the absolute beginners on the PC side.

    I'll include what I did in the dimension software (sabretooth 2x32) to get that working as well.

    Hang in there mate. You'll get it working.
    • Like Like x 1
    • Friendly Friendly x 1
  20. Alvaro George Menendez

    Alvaro George Menendez New Member Gold Contributor

    Joined:
    Aug 7, 2024
    Messages:
    13
    Location:
    Sydney NSW Australia
    Balance:
    63Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    DC motor, Arduino, Motion platform, 4DOF
    Thanks Kevin .. Your a gentleman and a Scholar, You have been very generous with your support and hope that I can get this rig up and running. Spent a bit of time over the last couple pf days making sure of no duplicate files and downloading all files etc. Also finished physically installing the wind sim with two 3000rpm server fans to eventually get it running with an Arduino Uno R3 and two IBT2, strapped in the HF8 Haptic seat insert over the racing seat and started my marketplace hunt for a racing seat harness so that I can utilise the extra 2x32 I have coming in. The Pimax 8KX VR Headset is a bit of an unknown for me but Pimax are working on Motion Cancellation to add to their app.
    thumbnail_IMG_8745.jpg thumbnail_IMG_8746.jpg thumbnail_IMG_8748.jpg thumbnail_IMG_8749.jpg thumbnail_IMG_8750 (1).jpg thumbnail_IMG_8750.jpg thumbnail_IMG_8752.jpg thumbnail_IMG_8748.jpg
    • Like Like x 1
    • Friendly Friendly x 1