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

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0

    Hi Jeroen

    You can find the latest version of AMC1.5 here:
    post7978.html#p7978

    And more particularly you need to use this file: amc1_5_bottom.pdf [75.31 KB]

    Regards, Thanos
  2. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi zaphod42,

    I program my AVR motion controller using simple BASIC. More particularly the BASCOM compiler. About sharing the code, I'm not sure. I shared my source code before with ElectronicJack but still haven't heard any news from him, nor seen any advancements from his side... The only thing I can do is to adjust my code to be able to run on ATmega128. But you have to be able to use specific crystals like the 22.1184Mhz on it rather the one on the DEV board or its internal RC clock. So if you give me some more information on the type or the model of your DEV board I could help you.

    I can give you the plans of AMC1.5 in SPRINT-Layout v5.0 format or Gerber.

    Regards, Thanos
  3. Jeroen

    Jeroen DoctorXeno

    Joined:
    Oct 3, 2007
    Messages:
    120
    Location:
    Holland
    Balance:
    - 55Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Thought that I needed 2 pcb's... 1 for the controller and 1 for the h-bridge... :blush:
  4. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Oups, I forgot...

    Here is the latest plans for the DSMhb1.2b:
    post7981.html#p7981

    Use this file: DSMhb1_2b_sprint_bottom.pdf [61.68 KB]

    Regards, Thanos
  5. Jeroen

    Jeroen DoctorXeno

    Joined:
    Oct 3, 2007
    Messages:
    120
    Location:
    Holland
    Balance:
    - 55Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Great... now i can find a company who wil make them.

    Do i need the small 1 too? Thats for the lcd right?
  6. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi,

    @Jeroen

    I post here the latest layout for the parallel LCD board (made with Sprint-Layout5)

    Parallel_LCD_photo_bottom.gif

    Parallel_LCD_photo_top.gif

    Parallel_LCD_sprint_combined.gif


    In this PDF there are all related layers.
    Parallel_LCD_sprint.pdf

    And here is only the bottom side that you should give to an etching service to make it for you.
    Parallel_LCD_sprint_bottom.pdf

    GERBER FILES:
    Parallel_LCD_sprint_gerber_excellon.zip



    NOTICE
    All the PDF layout plans I give are meant to printed as 1:1 on printer paper (or transparent paper)


    Best Regards, Thanos

    (EDIT: FIXED the swapped RS,E labels)
  7. zaphod42

    zaphod42 New Member

    Joined:
    Sep 21, 2007
    Messages:
    17
    Balance:
    3Coins
    Ratings:
    +0 / 0 / -0
    Thanos, I'm not familiar with BASCOM, and fair enough about sharing the code. The ATmega128 board I use is made by Juni Australia, its not on the web, it was a once off run for an industrial project and I ended up with a few boxes full of them when they were discarded. They have the ADC's on port A, the LCD ( 4 bit mode) is on PD4,5,6,7 enable on PD0 and RS on PD1, there are seven general i/o on PG0,1,2 and PC4,5,6,7. The full 8 bits of port A are available as output only (buffers). The RS232 port is on PE0,1. The circuit diagram unfortunately is hand drawn.
    I can drop in any RS232 compatible crystal , it currently runs a 11.0592 mhz xtal. The 128 is only rated to 16mhz so I don't know if it'll go any higher.
    It is housed in a DIN rail enclosure with plug in i/o conectors and a bunch of leds showing I/O conditions. ( i'll post a photo if you want)
    As you can see there are quite a few changes required to use these for the AMC. If I can get these going I may be able to supply the sim market down under seeing how hard it is to get electronic gear down here.

    Does BASCOM generate an ASM file or only the hex file??

    Yes I should be able to import Gerber files to change the AMV1.5 to a standard 10 pin AVR programming headder.

    How far off is AMC2.0?? I may wait if its not far off??

    Thanks Zap.
  8. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Zap,

    I'd like to help you much but my time is limited to try programming something like this from distance, and involving in endless communication through email or PM's to get it in working condition.

    I have a proposition for you. I can make it work for you, if you send me one or two of your boards. I already have STK500 programmer with 10pin header, and I can use on it bigger crystals of around 14Mhz or 18Mhz to make it faster.

    But before that, I want to tell me if you have access to the following ports:
    PB5, PB6, PB7 and PE3, PE4, PE5
    I'm very interested in those ports cause they are the hardware output PWM ports! SIX channels! Enough, even for 6DOF control!

    Also make sure you have access to the following ports that are to be used with ADC:
    PF0, PF1, PF2, PF3, PF4, PF5, PF6, PF7

    And it would be better if the PD0 and PD1 ports were available too as I could use them for TWI communication protocol with slave subsystems (encoder controllers).

    -Bascom generates only HEX files.

    -Here are the GERBER data from my AMC1.5:
    AMC1_5_gerber_excellon.zip

    -My UAMC2.0 controller needs a lot of work yet until is in stable state, but I could work on both interfaces the same time. For start I can adjust the 2DOF code of the AMC1.5 (Firmware version 1.0) for your board that later can be extended to 3DOF or 6DOF.


    Best Regards, Thanos :cheers:


    PS. ATmega128 was my first choice when I was looking for appropriate chip for 6DOF controller. But I was stumbled on the fact that was SMT package (QFN) and not easy to be used with homemade PCB's!!
  9. zaphod42

    zaphod42 New Member

    Joined:
    Sep 21, 2007
    Messages:
    17
    Balance:
    3Coins
    Ratings:
    +0 / 0 / -0
    Thanos, Yeah sorry the ADC's are on port F , Brain fade. And just checking the board only 6 of the ADC's are wired to the external conectors, PF6 and PF7 are not connected at the micro.

    Unfortunatly all the fast PWM's (PB5, PB6, PB7 and PE3, PE4, PE5) are wired to LEDs on the board. (could be possible to rewire). I'll write a test prog to see what frequency these fast PWM's run at. Acording to my calculations they should run at 43khz. I'll let you know
    The PD0 & PD1 are available as well as the second uart PD2 and PD3.
    The first uart PE0 & PE1 is connected to a DB9 via a MAX232.

    It looks like its only going to do half the job without major modifications. I'll keep looking at it though.


    On another subject , how do you get more that two DOF's from the USO of x-simulator?
    I might write some code to just to suit my H drivers and test a board.


    Zap.
  10. faller

    faller New Member

    Joined:
    Jan 20, 2008
    Messages:
    5
    Balance:
    0Coins
    Ratings:
    +0 / 0 / -0
    Hello,
    I've just finished Tronic's AMC motor motin controller and it turned out ok for my first time.
    I'm using the 18Mhz crystal and was able to program it successfully. But I seem to be having some serial communication problem.
    First, when I use X-sim profiler to test the X,Y slider to see if the first two number on the LCD of the AMC would change respectively but nothing happens. After multiple attempts and powere on and off I was able to see those numbers change as I move the sliders in X-Sim profiler. But it wasn't consistent, it seems to be intermittant. Sometime it would work and sometime it wouldn't and sometimes only the X value would change and not the Y value and vice-versa.
    Then I try to see if I could change the Kp proportionality through hyper terminal. I followed the instruction on how to go in there and the setup changes and it doesn't seem to want to connect. What could be the problem here? Is it a bad crystal or my pcb?
    I thought I had bad serial cable, I went out and bought another one and same result. Sorry for all the questions?

    Here is a picture the AMC:
    [​IMG]
  11. egoexpress

    egoexpress Active Member

    Joined:
    Dec 13, 2006
    Messages:
    3,839
    Location:
    Germany - Frankfurt/M
    Balance:
    421Coins
    Ratings:
    +10 / 1 / -0
    Hi

    Good job!

    Thanos is in vacation currently, so you may have to wait some days till he answers.

    Regards
    Christian
  12. Jeroen

    Jeroen DoctorXeno

    Joined:
    Oct 3, 2007
    Messages:
    120
    Location:
    Holland
    Balance:
    - 55Coins
    Ratings:
    +6 / 0 / -0
    My Motion Simulator:
    2DOF, DC motor, Arduino, Motion platform
    Hi Thanos,

    First of all.... Hope you had a good vacation. I have a few questions right away for you. Hope you can answer them for me.
    I found a etching service, not cheap, but ok. The only thing they are asking about is a gerber file of the lcd-print? The other
    2 were fine.

    -How much microns should the soldermasks be?
    -Are there some other things that i should inform them about?
    -And is there a solderguide for the avr-controller?

    Hope to hear from you soon. Thank you so far.

    Greetings,

    Jeroen
  13. lotada

    lotada New Member

    Joined:
    Jul 31, 2008
    Messages:
    41
    Occupation:
    coffe Roaster
    Location:
    Kralupy nad Vltavou
    Balance:
    248Coins
    Ratings:
    +0 / 0 / -0
    Hi to all i am new here between you i build own AVR motion controller(1.5v) and Simple mosfet-bridge(v1.2b) i whave few questions.. i dont know which potentiometers i have to buy for the output for joyrider? and also i want to ask why are the MOSFETS IRF 4905 and IRFZ44 on the 3pole connectors can i give it direct to the baord..? Also i want ask about DPS for AVR controller v1.5? why isthere version with filled ground why itis? what type have i to use? I will take few photos when i finish my board.. so please help me with building.. Bye Mila from Czech republic....
  14. zaphod42

    zaphod42 New Member

    Joined:
    Sep 21, 2007
    Messages:
    17
    Balance:
    3Coins
    Ratings:
    +0 / 0 / -0
    Thanos, Are you back from holidays yet? Did you enjoy them?

    I have further investigated this Mega128 board and I can get access to only 7 of the ADC's and only 5 of the output compare ports , PF7 & PE3 are not conected without major modifications.
    I've writen some test code and the fast PWMS do run at 43khz without the prescaller and that is with a 11.059Mhz xtal.

    I am trying to write some motor PID code but the maths needed in assembler is proving difficult.
    I've looked into sending you a couple of boards but the freight from Au to Greece might have to wait a few paydays.

    Where do I get information about the serial/RS232 and the data that needs to be converted to position?.

    If I develop a controller based on this board I might use the second UART for calibration, setup and diagnosis instead of the LCD display. There are a dozen LEDs for warnings ect as well. What are your thoughts?

    Would you like me to PM you the circuit diagrams or wait untill I have something that works?
    Should I post a photo of the Board?

    Also why do you use 10 bit when the data from x-sim is only 8 bit?

    Zap.
  15. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Faller,

    First of all, to be able to connect to hyperterminal mode you have to connect both RX & TX connector wires. Also be sure that the resistor right next to the LED in the MAX232 section is 270 Ohm!!! Does this Led light?
    avrpcb15_serial_problems_fix.gif

    Another thing you can try, is to avoid using ceramic capacitors next to the crystal. Use polymer (polypyrrole) type as they are more stable and accurate. I can't figure out the type you used from the photo, its small, maybe a larger photo? You can take even better detail photos with your SONY DSC-S750 ;)
    And the crystal should be 18.432 Mhz. Not just 18Mhz!!!!

    Are you using a native Serial Port on your PC or USB2Serial converter? Some USB2Serial converters dosn't work at all, and some require you to set the communication type (inside their device properties) as Serial Printer.

    What power source are you using? I see that you power the backlight of your LCD through the regulator of the AMC. I guess that the regulator (LM2940) must be burning!!! In any case try to use a 6volt 1Amp power source (or a set of four AA batteries)

    I hope that you didn't tried to power the DSMhb1.2b yet... You have placed the FAN UP-SIDE DOWN !!!! This way, it won't blow air on the mosfets!!

    Regards, Thanos
  16. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Jeroen,

    Here is the gerber data for the small parallel LCD board:
    Parallel_LCD_sprint_gerber_excellon.zip

    -I really don't know how much microns should be the solder mask.

    -And I would avoid putting Solder Mask on the DSMhb lines to be able to reinforce them later...

    -No there is no solderguide for the AMC1.5 cause I last time I assembled one I did it in a rush. Maybe I'll prepare one next time that I will assemble a AMC1.5.

    Thanos
  17. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Mila,

    You can purchase some simple 100KOhm 270degree potentiometers and add 1:3 reduction gears on their axle to be able to have them measure the 90 degrees rotation of the Joyrider on each axis!!

    You can connect the Mosfets directly on the board, but I prefer the terminal connectors cause I can replace them easily if I burn them accidentally!!

    What is DPS?

    There are two versions of the PCB, with filled ground and without, cause each one has its advantages. Filled Ground PCB is more immune to electrical noise, but harder to solder. If not careful enough, you can easily create a short-circuit bridge somewhere. On the other hand some prefer the no filled ground PCB layout cause its easier to develop with their own etching tools and easier to solder the materials on it.

    Regards, Thanos
  18. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Zap,

    Well, six ADC are enough, but with five PWM ports we will not be able to get 6DOF motion... If we could pull a wire out of one of the missing ports...

    Yes I know about the Fast PWM mode, but it works only in 8-bit mode I think? I'm using 10-bit PWM mode as it cooperates with the 10-bit ADC mode to implement an internal 10-bit positioning mode in the end!!! On the old x-sim profiler I was taking the 8-bit data, multiply them by 4, to transform them in 10-bit resolution also with little stepping. But this stepping is not visible because of the way I treat the motors with speed control!!!!

    Yes, PID is a little difficult to be implemented in microcontroller but its necessary for the positioning control. I don't mind if it takes months to sent me some of your boards, I will have time, in between, to finish my UAMC2.0. Normal mail package should be fine! I have received such packages from all around the world with no problems so far.

    What do you mean? The settings for the x-sim profiler or the configuration of the UART in the Atmega?

    Yes you can use the second UART for debugging or changing its settings on the run, but it will slow down a little the positioning control and you will need a second Serial port on your computer. Its ok for the development process but not likely usable by simple users... Perhaps you can attach a Serial LCD on the second UART!!

    Yes, I'd like to see the circuit diagram of it! And some photos of the board for sure!!!! :thbup:

    Regards, Thanos
  19. wannabeaflyer

    wannabeaflyer Active Member

    Joined:
    Jul 31, 2008
    Messages:
    248
    Location:
    UK - London area
    Balance:
    971Coins
    Ratings:
    +34 / 0 / -0
    Hi Thanos, and all the members of X-sim. been watching the progress of thanos and this aspect of motion simulation and have to say like everyone else that realise the contribution sorry massive work that you guys have done and are doing for the dreamers out there you guys actually make it possible so big up thanks and no Bull thats a genuine compliment..

    i have for the last 3 years on and off been building my motion cockpit based mainly on the work of JIM (jimspage.co.nz & Craig warners design ideas and am happy to say i have all the elements in place just a lot of fine tuning and rebuilding going on at the moment will post some pictures ASAP.. not being one to settle i have been looking at Ian (buggies.builtforfun.co.uk ) and last but no least Roland over at simnl ?? . i have bought all the parts to make your Dual H-bridge controller and and now trying to outsource or DIY etch the PCB.. i think i have collected every bit of info you have so generously given ut still need to ask silly question about the LCD used on the AMC controller.

    i may have missed it somewhere but can you let me know the model / type or alternatives i could use when i get to build your AMC controller ... :cheers: brilliant work thanos we need guys like you and this forum .. PS has anyone used geared electric wheel chair motors in their projects the 3 that i have spin at around 65 RPM @ 24 VDC will these be good enough for my attempt at a SIMforce GT type motion race seat to go with your electronics.. :D
  20. tronicgr

    tronicgr

    Balance:
    Coins
    Ratings:
    +0 / 0 / -0
    Hi Wannabeaflyer

    I remember you from MyCockpit! (if i recall right). Well, Jim is one of the pioneers in home motion simulators. Thanks to him I decided to use wiper motors on my joyrider! But he likes doing things his way. His software motion interface is the only one currently that does not support my electronics even if I volunteered to make help him on this in the past. :crazypilot:


    -Anyway, about the LCD matter, you can use any type parallel LCD you want, as long as it is HITACHI 44780 controller compatible!!

    Here is an example of a x-sim user that connected a blue backlight one!
    [​IMG]


    -About the wheel chair motors you have and spin at around 65 RPM @ 24 VDC, I don't see any reason why not using my DSMhb1.2b to drive them! How many watts are they rated? Do you know their Ampere demand?



    Best Regards, Thanos

    PS. Edit a little your post, as some of the sentences are appearing double times...