584,865 active members*
4,957 visitors online*
Register for free
Login
Page 1 of 2 12
Results 1 to 20 of 29
  1. #1
    Join Date
    Nov 2014
    Posts
    19

    KFLOP in CL Step Mode - Output Instability

    Hey there,

    I'm back again (and so soon). I just got my Kflop talking to my Gecko to run my motors (Check). Next step is figuring out how to configure KMotion in CL Step mode to help control my motor position. I've spend the last couple hours trying to figure out the best set of values to use across the Config and Step Response screens, but I'm having trouble understanding what I'm seeing. There's no load on my motors, so I had assumed that my encoder would simply track the motor Position and no corrections would be applied. However, as soon as I try to increase my Integral Coefficient to anything besides '0' my Output (or Correction) immediately goes off the charts. Here's my setup:

    Controller: KFLOP (powered by USB)
    Driver: Gecko G540
    Motors: NEMA 23s w/ Encoders (STP-MTR-23079E)
    Encoders: Incremental with Line Drive (Differential) Output (STP-MTRA-ENC9)

    The encoders are sending 400 ppr so for Quadrature I'm assuming that means 1600 counts per revolution. The Gecko automatically applies 10 usteps per full step and my motors have the standard 200 steps per rev. All this together means my Gain = 2000/1600 = 1.25. I've tried other values, but they just make the situation look worse. I also setup a 2nd Order Low Pass filter following the example on the Dynomotion website (Freq = 100Hz, Q =1.4) and Downloaded it to the KFlop, but I didn't seen any change in behavior.

    I ended up limiting the Max Correction applied until I can fix the in stability, I realize I'm probably asking super newbie questions again, but please know it's with the intention of learning more.
    Please see attached screen shots and, as always, any advice would be greatly appreciated.





  2. #2
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    Hi,

    I think you have the Input Gain set correctly as without corrections it follows quite well. When it is following well its better to plot error to better see how it is doing. Also post the raw data (zipped) so we can plot and zoom however we wish.

    Its good to fully characterize the open loop system (PID gains 0) to see what size and under what conditions the errors are. Then go open loop to see if things can be improved.

    I think you simply have too high I gain so it is violently over correcting causing an overshoot stall and so on. You didn't tell us what values you tried. Maybe try 0.0001 then start increasing.
    TK
    http://dynomotion.com

  3. #3
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    Quote Originally Posted by TomKerekes View Post

    I think you simply have too high I gain so it is violently over correcting causing an overshoot stall and so on. You didn't tell us what values you tried. Maybe try 0.0001 then start increasing.
    Good advice. I started smaller and was better able to characterize the behavior of corrections for various Integral values. The results of my experiments are attached below. I left the Input Gain at 1.25 and set my V to 80000 which should correspond to 120 IMP. My machine is very small with a work area of 12" x 13" x 4" and doesn't cut much more than wood, I doubt I'd try to go much faster. I have Move and Step plots for Integer Coefficients of 0, 0.001, 0.005, 0.007, 0.01. Move Size of 60000, and Step Size of 10. All data is zipped and attached as well across the next few posts.

    In my layman's opinion it seemed as though I = 0.005 was the most well behaved. For I > 0.005, following the Step tests, I could here my motor continue to make tiny adjustments even as it was just sitting there with no Commands to execute. I'm assuming this is in response to noise in my Encoder signal (I have Diff Encoders, but I'm only using them as Solo), however, it's strange because I don't see this behavior following a Move test, only following a Step test.

    My questions go as follows:

    1) Which of these do you think looks the best and why?

    2) It seems as though I'd want the quickest response from my Control Loop possible without creating instability. So if I'm stable at I=0.005 it would be preferable to I=0.001. Does this track?

    3) I'm surprised the control loop could be made to stall the motor so easily. Should I set my Max Output to something much smaller to avoid that possibility? If my motors start lagging too far behind (let's say 0.005") I'd probably be better off stopping everything with Max Following Error rather than having my Control Loop fail to compensate, stall the motor, and create a huge error anyway.

    4) Should I be worried that I can't set my Step Size much higher than 10 Microsteps? This only corresponds to 0.00025" but when I set my tool height or locating a specific position I'm usually approaching at 0.001" for each tap of my keyboard. I'm assuming KmotionCNC and Mach3 ramp their step commands to avoid this kind of problem, but I don't know that for certain.

    5) Unrelated, but is there a way to keep my Configurations saved on the Kflop? Or do I have to write a C program and enable a thread to reload everything because it only has volatile memory? If it's the later than would it be sufficient to "Export All to Open C Program" for each axis and just save and run that as a thread? For that matter, how would I set my PID or VAJ values when I'm running a program in Mach 3 or KMotionCNC? Do those get sent to the Kflop and just continue to apply automatically, or are they enacted by the CNC software itself?

    I hope that's not too many questions in a row. I can start a new thread for the last set of inquiries and title it something more appropriate if that's preferable.

    Thanks again for all your help Tom! You're quite the life saver.

    MOVE TEST I = [0, 0.001, 0.005, 0.007, 0.010], V = 80000, Size = 60000

  4. #4
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    STEP TEST I = [0, 0.001, 0.005, 0.007, 0.010], V = 80000, Size = 10

  5. #5
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    MOVE Test Data Attached

  6. #6
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    STEP Test Data Attached
    Attached Files Attached Files

  7. #7
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    1) Which of these do you think looks the best and why?
    Well it sort of up to you to balance responsiveness to smoothness and stability. Maybe I = 0.005


    2) It seems as though I'd want the quickest response from my Control Loop possible without creating instability. So if I'm stable at I=0.005 it would be preferable to I=0.001. Does this track?
    Yes. They all look stable to me.


    3) I'm surprised the control loop could be made to stall the motor so easily. Should I set my Max Output to something much smaller to avoid that possibility? If my motors start lagging too far behind (let's say 0.005") I'd probably be better off stopping everything with Max Following Error rather than having my Control Loop fail to compensate, stall the motor, and create a huge error anyway.
    Most instabilities will keep increasing in amplitude, velocity, acceleration until something fails. Yes Max Output shouldn't really ever come into play if Max Following error is used to disable the axis beforehand. Max Error can be useful to correct large errors gradually. For example if there is somehow a large error then rather than the Integrator ramping at a large rate and stalling the motor, Max Error can treat large errors as smaller errors and make corrections more gradually. But with such a small Max Following Error it is pretty much mute also.


    4) Should I be worried that I can't set my Step Size much higher than 10 Microsteps? This only corresponds to 0.00025" but when I set my tool height or locating a specific position I'm usually approaching at 0.001" for each tap of my keyboard. I'm assuming KmotionCNC and Mach3 ramp their step commands to avoid this kind of problem, but I don't know that for certain.
    No. Making a large instantaneous step is likely guaranteed to create a stall or missed steps. A real system will never do this. The KMotionCNC and Mach3 "steps" are really moves with limited acceleration and velocity.



    5) Unrelated, but is there a way to keep my Configurations saved on the Kflop? Or do I have to write a C program and enable a thread to reload everything because it only has volatile memory? If it's the later than would it be sufficient to "Export All to Open C Program" for each axis and just save and run that as a thread? For that matter, how would I set my PID or VAJ values when I'm running a program in Mach 3 or KMotionCNC? Do those get sent to the Kflop and just continue to apply automatically, or are they enacted by the CNC software itself?
    Its possible to Flash things into KFLOP but we don't recommend it. Eventually you will create a C Program to Configure and initialize everything and this can be performed with an INIT button in KMotionCNC or the RESET button in Mach3. See also here.

    Overall the results look good to me. The errors at velocity have been reduced from about 20 steps to near zero. During Acceleration reduced from about 20 to about 7.

    You didn't show us what Filter you are using. You might try different Frequencies to see if you can get better results.

    You might be able to reduce the Start/Stop Errors with Feed Forward. The basic process is that without FF there are normally lags in the response. Increasing FF should reduce the lags. Increasing too much will result in a lead instead of a lag.
    TK
    http://dynomotion.com

  8. #8
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    Ok great, sounds like I'm making some progress. I spent the last couple days attaching and wiring up my Limit Switches, but I'm not sure how the KFLOP (or KMotion) interprets the signals. I'm running my switches in Normally Closed mode to make sure I detect if one of the wires comes loose. I also wired the two switches on each axis in series so that the signal would go from High to Low regardless of which one is tripped. On the KFLOP side I tried to hook up the supply side of each switch pair to either 3.3V or 5V and then the ground side to the Pins on which I'm listening for a drop in the signal. For Axes X,Y,Z I used Pins 13 (IO6), 14 (IO7), and 21 (IO14).

    I then opened up the Digital IO screen to see if depressing the switches would register in real time. When hooked up to the 5V supply, Pins IO6, and IO7 stayed High but were unresponsive to my triggering the switches. IO14 did respond to a pressed switch, but would alternate On/Off while the switch remained depressed. Confoundingly, Pin IO 15 would respond to the switch as well, holding it's value when the switch wired to IO14 was depressed.

    When hooked up to the 3.3V supply, all three IO pins would alternate On/Off and did not seem to notice my pressing any Limit Switch. I feel like I'm making some simple mistake here on the software side. I tested all my switches for continuity, so it's not a wiring issue. What am I missing? If I just shorted a supply pin to a GIO pin shouldn't that pin stay High unless the signal is physically interrupted?

    Also, for my filter I'm just using the Q and Freq from the example on your website, Freq = 100, Q = 1.4 What do these numbers usually depend on? I understand the Freq value limits how often corrections are made, but what does Q represent? Which value would you say is more important to increment for response testing? Lastly, what's a good starting point and increment? I think I should be able to notice myself how changes effect the response behavior from the Position Error plots. Same questions for FF, what's a good starting value and increment for teasing that out?

    Thanks again all your invaluable help!

  9. #9
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    Hi,

    First of all avoid connecting any KFLOP IO directly to 5V. KFLOP are 3.3V IO and are clamped to the 3.3V Supply Rail. So connecting to 5V causes large clamping currents.

    KFLOP IO are extremely high impedance and must be driven low and high. If left open they can float to any voltage level and basically change at random. 8 pins each on KFLOP JP4 and JP6 have built in pull down resistors. So you might use those instead as they will guarantee to go low when disconnected. Note those IO will be damaged if connected to +5V.

    Note 3.3V signals are not normally used for limits. They may pick up noise or even voltage spikes that if large enough may damage KFLOP. Instead opto isolated 24V signals such as those provided by our Konnect board, or your own circuitry, or 3rd party devices might be used.

    I don't understand your 3rd paragraph. Connecting to 3.3V should always read high. I suspect you had a wiring mistake. You should check the voltage at the KFLOP input pins with a voltmeter.

    Regarding low pass filter: The filter basically has no effect until the specified frequency and then starts passing signals less and less for signals at higher and higher frequencies. The simplest approach is to just experiment with frequencies in the range from about 30Hz to 300Hz and for each frequency re-optimize the I gain to see which gives the overall best performance. Q basically controls how smoothly the filter curves down. Just leave it at 1.4.

    Regarding FF: Normally without FF servos lag somewhat behind when accelerations or velocities change. FF can make an immediate change when accelerations or velocities change. Start with a small enough number to observe no effect (ie 0.0001) then increase until you observe an effect. When the errors begin to lead any changes then the value is too large.

    HTH
    TK
    http://dynomotion.com

  10. #10
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    Quote Originally Posted by TomKerekes View Post
    Hi,

    Instead opto isolated 24V signals such as those provided by our Konnect board, or your own circuitry, or 3rd party devices might be used.

    HTH
    Ok sounds like I misunderstood how KFLOP reads signals. And it makes sense that I would need to isolate those from noise. I did a little reading about my Gecko G540 and I'm seeing folks run their switches through that board like shown below.



    Looks like these inputs get isolated with a ILQ74 Optocoupler. Based on this diagram this would provide me with a 12V opto isolated signal. Could I use that?

    Also, please forgive this very basic, but critically important question: If I were to route a 24v signal from the Konnect (or this 12V signal from my G540) to one of the KFLOP general IO pins, wouldn't that exceed the 5v tolerance? Just trying to understand how this works, so I don't damage my board.

    Many thanks

  11. #11
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    I did some more troubleshooting. When I hook up my switches through the optocoupler on the G540 they generate a 3.8V signal when depressed (up from 0.8V when left unpressed). I tried to hook this up to Pin IO6 on the Kflop and initially I thought it was working. On the Digital IO screen I could see real time response when testing my switches and no flickering in the check mark in the State box. However when I tried to run my motor the Limit got flipped almost instantly without my touching the switch. On the consol screen I could confirm that as soon as I try to Enable an axis channel the Limit is triggered quickly thereafter.

    I figured this could be because, as you mentioned, with no signal applied the voltage at the pin might fluctuate. I then tried hooking the signal from the G540 to Pin IO16 with the pull down resistor and didn't seem to get any response from the switches on the Digital IO screen. Testing with a voltmeter showed that when I have this signal hooked up to Pin IO16 the signal barely get's to 0.15V when the switch is depressed (up from the 0.08V when left unpressed).

    I feel like I'm getting closer to a working setup, but still no joy.

  12. #12
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    Also, please forgive this very basic, but critically important question: If I were to route a 24v signal from the Konnect (or this 12V signal from my G540) to one of the KFLOP general IO pins, wouldn't that exceed the 5v tolerance? Just trying to understand how this works, so I don't damage my board.
    Yes connecting 5v, 12V or 24V to a KFLOP IO pin will likely cause damage. An opto coupler board like Konnect has 2 sides. One side has 24V signals and the other has 3.3V signals and as the name implies the two sides are totally disconnected with only a beam of light going from one side to the other. Only the 3.3V side connects to KFLOP.

    The "open collector" opto coupler outputs of the G540 are very similar to switches. And they either switch to ground or go open like a switch. So you have a similar problem as you did with the limit switches. The pin for IO16 has a pull down resistor. So that doesn't work with the G540 optocoupler outputs because those pull down also. There isn't anything to make the signals go high. If you connect the G540 Opto outputs to an IO without a pull down resistor (ie IO6) and add a 1K Ohm pull up resistor to 3.3V it should work. You might post a circuit diagram here for us to check before you apply power so we can see you understand what I am describing.

    HTH
    TK
    http://dynomotion.com

  13. #13
    Join Date
    Jan 2018
    Posts
    1516

    Re: KFLOP in CL Step Mode - Output Instability

    Quote Originally Posted by akmolski View Post

    Also, please forgive this very basic, but critically important question: If I were to route a 24v signal from the Konnect (or this 12V signal from my G540) to one of the KFLOP general IO pins, wouldn't that exceed the 5v tolerance? Just trying to understand how this works, so I don't damage my board.

    Many thanks
    You need isolation units like this inbetween them to change one voltage signal to another voltage.
    You can find ones that you can have adjusted to your specification. Such as going from 12 / 24v in to 5v out, or 5v in to 12 / 24v out etc.
    Also for pnp or npn connection or both.

    Here are some examples.






    I buy all my boards from aliexpress. Such as:

    https://www.aliexpress.com/item/1005...c00eH5g6c&mp=1

  14. #14
    Join Date
    Nov 2014
    Posts
    19
    Quote Originally Posted by TomKerekes View Post
    If you connect the G540 Opto outputs to an IO without a pull down resistor (ie IO6) and add a 1K Ohm pull up resistor to 3.3V it should work. You might post a circuit diagram here for us to check before you apply power so we can see you understand what I am describing.

    HTH
    Ok I think I understand. The octocoupler is kindof like a digital switch, reading a 12V signal and outputting 3.8V when tripped. I could draw something up but I've done some reading on Pull Ups and I think I understand what to do.

    Per your suggestion, if I'm connecting my G540 outputs to Pins 13, 14, and 21, simply sticking three 1kOhm resistors, one between each of those pins and Pin 1 (VCC33 or 3.3V) should Pull each of those pins Up High when the switch is tripped. Otherwise the octocoupler acts like a ground and keeps them Low.

    I got a bit confused because even left disconnected I was reading 3.8V between the three octocoupler outputs and ground when tripped. I figured this was equivalent to hooking up a 3.3V source. But from what your saying they act more like an open switch, still fluctuating randomly, if not actually connected to a 3.3V source to set them.

    Thx again for your help, I'll try this tomorrow when I have the day to work on this.

  15. #15
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    I got a bit confused because even left disconnected I was reading 3.8V between the three octocoupler outputs and ground when tripped. I figured this was equivalent to hooking up a 3.3V source. But from what your saying they act more like an open switch, still fluctuating randomly, if not actually connected to a 3.3V source to set them.
    That is a bit strange. Why it would be 3.8V without any positive supply connected anywhere. But again a floating wire can be unpredictable. Whatever leakage, or parasitic capacitance, or stray noise can change the voltage.
    TK
    http://dynomotion.com

  16. #16
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    Quote Originally Posted by TomKerekes View Post
    That is a bit strange. Why it would be 3.8V without any positive supply connected anywhere. But again a floating wire can be unpredictable. Whatever leakage, or parasitic capacitance, or stray noise can change the voltage.

    Hey there, so I tried adding a Pull Up resistor, but that didn't really help. I tried adding my own pull downs too and even went so far as to run a ground wire to IO6 directly just to make sure there was no software glitch tripping my Limit and throwing "Pos/Neg Limit Axis Disabled" up on my console screen. Grounding the pin outright seemed to be the only way avoid disabling my axis.

    After doing a bunch of reading about pull up resistors, pulls down resistors, and open collector logic gates, I don't think my ILQ74 optocoupler acts like an open collector. My switches are normally closed. When the voltage on the switch side of the opto goes from 12v to 0v (open switch) the voltage on the Kflop side goes from 0.08v to 3.8v. It reverses the signal. Adding the Pull Up resistor predictably left IO6 permanently High.

    I need to do the opposite and bring that 0.08v float down to straight 0v (or Ground). This 0.08v resting voltage is the only thing I see that could still be a reason this Limit get's tripped. On the Kmotion Digital IO screen it seems like the switches are well behaved. There is no flickering at all in the State Check box when I'm Low (0.08v) or High (3.8v) on IO6, but despite this, something inside the software seems to trigger the Limit regardless. Is 0.08v enough to trigger a High state on that pin, and set off my Limit? Is there a way to change that threshold in software?

    To be honest I thought once I was done attaching and wiring my switches, this part of the process would be relatively simple. I'm about to give up, bypass the Kflop entirely, and just hook up all my Limit Switches in series across my E-Stop wire. It's not elegant and I won't be able to use my Limits for Homing, but it should stop my machine from destroying itself if all else fails and that's really the important part.

    Thanks again for all your help and patience. I really wish I knew more about all this, so that something as simple as getting a microcontroller to recognize a button push wouldn't stump me for days on end.

  17. #17
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    Hi,

    I wouldn't be discouraged I think you are almost there. Grounding and noise can be one of the most complex and difficult things in electronics.

    even went so far as to run a ground wire to IO6 directly just to make sure there was no software glitch tripping my Limit and throwing "Pos/Neg Limit Axis Disabled" up on my console screen. Grounding the pin outright seemed to be the only way avoid disabling my axis
    That pretty much proves you have noise in your wiring to IO6.


    I don't think my ILQ74 optocoupler acts like an open collector
    I think they are.


    My switches are normally closed. When the voltage on the switch side of the opto goes from 12v to 0v (open switch) the voltage on the Kflop side goes from 0.08v to 3.8v. It reverses the signal.
    That makes perfect sense. When you remove 12V from the LED side the phototransistor turns off (goes open) so your pull up resistor pulls the signal up to 3.8V.

    Note KFLOP can be configured for limits with either polarity. In the above case do not set the "Stop when low" option.


    I need to do the opposite and bring that 0.08v float down to straight 0v (or Ground).
    wrong


    This 0.08v resting voltage is the only thing I see that could still be a reason this Limit get's tripped.
    No, there is likely noise that you can't see without an oscilloscope.


    On the Kmotion Digital IO screen it seems like the switches are well behaved. There is no flickering at all in the State Check box when I'm Low (0.08v) or High (3.8v) on IO6
    Noise glitches are usually very narrow pulses. The Digital IO Screen only samples the inputs several times per second. The chances you see anything on the Screen is very small. Where as the KFLOP Axis continuously samples the limits every 90us.

    btw here is a little program you can test to see if the signal ever goes high. It runs and watches the input and if it ever is seen high prints a message and terminates.

    Code:
    #include "KMotionDef.h"
    
    // Simple check for Glitch on Input Pin
    
    main()
    {
    	while (!ReadBit(6)) ;  // tight loop while input is low
    	printf("Input was high!!\n");
    }



    KFLOP inputs are standard 3.3V LVTTL signals. Anything below 0.8V is guaranteed to be read as a low signal. Signals are therefore driven below 0.4V to have some margin. 0.08V is a good low level, if there aren't any spikes going above 0.8V


    Is there a way to change that threshold in software?
    no


    Most likely the wiring between the opto coupler and KFLOP is picking up noise. How long is it? More than several inches? Is it shielded? Where is the pull up resistor?

    Another solution might be to add a filter capacitor (0.1 to 0.001uF Ceramic) on IO6 to GND located very close to KFLOP. This would stop any noise glitches from entering KFLOP. Something similar to this (but different connector/pins in your case)

    Attachment 466728

    HTH
    TK
    http://dynomotion.com

  18. #18
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    Quote Originally Posted by TomKerekes View Post
    Hi,

    Most likely the wiring between the opto coupler and KFLOP is picking up noise. How long is it? More than several inches? Is it shielded? Where is the pull up resistor?

    Another solution might be to add a filter capacitor (0.1 to 0.001uF Ceramic) on IO6 to GND located very close to KFLOP. This would stop any noise glitches from entering KFLOP. Something similar to this (but different connector/pins in your case)

    HTH
    Ok so the Pull Up resistor I added was between IO6 and Pin 1 (or 3.3v). I might have made a mistake the first time around. I tried it again just now and I could see IO6 go from 0.14v to 3.49v when I tested my switches.

    I also ran the simple program you supplied and I got "Input was high" immediately on the console. I guess this means you're correct and there is noise in my data wire. The cable connecting my G540 to the Kflop is a regular unshielded DB25 to IDC26 ribbon cable 7 inches long. I cut off the IDC26 side and routed the appropriate wires to a breakout board for the J7 connections. The breakout board is connected to J7 with a standard IDC26 ribbon cable about another 7 inches long.

    I tried adding a 0.01uF cap on the breakout board itself between IO6 and Gnd, but it did not seem to do much. I'm guessing I need to pick up a IDC26 ribbon cable like the one you pictured with two connectors very close to each other so I can add the cap much closer to the Kflop.

    I could also solder shielded wires inside the DB25 (it comes open and the solder terminals are accessible) that I can use to route just the Limit switch signals to the Breakout Board, but then wouldn't I still have to worry about picking up noise on the ribbon cable between that board and the Kflop? I'll look into shielded IDC26 cables just in case, but I would have to get one like just described with two connectors really close to each other where I can insert a Filter cap.

    Thanks again, I'll keep trying for now, while I also start to figure out how to put together my Initialization program.

  19. #19
    Join Date
    Nov 2014
    Posts
    19

    Re: KFLOP in CL Step Mode - Output Instability

    It doesn't seem like the internet has too many shielded ribbon cables or "close double ended" IDC26 cables readily available. I might just try to DIY this, by shielding each of my two ribbons with aluminized tape (and then insulating with PVC or Electrical tape) and if that alone doesn't work then splicing in a filter cap between IO6 and Gnd right my the Kflop.

    Should I connect my DIY shielding to Gnd? This whole assembly sits in a plastic box, so I'm not exactly sure where/what I would ground it to.

    I'm curious how most people deal with connecting their Limit Switches. I can't believe it would be this complicated in every setup. Is it really just the poor quality of my Opto signals that's making this so difficult? Do people usually run shielded cables throughout their design?

  20. #20
    Join Date
    May 2006
    Posts
    4043

    Re: KFLOP in CL Step Mode - Output Instability

    You're sure not having much luck...

    I tried adding a 0.01uF cap on the breakout board itself between IO6 and Gnd, but it did not seem to do much.
    I'm surprised. 7 inches away shouldn't be that bad. There must be a very strong noise source. Are there motor wires or motor supply wires nearby? You might use the glitch program while moving things around, shutting things off to see if you can identify the source.

    It might be a grounding issue also.


    I'm guessing I need to pick up a IDC26 ribbon cable like the one you pictured with two connectors very close to each other so I can add the cap much closer to the Kflop.
    If you buy a connector you can just crimp it on near the end. See here.


    I could also solder shielded wires inside the DB25 (it comes open and the solder terminals are accessible) that I can use to route just the Limit switch signals to the Breakout Board, but then wouldn't I still have to worry about picking up noise on the ribbon cable between that board and the Kflop?
    Yes I think so.


    Another option would be to do software filtering. For example use the DeBounce function to check that the signal was high 100 times in a row, then set a virtual bit and configure the Axis to Limit Trip on the Virtual bit. But I prefer to solve the problem at the source in the hardware if possible. One risk is it greatly reduces the frequency of the problem rather than totally eliminating it. It would add like 20 ms to the response to the Limit also.
    TK
    http://dynomotion.com

Page 1 of 2 12

Similar Threads

  1. KFlop how to configure spindle as Step and Dir No output for DIR
    By vetsen in forum Dynomotion/Kflop/Kanalog
    Replies: 6
    Last Post: 10-08-2015, 07:08 PM
  2. Step by step guide settings Kflop (Russian language)
    By ukr_sasha in forum Dynomotion/Kflop/Kanalog
    Replies: 2
    Last Post: 04-29-2015, 05:23 PM
  3. Step Mode and Continius Mode exchanged
    By iron_aro in forum Mach Software (ArtSoft software)
    Replies: 0
    Last Post: 06-04-2014, 05:42 PM
  4. kflop step&dir in velocity mode?
    By mmontev in forum Dynomotion/Kflop/Kanalog
    Replies: 4
    Last Post: 06-24-2013, 02:38 AM
  5. Not getting +5 VDC output with KFlop
    By nova24 in forum Dynomotion/Kflop/Kanalog
    Replies: 0
    Last Post: 01-30-2012, 03:31 AM

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
  •