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

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,952Coins
    Ratings:
    +1,016 / 10 / -1
    Compiles OK for me...

    the errors you listed show two files:
    SMC3.ino:135:11: error: 'const int ENBpin1' previously defined here
    SMC3_for_GSeat.ino:136:11: error: redefinition of 'const int ENApin2'

    Did you have two open or something? Try again with just the file you attached above and it should work unless your compiler is installed wrong. Did the original version of SMC3 compile?
  2. RufusDufus

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,952Coins
    Ratings:
    +1,016 / 10 / -1
    If it only moves in one direction it usually means one half of the h-bridge is blown.

    I agree with @Pit, 24V is out of spec for many h-bridges used here - which one are you using?
  3. RufusDufus

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,952Coins
    Ratings:
    +1,016 / 10 / -1
    Sounds like the motors are moving beyond the max limits setup using SMC3Utils. Alternatively the h-bridges are going into thermal or overcurrent shutdown.
  4. speedy

    speedy Well-Known Member

    Joined:
    Feb 1, 2012
    Messages:
    1,193
    Location:
    Alexandria , Egypt
    Balance:
    7,933Coins
    Ratings:
    +1,287 / 10 / -0
    My Motion Simulator:
    3DOF, AC motor, Arduino, Motion platform
    Thanks very much @RufusDufus ...
    Oh yah ... I'm the first one to download and test this time .:thumbs

    Untitled.jpg

    - The Util. opens a CMD window it closes the Util. when closing it ... is that ok ?
    Untitled.jpg
  5. RufusDufus

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,952Coins
    Ratings:
    +1,016 / 10 / -1
    Hi @speedy, Yes its OK, I forgot to set the compiler switch to hide the cmd window.

    I'll recompile later tonight and post an update - just ignore the cmd window for now.
    • Like Like x 3
  6. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    Thank you @RufusDufus for this "silent" release.
    • Agree Agree x 2
  7. tailele

    tailele Member

    Joined:
    May 3, 2015
    Messages:
    40
    Location:
    italy
    Balance:
    349Coins
    Ratings:
    +6 / 0 / -1
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Sorry , maybe i'm lost a point. I would know how i'll could amplifer a signal...i mean that if my signal is very small, and my motor does very small moviments (for example for the surge moviments), is there a method for amplifer this signal ? In my case i would a surge moviments for the shift change or brake, but if i set the surge movimet to 100%, there is a small moviments anyway (max 15°, and i would a 90° moviment in motor's rotation)...maybe do i must use a amplifer? And where could i put it? Thanks a lot
  8. gorzasty

    gorzasty Active Member

    Joined:
    Apr 2, 2012
    Messages:
    151
    Occupation:
    photographer, IT specialist
    Location:
    Poland, Wrocław
    Balance:
    1,060Coins
    Ratings:
    +41 / 1 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    You are right. I'm not good at it ;/ I edited file onece more and this time it was loaded with the succes. But... after some tests the motors working like with Your standard code SMC v0.7 in both directions. So does the code need to be change or I'm doing something wrong again? This time code is here: LINK
  9. RufusDufus

    RufusDufus Well-Known Member

    Joined:
    Jul 21, 2013
    Messages:
    681
    Location:
    Adelaide Australia
    Balance:
    15,952Coins
    Ratings:
    +1,016 / 10 / -1
    Oh yeh sorry, I forgot it is using unsigned values....

    The added lines should be:

    Code:
    if (Target1<512) { Target1 = 512; }
    
    if (Target2<512) { Target2 = 512; }
    
    if (Target3<512) { Target3 = 512; }
    
    • Like Like x 1
    • Useful Useful x 1
  10. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    hi your issue seems to be related to simtools anyway please open a separate thread and upload any screenshots and pictures of your installation.
  11. gorzasty

    gorzasty Active Member

    Joined:
    Apr 2, 2012
    Messages:
    151
    Occupation:
    photographer, IT specialist
    Location:
    Poland, Wrocław
    Balance:
    1,060Coins
    Ratings:
    +41 / 1 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    THX @RufusDufus . I'will check it and let You know here.
  12. gorzasty

    gorzasty Active Member

    Joined:
    Apr 2, 2012
    Messages:
    151
    Occupation:
    photographer, IT specialist
    Location:
    Poland, Wrocław
    Balance:
    1,060Coins
    Ratings:
    +41 / 1 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Works like a charm! Gr8 thing, in my opinion worth of imlementing in SMC3 Utility for all DIY G-Seat owners as long as SIMTOOLS won't allow us to setup motors asymetrical.
  13. jaco73

    jaco73

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    your recommend to replace IBT-2, for use as motor 24v smolka?
  14. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    Pardon ?
  15. jaco73

    jaco73

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    lo siento, cosas del traductor, El problema es que se quemaron los iBT-2 y los quiero sustituir, quería que me recomendaran unos h-puentes pára usar con motores Smolka 24v, Que No fuesen los iBT-2, estoy ahora probando con 1 monstermoto shield, pero supongo que Será mejor trabajar a 24v para Sacar el Rendimiento a los motores

    I'm sorry things translator, the problem is that the IBT-2 were burned and want to replace, want to recommend me some H-bridges for use with smolka 24v engines, which were not the IBT-2, now I'm testing 1 monstermoto shield, but I guess it will be better to get the performance 24v engines
    Last edited by a moderator: Oct 7, 2015
  16. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    12V = half speed! F. eg VNH5019 supports 24V or Sabertooth and some unknown Chinese bridges...
  17. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
  18. jaco73

    jaco73

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Thanks Pit:cheers
    El problema que tengo ahora,que fue el motivo por el cual se quemaron los ibt-2,en el ordenador portatil con windows 8.1,funciona todo correcta mente,el problema esta en el sobre mesa,que tiene windows 10,os pongo un video para que vean mejor,normal mente solo funciona unos segundos,en el video duro mas.tambien si tengo encendida la fuente de alimentacion SMC3Utils no reconoce al arduino



    The problem that I have now, which was why the IBT-2 was burned in the laptop with Windows 8.1, everything works right mind, the problem is in the above table, you have Windows 10, you get a video to look better, normal mind only works a few seconds, hard video mas.tambien if I have turned on the power supply does not recognize the arduino SMC3Utils




    Last edited by a moderator: Oct 7, 2015
  19. Pit

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

    Joined:
    Oct 2, 2013
    Messages:
    3,012
    Location:
    Switzerland
    Balance:
    30,451Coins
    Ratings:
    +3,091 / 31 / -0
    My Motion Simulator:
    DC motor, Arduino, 6DOF
    @jaco73 first reduce the Ki integral term, it can be set to 0. If SMC3 works under Win10 I do not know, because I do not use win10...I have a perfectly running win7 system and any changes are resulting in a disaster for sure ;)
  20. jaco73

    jaco73

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Al principio tenia ki a 0,cambie valores para testar,voy probar a cambiar el windows 10,aun que un dia funciono correcta mente


    At first I was ki 0, change values to test, I'll try changing the Windows 10, even one day I run right mind