Mill knee driving with a stepper

Advert

Mill knee driving with a stepper

Viewing 25 posts - 26 through 50 (of 56 total)
  • Author
    Posts
  • #162801
    Ian P
    Participant
      @ianp
      Posted by Neil Wyatt on 06/09/2014 09:35:36:

      Hi Ian,

      Check the PIC data sheet, usually one of the two crystal connections will be usually suitable for inputting an external clock signal.

      Neil

      Neil

      True, but when programming a PIC there are options to configure the PIC inputs to suit the type of clock device. The PIC I have is already programmed for a basic crystal.

      Ian P

      Advert
      #162804
      Michael Gilligan
      Participant
        @michaelgilligan61133
        Posted by Ian Phillips on 06/09/2014 09:09:26:

        A worm and pinion would work but the reduction ratio will probably be far too high. I suspect the best compromise will be in the region of 2:1 to 5:1 which is outside the worm and pinion practical range.

        Ian P

        .

        question

        MichaelG.

        #162806
        Les Jones 1
        Participant
          @lesjones1

          Hi Ian.
          I think feeding the clock signal into pin 13 should work. I think it should work without changing the oscillator configuration. (And also without removing the 33pf capacitors from pin 13 & 14) I do not understand exactly what the "Decay" setting does even after reading the data sheet on the chip used in the driver that I use (TB6560) I have set the current to 2.2 amps to match the stepper motor that I have used. (Arc Euro 180 N.cm) I think it would be easier just to buy a 10 MHz crystal off Ebay rather than using the oscillator.

          Les.

          #162809
          John Haine
          Participant
            @johnhaine32865

            Trevor, sorry, more questions…

            • What stepper drivers are you using?
            • When you drive at low speeds, are you making small movements (e.g. incremental jogging) or continuous?
            • Do things behave better with in microstepping?

            i have a theory… Steppers have a sinusoidal torque vs displacement curve, at least at low speeds. When one winding is energised and the other isn't, at zero displacement the torque is zero, as the displacement increases to 0.9 degrees it rises to a maximum then decreases to zero at 1.8 degrees. When both windings are energised, the curve moves along 0.9 degrees so the load sees maximum torque and should move 0.9 degrees; then the first winding is switch off and the curve moves along another 0.9 degrees; then the first is energised in the opposite sense to move another 0.9…and so on. With microstepping, instead of the the windings being either on+, on-, or off, the currents are modulated to move the torque curve by a fraction of a step per input step, but this means that the torque increment per step is much smaller. If stiction is too large then the load won't start to move until several micro steps have been accumulated, when hopefully it might catch up but if the total number of steps is too small it might not.

            This would be consistent with your observation that increasing the current, and therefore the maximum torque, decreases the speed where the problem occurs. My suspicion is that you need to increase the torque and decrease any possible stiction. Minimum microstepping will increase the torque increment. Ideally have a toothed belt reduction to increase torque and give better resolution rather than depend on microstepping. A counterbalance is an elegant engineering solution to reduce load on the screw, and I have thoughts swirling in my brain of an active counterweight with a worm geared dc motor driving a drum to take up a steel cable, with a micro switch sensing cable tension and controlling the motor. Compact, constant lift, easily adjustable.

            John.

            #162811
            Neil Wyatt
            Moderator
              @neilwyatt

              Hi Ian, I've checked the datasheet for the PIC16F87X and as far as I can see it will just work as long as you use the CLKIN pin and not CLKOUT.

              You won't do any harm by trying it. The input is a schmitt trigger so teh wave shape is unimportant, in fact the external clock spec is essentially for it to be good square wave between 'DC' and Fmax.

              Neil

              #162817
              jason udall
              Participant
                @jasonudall57142

                Just a thought..

                If you have the stepper coupled already. .a simple test of low speed drive with an added counter weight will prove illuminating.

                It should be a simple test to try.

                The case of no movement at low rate but acceptable at medium to high speed .

                Consider the case if pushing a barrel up a ramp with a rifle shot…

                Bang pause bang pause…

                This is what the stepper is doing…

                So if the barrel rolls back to start position during the pause…result no net movement……

                Increase the rate of fire…..and you reach a point where the barrel will progress…

                I think this might explain the behaviour…

                The motor obviously develops enough torque ( it has sufficient at high speed)…But some part of the mechanical system is interfering with the result…

                Again simply try a counter weight…they are popular in industrial solutions

                #162826
                David Colwill
                Participant
                  @davidcolwill19261

                  Hi,

                  When I converted my bridgeport clone I had the same dilemma. I opted like you to keep the old screw and as a temporary job stuck a 34 size motor via a 2:1 reduction straight on to the shaft that takes the crank handle. I used drivers that connect straight into the mains. I have run this reliably at 1500 mm / min with no gas struts or counter weights. I have never experienced any problems at low feed rates. The machine has a DRO fitted that is completely independent of the CNC and the accuracy is in the order of .02mm which is more than good enough for my purposes.

                  In your shoes I would certainly try gearing via a toothed belt as I know it works.

                  Regards.

                  David.

                  Ps I have no plans to alter the set up other than to fit belt guards.

                  #162828
                  TrevorG
                  Participant
                    @trevorg

                    Posted by John Haine on 06/09/2014 08:41:59:

                    Your observation that everything seems to work with high feed rate with no missed steps seems inconsistent with the knee not moving at all at low rates. A high rate has to start somewhere after all!

                    I agree totally. Trying to get my head around this inconsistency is what drove me to raise this issue in the first place. Its not just being unable to understand what is going on. It is that feeling that I am missing something important that will come back to haunt me later in the project.

                    Answers to the questions about my configuration.
                    1) I am using a commercial microstepping controller. So it always micro steps, minimum 2 microsteps/step. I have tried changing 8 down to 2 microsteps. Does not appear to affect the problem.
                    2) The controller is driven by an AVR board of my own design with my own software so I know exactly what it is doing and when.
                    3) The AVR receives a command from the main control unit (an RPi) in the form move Xmm @ Ymm/sec. It then converts this into a number of pulses and a pulse rate. It then puts out the pulse train at the fixed pulse rate. At the moment there is no acceleration/decceleration ramp.
                    4) At the moment the s/w is fairly basic as I intend to integrate my hardware into commercial s/w for higher level control once I have the steppers running correctly. Stepper drives are new to me and like a lot of people I am still trying to get my head round them. Once I have a definition of the drive requirements microcontrollers and s/w are straightforward for me (if a little time consuming) .
                    5) The knee has leadscrew is 4tpi and the handwheel (driven by the stepper) is connectected by 2:1 bevel gearing giving an effective 8tpi
                    6) The X & Y axis have been fitted with ballscrews and toothed pulleys(1:1.67) to 3Nm stepper and are working without any problems
                    7) Before the project started a crude measurement showed that the knee handwheel needed 5.6Nm to overcome stiction (moving up).

                    One thing I omitted to say earlier on is that the problem only occurs when raising the table. Lowering it is fine. So the issue is definitely load related. Sorry I thought I had mentioned it but checking back I don't seem to.

                    I will try putting a scope on the motor drive waveform. I did this when I first bench tested the stepper off-load. With PWM mush the result was unhelpfull. May be better with the motor underload.

                    Trevor

                    #162829
                    TrevorG
                    Participant
                      @trevorg
                      Posted by David Colwill on 06/09/2014 15:37:48:

                      Hi,

                      When I converted my bridgeport clone I had the same dilemma. I opted like you to keep the old screw and as a temporary job stuck a 34 size motor via a 2:1 reduction straight on to the shaft that takes the crank handle. I used drivers that connect straight into the mains. I have run this reliably at 1500 mm / min with no gas struts or counter weights. I have never experienced any problems at low feed rates. The machine has a DRO fitted that is completely independent of the CNC and the accuracy is in the order of .02mm which is more than good enough for my purposes.

                      In your shoes I would certainly try gearing via a toothed belt as I know it works.

                      Regards.

                      David.

                      Ps I have no plans to alter the set up other than to fit belt guards.

                      Interesting. As stated above the effective leadscrew rate between the handle and the knee on my machine is 8tpi. I would be interested to know the value for your bridgeport clone. WhileI suspect your knee is heavier than mine it should be close enough to be helpful.

                      Trevor

                      #162835
                      Les Jones 1
                      Participant
                        @lesjones1

                        Hi Trevor,
                        It might be easier to use an analogue ammeter to measure the coil current as this will average out the PWM drive. As you have described your setup it would be easy to write a bit of code to single step the motor. (It would only need to simulate a push switch with a de bounce circuit added.) As the nearest you can get to no micro stepping is 2:1 then I would expect the current cycle through this sequence. Zero current, Half current, Full current, Half current, and back to zero current. If you use an oscilloscope to monitor the current you would need a suitable low pass filter to average out the PWM waveform. If there was any springiness in the drive between the motor and the actual leadscrew (Which sounds unlikely from your description.) AND the driver module reduced the drive current between steps then Jason's analogy could explain what is happening.

                        Les.

                        Edited By Les Jones 1 on 06/09/2014 17:41:13

                        #162839
                        Les Jones 1
                        Participant
                          @lesjones1

                          Hi Trevor,
                          I have just found out that the way I thought 2:1 micro stepping works is incorrect. I assumed at the half step position that the current in each winding was half the maximum value. It appears from this reference that both coils have the full current flowing through them.

                          Les.

                          #162840
                          jason udall
                          Participant
                            @jasonudall57142

                            ….lowering is fine.

                            ….really. ..you do surprise me…

                            Sorry but didn't you read my suggestion above a bout the possible mechanism….

                            What you have is the "barrel" .rolling back before the next shot moves it any further up the slope..

                            In this case the small ( but real) back drive of the table weight on the acme jack screw..is smaller than the step…and what you get is the stepper impulses the machine up…it moves under drive..coasts..reaches max height..falls..and back drives….

                            With a faster pulse train you complete the next step before you end up back at step one ( excuse the pun)…

                            So if you move down the coast is downwards…thus apearing ok

                            If you add a counter weight you appear to reduce the gravity on the table ( mass stays the same but your upwards parabola height is increased and your limit of interstep time ( before no movement is seen) will reduce…the consequence would be to let the system work at a slower speed than now……

                            Again an experiment will show whether this will help

                            If the table masses 100 kg…and 20 rpm is lowest speed achived…

                            Hang say 20 kg over pulley..and retest…and get new lowest speed of say 5rpm…

                            #162841
                            jason udall
                            Participant
                              @jasonudall57142

                              Btw on my cva I too find moving the knee down easier than up

                              #162865
                              TrevorG
                              Participant
                                @trevorg

                                Hi Jason,

                                I think with the number of posts I was going through I missed the point you were making. As you say it does explain the rather strange symptoms I have observed.

                                Implicit in this explanation is the idea that the torque used to drive the motor is greater than the holding torque. While I don't find this too surprising it suggests a hole in my understanding of stepper motors. At this stage I want to go through the reference that Les has provided. Then I want to think my way through the whole issue.

                                I knew my understanding of microstepping was poor. To that I need to add the whole issue of how torque varies throughout a step.

                                As for a counter weight the problem is how to attach it to the mill so that it does not just tear itself apart. The shape of the mill itself does not easily lend itself to such a system. With the masses involved a quick suck it and see experiment is probably not a good idea.

                                Trevor

                                #162869
                                John Haine
                                Participant
                                  @johnhaine32865

                                  What is clear from Jones on stepping motors is that at low speeds the holding torque is the same as the maximum torque. As you drive the motor the angular position for max holding torque as a function of displacement is moved along, in steps, not impulses.

                                  Are you using the common 2m542 drivers (these have minimum 2 micro steps)? These seem very trouble free. I doubt there is much point trying to measure the current to the motors, just swap the driver with one of the other axes and see if it behaves the same. You don't say, but I assume the other axes work fine at low speed? And have you checked raising/lowering repeatedly the knee at higher speed with a dial indicator to make sure there are no lost steps that you may not be noticing? You could also try feeding the driver from a PC parallel port with Mach 3 just to eliminate your AVR board and software.

                                  #162872
                                  jason udall
                                  Participant
                                    @jasonudall57142

                                    One of the things about steppers..torque falls off with "rpm"

                                    So if torque ok at 20 rpm then torque should be ok at 5 rpm

                                    If torque ok knee down at 5 rpm then torque will be the same at -5 rpm ccw vs cw

                                    This leads to a "mechanical" type problem

                                    Ok if a counter weight is not possible for test of knee move then maybe a extention spring..fixed to the quill say and clamped to the table. ..now back off the knee…to tension the spring..now tryslow up on knee..if now works you know that some help or bias would answer the question

                                    #162873
                                    jason udall
                                    Participant
                                      @jasonudall57142

                                      One of the things about steppers..torque falls off with "rpm"

                                      So if torque ok at 20 rpm then torque should be ok at 5 rpm

                                      If torque ok knee down at 5 rpm then torque will be the same at -5 rpm ccw vs cw

                                      This leads to a "mechanical" type problem

                                      Ok if a counter weight is not possible for test of knee move then maybe a extention spring..fixed to the quill say and clamped to the table. ..now back off the knee…to tension the spring..now tryslow up on knee..if now works you know that some help or bias would answer the question

                                      #162875
                                      jason udall
                                      Participant
                                        @jasonudall57142

                                        Ok 200 step motor.half stepped 8 tpi leadscrew…
                                        1/3200 ” per step..
                                        =0.0003125″
                                        Ie 0.3 thou…

                                        How if the table was ” loose” …free to float vertically this much…how long would a rise and fall take?….
                                        Newton anyone…d =ut +1/2at^2…
                                        Solve for t…

                                        #162888
                                        Les Jones 1
                                        Participant
                                          @lesjones1

                                          Hi Trevor,
                                          I had a thought overnight about some other tests you could do, You could remove the stepper motor from the mill and attach an arm and spring balance to it. Also have a dial gauge touching the arm about 63.7 mm from the axis. (So 1mm movement corresponds with one step.) With the driver powered up but with no step pulses being sent to it pull on the spring balance with a force that corresponds with a torque of about 6 Nm (I think you said that you measured the static torque required to raise the knee was about 5Nm) Note the change in reading on the dial gauge. If the deflection is a significant fraction of a step then there must be too low a holding current being applied. If this does not show a problem then you could see the result of sending single steps to see if it moved and then went back to its original position.

                                          Les.

                                          #162891
                                          David Colwill
                                          Participant
                                            @davidcolwill19261

                                            Hi,

                                            I'm pretty sure that the Z axis screw on mine is 5mm pitch. You say that you have no acceleration ramp, I found that I had to fiddle around with acceleration in mach 3 to get things working nicely.

                                            Regards.

                                            David

                                            #162894
                                            Les Jones 1
                                            Participant
                                              @lesjones1

                                              Hi Jason,
                                              This is my calculation for how long the knee would take to fall the distance of one step.

                                              Acceleration due to gravity = 32 ft per sec^2

                                              S= u + 1/2at^2 (Assume u = 0)

                                              For 8 TPI 1 step = 1/(8 x 200) = 1/1600 = 0.000625"

                                              0.000625" = 0.000625/12 feet = 5.21 X 10^-5 (0.0000521 feet)

                                              So 0.0000521 = 1/2 x 32 x t^2

                                              So t^2 = 0.0000521 X 2 /32 = 0.0000521/16 = 0.00000326

                                              So t = Sqrt 0.00000326 = 0.0018 seconds = 1.8 mS

                                              Les.

                                              #162907
                                              John Haine
                                              Participant
                                                @johnhaine32865

                                                The knee will be very highly damped by the slideway friction, and indeed stiction effects if it has to reverse, so I think this is a very idealised calculation.

                                                #162913
                                                John McNamara
                                                Participant
                                                  @johnmcnamara74883

                                                  If the stepper is slipping it is not happy and being operated near its limit. I think you will need to increase the torque on the screw with gearing between the stepper and the Feed screw. There are all sorts of nasty striction for want of a better word for the varying friction you get from a metal on metal slide way.

                                                  The drive I posted earlier in this thread used two stages of 3 to one reduction there was no problem at all with missed steps.

                                                  Regards
                                                  John

                                                  #162918
                                                  jason udall
                                                  Participant
                                                    @jasonudall57142

                                                    Ok so it works a 60 mm/min..but not at 0.6

                                                    Thus that’s 1mm/s and 1/100 mm/ sec

                                                    With the given 400 steps/rev and 8 tpi (3 mm) so this gives about 8 micron per step…so at 1/100.mm/s…that gives about 1 step per second…….
                                                    And 100 steps /sec for the slowest working speed… 1 step per sec is very slow…and plenty of time for my theoretical rise coast fall cycle….

                                                    #162934
                                                    John Haine
                                                    Participant
                                                      @johnhaine32865

                                                      Trevor,

                                                      You didn't say exactly which driver you were using just that it has a minimum microstep of 2. I diod ask if you were using the 2M542 type which are commonly available on eBay – these have a function that reduces the idle current when stepping stops (presumably after a short timeout). This means that their holding torque characteristics at very low speeds could be quite anomalous. As far as I can tell (don't have my data sheet to hand right now) it is "SW4" that selects this function – if you are using this type of driver then this could be worth checking and maybe just toggling sw4 to see if it makes a difference?

                                                      John.

                                                    Viewing 25 posts - 26 through 50 (of 56 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