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

Tronic's AMC motor motion-controller with pwm/servo output

Discussion in 'SimTools compatible interfaces' started by tronicgr, Aug 30, 2007.

  1. Nicko355

    Nicko355 New Member

    Joined:
    Oct 17, 2009
    Messages:
    27
    Occupation:
    Automotive Tech
    Location:
    Sydney , Australia
    Balance:
    483Coins
    Ratings:
    +15 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi Fredspeed
    If you have not already done so, check you programming circuit with a multimeter . Unplug power supply off.Remove all the jumpers on the board . Remove TX and RX leads. All the dip switches off. Install your programming leads (from mosi to mosi, miso to miso, sck to sck ,reset to reset ,gnd to gnd) The way I checked mine was with the cable connected to the ISP port.Look at the computer end of your cable and you will see the numbers 1-9.
    Look at your circuit diagram and you can trace these all the way back to Atmega and other parts.
    Cable pin3 to the ISP transistor middle pin(Base) should be 10k
    Cable pin4 to pin 6 on the Atmega (looking from the top pin1 is top left, through to lower left should be 4.7 k
    Cable pin5 to the ISP transistor middle pin(Base) should be 15k
    Cable pin5 to pin 11 on the Atmega should be 0.0 k
    Cable pin6 to pin 8 on the Atmega should be 4.7k
    Cable pin8 to pin 7 on the Atmega should be 0.0k
    Now check your power 5V
    Power on (multimeter on Volts)Carefully probe pin 10 on the Atmega should be 5V
    Atmega pin 9(reset) to any available Gnd eg last pin on J1 (servo power)should change state 3.5v to 0v when pressing the reset switch
    Remove crystal each side of the socket should be a low voltage like 0.7v
    Test all this and let me know your results CHEERS Nick
  2. watkykjy

    watkykjy Member

    Joined:
    Nov 29, 2009
    Messages:
    30
    Balance:
    - 10Coins
    Ratings:
    +0 / 0 / -0
    Stupid internet connection that drops mid-posting... And then I end up posting most posts twice.. Sorry guys... Blame South Africa crappy bandwidth :)
  3. fredspeed

    fredspeed New Member

    Joined:
    Sep 1, 2009
    Messages:
    263
    Location:
    Northern Norway
    Balance:
    418Coins
    Ratings:
    +3 / 0 / -0
    Hi Nick, I wonder if you are able to reas minds? I vas just thinking about asking on the forum how I can use the multimeter to check all the connections needed to program!!! I will go thru your list this afternoon. Again Thank you!
  4. watkykjy

    watkykjy Member

    Joined:
    Nov 29, 2009
    Messages:
    30
    Balance:
    - 10Coins
    Ratings:
    +0 / 0 / -0
    Ahoy again mates,

    Another upate from me.. Thanks A LOT for the info Tom, I managed to get my motors connected to the X-sim, and after resetting the amc a few times and unplugging and re-connecting the serial cable, it started WORKING!!! I literally got goosebumps when I saw the motors respond to the sliders in the math section!!!

    I figured out why my screen goes blank when I run the motors. The one wiper motor I was using as a test was a MOFO motor, and it was pulling so many amps when I did sudden direction changes, that the amc's screen went blank. For some reason that was the only thing that went haywire, but the amc stayed online, and I still retained control over the motor through x-sim.. Weird. Anyway, I am out shopping for new wiper motors this morning, so if any of you have some suggestions as to which motors to use, fire away! :) Also, I am looking at a nice logitech wheel with a very cool momo steering wheel and everything. Even comes with adjustable stiffness in the pedals, so you can make it feel softer or harder if you prefer!



    I guess all that's left now (besides making everything look nice and pretty and finishing off the frames) is to install some games and run force sender with the game exe and profile specified?

    Thanks again for all the help guys, it's really appreciated, looking forward to joining in my first online sim game!

    :cheers: :cheers:
  5. Nicko355

    Nicko355 New Member

    Joined:
    Oct 17, 2009
    Messages:
    27
    Occupation:
    Automotive Tech
    Location:
    Sydney , Australia
    Balance:
    483Coins
    Ratings:
    +15 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi everyone I posted earlier but does not apear to have been submitted. My query is ,I cannot connect to xsim could anyone give me the basics of how to connect I have tried everything I can think of Help CHEERS Nick
  6. Frakk

    Frakk Active Member

    Joined:
    Apr 15, 2009
    Messages:
    1,144
    Balance:
    328Coins
    Ratings:
    +4 / 0 / -0
    Nicko, read the manual and search the forum in the right section. There are lots of info about the program.
  7. Nicko355

    Nicko355 New Member

    Joined:
    Oct 17, 2009
    Messages:
    27
    Occupation:
    Automotive Tech
    Location:
    Sydney , Australia
    Balance:
    483Coins
    Ratings:
    +15 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Yep i have searched and read for 2 days I will keep researching , but my eyes are not copeing . Do you think if i am able to use Hyperterminal successfully and the data LED flashes when xsim is searching for my hardware that i am on the right track ?
    CHEERS Nick
  8. Frakk

    Frakk Active Member

    Joined:
    Apr 15, 2009
    Messages:
    1,144
    Balance:
    328Coins
    Ratings:
    +4 / 0 / -0
    I don't know if x-sim is searching for hardware, but it should be ok if you see data is coming in. I haven't used the AMC so I can't really tell what you should see. I haven't seen Thanos post for a long time, he would be your greatest help.
  9. 914tom

    914tom Member

    Joined:
    Nov 19, 2009
    Messages:
    37
    Balance:
    - 30Coins
    Ratings:
    +0 / 0 / -0
    hi nick

    should work for you too. ;D

    tom
  10. watkykjy

    watkykjy Member

    Joined:
    Nov 29, 2009
    Messages:
    30
    Balance:
    - 10Coins
    Ratings:
    +0 / 0 / -0
    Hi guys,

    Tom is right, the tutorial should get you going as well... Although, I must be honest when I say that i am now able to control my motors by adjusting the sliders in the math section, but I would ultimately like to do some kind of demo game or something so that I can see how the motors respond when driven by an actual game. I just don't know (yet) how to do that, but the fact that everything is working is good enough... The rest I will figure out, or one of you kind gentleman will share with me how to do it :)

    One last thing on the AMC though. If you can see it in hyperterminal, then in theory you should be able to see it in x-sim too, however, as I stated in my previous post, I had to take out the null modem cable, then press the reset button on the AMC one or twice, and only then plug in my cable again for the thing to start working. This of course happened after openening force sender, clicking on send data, then opening up the profiler, and, provided you downloaded the profile mentioned in the previous post by Tom, it should start automatically. The only other pre-requisite I can mention is to actually have your steering wheel connected to your machine when doing all of this..

    I also discovered something very dumb today, and again I'd like to call on the experience of you guys that have done this thing before. I tried over 10 different sizes, brands, etc of wiper motors today, and ALL OF THEM, without exception, was able to short out the power supplies I had connected to them. I was using old AT power supplies (rated at 12V, 9A max), and I had 2 of them in parallel for every motor (thus 18A usable for every motor), 4 power supplies in total, but yet, when I ran the motors full speed in one direction, and rapidly change it to the other direction, it would cause a dead short for a very short amount of time (as the motor comes to a standstill and start spinning in the other direction again), and this would cause the pc power supplies to immediately shut down... The ONLY way I have been able to compensate for this so far was to run the motors on a car battery...

    Has anyone come across this before and what did you do to overcome this problem?

    Thanks guys, I think I should start uploading some pics of our frames, etc? ;)
  11. Frakk

    Frakk Active Member

    Joined:
    Apr 15, 2009
    Messages:
    1,144
    Balance:
    328Coins
    Ratings:
    +4 / 0 / -0
    You didn't discover anything dumb, that's how DC motors work. I could go into the physics but the point is, they draw the most current when they don't spin (the two contacts are in fact shorted, except for the coil resistance). They draw even more if they are spinning the opposite way...

    When the motor starts spinning, it creates a revers voltage opposing the supply voltage, therefore less current flows. When you reverse the polarity while the motor is spinning, this voltage will draw current instead of opposing it... not a good thing. If those power supplies didn't have protection, you would have blown both...

    Every DC motor controller should take this into consideration. The motor should be stopped before reversing it's direction by shorting the two terminals together (connect both to either + or -).
  12. 914tom

    914tom Member

    Joined:
    Nov 19, 2009
    Messages:
    37
    Balance:
    - 30Coins
    Ratings:
    +0 / 0 / -0
    hi again guys,

    the thanks are not for me, because i dont know nothing special,i only make my research public .
    for your shortcut problem, an the fact that your AC/DC adapter shut down.
    again in another threat i saw a person who use a LARGE Car HiFi capacitor (1F or so) parallel to the AC/DC adapter.
    maybe this can solve your problem ?
    not testet only suggested ....

    TOM
    ... looking for motors *g*
  13. fredspeed

    fredspeed New Member

    Joined:
    Sep 1, 2009
    Messages:
    263
    Location:
    Northern Norway
    Balance:
    418Coins
    Ratings:
    +3 / 0 / -0
    Nick- Here is my results testing AMC:

    Cable pin3 to the ISP transistor middle pin(Base) was 9.95 k
    Cable pin4 to pin 6 on the Atmega (looking from the top pin1 is top left, through to lower left) was 4.69 k
    Cable pin5 to the ISP transistor middle pin(Base) was 14.82 k
    Cable pin5 to pin 11 on the Atmega was 0.0 k
    Cable pin6 to pin 8 on the Atmega was 4.7k
    Cable pin8 to pin 7 on the Atmega was 0.0k
    Check power 5V
    Atmega pin 9(reset) last pin on J1 (servo power) change state 4.94 to 0v when pressing the reset switch
    Removed crystal, each side of the socket was a low voltage like 0.8v

    Seems like most of it was nearby your values exept pin 9 on atmega that was 5v not 3.4! I dont know if that is a problem or not. The good news must be that my soldering cant be to bad and the connections ok, and the bad news must be that I am still not able to find the solution. Could my Atmega be broken? :?
    Anyhow this was a really good help, because i have minimized the number of reasons it wont work. :)

    Fred
  14. Nicko355

    Nicko355 New Member

    Joined:
    Oct 17, 2009
    Messages:
    27
    Occupation:
    Automotive Tech
    Location:
    Sydney , Australia
    Balance:
    483Coins
    Ratings:
    +15 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hey Fred plug in the 14 Meg crystal open ponyprog go to
    SETUP Calibrate > should be ok
    SETUP Interface >I/O or api > Probe>should be ok
    DEVICE>Avrmicro>ATmega 8535
    COMMAND>Programme options >Check box (tick on) 1>7>8
    COMMAND>Security and configuratin bits> here you will either get an error message click ignore or a check box click on read, here it should read without an error message watch the red LED see if it flashes if error occurs try it without the crystal capacitors if error occurs again I think this is where you may have to try another ATmega Let me know how you go CHEERS NICK
  15. Nicko355

    Nicko355 New Member

    Joined:
    Oct 17, 2009
    Messages:
    27
    Occupation:
    Automotive Tech
    Location:
    Sydney , Australia
    Balance:
    483Coins
    Ratings:
    +15 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino
    Hi am I to use a nullmodem cable or straight thru when connecting to x sim ?
    CHEERS Nick (Man its hot in Sydney today)
  16. fredspeed

    fredspeed New Member

    Joined:
    Sep 1, 2009
    Messages:
    263
    Location:
    Northern Norway
    Balance:
    418Coins
    Ratings:
    +3 / 0 / -0
    Hey Nick. I will give it another try in Ponyprog after work, unless my Wife gives me a lot of work preparing christmas! ;P The only place I have found atmega in online shops (Not all send to private) is Digikey, but they charge minimum 18 Euro for posting, so it will be an expensiv atmega. if you know another place that ship worldwide let me know. Happy christmas. (Man its cold in Northern Norway today!!!) :cheers:
  17. 914tom

    914tom Member

    Joined:
    Nov 19, 2009
    Messages:
    37
    Balance:
    - 30Coins
    Ratings:
    +0 / 0 / -0
    Hi Niko,

    you luckyone, last week we had -11° an snow, today 0° an Rain.
    Snow + Rain .... its a mess on the streets, but fun to drive *g*
    N O, you don't us a NULL Modem cabel but a Straight through cable with a male/female connector.
    TOM
  18. watkykjy

    watkykjy Member

    Joined:
    Nov 29, 2009
    Messages:
    30
    Balance:
    - 10Coins
    Ratings:
    +0 / 0 / -0
    Hi again guys,

    Time for my daily update :)

    Today we sanded down our frames (we have built both of them from steel tubing), and filled up the gaps with body putty and made everything look pretty. I just got a picture from the guy that is building with me showing the primer being painted onto the first frame. With a bit of luck, we should finish the painting of the frames tomorrow, and then we can start adding all the rest together (pulleys and stuff).

    For anyone looking for pilot shaft bearings, we were able to find them at a metal shop, and they stocked the loose pulleys used for electric gates. They are a little expensive, but worthwhile, especially if you can't find any of those type of pulleys staright off..

    Anyway, i suppose I will have to open my own thread to show the progress begin made sometime.

    Until then, good night, God bless and GOODBEYE!! :)
  19. 914tom

    914tom Member

    Joined:
    Nov 19, 2009
    Messages:
    37
    Balance:
    - 30Coins
    Ratings:
    +0 / 0 / -0
    this threat is worthless without a picture (even wwhen off topic ...) *G*
  20. watkykjy

    watkykjy Member

    Joined:
    Nov 29, 2009
    Messages:
    30
    Balance:
    - 10Coins
    Ratings:
    +0 / 0 / -0