Announcement

Collapse
No announcement yet.

Spindle encoding techniques

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Spindle encoding techniques

    Ok, not really an encoder, I suppose, but perhaps a pulse generator. The idea is to attach this to the lathe's spindle so I can tell the RPMs. I also have another nefarious use, so I'd prefer a digital solution.

    My first thought was a disk with small magnets at its perimeter and using a hall effect sensor to get the pulses.

    Then i thought maybe a disk with a lot of holes and an LED/phototransistor would be good.

    I opened a deal injket printer this week and saw a clear disk with a *lot* of radial scores and the LED/phototransistor combo too. Lots of pulses there. I could barely see the scoring.

    So what's a good way to make an encoder which produces a lot of pulses per rev? I believe I could drill 128 holes in the 3" disk I'm contemplating. That would be using a 1/32" bit and leaving about 1/32" of material between the holes. I don't have a feel for the minimum size of the hole. If not enough light gets through the phototransistor won't be able to do its thing.

  • #2
    A magnetic reluctor circuit as used in many car ignitions would be my choice. The moving part is like a gear wheel and you possibly have a suitable one already turning with the spindle.

    Comment


    • #3
      For something like a tachometer, you really don't need that many pulses per revolution. A few holes in a metal disk with a photo-gate should work just fine. Encoders need many holes/lines so that they can resolve a small enough angle.

      One thought for making your own encoder is to draw it in a CAD package (or Paint) and print it on transparencies that are used on overhead projectors. Laser printers should produce thin enough lines to make a reasonable encoder.

      Comment


      • #4
        Wes had a great article about this in the Digital Machinist -- he used an automotive Hall Effect sensor, with a magnet stuck onto the encoder wheel.

        Allegro makes good Hall Effect sensors, and you can ask for 5 - 6 sample for free.

        http://www.allegromicro.com/en/Produ...ories/Sensors/
        "Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did."

        Comment


        • #5
          You can download a nice little program to generate encoder disks from my web site here: 1MB, right click and Save as

          http://metalshopborealis.ca/misc/encoder.msi

          It will generate any size and tooth count you need. You can print it out on a transparency and make whatever you want.

          To make a really fine tooth encoder there is a trick you can use that makes the resolving power of the optical detector irrelevant. Use two disks, one rotating and the other the same tooth count stationary very close to the revolving one as a mask. The two disks will produce a shutter effect as the lines are alternately lined up or interleaved. This allows the use of nearly any light source and detector. Incidentally, silicon solar cells have microsecond response times.
          Free software for calculating bolt circles and similar: Click Here

          Comment


          • #6
            Evan, is the point to the trick that for some brief instant all the light is blocked assuming the line widths are properly sized?

            If this is the case, it would seem I could also put a mask with a single slit in front of the sensor and forgo the 2nd disk.

            Comment


            • #7
              That won't let very much light through if the tooth count is very high since the slit will be very fine. As long as the two disks are printed from the same pattern at the same time the widths will be correct. When a pattern that is nominally 50/50 light dark is printed the pattern will always have more black than white because of spreading of the black ink. That insures the pattern will black out when the line are staggered. That will give maximum contrast between the on and off state.

              This is a technique that is used in commercially made encoders. By changing the tooth count of the mask to the rotor the pulse frequency can be altered as well using the moire effect. It also produces a quadrature signal that is far less dependent on the position of the detectors.
              Free software for calculating bolt circles and similar: Click Here

              Comment


              • #8
                On my cnc mill I wanted pulse feedback so I could get a closed loop spindle through Mach3. When it was an R8 spindle I used a Keyence retroreflective fiber optic sensor. I made 1/4" thick aluminum ring that went around the spindle nose. Through the side of the ring I drilled and tapped a 3mm hole for the fiber head and used some 1/4" teflon tubing to protect the fibers leading back to the amp mounted higher up on the head. I painted a black mark on the spindle and ran the autotune on the sensor. It sets the on/off threshold. The sensor was interfaced to the computer with an opto22 DC Input module. Worked great. Did have an issue where I was not getting good pulse form out of the sensor amp. Fixed that by adding a resistor in parallel to the output signal.

                Worked fin all the way up to 6k rpm which if the fastest I ran the spindle.

                Since then I have changed the spindle to a 30 taper and there is no space near the nose to mount the sensor. I drilled and tapped a hole for the sensor in the side of the vari-speed housing. It now reads a mark on the lower non-moving part of the reeves drive pulley on the spindle. Bad thing about this setup is that it will not read the correct speed in back gear.

                You could use a variable reluctance sensor to pickup the signal off the back gear spur that is attached to the spindle. I would use a divide by counter to get one pulse per rev.

                On my Hercus CNC I yanked the resolver and installed a encoder. I didnt feel like making the board to convert resolver to quadrature so I just replace it. I had a 2500 line encoder with index marker in with a bunch of other stuff and made an adapter to fit it in the resovers place. I will have to make a one shot timer that is triggered by the index pulse to lengthen the pulse to something that Mach will see. The pulse only lasts for 1/2500 of the turn so at 3400 RPM that is a real short pulse. But its what I had in my boxes of goodies that will fit in there.

                If you are intending to use the index pulse for either CNC threading or a electronic lead screw project (Or if you just want it so the spindle always stops with the chuck key hole up) you really dont gain anything by using more than one mark from an encoder.

                Comment


                • #9
                  yep.. BP's are a pain to find a decent sense location. My approach (next project) is to drill 2 or 4 holes in the bull gear, and mount a sensor vertically in the top housing. I guess I could drill 128 or 256 holes, but all I want is rpm.
                  Last edited by lakeside53; 05-31-2009, 01:39 AM.

                  Comment


                  • #10
                    I would just use one. Then you have a precise spindle location. Otherwise if you are going to use multiple spots you might as well use a variable reluctance sensor and count the gear teeth. You could use the sensor out of this:

                    http://cgi.ebay.com/Dynapar-Series-7...3286.m20.l1116

                    Comment


                    • #11
                      Originally posted by macona
                      Otherwise if you are going to use multiple spots you might as well use a variable reluctance sensor and count the gear teeth. You could use the sensor out of this:

                      http://cgi.ebay.com/Dynapar-Series-7...3286.m20.l1116
                      I have one of those Dynapar encoders. They're neat in that the big inductive ring allows you to bolt on to an existing motor (or the top of the Bridgeport spindle, where you'd put a power drawbar), but they use a 60-tooth gear that fits inside that inductive ring, and it looks like it's missing on that auction.

                      By the way, the Dyanpar generates a full differential quadrature, so you'll need to use a quadrature tachometer, or build a quadrature step/direction state machine.
                      Last edited by lazlo; 05-31-2009, 06:51 AM.
                      "Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did."

                      Comment


                      • #12
                        I second the Allegro hall sensor, if you've got a suitable gear for the sensing.

                        Here's what I did a few years back: http://www.fricktion.net/~mfrick/lathe/gearsensor/

                        Works great.

                        -Matt

                        Comment


                        • #13
                          Originally posted by Ryobiguy
                          I second the Allegro hall sensor, if you've got a suitable gear for the sensing.

                          Here's what I did a few years back: http://www.fricktion.net/~mfrick/lathe/gearsensor/

                          Works great.

                          -Matt
                          I sent out a bunch of these some time back, to anybody who asked. Anybody ever use them?
                          Weston Bye - Author, The Mechatronist column, Digital Machinist magazine
                          ~Practitioner of the Electromechanical Arts~

                          Comment


                          • #14
                            Laslo mentioned an article in Digital Machinist. I don't know which one, but I have addressed encoders more than once - all shop made.

                            The first was using bonded nitrile ferrite (refrigerator magnets). I described remagnetizing these to provide desired encoder patterns, and using Allegro Hall-effect sensors arranged to provide quadrature output.





                            Ferrite magnets can be remagnetized by exposing them to a strong magnetic field. Neodymium magnets possess sufficient strength to accomplish this when brought into close proximity to the ferrite. Samarium-cobalt also works, though not as well as the Neo. I have also done this with pulsed coils.
                            Weston Bye - Author, The Mechatronist column, Digital Machinist magazine
                            ~Practitioner of the Electromechanical Arts~

                            Comment


                            • #15
                              Another article dealt with winding coils on the lathe and I needed a turns counter. The Sherline lathe was easy to adapt for this purpose. I added a couple of easily installed details, carrying a Hall sensor and permanent magnet.



                              Weston Bye - Author, The Mechatronist column, Digital Machinist magazine
                              ~Practitioner of the Electromechanical Arts~

                              Comment

                              Working...
                              X