Arduino Rotary Table for Dummies

Discussion in 'Machine Modifications' started by bmac2, Apr 24, 2017.

Help Support HMEM by donating using the link above.
  1. Jan 31, 2018 #161

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    Bmac’s original sketch works only in steps*ratio is less than about 32000. If you make the changes as per message #70 it will work. There are some other issues but they are largely a matter of precision which might not even be noticeable.

    My sketch uses the same keyboard coding as bmac’s but the keypad is connected to the pins differently.
    John
     
  2. Feb 1, 2018 #162

    johnstij

    johnstij

    johnstij

    New Member

    Joined:
    Aug 6, 2012
    Messages:
    2
    Likes Received:
    0
    Gender:
    Male
    Location:
    uk
    Thanks for that John.
    I still could not get Bmac2's sketch to work. But after changing the key pad connections yours is good to go. What is a good value to enter for step delay ? I've set it at 1000.
    Thank you.
    Ian
     
  3. Feb 2, 2018 #163

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    A stepdelay of 1000 is equivalent to 500 steps per second which is what Bmac’s sketch used. Decreasing stepdelay will increase the steps per second but will also decrease the stepper’s torque.
     
  4. Mar 1, 2018 #164

    camm-1

    camm-1

    camm-1

    Well-Known Member

    Joined:
    Feb 15, 2012
    Messages:
    102
    Likes Received:
    38
    Hi
    In ordered all the **** at ebay and now trying to get something to work.
    After a couple of ours I finally find a driver for this Arduino uno Clone that works.
    And conect the Lcd display and downloded and uploaded the program
    but it only lights up and nothing happens then I klick on serial monitor,
    its only a empty window and the baud is on 9600.
    Have put on other cables if it should be that but no.

    Ove
     
  5. Mar 2, 2018 #165

    camm-1

    camm-1

    camm-1

    Well-Known Member

    Joined:
    Feb 15, 2012
    Messages:
    102
    Likes Received:
    38
    Im a dum dummie on this I know but I want to learn.
    Somtimes I can load a unzipped file but most of the time it says invalid library.
    And if I manage to load the 12c display it have a different adress and dont find the line bmac have on his photo to change it.
    I maybe have to give up this:confused:
     
  6. Mar 2, 2018 #166

    crankshafter

    crankshafter

    crankshafter

    Well-Known Member

    Joined:
    Jul 17, 2007
    Messages:
    367
    Likes Received:
    22
    Hi Ove.

    Don't give up buddy. It's only a matter of time and then the bulb will light up

    CS
     
  7. Mar 3, 2018 #167

    bmac2

    bmac2

    bmac2

    Well-Known Member

    Joined:
    Aug 16, 2013
    Messages:
    889
    Likes Received:
    570
    Hi Ove, I just checked and it’s line #7 in the sketch that you will have to edit. Only change the address (underlined) with the address you got from the scan and click on the upload arrow (top left under Edit)

    I2C Tes.jpg

    If you get a blank screen or the entire screen lights up first check that the LED jumper (circled on the left) is on the 2 pins and then try turning the contrast pot (circled on the right) with a small screwdriver.

    Hang in there . . . Bob

    I2C Pot.jpg
     
  8. Apr 4, 2018 #168

    NutNoxNut8

    NutNoxNut8

    NutNoxNut8

    New Member

    Joined:
    Apr 4, 2018
    Messages:
    1
    Likes Received:
    0
    Firstly thank you for the clear build instructions very happy !- I have made 2 of these 1 for indexing on my milling machine -works perfect and 1 for my tig welding rotary table this i have a couple of problems with. 1) i need to control the rpm to adjust my travel speed before welding which varies with size and thickness of the aluminum tubing i am welding ( is it possible to hook up a potentiometer in your configuration ?) and the next is the fact that the high frequency of the tig machine ( welding mostly aluminum ) interferes with the control box - i suspect its the fact that i have not got a decent earth bushing construction on my rotary table or is it the high frequency that upsets things anyway ?.

    Wonder if anybody has a simple solution for this or has had the same question ?

    Many Thanks in advance
    Nick
     
  9. Apr 10, 2018 #169

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    Attached are pictures of my controller. I had an arduino Pro Micro so I used it. A nano would work just as well. Both of them have standard pin spacing which makes it easier to connect the keypad. I'm using as 18V lithium supply so I used an 8V regulator to drop the voltage to the arduino.

    I used a 330 oz-in stepper and a pololu driver. The pulley ratio is 4.2 and I'm using 16 microsteps for 3200 steps per rev. These have to be entered as integers but since they are multiplied together, I entered a table ratio of 42 and 320 steps. With a step delay of 500 usecs, it has enough torque that it is difficult to hold the spin index wheel tight enough to get it to miss steps. With a step delay of 250 usecs I'm pretty sure it missed an occasional step when starting to move.

    I've also attached a picture of my 18V powerpack. Originally I only intended to use it at our local "show and tell". It works so well though, that its likely the only supply I will use with the indexer. I found the 3D stl file for it at https://www.thingiverse.com/thing:352094

    Kudos to bmac for writing up the assembly instructions.

    IMG_0522.jpg

    IMG_0521.jpg

    IMG_0523.jpg

    IMG_0524.jpg

    View attachment EEPROM_2118-final.zip
     
  10. Apr 12, 2018 #170

    scoopydo

    scoopydo

    scoopydo

    Member

    Joined:
    Nov 12, 2009
    Messages:
    5
    Likes Received:
    1
    tjwal,

    I really like the way you've built your controller . Part 3D print and part aluminum. Would you happen to have a schematic? I've been working on your take on this but I can't get the keypad to work. Can't figure what I'm doing wrong, I've tried wiring the keyboard both ways to no avail? I know it's somthing simple but just can't get past that.

    Thanks George
     
  11. Apr 12, 2018 #171

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    George
    I too had difficulty getting my keypad to work. I finally wrote a sketch to test the keypad. I posted it in message #128. It echos the key presses to the serial monitor so you can see what is happening. You adjust the row and column pin assignments until it works and then copy those over to the indexer sketch.

    I didn't use a schematic when I put my controller together. However, looking at the pictures and my code I came up with the attached. It is for the pro-micro that I used. It allows me to plug the keypad in without using jumpers. I think a nano would be better choice than the pro-micro just because of the idiosyncrasies of uploading to a pro-micro. I believe the nano pinout also allows for 8 consecutive pins to be used for the keypad.

    John

    I

    View attachment Index Controller.pdf
     
  12. Apr 13, 2018 #172

    scoopydo

    scoopydo

    scoopydo

    Member

    Joined:
    Nov 12, 2009
    Messages:
    5
    Likes Received:
    1
    Thanks, John! I do have a Pro Mini but was trying to use a nano. It does support 8 consecutive pins for analog support. I'm using the same driver as bmac used, mainly because I've bought one or two whenever I found them on sale. I do have a Pololu driver in stock but I like the higher amperage.

    Agin thanks! George
     
  13. Jun 10, 2018 #173

    ramkitty82

    ramkitty82

    ramkitty82

    New Member

    Joined:
    May 27, 2018
    Messages:
    2
    Likes Received:
    0
    Gender:
    Male
    I got mine working after some messing around. Default code threw a warning for variable overflow which for some reason prevented any stepper movement. Changing the multiplier formula to include a type cast as follows corrected my issue
    const int Multiplier = ((unsigned long)StepsPerRotation * TableRatio)/360;
     
  14. Jun 10, 2018 #174

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    Be aware that (StepsPerRotation*TableRatio) must be exactly divisible by 360 for the original sketch to be reasonably accurate.
     
  15. Jun 10, 2018 #175

    tjwal

    tjwal

    tjwal

    Active Member

    Joined:
    Sep 22, 2013
    Messages:
    42
    Likes Received:
    5
    A follow up to my post #169, after using the indexer for about 20 minutes it started losing steps. I assume the little stepper driver was over heating. I’ve rewired an external driver but haven’t got around to testing it.
     
  16. Jun 11, 2018 #176

    harrzack

    harrzack

    harrzack

    Member

    Joined:
    May 14, 2013
    Messages:
    9
    Likes Received:
    2
    Here is a link to yet another take on creating an indexer with an arduino:

    The concept needs a bit of refinement for real accuracy on odd-tooth spacing but I have an idea for that... when I get my 'round-2-it' !
     
    scoopydo likes this.
  17. Jun 11, 2018 #177

    ramkitty82

    ramkitty82

    ramkitty82

    New Member

    Joined:
    May 27, 2018
    Messages:
    2
    Likes Received:
    0
    Gender:
    Male
    Good advice since that information is burried in depth of forums rather than front page. My 6" rotary table is just double the handle rotations maintaining the null modulus but this caused steps*ratio to be to large
     
  18. Jun 12, 2018 #178

    scoopydo

    scoopydo

    scoopydo

    Member

    Joined:
    Nov 12, 2009
    Messages:
    5
    Likes Received:
    1
    Cool idea and simple menu system. I checked out your website but there doesn't seem to be much information there? And the video seems to be several years old. Are you going to have more information available? I'd like to build another rotary table and would like to try something different.

    George
     
  19. Jun 13, 2018 at 3:08 PM #179

    harrzack

    harrzack

    harrzack

    Member

    Joined:
    May 14, 2013
    Messages:
    9
    Likes Received:
    2
    Yes - the project is a tad old! I've gotten off into a number of other things and had to put that on the back burner.
    I can give you the Arduino source (but it may be a bit obscure!) If you are interested in giving it a go I'll be glad to help out as I can.

    One of the big probs I see with this is the interpolation needed for odd step sizes. Which is what those 'plates' are for on a mechanical dividing head. So - I've been thinking if I can get the degrees/step down to a fine enough level the error would be (largely) insignificant. The rotary table gives 4 deg per rev which could then be divided down with stepper pulley ratios. It would be slow moving - but so? :)

    If interested I'll dig out some of the calcss I did for this and pass them on.
    Thanks for looking!

    =Alan R.
     
  20. Jun 13, 2018 at 4:21 PM #180

    scoopydo

    scoopydo

    scoopydo

    Member

    Joined:
    Nov 12, 2009
    Messages:
    5
    Likes Received:
    1
    harzzack, thanks for the reply. I think I'll have to give it a pass. The setup I have works great so I think it'll just get duplicated for the next one.

    George
     

Share This Page