584,805 active members*
5,290 visitors online*
Register for free
Login
IndustryArena Forum > MetalWorking Machines > Shopmaster/Shoptask > AC servo conversion on CNC Patriot VFD machine
Page 1 of 2 12
Results 1 to 20 of 33
  1. #1
    Join Date
    Sep 2006
    Posts
    177

    AC servo conversion on CNC Patriot VFD machine

    I have 3 AC servo motors and drives (2 that are nema 34 and 1 that is nema 42) that I thought would be relatively easy to put on the shopmaster in place of the stepper motors. Below are pics of the motors the faceplates and the drives. The motors are Pacific Scientific; 2 with resolver feedback and one with encoder and hall signals. The drives are Pacific Scientific SC903 and SC904 with OC930 and OC950 option cards, respectively, and one is Kollemorgen Servostar CD. I also have a 3-phase power filter, which i'm going to use to filter the single phase 240 V AC. Although the filter is for 3-phase, I called the manufacturer and they said it will also work almost as good for 240V AC single phase. The first step will be to power-up the drives and motors to see if they still work (I haven't turned them on in about 5 years). I have some SSR's i plan to use as a switch for the 240 V power into the filter, and I need to use some switches to enable/disable the drives. I'm going to put the power switch and enable switches in a homemade wooden box. Then tune the motors with no load. I found all the manuals and software for the motors and drives on the Kollemorgan website. I'm not completely decided yet if i'm going to use the tuning from no load. One of the manuals said that if you have backlash the motors should be tuned with no load. My shopmaster seems to have a 2-3 thou backlash in each acis. I'm open to advice on this one.

    The nema 34 motors should be a direct (or close to it) swap (since the steppers are also nema 34). The nema 42 motor will need a new mount, timing pulley, and belt (going to order from mcmaster). I'm using the nema 42 for the x axis, the next smaller motor for the y-axis and the smallest motor for the z-axis. For safety (since runaway can happen with AC servos), I'm going to use two latching switches that can be positioned anywhere on each axis that when pressed will either cut the drive power or disable the enable pins. Anyone know which is better to use? I would think that disabling the enabling pins would be better because the motors should stop quite fast as opposed to cutting the drive power which may allow the motors to keep going for longer because the drive may store power in capacitors etc.

    After I finish the conversion and if all goes well I might try something. This something is to use the glass scale DRO output as a position feedback on the z-axis Servostar CD drive and the motor encoder/hall as velocity/torque feedback for a dual loop to maximize accuracy with the parts/pieces that I currently have. This is possible with the z-axis (small motor and servostar drive) since this drive has an optional encoder input for just this. The manual said the it's preferable to have zero backlash for this though. So we'll see. I don't want to get ahead of myself, but I also have a brand new zero backlash ground C3 ballscrew (ebay find...actually I have 2 of these) I could maybe resolve the backlash on the z-axis rolled ballscrew.

    All the motors and drives I got from ebay for a previous project; they all seem to be in good shape. The nema 42 motor I know is a little overkill, but it'll fit if I make a new faceplate (i'm going to change the pulley ratio on this one to 1:1). I'll post updates and pics as I make progress and hope to hear any feedback (good/bad, advice, recommendations, questions, or whatever) from fellow shoptask (or not) folks. This is exciting for me and I hope you enjoy following along.
    Attached Thumbnails Attached Thumbnails 1.jpg   2.jpg   3.jpg  

  2. #2
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I'm back and want to post progress on the conversion. I should be posting more regularly in the future. I got answers to the questions I previously had on other threads. Turns out that I need to tune the motors while attached to the patriot for best results. For safety shutdown in case of servo runaway my plan (after consulting the servo forum) is as follows: I want to feed lines from the glass scale DRO cables back to mach 3. This way mach3 will know the actual position at any given time. Then i'll make a brain to set the criteria when to activate the safety shutdown (which will be both to disable the enable pins and cut the power to the drives and also spindle power). If the travel goes beyond given limits or if the position error exceeds a certain value then the signal to active the safety stop will be activated.
    Below are pics on how I tapped into the scale DRO lines. I decided to tap into the scale cable rather than from inside of the DRO readout box. I took the connector apart to get to the wires, then cut into the wire shielding on a small spot and soldered new wires to these. I used hot glue to stabilize things and cover the exposed solder/wire and covered that in electrical tape and closed it back up. It was not easy though...took decent amount of patients and persistence to get it done well. Still have to do the other two lines. For info on what wires colors were what I looked up the scale data sheets on the jenix website (Red: +5V supply, Yellow: A, White: B, Green: Z, Black: 0V supply, Black shield: ground). I tapped into the A and B signals.

    Eager to hear any new comments/concerns/advice/questions.

  3. #3
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I've been getting things done. Broke though several obstacles, but got a new one. What I got done is: I checked and wired the power, drive, and AC servo motors. I can now run and tune the motors. I tapped into all three glass scale cables and got the A and B lines. I found out that the encoder signals are isolated, so I had to add a pull down resistor between the glass scale negative supply and ground (I did this inside the box). I also had to hook directly into the parallel port because going through the gecko drive didn't work either. I ordered a 2nd parallel port for inputs for the other 2 axis encoders. I also wrote one small practice brain. I made a parallel port cable so I don't have to cut up the one that came with the machine (b/c I will need the step and direction pins for 3 axis rather than going into the gecko drive). So my problem is that after I tried the new parallel port cable the spindle and 3 stepper motors now have acquired some noise and the spindle moves a little here and there when it is just powered up with mach3. The step motors now for some reason don't move when I use the jog feature either. I had the noise issue when I first got the machine and it wasn't the gecko drive, it was the computer power supply cable too close to the stepper motors. I tried that this time but it didn't work. Has anyone else had this noise issue. Anyone else have any ideas why the noise and no axis motion? I checked the computer parallel port and the outputs appear to be working. Attached are pictures.
    Attached Thumbnails Attached Thumbnails scale_cable 010.jpg   scale_cable 013.jpg   scale_cable 014.jpg   scale_cable 017.jpg  


  4. #4
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I got the biggest problem of no movement solved. I reset the cmos battery in the computer and reseated the memory and after that I get axis movement now. There still is noise. I would be good to get that solved next.

  5. #5
    Join Date
    Jan 2009
    Posts
    334

    Re: AC servo conversion on CNC Patriot VFD machine

    Quote Originally Posted by mackeym View Post
    I got the biggest problem of no movement solved. I reset the cmos battery in the computer and reseated the memory and after that I get axis movement now. There still is noise. I would be good to get that solved next.
    Excellent work. I am just about finished with my AC servo conversion of a Denford NovaTurn. Check your shielded wires especially the encoders. Route all high voltage separate form encoder wires. Limit switches are great to prevent over-travel. I use the servo enable functions- software. For initial testing, leave your motors unconnected to machine. In this way you can do some basic tuning and not worry about run-away. Look for Denford NovaTurn, Gizmosphere on PathPilot, iBOB2, Iron-man Servos Red Candy Running etc to see some of my work.


    Hope this helps,

    Iron-Man

  6. #6
    Join Date
    Feb 2009
    Posts
    281

    Re: AC servo conversion on CNC Patriot VFD machine

    Since you are splitting out the signals from your Jenix DRO, I have a question. On our units, when switching from mill to lathe, the DRO scales do not match the Mach3 scales- as I'm sure you are aware, in lathe mode the X scale in Mach 3 is the Y scale on the Jenix and the Z scale in Mach 3 is the X scale on the Jenix. This is confusing in lathe mode. I thought to try and put a switch between the signal wires that would re-route the signals to the proper scale, so I would have a switch labelled LATHE-MILL. I believe the power and ground could be left as-is and only re-route the signals, but it would require a 9 pole switch which I have not been able to find. If only 2 of the wires need re-routing, then a 6 pole switch would do the job and they are available. So my question is, of the Yellow, White and Green wires, would all three need switching, or could I get by with only switching 2.

  7. #7
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    Thanks for the tips Iron-Man!

    I sorted out the wires and tried a couple different parallel port settings and it seems ok now. I tried my new parallel port cable with shielding and including the encoder input directly into the parallel port. It seems to be working when a lower pull-down resistor (1Kohm or 500 ohms) is used. The weird thing is mach3 encoder readout is accurate when I jog using the keyboard, but when I input a move with MDI like .2" or so, the encoder readout isn't right anymore. Next i'm going to try a pull-up resistor on the two encoder signals and the 5V supply (but i need to read more on this before I do it).

    The noise and slight spindle movement comes and goes....maybe it started back up because I shielded the split-out encoder wires with aluminum foil. My 2nd parallel port card came today, so I can put that in now.

  8. #8
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    Instructor37, it probably wouldn't hurt to do just the A and B channel wires of each encoder, but I would do it on the safe side and re-route all 3 A, B and Z to do it right. For a bigger pole switch you could get a 2 pole switch and use that to drive two 6 pole switches. This would give you 12 lines of switching.

  9. #9
    Join Date
    Jan 2009
    Posts
    334

    Re: AC servo conversion on CNC Patriot VFD machine

    Quote Originally Posted by mackeym View Post
    Thanks for the tips Iron-Man!

    I sorted out the wires and tried a couple different parallel port settings and it seems ok now. I tried my new parallel port cable with shielding and including the encoder input directly into the parallel port. It seems to be working when a lower pull-down resistor (1Kohm or 500 ohms) is used. The weird thing is mach3 encoder readout is accurate when I jog using the keyboard, but when I input a move with MDI like .2" or so, the encoder readout isn't right anymore. Next i'm going to try a pull-up resistor on the two encoder signals and the 5V supply (but i need to read more on this before I do it).

    The noise and slight spindle movement comes and goes....maybe it started back up because I shielded the split-out encoder wires with aluminum foil. My 2nd parallel port card came today, so I can put that in now.
    What you did in post #2 if ok for testing but not for a "electrical noise" free system. The wires are not shielded and eddy currents will enter the wires. Remember not only should the wires be shielded but some wires need to be "twisted wire pairs". See this for good information: http://www.dynapar.com/uploadedFiles...e%20Simple.pdf

    If you decide to change at a later date, I would suggest going to linuxcnc and using a MESA 5i25/6i25 with a 7i76 for stepper control or a 7i77 for servo control. Linuxcnc can be adapted quite easily, although there is a learning curve.

    Hope this helps,

    Iron-Man

  10. #10
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    Hi Iron-Man, after i got the 2 wires from the cable, I twisted the A/B channels of each axis together then I held all 3 axis wires together and put aluminum foil for shielding over them and hooked this aluminum shielding to the original cable shielding. Pull-up resistors did not seem to help things any. However, one pull down resistor between the neg supply and ground works wonders on getting accurate readings. I previously had issues with the output when using the MDI input but it was just how I was zeroing things and how mach3 compensates the encoder then the DRO is zeroed. I read the lower the resistance the faster the circuit can run....I found that resistances of 500ohm down to 160ohms (at 160ohms there 1-2ma of current going through the resistor depending on the state of the A/B channels with a 160ma power supply I assume i'm still safe but I would like to use the highest resistance and still give accurate encoder readings) give basically exact encoder readings. It's only when noise issues start picking up that there is a few thous of error. I the noise seems to occur when I do a lot of jogging, and i'm convinced it's coming from some type of constructive interference between the stepper motors and drive. I've always had this issue with my patriot....it's not bad but some noise does occur. I want to try tuning the resistor/pot for each motor/axis on the gecko540 drive. I think that noise gets back into the gecko drive and then goes to the spindle output to cause slight spindle movement. I'm not going to worry about this noise b/c the steppers will be replaced and I hope I don't have any problem with the drives I have (the pac sci drives are a little old but good quality).
    Got the new parallel port card installed and working with mach3

    I'm still making forward progress. Things I need to do decide on the pull-down resistor value and hook up the rest of the axis encoders to mach3. Write a brain to stop everything if following error or absolute position are outside of some specified numbers. Put in the relays for emergency stop signal from mach3 brain (to cut drive enable and drive power supply). Then tune the motors, hook them to mach 3 to make sure step/dir movement works, mount them on the machine (X-axis will need a new mounding plate, y and z are swappable as is), tune motors on machine. That will be it I think. Sorry for the run-on style of this post, but I hope it gives good info and stirs good interest.

  11. #11
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    An update. For a pull-down resistor, 500ohms works well. This is what i used. If I get encoder errors at high axis speed I believe a 250ohm resistor will fix this. I hooked up the spliced out encoder pins to mach3 successfully; all three are reading accurately while jogging. I wrote a brain to output a relay if the following error exceeds 5thou and it appears to be working too. I'm happy with the progress. I successfully spliced the glass-scale encoders to mach3 and wrote a brain. I plan to use the encoder inputs and this brain and output for a servo safety shutdown. I'm thinking I don't even need to set axis limits because the 5 thou error shutdown would have taken affect in the case of run-away before a limit bound is signaled. Some pics below.
    Attached Thumbnails Attached Thumbnails Encoder Safety Brain.JPG  

  12. #12
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    An update. I finished the AC servo safety shutdown! On my first try I found out the mach3 brains stop when mach3 emergency stop is active; this caused the mach3 outputs to turn off which let the power turn back on. To get around this, I used a latching (either single or dual coil would work) single coil SPDT relay to be controlled by two parallel port output pins (mach3 outputs 3 and 4). I used two brains one for each output: one active high and one active low output (pics of final brains below). To get the active low I selected active low in port/pins in mach3 outputs. For the relay, I used PB1619-ND relay from digikey (manufacturer part number V23026C1051B201). For added protection on the computer parallel port pins and to provide addition electrical current capability, I used a unity gain buffer to amplify and output signals (Digikey part number LT1010CN8#PBF-ND). The relay I chose works as follows. Two pins connect to the coil. When a voltage is applied the relay from the buffer amp outputs the relay closes supplying a 5 V power signal. When the relay coil voltage is reversed, the relay contacts open. This setup is not enough to get it to work because the parallel port outputs change back when mach3 emergency stop is active. To prevent the relay from opening, I added a diode (Zener diode IN4742A from RadioShack) in series with the relay coil to allow current flow only in one direction. When the safety shutdown system needs to be turned back on to allow current to go in the opposite direct, I added a switch in parallel to the diode (to bypass the diode) (a push button momentary type switch is best to actuate the relay when mach3 is started. If mach3 is not started the parallel port pins may not be in the right setting).

    For a 5V power supply I tapped into the computer 5V power going to the cd rom (red wire). I however, highly recommending not to use the computer power supply for the 5V because I had issues with the computer when I connected something wrong and had higher than typical current from the power supply. The computer would not boot; to fix this I unplugged the computer power cable and shorted the + and neutral lines to the ground line on the back of the computer. I also had an issue with the parallel port card (2nd mach3 parallel port as I needed more input/output pins) (I used a StarTech.com 1 Port PCI from office depot). The computer wouldn't start with the card in the computer. To solve this I started the computer without the card, entered the bios, disabled the PCI slots, let the computer startup, shutdown the computer, put the card in the computer, turned the computer on, restarted the computer, entered bios and enabled the PCI slots, let the computer boot and the card with card worked without issues. I've never had such an issue with a computer card and it may have even been just the computer power supply pins needed shorted. This is what I did to get the computer working. Hence, I do not recommend using the computer power supply for the 5 volts needed. I'm currently using the computer power supply, but will most likely use a wall plug-in 5V power adapter I have one from an old cell phone that I probably will use. If using a separate power supply if it stops working you may not know it and the safety shutdown would just not work. To know that it is working an LED or light indicating that the 5V power supply is active would make the shutdown more reliable.

    The latching relay sends 5 V power supply signal to four normally closed SPST relays (digikey part # 306-1247-ND). One of these relays when closed sends 120VAC to the input of 2 solid state relays allowing the main power to be turned on. This relay is controlled by the 5V power from the latching relay. The negative pin on the coil is connected to ground. The way I have it setup is 2 lines for 240VAC power goes through the 2 SSRs into a power filter that I had. It then is router to both the power cord of my the patriot VFD machine and the AC servo drives. For the emergency stop on the patriot machine, i first tookout the emergency stop wires to bypass the switch. I used this emergency stop switch and wired it in series with the NC SPST relay controlling the SSRs. Thus, the emergency stop has the same function as before, so now it accounts for both the AC servo drives and patriot machine. The other 3 NC SPST relays are used to disable the drives when the shutdown from mach3 has been initiated. The coil in these relays are wired the same as the NC SPST controlling the main power. I added flyback diodes to all of the NC SPST relays (IN4742A).

    One last thing. The x, y, and z axes from the glass scales are routed to encoders 1,2 and 3 in mach3 setup in mach3 mode. In the mach3 lathe screen encoders 1, 2, and 3 in the setup are set to y, z and x glass scale axes. Counts/unit is 5080.

    The way I operate the setup starting when everything is turned off is: turn on computer, open mach3, make sure error (encoder vs dro is 0), turn on main power, turn on patriot spindle and steppers, hit mach3 reset, then operate as normal.

    So this is where i'm at!! Thanks for reading!!

  13. #13
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    It's been awhile, but i'm been working on the conversion here and there. I made a mounting plate from 3/8" thick mild steel plate for the x-axis biggest motor (nema42 frame) using the shopmaster. The others are nema34 and are a direct swap. This was my first milling experience and first on the shopmaster. The biggest hurdle I had was quill vibration (solved by partial tightening the quill stop). Also the spindle speed index marker magnet came off, so I took the one from the lathe and put in on the mill. I ordered a new magnet and put it on for the lathe.

    I had great success with getting accurate encoder readings in mach3 from the glass scale encoders by shielding the tapped wires and grounding each shield to the corresponding axis shield and then all three axes together and then grounding the shielding on the computer end well to the computer ground.

    I believed these drives had the capability of the sought after dual loop (position and velocity feedbacks from resolver and glass scale on shopmaster). I had a breakthrough and was able to get the dual loop to work with the drive. I'm able to make minimum steps of 0.005mm or steps of any factor of 0.005mm because of the glass scale resolution and servo drive capability. Because of the mm glass scale I need to use mm in mach3, otherwise there's a small error that accumulates. The max step input frequency for the pacific scientific drives I have is 500Hz, so with a 25um step size the max speed should be 30in/min....I was able to get close to 20in/min...I'm not sure why it isn't faster. These tests were done with the drive only and a parallel port on/off program for the step/dir signals. For working with mach3 the pulse width needs to be increased from 15us (mach3 max) because of a low pass filter of 20us time constant on the drive input. I'm thinking an arduino board to do the conversion to longer pulse width to see if this will get the drive to read the pulses.

    To improve the safety, I want the emergency stop button to disable the drives as well as cut the main power instead of just cutting the main power. I also want a separate switch for enabling/disabling the drives.

    I'm very happy with the progress and thanks for reading.

  14. #14
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I was able to get 30 in/min speed by changing the servo software program to have an even step size since fraction step size doesn't seem to affect distance. I ordered an arduino board and relays for improving the safety shutdown. I was able to get a response in mach3 using active low; however the response was dependent on pulse width and 15us still isn't long enough for accurate functioning....but it does respond to mach3 input, which is a step forward.

  15. #15
    Join Date
    Jan 2008
    Posts
    458

    Re: AC servo conversion on CNC Patriot VFD machine

    I've been following your post, but the electronic talk is way beyond my understanding. However, my old Patriot machine could get 40 IPM with the original stepper and the 2-1 drive ratio. Switching to a 1-1 would get you 60-80. It seems that with that monster servo, you should be flying to the point of being scary.

  16. #16
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    Thanks for following! The reason is because of dual feedback loops. Using a single regular velocity feedback loop, very fast speeds are possible. I, however, am attempting to improve positioning accuracy using the patriot glass scales as feedback, which should in theory remove nearly all errors from the ball screw and belt drives.

  17. #17
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    The max. input frequency (steps/sec) is slower for the dual loop setup (i want to set each step to 25um or ~0.001"). With 500 steps/sec, that gives 30"/min. With the single loop velocity feedback setup, the max. input frequency (steps/sec) is much much faster around 1,000,000 steps/sec. Yes, so with this motor very fast acceleration and speeds are possible.

  18. #18
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I added relays for disabling the drives when the emergency stop button is pressed. I also added a switch so I can easily disable the drives when needed. Still waiting on the arduino board.

  19. #19
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I got the arduino board for ~$20 (Duemilanove 2009 AVR ATmega328 p-20PU USB version) a couple days ago. It works to take the mach3 pulses and extend the width from 15us to 1500-2000us. When using this between the computer and SC954 drive, I am able to get a huge improvement in reading response. I'm using 20um for a single movement step, and with this ~20in/min is the max. speed. I was trying out the accuracy by jogging at different speeds and just random movements, and it's quite good; it says within about 0.003" (80um). Under certain manual pulsing conditions the error accumulates to 0.004-0.008", which is higher than I want with this setup. I'm thinking it's either out of sync pulse to what the drive will read or something to do with the servo tuning and how it responds under certain conditions or it could be noise in the arduino board. I'm going to try and change the control scheme of the drive to absolute instead of incremental to see effects the performance under mach3 pulse control. What i'm wanting to get is something that is accurate to about 20um or 0.001" along the whole axis travel and all speeds from 0 to 20"/min. This has turned out to be very challenging, but very rewarding. Thanks for reading.

  20. #20
    Join Date
    Sep 2006
    Posts
    177

    Re: AC servo conversion on CNC Patriot VFD machine

    I tried the absolute positioning scheme of the drive (SC954 Pacific Scientific) and the same errors accumulated under certain pulsing conditions.

Page 1 of 2 12

Similar Threads

  1. Replies: 0
    Last Post: 03-24-2014, 08:33 PM
  2. servo conversion vs stepper conversion
    By contractdesign in forum Bridgeport / Hardinge Mills
    Replies: 3
    Last Post: 07-26-2008, 08:54 PM
  3. X3 servo conversion questions
    By JB_in_Fla in forum Benchtop Machines
    Replies: 11
    Last Post: 04-18-2008, 06:06 PM
  4. Upgrade to Patriot Machine
    By Tweasl in forum Shopmaster/Shoptask
    Replies: 7
    Last Post: 04-09-2008, 06:35 PM
  5. New Patriot Machine out
    By gofastscottb in forum Shopmaster/Shoptask
    Replies: 11
    Last Post: 01-28-2008, 02:36 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •