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 Download Package Now!
  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 here. Do not following these rules will lead to permanent exclusion from this website: Read the forum rules.

Bunk bed & wheelchair 2DOF, IBT-2 24V

Discussion in 'Ready, set, go - Start your engines' started by Nim, Jun 23, 2019.

  1. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi All,

    I thought it would be a good time to start a build thread as I have some questions and would like to share my progress.

    Hardware
    Power supply 24v 10amp dc
    IBT-2 x2
    24v Invacare wheelchair motors x2
    Arduino Uno (clone?)

    I have started off with the rough design used in the wiper motor 2DOF tutorial and have modified to suit my bunk bed frame and larger motors.

    I am having some issues with motor 2 cutting out, motor 1 seems to work fine. I believe the issues are to do with my feedback values. In SMC3 utils there is a noticeable difference
    Motor 1 seems to be working well. Has relatively flat green feedback line

    Motor 2 works intermittently and cuts out feedback line peaks & troughs at the limits
    I will provide more info and photos soon
  2. Ads Master

    Ads Master

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
  3. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Ok this is the frustrating part. The feedback results seem to be inconsistent for motor 2. I have taken some screen shots and both feedback lines appear quite flat now.

    Hoping someone out there can provide some steps I can follow to troubleshoot. I suspect the answer may be in @RufusDufus's doco but its a bit technical for me to comprehend atm.

    Let me know if you need any more info screenshots etc. Any help would be appreciated.

    NB I am at the stage of trying to control the motors via simtools and smc3utils (i think i need to configure more in SMC3, although motor 1 seems to work well and all hardware and settings are indentical as far as I can see)
    No load to chair mounted either (cant wait ;))

    Attached Files:

    • m1.PNG
      m1.PNG
      File size:
      77.3 KB
      Views:
      63
    • m2.PNG
      m2.PNG
      File size:
      89 KB
      Views:
      58
  4. MarkusB

    MarkusB Active Member Gold Contributor

    Joined:
    Jun 30, 2015
    Messages:
    408
    Location:
    Germany
    Balance:
    3,037Coins
    Ratings:
    +357 / 1 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Last edited: Jun 26, 2019
  5. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Thanks Marcus are you suggesting that I use SMC3 version which has been modified for the Sabretooth with my IBT-2s? If so I am assuming this is to take advantage of the 'soft start'?
    I will read up on this, unfortunately, I can only test on the weekends.

    My main issue is that when I attempt to follow the instructions by RufusDufus and set everything (well mostly) in SMC3 to 0 and ramp up the PWMmax to get the motor moving etc. it doesn't really tell where to go from there. No criticism to the Dufus I am sure it's in the doco I just don't understand the way its worded.
    Adding to this is the fact I can get 1 motor to work reliably but not the other however hardware and software setting appear identical.
    I also need to understand under what conditions a power cycle is required to get the motors working properly. I am assuming feedback out of limits and maybe overheating as 2 possibilities? Any others?
  6. MarkusB

    MarkusB Active Member Gold Contributor

    Joined:
    Jun 30, 2015
    Messages:
    408
    Location:
    Germany
    Balance:
    3,037Coins
    Ratings:
    +357 / 1 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    I don't have any experiences with IBT-2.
    The reason why I said you need to check your SMC3 settings was that I saw some unusual values, like Max Limits set to 0, while both instructions (the one from RufusDufus as well as the one from @BlazinH) say you should set it to 255 in order to give the motors enough moving range.
  7. BlazinH

    BlazinH Well-Known Member

    Joined:
    Oct 19, 2013
    Messages:
    2,053
    Location:
    Oklahoma City, USA
    Balance:
    15,030Coins
    Ratings:
    +1,721 / 30 / -1
    I believe SMC3 settings are correct based on:

    "Clip Input Used to create a band at either limit of the target range beyond which any values sent to the SMC3 are clipped. In addition to this clipping, if the motor feedback does move beyond this range (typically through inertia), the SMC3 will attempt to brake the motors hard by driving them in reverse until they are back out of this limit zone. The value can be anything from 0-255 (however can’t be less than the current limit setting). Reverse braking is applied in the band between the Clip Input and the Max Limit settings. Reverse braking can be disabled - refer to PWMrev.

    Max Limits Used to create a band at either limit of the feedback range beyond which if the motors move (typically through inertia) the SMC3 will automatically shutdown the drivers and keep them disabled until reset. This is essentially a safety mechanism if something goes wrong. The value can be between 0-255 (however can’t be greater than the current clip setting)."

    Its confusing because he states, "can’t be greater than the current clip setting" for max limits. So I think the max limits setting is based on the bottom end of the graph in SMC3 utilities and the clip input setting is based from the top since clip input, "can’t be less than the current limit setting" also.

    Unless you have already narrowed the problem down further I would swap IBT's in order to test the one you have now on motor 2. Once its established they are both good then go on to test other things.

    And if need more info about SMC3 utilities here SMC3 Arduino 3DOF Motor Driver and Windows Utilities
    • Like Like x 1
    • Informative Informative x 1
    Last edited: Jun 26, 2019
  8. zapata_h

    zapata_h Member

    Joined:
    Dec 25, 2013
    Messages:
    149
    Occupation:
    Industrial Maintenance Manager
    Location:
    España
    Balance:
    334Coins
    Ratings:
    +27 / 0 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino
    We assume that you have modified the SMC3 code line in mode 2 to use the IBT-2, on one occasion something very similar happened to me with the feedback, the motor moved when I wanted, the result was a cable that made bad contact
  9. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Thanks Yes I can confirm and have recompiled and uploaded the SMC code using mode2. Im gonna look at the wiring and swap my IBT 2's around as suggested by BlazinH
  10. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Thanks yes this is the guide I have been struggling with a bit.
    Here are some of my points of confusion
    1. I dont see it stated anymore which output mode to use the SMC3 utility and have left it on the default of Monitor. Is this ok?
    2. I thought I read somewhere that the SMC Utility can be used to test/drive the motors as opposed to just providing diagnostics, is this true?
    3. Step 9 in the guide above mentions the green feedback line moving towards the blue line. In my results for one of my motors the blue line is fairly straight in the middle and my green line is peaking and troughing (substantially) above and below the blue line

    Going to try some swapping of IBT2s now
  11. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    One other question is what does the green feedback represent I am assuming this is the value from the potentiometer that is providing feedback on the position of the motor/shaft, is this correct?

  12. zapata_h

    zapata_h Member

    Joined:
    Dec 25, 2013
    Messages:
    149
    Occupation:
    Industrial Maintenance Manager
    Location:
    España
    Balance:
    334Coins
    Ratings:
    +27 / 0 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino
    Correct, and when increasing the PWMAX value slowly the green line should be approaching the blue line little by little, if not it exchanges +5 and gnd in the pot or reverses the rotation of the engine, never both at the same time that you will have the same problem
  13. Nim

    Nim New Member

    Joined:
    Feb 10, 2019
    Messages:
    7
    Balance:
    105Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Thanks ...Although I am still struggling I have learned a few things and eliminated some issues. My new IBT-2 arrived and it did not solve my issues so I went back to the pots and replaced them with the $4.95 Duinotech hall effect sensors from Jaycar. Has anyone used these or similar I was planning to put a magnet on the motor shaft and mount the sensor perpendicular? Curious to see/hear what others have done with these sensors or whether I must use the more expensive and hard to get rotary hall effects sensors others on this forum recommend?
    One lesson I learned was that by setting the mode to manual in SMC Utils you can control the motors manually ;)
    Another burning question is what factors can cause SMC utils to require a reset( unplug and plug in USB or restart app) apart from feedback values out of range (potentiometer greenline)?