586,103 active members*
3,718 visitors online*
Register for free
Login
IndustryArena Forum > CNC Electronics > Stepper Motors / Drives > Can you switch DC power to stepper drivers?
Results 1 to 9 of 9
  1. #1
    Join Date
    Dec 2009
    Posts
    1416

    Can you switch DC power to stepper drivers?

    Planning out some stuff for my control enclosure and electronics and I have a question. The DC supply for my steppers has a nice convenient 5 and 12 volt output in addition to the 50v power to the stepper drives. Using that to power the electronics however would mean that the stepper drivers would be on before I would be ready for them to be up and listening. My original idea was to have the electronics close a relay to the mains power of the stepper powers supply to turn them on and off - not going to work if I pull the power for the electronics from that supply.

    So my question is, can you switch off the DC supply to the steppers instead of the AC supply to the stepper power supply? I thought I read a note once that it was not good to do that, but now I can't seem to find the right terms to search it up again. All I keep finding is cautions to not unplug the motors from the drives while they are powered on.
    CNC: Making incorrect parts and breaking stuff, faster and with greater precision.

  2. #2
    Join Date
    Dec 2003
    Posts
    24221
    Why not have a small relay contact, multi-pole if necessary, to hold the stepper drives enable off until your system E-stop is released.
    Al.
    CNC, Mechatronics Integration and Custom Machine Design

    “Logic will get you from A to B. Imagination will take you everywhere.”
    Albert E.

  3. #3
    Join Date
    Dec 2009
    Posts
    1416
    Yeah, guess there are a ton of ways to skin the cat. I have been using EMC's notion of [Machine Power] which has to be toggled on through the GUI after E-Stop is released to handle the enable. Only issue is that the stepper driver's enable is active low which makes it more inconvenient since the absence of a signal while the driver is powered is considered 'enabled'. It works now because my current E-Stop is wired to the BOB enable so even though the drives are on and ready the BOB will not pass a signal till E-Stop is released. The C10 BOB is going away though since I am moving to a Mesa 7i43P for step generation and I/O.

    So I guess I need to come up with a pull-up on the driver enable that is powered with the drives and then snapped low by [Machine Power] when the system is ready to take control. Switching the power to them seemed easier and more fail-safe but then I have to get another 5V supply for the electronics. I suppose I can look to make the E-Stop circuit directly trigger the enables on the drives too that makes it a little more fail-safe I guess.

    I just read on the Gecko site that you are not to switch the DC side of their stepper drives so I'm guessing that this just an overall no-no of chopper drives in general.
    CNC: Making incorrect parts and breaking stuff, faster and with greater precision.

  4. #4
    Join Date
    May 2006
    Posts
    41
    Here's the basic issue - motors and generators are very mechanically similar.

    Step motors, like many permanent magnet motors, will generate electricity if back-driven. Imagine a motor generating power, and dumping it back into its driver.

    If you generate enough power, and it has no place to go except a relatively small local capacitor inside the drive, it can build up significant voltage. High enough to damage components.

    Power supplies, particularly linear supplies, tend to have large output capacitors. While a drive is attached, those capacitors give the charge somewhere to go, hence the voltage spike is muted.

    That's why they tell you not to put a switch on the power input. If you backdrive the motor with no supply attached you can generate a current which induces a voltage spike and kills the drive.

    Assuming that the drive you're using has the typical "protection" diodes which prevent current from flowing the wrong way through the output devices, it's possible to disconnect a drive from a power supply as long as you give a potentially damaging charge someplace to go. If you've got a decent range between the normal operating voltage and the maximum rated drive voltage, you could provide a TVS diode on the drive terminals, rated somewhere in the range to clamp the voltage.

    Or, if you must install a switch, you could install a power diode "backwards" across the DC power switch to give the current an "escape route" back to the supply once the drive voltage exceeds the power supply voltage.

    Or, like Al pointed out, you can just disable the drives till you need them.

  5. #5
    Join Date
    May 2005
    Posts
    1397
    Disable the drives until you need them.

  6. #6
    Join Date
    Dec 2009
    Posts
    1416
    The main issue is the Keling interprets disconnect as enabled so simple switching of the enable input wouldn't work. Also a weak pull-down resistor won't do it either so unless you drive it low it's on.

    I have made a circuit that should work though. It's an AND gate that will drive the output to ground and with enough drive to make it disable. The gate takes EStop and machine enable as inputs. If either is not on then the output is low.

    This avoids all the issues with killing power to the drives. I wish they had not made it default to enable when disconnected. It would not be hard to wire that input to +5 if you didn't need the enable.


    Sent from my iPod touch using Tapatalk
    CNC: Making incorrect parts and breaking stuff, faster and with greater precision.

  7. #7
    Join Date
    May 2005
    Posts
    1397
    Quote Originally Posted by photomankc View Post
    The main issue is the Keling interprets disconnect as enabled so simple switching of the enable input wouldn't work. Also a weak pull-down resistor won't do it either so unless you drive it low it's on.
    I'm not sure I understand why simple switching would not work... all you need is a toggle switch that drives the enable input to ground. You turn it on to disable the drivers, then power up, and finally open the switch to re-enable when ready.

    Of course, the more automatic way of doing that is to connect the enable lines to the PC. That is what I do on my 4Axis BOB:
    techref.massmind.org/techref/io/stepper/linistep/4axis5build.htm#DB25 the enable lines for the axis come back to the parallel port pins. As long as the PC is up and running first (and it normally would be right?) then the enables are held low while you power up the machine and then are brought high by the CNC software prior to each run. Most programs have motor enable systems that can be setup to automatically disable the motors after each run, or when the motors are not moving for some period of time, and then re-enable them prior to moving again.


    Quote Originally Posted by photomankc View Post
    I have made a circuit that should work though. It's an AND gate that will drive the output to ground and with enough drive to make it disable. The gate takes EStop and machine enable as inputs. If either is not on then the output is low.
    Great solution! Note that as long as nothing is driving the enable high, then all you need is to wire your estop and enable switches together. If either of them grounds the pin, the drives are disabled. They both must be open before the drive can run. That is an AND gate with no AND gate! One of the little tricks you can use with "open collector" signals like this where disconnected is on.

    Even if you hook up to the parallel port, depending on which signals you use, you can still just wire your estop or limit switches on top of the enable line. For example, the nSelectIn signal from a standard parallel port is open collector:
    techref.massmind.org/techref/io/parallel/signals.htm

    Quote Originally Posted by photomankc View Post
    This avoids all the issues with killing power to the drives. I wish they had not made it default to enable when disconnected. It would not be hard to wire that input to +5 if you didn't need the enable.
    I understand the concern, but keep in mind, they have a lot of users who would never even look at the enable line, and if you don't set it to be fully on when nothing is connected, you are going to get a lot of support calls!

  8. #8
    Join Date
    Mar 2003
    Posts
    35538
    Why do you need the drives to be disabled at all? The motors won't move unless steps are being sent from EMC.

    Most people tend to be concerned about inputs and outputs being toggled during power up. But it shouldn't be any problem at all with stepper drives, as again, they won't do anything until steps are sent to them.
    Gerry

    UCCNC 2017 Screenset
    http://www.thecncwoodworker.com/2017.html

    Mach3 2010 Screenset
    http://www.thecncwoodworker.com/2010.html

    JointCAM - CNC Dovetails & Box Joints
    http://www.g-forcecnc.com/jointcam.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  9. #9
    Join Date
    Dec 2009
    Posts
    1416
    Quote Originally Posted by James Newton View Post
    I'm not sure I understand why simple switching would not work... all you need is a toggle switch that drives the enable input to ground. You turn it on to disable the drivers, then power up, and finally open the switch to re-enable when ready.

    Of course, the more automatic way of doing that is to connect the enable lines to the PC. That is what I do on my 4Axis BOB:
    techref.massmind.org/techref/io/stepper/linistep/4axis5build.htm#DB25 the enable lines for the axis come back to the parallel port pins. As long as the PC is up and running first (and it normally would be right?) then the enables are held low while you power up the machine and then are brought high by the CNC software prior to each run. Most programs have motor enable systems that can be setup to automatically disable the motors after each run, or when the motors are not moving for some period of time, and then re-enable them prior to moving again.
    Yes a toggle could do that but not if another system drives that line too. If the toggle to ground disagrees with a PC signal of high well that's a short. I guess a really stout pull-down could work but a toggle switch was not my plan. Just wanted the machine enable signal to enable all the electronics but an EStop to completely over-ride all of that and force everything off.


    Great solution! Note that as long as nothing is driving the enable high, then all you need is to wire your estop and enable switches together. If either of them grounds the pin, the drives are disabled. They both must be open before the drive can run. That is an AND gate with no AND gate! One of the little tricks you can use with "open collector" signals like this where disconnected is on.

    Even if you hook up to the parallel port, depending on which signals you use, you can still just wire your estop or limit switches on top of the enable line. For example, the nSelectIn signal from a standard parallel port is open collector:
    techref.massmind.org/techref/io/parallel/signals.htm
    Thanks for the reference stuff. I'm actually using an external control card so the parallel port is just passing data to the external card not signals. The card however is indeterminate until the firmware loads so that is why I wanted the following true before drives or mill power enables:

    1.) EStop is released.
    2.) Machine Power is commanded on.
    3.) Watchdog is getting attention from control program.

    Might be over-kill but that seemed logical given EMC's startup procedure which is to both release estop and then activate Machine Power.

    I understand the concern, but keep in mind, they have a lot of users who would never even look at the enable line, and if you don't set it to be fully on when nothing is connected, you are going to get a lot of support calls!
    Yeah I get that, just wouldn't seem to tough to grasp to have it simply marked to bypass enable with +5v. Then again, I don't have to answer the phones or emails. It just irked me that the circuit they show as the input is a simple resistor and LED opto, but there must be more to it because that is not going to activate when disconnected AND disable when driven low.

    As is usually the case though, there are probably 10 ways to do this 9 of which are easier than I thought. The AND gate just struck me as a way to combine the signals, not goof and create a short in some unforeseen combination, and have the ability to turn the steppers off when not in use to reduce power consumption and heat as well as make the system more directly dead in the event I hit EStop without relying on EMC to pass that along.
    CNC: Making incorrect parts and breaking stuff, faster and with greater precision.

Similar Threads

  1. Need help w/ gecko drivers and power supply
    By m8kingit in forum CNC (Mill / Lathe) Control Software (NC)
    Replies: 8
    Last Post: 11-27-2008, 01:26 PM
  2. Buying Drivers and power supply AGAIN!
    By mulligan in forum Stepper Motors / Drives
    Replies: 5
    Last Post: 03-10-2008, 02:05 PM
  3. Steppers, Drivers and Power supply
    By robertg991 in forum Stepper Motors / Drives
    Replies: 21
    Last Post: 05-22-2006, 03:03 AM
  4. stepper drivers
    By Nilesh in forum CNC Machine Related Electronics
    Replies: 3
    Last Post: 06-23-2004, 02:05 AM
  5. stepper drivers
    By DDM in forum DIY CNC Router Table Machines
    Replies: 1
    Last Post: 01-19-2004, 07:58 AM

Posting Permissions

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