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. hooshang

    hooshang Active Member

    Joined:
    Jul 6, 2011
    Messages:
    273
    Balance:
    285Coins
    Ratings:
    +157 / 3 / -0
    My Motion Simulator:
    2DOF, DC motor, AC motor, Arduino, 6DOF
    Hi @speedy
    thank you for this solution that makes 3 AC actuator available simply
    but IMO you should better to drag Ard a little more to the right which the ARD usb port can have access
    from outside the electronic box.
    anyway this is exelent job
    thank you friend
    best regards
    • Like Like x 1
  2. speedy

    speedy Well-Known Member

    Joined:
    Feb 1, 2012
    Messages:
    1,193
    Location:
    Alexandria , Egypt
    Balance:
    7,931Coins
    Ratings:
    +1,287 / 10 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino, Motion platform
    @hooshang ... thank you my friend .

    BTW ... The Ard USB is intended to be connected to the internal onboard front USB of the computer if empty :D:D >>> like this costume red tape socket in my current DIY 2DOF controller ... Or using a normal USB cable connected to the PC back USBs .

    2015-09-02 12.14.49.jpg

    otherwise if you'll be using it in a separate box [2 of them for 6DOF ] ... So, there will be a plenty of space for the normal USB cable to be plugged in through a USB hole plus leaving a decent distance from the edge for bearing the cable load on the socket itself ... also like the above picture ... you'll have an Ard. reset button access hole + a TC at the Ard. side for the 12v computer power supply .
    they are all will have the same ground .:cheers
    • Useful Useful x 2
    • Like Like x 1
    Last edited: Dec 26, 2015
  3. speedy

    speedy Well-Known Member

    Joined:
    Feb 1, 2012
    Messages:
    1,193
    Location:
    Alexandria , Egypt
    Balance:
    7,931Coins
    Ratings:
    +1,287 / 10 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino, Motion platform
    :thumbs:thumbs:thumbs:thumbs:thumbs

    Thanks Tom ... That's what I was looking for ...and just by using 2-3 meter RJ11 phone extension cords to the VFD's terminals ... and a 2-3m. stereo extension 3.5mm plug shielded cables for F.B. pots .
    13Ft-Long-RJ11-6P2C-Plug-font-b-Telephone-b-font-Phone-Extension-Cord-font-b-Cable.jpg images (1).jpg
    to be cut and soldered / fastened at the other end . :thumbs:thumbs:thumbs

    updates are coming ASAP .:D
    • Like Like x 1
    Last edited: Dec 26, 2015
  4. RufusDufus

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,896Coins
    Ratings:
    +1,016 / 10 / -1
    Hi @speedy, have you thought about just isolating through the Arduino RS232? I have done this before... Use a cheap TTL USB to Serial converter from ebay ($1 to $2) and isolate the TTL transmit from the converter using a 6n137 and connect to the Arduino RS232 receive pin. You don't even have to worry about the receive signal for normal operation.

    This bypasses the Arduino onboard USB to rs232 converter. Of course if you wanted to hack into the board you could just use the on board one.
    • Agree Agree x 1
  5. speedy

    speedy Well-Known Member

    Joined:
    Feb 1, 2012
    Messages:
    1,193
    Location:
    Alexandria , Egypt
    Balance:
    7,931Coins
    Ratings:
    +1,287 / 10 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino, Motion platform
    Last edited: Dec 27, 2015
  6. speedy

    speedy Well-Known Member

    Joined:
    Feb 1, 2012
    Messages:
    1,193
    Location:
    Alexandria , Egypt
    Balance:
    7,931Coins
    Ratings:
    +1,287 / 10 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino, Motion platform
    Finished ... :thumbs
    I've used the commonly used terminal connectors to be angled and welded directly on board with wide pads ... So you don't have to use extra searching for sockets of plugs or purchasing more hardware ...
    I guess this is more easy since this is easier to wire every thing correctly ...


    Here is the final arranged layer picture and the 1:1 printable PDF file ...

    PCI Opto-Copler copper side.pdf

    10.JPG
    11.JPG

    Edit :board external dimensions will be like this to be easy installed in your computer ...
    • Like Like x 6
    • Winner Winner x 4
    • Useful Useful x 1
    Last edited: Jan 18, 2016
  7. Pastrana

    Pastrana Member

    Joined:
    Oct 30, 2015
    Messages:
    96
    Location:
    Argentina
    Balance:
    159Coins
    Ratings:
    +45 / 0 / -0
    My Motion Simulator:
    2DOF
  8. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    I tried to upload several of these versions, but none of them seem to contain an arduino sketch. They have the motor monitoring-controlling application, and the other file is just a brief 5 line text. I'm sure I'm not doing something right here. please help me
  9. Kirk

    Kirk Member

    Joined:
    May 19, 2014
    Messages:
    91
    Occupation:
    Sr Software Engineer
    Location:
    Texas
    Balance:
    15,087Coins
    Ratings:
    +114 / 2 / -0
    My Motion Simulator:
    2DOF, DC motor
    http://www.xsimulator.net/community...3dof-motor-driver-and-windows-utilities.4957/
    In particular, SMC3 v0.7.zip is what you want, and set "mode 2" in the source file.

    edit: ie: change
    #define MODE1
    to
    #define MODE2
    • Informative Informative x 2
    • Agree Agree x 1
  10. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    Has anyone had issues getting the Configuration software to interface with the arduino? I keep getting a "cannot read arduino" upon startup.
    • Like Like x 1
  11. Pit

    Pit - - - - - - - - - - - - - - - - Gold Contributor

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,438Coins
    Ratings:
    +3,089 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    do you mean when you are starting SMC3? Did you set the correct com port in the smc3ini file?
    • Like Like x 1
  12. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    You're a genius and a scholar good sir
  13. Pit

    Pit - - - - - - - - - - - - - - - - Gold Contributor

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,438Coins
    Ratings:
    +3,089 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    No, I am reading the manuals :p joke aside, I'm just kidding (but you are welcome to study the manuals nevertheless...:D )
  14. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    I'm noticing that as soon as I turn the computer on the motor seems to start running. Is the arduino code stored onboard? How do I unload it? Where's this manual at?
  15. Pit

    Pit - - - - - - - - - - - - - - - - Gold Contributor

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,438Coins
    Ratings:
    +3,089 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    hmm, in this case you have to go step by step though the SMC3 thread. The Arduino code is stored on the Arduino itself - you have to upload the SMC3 sketch first to the Arduino. Please go to the OP (first page on this thread) you will find all needed information there. BTW you need the Arduino software first to be able to upload any sketch to the Arduino, but this are basics usually IMO this should not to be mentioned...
  16. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    Everything is wired up correctly, but for whatever reason it's reading my motor as motor 2, which I find odd because I only have one motor wired up. It seems to jog the motor in a back and forth motion of increments of five degrees when I increase the pwm max setting. Changing the feedback limitation controls on the right has little effect on this. When I try to operate the motor in simtools, the arduino does light up as if communicating, but it's not receiving commands when I try output testing. suggestions? comments? derogatory statements?
  17. Kirk

    Kirk Member

    Joined:
    May 19, 2014
    Messages:
    91
    Occupation:
    Sr Software Engineer
    Location:
    Texas
    Balance:
    15,087Coins
    Ratings:
    +114 / 2 / -0
    My Motion Simulator:
    2DOF, DC motor
    First, I would ensure that you don't have the Arduino IDE open when you launch simtools, particularly not the serial monitor, as the connection can't be shared, so it simtools won't be able to open the com port. If you ever accidentally do, close both, then open simtools.

    http://www.xsimulator.net/community...3dof-motor-driver-and-windows-utilities.4957/


    Ensure you are wired as described in the "MODE2" graphic and that in the INO sketch file, you have "MODE2" defined instead of "MODE1".
    It is (nearly) guaranteed this is why you are seeing the wrong motor.

    If you still have problems, because Pin 13 is unused (and attaches to the light), I would add additional code that enables it as an output in "setup()", turns it off, and on receipt of the first good command, turns it on. This will narrow your issues down to "1) wiring" or "2) communications".
    • Like Like x 1
    • Informative Informative x 1
  18. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    After getting some sleep and looking over the diagram they have listed on page 1 of this thread, I noticed my pin locations were indeed setup for motor 2, not motor one. This obviously solved my "why is the SMC3 configuration software only running motor 2" issue.

    Unfortunately I still cant seem to get simtools to drive the motor when I go to test the axis's. I noticed the baud rate was set for 9600 on the arduino serial monitor tab, so I changed that to 115200 to coincide with the second figure in the sketch. The first being 500000, which I have changed in the Interface tab in Simtools. When I turn the axis "on" the arduino does seem to light up as if data is being sent to it. As far as turning the Arduino IDE off before launching sim tools, I gave that shot. Though after reading over Simtools starter instructions it does note to load up the sketch before opening up the Game Engine. Do you reckon I have something configured incorrectly with the SMC3 configurator?
  19. Pit

    Pit - - - - - - - - - - - - - - - - Gold Contributor

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,438Coins
    Ratings:
    +3,089 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    can you move the motors (correctly) by using SMC3?
  20. kimballfount

    kimballfount Member

    Joined:
    Oct 12, 2015
    Messages:
    88
    Location:
    greer,sc
    Balance:
    879Coins
    Ratings:
    +15 / 3 / -0
    My Motion Simulator:
    2DOF, Arduino
    Define "correctly", It shifts back and forth in increments of 15 degrees. The speed is adjustable, but the angle doesnt appear to be.