Arduino Rotary Table MEW 249

Advert

Arduino Rotary Table MEW 249

Home Forums Drawing Errors and Corrections Arduino Rotary Table MEW 249

Viewing 25 posts - 26 through 50 (of 109 total)
  • Author
    Posts
  • #277164
    Graham Titman
    Participant
      @grahamtitman81812

      Hello thank you everybody for your invaluable help i have just got both arduinos and the keypads to work after putting so many numbers to get the right hand key to work i arrived at

      850 return no key

      85 return right key

      230 return up key

      35o return down key

      450 return left key

      850 return select key.

      The only problem now is even with a 24volt supply it only revolves at about 14rpm as i had hoped to drive a small mill head up and down with one of them with a 3 to 1 reduction Thanks again Graham

      Advert
      #277190
      Andy Holdaway
      Participant
        @andyholdaway

        Graham,

        Have you changed the sketch to disable microstepping? At the top of the sketch you will see this line

        #define Microsteps 1 // Depending on your stepper driver, it may support
        // microstepping. Set this number to the number of microsteps
        // that is set on the driver board. For large ratios, you may want to
        // use no microstepping and set this to 1.

        The figure after #define Microsteps should be 1 to give the fastest speed.

        Andy

        #277238
        Graham Titman
        Participant
          @grahamtitman81812

          Thanks Andy i will give it a try this afternoon.Graham

          #277358
          peter ravenscroft
          Participant
            @peterravenscroft57700

            thanks carl

            regards

            peter

            #283220
            Nick Clarke 2
            Participant
              @nickclarke2

              Hi. I have built my indexer but I am getting weird results. Everything runs,the arduino is able to select all modes, all the keys do as they should but the stepper motor ( nema 23 ) runs very slowly and I am getting 72000 steps per rev, with ratio set 9 to 1. According to MEW article I should be getting 18000 steps per rev. Where have I gone wrong? I am using Gary Liming’s code ver 2.3. Any help would be well recieved….

              #283237
              Andy Holdaway
              Participant
                @andyholdaway

                Nick,

                At the top of the code are these lines:

                #define StepsPerRevolution 200 // Change this to represent the number of steps
                // it takes the motor to do one full revolution
                // 200 is the result of a 1.8 degree per step motor
                #define Microsteps 8 // Depending on your stepper driver, it may support
                // microstepping. Set this number to the number of microsteps
                // that is set on the driver board. For large ratios, you may want to
                // use no microstepping and set this to 1.

                Make sure that the motor you are using is 200 steps per revolution, and set Microsteps tp 1.

                Also make sure that the DIP switches on the TB6560 are not set for microstepping.

                Andy

                #283243
                Nick Clarke 2
                Participant
                  @nickclarke2

                  Many thanks, I will have to get a magnifying glass as I cannot see the dip switch chart printed on the board. Stepper motor did not seem to work at first, but after copying switch positions from article I got where I am now. I couldn’t make out the positions of the three black switches so made a guess…

                  #283250
                  Roger Williams 2
                  Participant
                    @rogerwilliams2

                    Hello all, thanks to Carl and others on here, Im happy with the way my Arduino RT project has finished up. One strange thing I noticed when using it recently is the way the CW and CCW buttons work in the RUN mode.When using divisions , angles or jog, the left (CW) button turns the table clockwise, and the right (CCW) anti clockwise as it should. However, in the RUN mode, the FIRST press of the left button turns the table anti clockwise, so does the other button. But if I press the left button again, it turns the table clockwise as its supposed to, and then normal after that.!!! This happens every time I select the RUN mode, then corrects itself.

                    Anyone else had this problem ?. Many thanks.

                    #283251
                    Carl Wilson 4
                    Participant
                      @carlwilson4

                      I will try to take a good photo of the driver board and get it posted here as a reference.

                      It sounds like the motor in the above post is not 1.8 degree per step. NEMA 23 is just a frame size, it doesn’t specify any of the other parameters.

                      Carl.

                      #283253
                      Nick Clarke 2
                      Participant
                        @nickclarke2

                        The label says ‘Stepping Motor type 57BYGH56-401A. I checkes specs on vendors ebay page and it is listed asv1.8 degrees per step…

                        #283257
                        Carl Wilson 4
                        Participant
                          @carlwilson4

                          Okay dokay. Sounds like a conflict between dip switch settings and software microstepping parameter.

                          #283259
                          Nick Clarke 2
                          Participant
                            @nickclarke2

                            Many thanks for your help. Have to take the Mem Sahib shopping so I will delve into the software upon my return…..

                            #283269
                            Neil Wyatt
                            Moderator
                              @neilwyatt
                              Posted by Roger Williams 2 on 09/02/2017 10:06:43:

                              Hello all, thanks to Carl and others on here, Im happy with the way my Arduino RT project has finished up. One strange thing I noticed when using it recently is the way the CW and CCW buttons work in the RUN mode.When using divisions , angles or jog, the left (CW) button turns the table clockwise, and the right (CCW) anti clockwise as it should. However, in the RUN mode, the FIRST press of the left button turns the table anti clockwise, so does the other button. But if I press the left button again, it turns the table clockwise as its supposed to, and then normal after that.!!! This happens every time I select the RUN mode, then corrects itself.

                              Anyone else had this problem ?. Many thanks.

                              This sounds like the software is losing track (unlikely), resetting the stepper driver or switching between microstep and normal modes.

                              #283354
                              Nick Clarke 2
                              Participant
                                @nickclarke2

                                I think I have cracked it! Altered microstepping to 1 ans put both microstepping dip switches to off. Set ratio to 90 to 1 and set 1 step. Display reported 18000 steps/div, which corresponds to magazine article. I will no doubt find out for cure once motor is grafted on to rotary table. Many thanks Andrew….

                                #283417
                                Carl Wilson 4
                                Participant
                                  @carlwilson4

                                  Spot on Nick, well done.

                                  #283637
                                  peter ravenscroft
                                  Participant
                                    @peterravenscroft57700

                                    hi

                                    i thought you might like to see my offering of my dividing head based on the chuck felllows deign with the software from the one in model engineer workshop

                                    regards

                                    peter

                                    #283643
                                    Graham Titman
                                    Participant
                                      @grahamtitman81812

                                      Hi thanks to the help from forum members i got my dfrobot keypad to work running a r/t but i then bought a sainsmart one for another project and in the house in the warm it seems to work ok but take it down to the cold workshop and make it work hard driving a small Emco milling head up an down in the run mode and it does what Roger Williams 2 does.Graham

                                      #283669
                                      Nick Clarke 2
                                      Participant
                                        @nickclarke2

                                        Now that all seems to be working correctly I am a little confused. When I program in a number of steps, say 4 whenratio is set to 9 :1, the shaft spins a number of times to arrive at division 1. When the button is pressed for division 2, again, the shaft spins a number of times before stopping, but, not at 90 degrees to where division 1 was. I was expecting the shaft to spin as it does, but was expecting it to land 90 degrees on. I am hoping this is due to the ratio and will come right once grafted on to rotary table. I am going to add a 1:1 ratio as a test, as every division should then be equal.

                                        #283674
                                        Neil Wyatt
                                        Moderator
                                          @neilwyatt
                                          Posted by Nick Clarke 2 on 11/02/2017 17:07:31:
                                          Now that all seems to be working correctly I am a little confused. When I program in a number of steps, say 4 whenratio is set to 9 :1, the shaft spins a number of times to arrive at division 1. When the button is pressed for division 2, again, the shaft spins a number of times before stopping, but, not at 90 degrees to where division 1 was. I was expecting the shaft to spin as it does, but was expecting it to land 90 degrees on. I am hoping this is due to the ratio and will come right once grafted on to rotary table. I am going to add a 1:1 ratio as a test, as every division should then be equal.

                                          If you have a 36:1 ratio table then four divisions = 36/4 = 9 full turns per division

                                          Neil

                                          #284029
                                          Nick Clarke 2
                                          Participant
                                            @nickclarke2

                                            Well I grafted the stepper on to my Sorba rotary table and was most disapointed. Table turns painfully slowly. When I go for 4 divisions the table only moves a tiny portion og the required division, and 45 degrees moves 10 degrees. See video
                                            https://youtu.be/yrPmzaC1mMo

                                            #284233
                                            SillyOldDuffer
                                            Moderator
                                              @sillyoldduffer
                                              Posted by Graham Titman on 11/02/2017 13:57:23:

                                              Hi thanks to the help from forum members i got my dfrobot keypad to work running a r/t but i then bought a sainsmart one for another project and in the house in the warm it seems to work ok but take it down to the cold workshop and make it work hard driving a small Emco milling head up an down in the run mode and it does what Roger Williams 2 does.Graham

                                              Graham,

                                              This sounds as if your key values aren't quite right.

                                              The Arduino works out which key is pressed by measuring a voltage. The voltage varies: not only with the make and version of the board, but also with the tolerances of the resistors used. If the voltage measured is near a boundary, you may get inconsistent results.

                                              Gary Limings wrote this helpful comment in his code:

                                              // average values for my board were: 0, 144, 324, 505, 742
                                              // add approx 100 to those values to set range

                                              But he didn't explain how to measure those 'average values'.

                                              I've knocked up this short program to do just that. It should be compiled and loaded into the Arduino just to find out what your key values actually are. It can be done with the motor connected; the program doesn't use any of the pins.

                                              Once the key values are known, Gary's program can be modified to match your LCD board and reloaded.

                                              In use, the program displays "Push a Button"

                                              dsc04217.jpg

                                               

                                              After a key has been pressed, it's actual measurement will be displayed for 1.5 seconds. Write the results down for each key (apart from RST!).

                                              dsc04216.jpg

                                              From my DFRobot I got: RIGHT 0, UP 100, DOWN 255, LEFT 409 and SELECT 638.

                                              Open Gary's program in the Arduino IDE and scroll to the very end. The last few lines of his code look something like this:

                                              if (key_in > 850) return NO_KEY;
                                              if (key_in < 70) return RIGHT_KEY;
                                              if (key_in < 230) return UP_KEY;
                                              if (key_in < 350) return DOWN_KEY;
                                              if (key_in < 450) return LEFT_KEY;
                                              if (key_in < 850) return SELECT_KEY;

                                              It's the numbers that need to be right. Using Gary's 'add 100 rule' and the measured numbers, the code should be amended to read.

                                              if (key_in > 738) return NO_KEY;
                                              if (key_in < 100) return RIGHT_KEY;
                                              if (key_in < 200) return UP_KEY;
                                              if (key_in < 355) return DOWN_KEY;
                                              if (key_in < 509) return LEFT_KEY;
                                              if (key_in < 738) return SELECT_KEY;

                                              Hope this removes some of the mystery!

                                              Dave

                                              Edited By SillyOldDuffer on 14/02/2017 17:25:08

                                              #284286
                                              Michael Gilligan
                                              Participant
                                                @michaelgilligan61133

                                                Thanks, Dave

                                                That is sure to come-in useful.

                                                MichaelG.

                                                #284335
                                                Graham Titman
                                                Participant
                                                  @grahamtitman81812

                                                  Thanks Dave i will give it a try later on Graham

                                                  #284587
                                                  Roger Williams 2
                                                  Participant
                                                    @rogerwilliams2

                                                    Hello all, just done Silly Old Duffer's LCD Push Button sketch, added 100 to the figures as per Gary Liming, but still the same glitch,….Run mode CW direction goes wrong way on the initial Left button press, then corrects itself after that. . Step, Angle and Jog are perfect !. Must be doing something wrong somewhere.

                                                    One thing I have done when re-programming the Arduino, was to make a hole in the box to connect up the USB cable , so much easier than disturbing everything.

                                                    #284591
                                                    Engine Builder
                                                    Participant
                                                      @enginebuilder

                                                      One thing not mentioned in the article is where to set the switches on the driver board.

                                                      This is how mine are set and it works fine.

                                                      sw1 on

                                                      sw2 on

                                                      sw3 off

                                                      all dip swiches off

                                                    Viewing 25 posts - 26 through 50 (of 109 total)
                                                    • Please log in to reply to this topic. Registering is free and easy using the links on the menu at the top of this page.

                                                    Advert

                                                    Latest Replies

                                                    Viewing 25 topics - 1 through 25 (of 25 total)
                                                    Viewing 25 topics - 1 through 25 (of 25 total)

                                                    View full reply list.

                                                    Advert

                                                    Newsletter Sign-up