585,766 active members*
3,964 visitors online*
Register for free
Login
Page 1 of 2 12
Results 1 to 20 of 28
  1. #1
    Join Date
    Oct 2012
    Posts
    44

    Axis's creeping away...

    I just got the wiring and most of the programming done on my Tree 325 retrofit. (Kflop/Kanalog) After battling with an air pressure interlock (forgot I tied that in...) I got the E-stop loop enabled, which activates the servo cards.
    As soon as they go enabled, all three axis's began creeping slowly (may 5 IPM) in a particular direction. (When I say enabled, the relay supplying voltage to it gets turned on. Has nothing to do with the KFLOP)

    The DAC's appear to read 0V.

    Is this what people refer to as run-away? It seems that if the gains were backward, it would go to full rapid speed... not slowly, steadily roll one way.
    I hesitate to reverse the gain, lest I create a REAL run away and crash something.

    Is there something I should check?

  2. #2
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    This is a common issue with analog drives. It is almost impossible to command exactly zero speed with an analog signal with no offset or noise. This won't matter when the servo is enabled because the servo will command whatever voltage is necessary to hold position. It is only a problem when the servo feedback loop is disabled. The only sure way to avoid creep is to disable the amplifier. If you allow KFLOP to enable/disable the amplifiers you can avoid this. You will need to add a watchdog loop that watches the axis enables and if any are disabled then disable the amplifiers.

    There is also an Axis Channel OutputOffset parameter that can be used to reduce the creep.

    HTH
    Regards
    TK
    TK
    http://dynomotion.com

  3. #3
    Join Date
    Oct 2012
    Posts
    44
    Tom,
    I've done a bit of digging.

    As it stands now, the amps can't activate unless the SWENABLE relay driver on the Kanalog is activated.

    So that means I might have an encoder feedback problem? I did notice on the axis screen that when I manual moved the axis, some of them would advance one way, but not the other. Z didn't seem to change at all. Y worked fine both ways, but was still creeping.


    I have my servo tachs on the same ground pin as the servo amps... would that cause this issue if they were referencing different grounds?

  4. #4
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    Using the SWE (Switch enable output) doesn't fully solve the problem because it comes on as soon as KFLOP boots up and initializes all the IO but before the servo is initialized and enabled. You really need an additional enable output that you can turn on at the same time as you enable the servo.

    Working or not encoders will have no effect on this drift when the axis is disabled (but the amplifiers are enabled). But it doesn't sound like they are working properly. If you rotate them by hand the position should track and return to the same position when the encoder goes back to the same position.

    A common problem is to wire single ended encoders to the Kanalog differential inputs leaving half of the inputs floating. This will not work.

    Regards
    TK
    http://dynomotion.com

  5. #5
    Join Date
    Oct 2012
    Posts
    44
    Thanks!

    I'm still a bit confused though. The way my system is setup is that the servo amps are activated is by the relay Estop replay 1CRE (pg3, upper right hand corner)

    In order for this to pull in, I have to hit a physical "reset" button on the user console. (makes wire 214 +24V via a momentary on button.)
    So, the amps can't really come on 'till I hit that button, and even if I wait a few seconds and hit reset the problem persists.

    I suppose I could move the output anyway, but it still seems like I'd have this problem. Could there be a problem with my drive initialization code that's causing the drives never to enable?
    Attached Files Attached Files

  6. #6
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    Aren't we all

    I don't really understand your point or the sequence of operations.

    But yes, if you wait however long and then just enable the amplifiers then they will always start drifting.

    The key is to enable the amplifiers and the servo at the same time. So the amplifier enables need to be interfaced to KFLOP so your init program can do both.

    But before you worry about slow drift when disabled you should get your encoders and servos working.

    Regards
    TK
    http://dynomotion.com

  7. #7
    Join Date
    Oct 2012
    Posts
    44
    Ok. I beleive what you're suggesting is this:

    The init program will have all the axis initialization information... Then will enable the drive using the appropriate code, then set the appropriate bit to HI to turn on the servo amps. Assuming I fix the encoder reporting issue, I won't have the drifting problem?

    The sequence of operations is as follows (Currently):
    -PC boots
    -I turn on the 24V and 5V power supplies, and by extension, the KFLop board.
    -A few seconds pass
    -I press the physical "reset" button. Then, as long as the EStop button isn't pushed, there is no overtravel condition, the air/lube levels are fine, the spindle is online, and no overloads are tripped, the servo amps can enable. The circuit is a latch-on type, so it stays on until one of the above conditions is no longer true.

    I'm afraid I don't understand what you mean by this:

    "The key is to enable the amplifiers and the servo at the same time. So the amplifier enables need to be interfaced to KFLOP so your init program can do both."
    I understand that amplifiers need to be turned on when the servo is enabled. But what is the difference between the servo and it's amplifier? What enables the servo? Is it all the code created by the "config and FLASH" screen? Or is it "EnableAxis()" command? Basically I need to have the "EnableAxis(...) followed by "setBit(XX)=1" (where that bit turns on the DC amplifiers)?

    I'm not trying to be difficult, I just think there's some basic level of understanding of terminology that I'm lacking!
    Your help is much appreciated.

  8. #8
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    I think you get what I mean. Sorry for using the ambiguous term "servo". I'm probably the one using the wrong terminology. I should have indicated I meant the EnableAxis C function. When a KFLOP Axis Channel is disabled it basically does nothing except commands the DAC output to zero. After EnableAxis is called then the KFLOP Axis Channel begins doing the servo calculations based on the encoder position and commanding DAC output voltages.

    The majority of the code in the Init C program is not the "servo". But it is setting parameters that will be used by the servo calculations.

    So yes, the Init program should enable the external amplifiers and call the EnableAxis function at about the same time. It probably is a bit smoother to enable amplifiers a few milliseconds before calling EnableAxis depending on how long it takes for the amplifiers to be ready. It is usually better to have the amplifiers come on early and accept slow drift for a few milliseconds, rather than have KFLOP try to make corrections before the amplifier is ready to respond which might cause bigger and bigger correction attempts and then a big jump when the amplifiers finally respond.

    HTH
    Regards
    TK
    http://dynomotion.com

  9. #9
    Join Date
    Oct 2012
    Posts
    44
    Thanks for your help! that all makes more sense.

    I'm trying to figure out why my servos are acting all crazy. Im sending +4.6V to the encoders, and am getting a 1.4 to 1.42v signal to the JP1 on Kanalog.

    Are those inputs LVTTL? Is 1.4V enough for the Kanalog to detect? The encoder that works perfectly is at 1.42V, and has the shortest physical run to the encoder. The one that works in one direction, but not the other, is at 1.42V on one channel, and 1.41 on the other. The axis that doesn't seem to respond at all is 1.41V, and is physically the farthest away.

    Do I need more voltage to get the encoder inputs to work? what's the voltage threshold?

  10. #10
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    That doesn't sound right at all. A differential driver should put out at least 3V. And there should be 2 signals a + and a - signal. When one is high (at least 3V) the other should be low (less than 0.4V). Differential inputs need for the difference between the two inputs to swing positive and negative.

    A common mistake is to think you can connect a single ended output to one of the differential inputs and just leave the other floating (unconnected). But this will not work.

    Regards
    TK
    http://dynomotion.com

  11. #11
    Join Date
    Oct 2012
    Posts
    44
    I'm pretty sure the encoders are differential. I'll attached a picture of the original electrical diagram. I hooked the encoders up the same way.

    The only thing not shown on this is that there are 1K pull-up resistors on each of the channels... so channel A is pulled up to 5V, and the -A is not.

    It still seems like this would bring them to 5Volts, or at least closer than 1.4!
    Attached Thumbnails Attached Thumbnails ENCODER.jpg  

  12. #12
    Join Date
    Oct 2012
    Posts
    44
    Tom,
    Based on the wiring, it looks like these are differential, no?

    As of now, one encoder works just fine.

    One encoder will read corrected when I manually move the motor one direction, but not the other.

    The third encoder doesn't register at all.

    All of the axis's worked great when the old control was removed. I'm not sure how to diagnose them.

  13. #13
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    It definitely looks to be a differential encoder if the wiring diagram is accurate.

    Encoders are fairly easy to diagnose. Completely disconnect them from everything, apply +5V power, rotate the encoder, and the A+ A- B+ B- outputs should toggle high (>3V) and low (< 0.5V). If they don't all toggle then either the wiring is wrong, they aren't really differential drivers, or the encoder is bad.

    The toggling may be too fast to see with a voltmeter but if you stop at random positions then any signals should be sometimes high and sometimes low at random.

    Whatever state one signal is at (high or low) the complementary signal should always be the opposite.

    In your case of seeing only 1.4V unchanging then something is wrong. Most likely no power or ground connections.

    HTH
    Regards
    TK
    http://dynomotion.com

  14. #14
    Join Date
    Oct 2012
    Posts
    44
    Tom,
    I disconnected the encoders from the Kanalog board. They all worked fine - cycling 0 to 5V and all that.

    I re-attached them to the Kanalog board, and they were right back to reading 1.4V again!

    I've ensured that the power and ground connections are good, and the Kanalog board connects to the same ground on the 5V supply that they encoders do.

    Would the fact that the USB cord still poweres the Kanalog board potentially cause a problem? I'm grasping at straws here!

  15. #15
    Join Date
    May 2006
    Posts
    4045
    Hi Nick,

    I can't imagine what could be going on. Kanalog has a 470 ohm termination resistor across the + to the - input. This is no problem for a standard differential driver to drive. But I would suggest to disconnect the encoder again, apply separate +5 V power to the encoder, verify that the outputs toggle properly (3V or more), then add an external 470 ohms across the + to - outputs and check that they still toggle properly.

    An extra ground connection to the USB Ground/PC Ground should not matter.

    You are connecting to Kanalog JP1 or JP2 correct?

    I suppose the Kanalog could be somehow bad. With power off and everything disconnected you should read ~470 ohms across the + to - inputs. There should also be a high resistance >20Kohms to ground or +5V.

    You could also verify that there is no problem with the Kanalog somehow forcing the pins to be at 1.4V by connecting an external resistor of ~200ohms from the Kanalog input to +5V or Ground and verify that the voltage goes high and low.

    HTH
    Regards
    TK
    http://dynomotion.com

  16. #16
    Join Date
    Dec 2011
    Posts
    0
    Tom / Nick


    I've used a few differential line driver style encoders (RS422) and have never personally needed additional termination resistance or pull up resistors. I have a few (Encoder Products HV line driver type) connected to my test KFLOP+KANALOG This system is powered by a MeanWell QP-200D which supplies the 5V for KFLOP and the Encoders, as well as supplying +24V for other servo controls.

    I have never connected differential encoders with additional hardware... simply +VDC, COM, and A to A and /A to /A, etc. I should also note I am no EE or Encoder Guru and for that matter I have also never tried connecting line driver encoders with runs much longer than 10'.

    That said...

    Looking at your original Encoder (ENCODER.JPG) Image I see the 1k pull-up resistors on A, B, and MARKER. In that Image I also notice that /MARKER is not connected at all [NC].

    Regardless of whether or not you connect the Marker on KANALOG JP2 (which it appears you are not anyway) the fact that the original setup was using it (and deliberately left one end of the "differential" output floating), leads me to believe this is not a RS422 Line-Driver style "differential" encoder.

    Perhaps it is an Open-Collector with Complementary "differential" outputs? Sounds like a mouthful, but I know EPC (Encoder Products) offers "Specialty Output" Types on select models that provide exactly that type of output. They call them OD type.

    Just some thoughts in an attempt to help troubleshoot.

    Best Regards

    Patrick

  17. #17
    Join Date
    May 2006
    Posts
    4045
    Open Collector encoders are common on older systems, but I don't think that would explain the signals at 1.4V. Open collector would drive the signals low and without any pull up they would probably always remain low. So I'm at a loss to explain what he is seeing. An open and undriven input will often float at ~1.4V but Nick said he checked the wiring.

    Regards
    TK
    http://dynomotion.com

  18. #18
    Join Date
    Oct 2012
    Posts
    44
    Quote Originally Posted by TomKerekes View Post
    Open Collector encoders are common on older systems, but I don't think that would explain the signals at 1.4V. Open collector would drive the signals low and without any pull up they would probably always remain low. So I'm at a loss to explain what he is seeing. An open and undriven input will often float at ~1.4V but Nick said he checked the wiring.

    Regards
    All Jp1 terminals read ~470 ohms, 50K to ground, open line to the 5V.

    I applied 5V to the encoders, and a 330+150 (480 total) ohm resistor - and the voltage read 1.5 volts. The other channel of the encoder would read 4.95. So, something about having 470 ohms across it holds the voltage to 1.4 volts. (It would cycle to 0 volts as I moved the encoder.) This phenominon follows the resistors.
    I'm not sure what to do here. do I need a pull down resistor on the channel negative side? remove the pull up?

  19. #19
    Join Date
    May 2006
    Posts
    4045
    They might be open collector outputs that will require pull up resistors.

    But I don't understand exactly what you have wired and where you are measuring. Are you placing the 480 ohms across the + and - pins of either the A side or the B side? Actually there should be two 480 ohm resistors. One for the A side and one for the B side.

    Are there any pull up resistors installed? It seems like there is only a 1K pull-up on one of the signals (+ or -) like what was shown in your diagram. Is that included in this test?

    If so it seems like they are open collector outputs and should have pull up resistors on both signals. I don't understand how it could have originally worked well before with a pull up only on one side. With a pull up on both signals both signals should toggle in a complementary manner between about 0.4V and 1.4V which should be enough for Kanalogs Differential input. The inputs will "see" +1.0 and -1.0V. A stronger pull up of about 500 ohms might be better.

    Regards
    TK
    http://dynomotion.com

  20. #20
    Join Date
    Dec 2003
    Posts
    24220
    Quote Originally Posted by nickcornilsen View Post
    Tom,
    I disconnected the encoders from the Kanalog board. They all worked fine - cycling 0 to 5V and all that.

    I'm grasping at straws here!
    What is the make/model # of the encoders?
    Al.
    CNC, Mechatronics Integration and Custom Machine Design

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

Page 1 of 2 12

Similar Threads

  1. Z Axis creeping
    By RustedOut in forum Charter Oak Automation Support Forum
    Replies: 53
    Last Post: 09-26-2012, 06:56 PM
  2. Kaliburn CNC Plasma- Motors Creeping
    By Donie in forum Waterjet General Topics
    Replies: 2
    Last Post: 12-23-2011, 11:38 AM
  3. 8020m - unable to adjust creeping axis
    By alphonso in forum Fagor Automation
    Replies: 3
    Last Post: 06-02-2009, 01:52 PM
  4. Z axis creeping up!
    By MAX711 in forum Mach Software (ArtSoft software)
    Replies: 8
    Last Post: 07-13-2006, 12:33 AM
  5. Problem with Z Axis creeping up
    By HansM in forum DNC Problems and Solutions
    Replies: 31
    Last Post: 09-10-2005, 04:16 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
  •