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 SMC3 Arduino 3DOF Motor Driver and Windows Utilities

Discussion in 'SimTools compatible interfaces' started by RufusDufus, Dec 1, 2013.

  1. getti

    getti Currently building my first 2dof seat mover...

    Joined:
    Oct 27, 2012
    Messages:
    124
    Location:
    Canada
    Balance:
    45Coins
    Ratings:
    +45 / 1 / -0
    My Motion Simulator:
    2DOF
    I found the Event logs but not sure how to make sense of all this, what am I looking for?

    One other thing I should mention is when it is not working I open the device manage and the Arduino is still there listed under com12 as normal with no warning or anything beside it.
  2. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    Are there error messages in the logs that coincide with the disconnects and if so what is the error message?

    Interference or power spikes could cause disconnects, along with faulty cables r ports. You could try a car battery to see if it is power spikes.

    Good cable management and appropriately sized clip on ferrite magnets can help reduce interference: https://www.ebay.com/sch/i.html?LH_...sacat=&_sadis=&_sop=12&_udhi=&_udlo=&_fosrp=1
  3. Gadget999

    Gadget999 Well-Known Member

    Joined:
    Dec 27, 2015
    Messages:
    1,886
    Location:
    London
    Balance:
    11,543Coins
    Ratings:
    +453 / 9 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, 6DOF
    @RufusDufus

    did you consider an Arduino with more pins so you can run 6 or more actuators ?

    regards
  4. Petemnz

    Petemnz Member

    Joined:
    Aug 23, 2019
    Messages:
    53
    Occupation:
    Sparky by Trade
    Location:
    Auckland, New Zealand
    Balance:
    60Coins
    Ratings:
    +35 / 0 / -0
    My Motion Simulator:
    3DOF, DC motor, Arduino
    This worked great now feedback reaches limit levels for clip and motor cut - (I changed to 1.5 scale range suit my setup) - Thanks
  5. giorgionrg

    giorgionrg New Member

    Joined:
    Feb 2, 2020
    Messages:
    8
    Occupation:
    Technician
    Location:
    Italy
    Balance:
    90Coins
    Ratings:
    +3 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi everyone. I'm a new forum member. congratulations for the works, they're amazing. After years i decide to begin my 2dof project. I'm not very smart with arduino and coding in general...
    I'm trying to follow the guides of this forum, but a i'm little bit confused.
    My setup consist in:
    -Arduino Uno;
    -2x Monster MotorShield;
    -2x Psu HP 600pb 575W:
    -2x Bosch wiper motor.

    My intent is to use 1 motorshield for each motor.
    These are the connection that i made:

    Arduino -------- Monster Moto 1
    2 (Motor 1 H-Bridge ENA) ---------------7 and 8 (INA1 and INB1)
    3 (Motor 1 H-Bridge ENB)----------------4 and 9 (INA2 and INB2)
    9 (Motor 1 PWM) --------------------------5 and 6 (PWM1 and PWM2)
    Arduino -------- Monster Moto 2
    4 (Motor 2 H-Bridge ENA) ---------------7 and 8 (INA1 and INB1)
    5 (Motor 2 H-Bridge ENB)----------------4 and 9 (INA2 and INB2)
    10 (Motor 2 PWM) --------------------------5 and 6 (PWM1 and PWM2)

    Furthermore i connected the two potentiometer to A0 and A1 with the relative supplies.

    The code loaded on the arduino is the SMC.ino v1.0.

    now, when i turn on, nothing happens.

    Where did I go wrong? I forgot something?

    Thankyou in advance for the precious help.
  6. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    I suggest you use the SMC3code, as it has a handy app for doing the configuration, and extensive setup instructions: https://www.xsimulator.net/communit...3dof-motor-driver-and-windows-utilities.4957/

    Most wiper motors require ground isolation, so make sure that is done before anything else: https://www.xsimulator.net/community/faq/wiper-motor-mandatory-ground-isolation.25/

    Similarly, if you are using clone MMs then test them before use, as often they are faulty: https://www.xsimulator.net/community/faq/reputable-monster-moto-suppliers-testing-before-use.158/
  7. Kashif Saeed

    Kashif Saeed New Member

    Joined:
    Nov 23, 2019
    Messages:
    16
    Balance:
    49Coins
    Ratings:
    +2 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, 6DOF
    Hello everyone!
    I have done all the configurations of smc3 and i am using ibt 2 motor driver. But the problem is that motor is moving only in one direction, it stops when the feedback changes.
    TIA.
  8. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
  9. Kashif Saeed

    Kashif Saeed New Member

    Joined:
    Nov 23, 2019
    Messages:
    16
    Balance:
    49Coins
    Ratings:
    +2 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, 6DOF
    Thanks @noorbeast for the reply.
    i am using wheelchair motor(CM808-075A) and IBT2 controller.

    before SMC3, i checked the driver and motor by applying simple Arduino code for IBT2 and everything was working fine.
    i am new here.
    i follow the instructions for SMC3 and in the result my motor is working but only in one direction.

    looking forward for the help

    TIA.
  10. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    You will need to explain a bit more about what you have or have not done, plus post pictures of al of your settings. For example, is it set to Mode 2 and is one motor only moving in one direction, or both?
  11. giorgionrg

    giorgionrg New Member

    Joined:
    Feb 2, 2020
    Messages:
    8
    Occupation:
    Technician
    Location:
    Italy
    Balance:
    90Coins
    Ratings:
    +3 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi noorbeast, Thank you very much for the reply.
    Sorry to just pick up now, but I've been out on business.
    Yesterday i tried to follow your suggestion; the problem was the motor's ground isolation. Now them move.

    I will now proceed with the next steps and keep you updated on developments.
    • Winner Winner x 1
  12. Kashif Saeed

    Kashif Saeed New Member

    Joined:
    Nov 23, 2019
    Messages:
    16
    Balance:
    49Coins
    Ratings:
    +2 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, 6DOF
    Hey noorbeast,
    Thank you for the reply.

    I just review my system again and found the problem that was related to my motor driver.
    My IBT2 was not working properly.
    I bought a new IBT2 and everthing is working fine.

    I am facing another problem that i would like to share with you.
    I am trying to operate simtools and simhub simultaneously by using LFS and demo version of simtools. But both of them are not working at the same time.
    I guess this problem is related to some kind of port conflict. When i tried to patch the game using simtools, it updates the cfg file of LFS and by fixing the LFS in simhub, it update the cfg file according to simhub configuration and simtools not getting the values.

    It will be honor for me @noorbeast if you please resolve my problem.

    Looking forward for your kind response.

    TIA
  13. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
  14. Kashif Saeed

    Kashif Saeed New Member

    Joined:
    Nov 23, 2019
    Messages:
    16
    Balance:
    49Coins
    Ratings:
    +2 / 0 / -0
    My Motion Simulator:
    2DOF, 3DOF, 6DOF
    @noorbeast ,
    Actullay, I'm not familiar with port forwarding.
    Well you please tell me that how i can use the port forwarding or reffer to the tutorial?

    TIA
  15. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    It is explained on the SimHub GitHub page: https://github.com/SHWotever/SimHub/wiki/Sharing-UDP-data-with-other-applications

    I have added it to the FAQs here: https://www.xsimulator.net/community/faq/simhub-port-forwarding.356/

    And updated the Glossary: https://www.xsimulator.net/community/faq/glossary-of-acronyms-and-names.66/
    Last edited: Feb 21, 2020
  16. giorgionrg

    giorgionrg New Member

    Joined:
    Feb 2, 2020
    Messages:
    8
    Occupation:
    Technician
    Location:
    Italy
    Balance:
    90Coins
    Ratings:
    +3 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi Noorbeast,
    i've a new problem...
    I've done several tests but the issue I'm facing seems to be not connected to a bad wiring.
    Now when I turn on the system the motors move but after a short rotation they stop(both pot are connected to the motors).
    As I try to move whatever pot manually it doesn't do anything. The motors seem to be stuck.
    I debugged the feedback positions in arduino monitor and found out that those have not reached the limit values set in the code.
    In details:
    -Motor1 moved from 512 to 214
    -Motor2 moved from 512 to 771
    (both pot were initially set to middle position).

    Moreover when I run Simtools the motors do not move.

    any suggestion?
    thank you in advance.
  17. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    SMC3 has to be fully configured and working as expected before using SimTools.

    Are the motors ground isolated?

    Do the motors rotate freely in either direction if directly connected to power?

    Double check the pots, their wiring and please post pictures of all of your settings.
  18. giorgionrg

    giorgionrg New Member

    Joined:
    Feb 2, 2020
    Messages:
    8
    Occupation:
    Technician
    Location:
    Italy
    Balance:
    90Coins
    Ratings:
    +3 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi noorbeast,
    the motor are ground isolated and rotate freely in either direction if directly connected to the power (pots disconnected).
    Settings attached below.

    Thankyou

    Attached Files:

  19. noorbeast

    noorbeast VR Tassie Devil Staff Member Moderator Race Director

    Joined:
    Jul 13, 2014
    Messages:
    20,463
    Occupation:
    Innovative tech specialist for NGOs
    Location:
    St Helens, Tasmania, Australia
    Balance:
    144,614Coins
    Ratings:
    +10,741 / 52 / -2
    My Motion Simulator:
    3DOF, DC motor, JRK
    Are the motors getting power when they get stuck, if not check if PSU has been tripped.
  20. giorgionrg

    giorgionrg New Member

    Joined:
    Feb 2, 2020
    Messages:
    8
    Occupation:
    Technician
    Location:
    Italy
    Balance:
    90Coins
    Ratings:
    +3 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    No, when the motors stop don't receive current. The PSUs are ok, I measure both at 12V.

    I made more tests and i noticed that, unplugging the pots to the motors, all seems to work properly.

    I've a question: is it normal that when I power on the system the motors spin without me giving any commands?

    Note: I didn't modified the .ino code.

    Thankyou.