586,096 active members*
3,813 visitors online*
Register for free
Login
IndustryArena Forum > CNC Electronics > CNC Machine Related Electronics > limit switch wiring with shielded cable
Results 1 to 18 of 18
  1. #1
    Join Date
    May 2006
    Posts
    94

    limit switch wiring with shielded cable

    I just finished wiring limit switches for my new DIY router and am having problems with the system tripping intermittently. I used two conducter 22 g. shielded cable, wiring the switches in series, twisting the two conducters together for each connection, treating them as one conductor. The wire starts at pin 15, of BOB, goes to a switch, then a new piece of wire goes from that switch, finally returning to the controller box after the sixth switch where its connected to the BOB's groung lug.I twist the grounding wire together at each junction, and twisted together all the grounding wires of the limit switches and the seperately wired home switches (3 of them, and they work perfectly) in the controller box, grounding to the box itself. I get no problems when I disenable the limit switches, but when I enable them, i get periodic unexplained trips, though they work properly when any of the switches is intentionally tripped. It seems like my technique might be at fault. There was one connection where if I handled the exposed connected pair of grounding wires with my fingers I could usually cause a trip.
    I'm new to all this stuff, so I'm sure I could be making some fundamental error. Thanks!

  2. #2
    Join Date
    Apr 2003
    Posts
    307
    Ground loops?
    Your shielding should be connected to ground in only one place. If your grounded shielding touches ground again you have just created a ground loop.

    Chris

  3. #3
    Join Date
    May 2006
    Posts
    94

    limit switch problem

    The grounding (shielding ground that is) wire isn't attached at its origin, but when I completed the circuit the grounding wire was attached to the single shielding grounding wires of the home switches. I didn't attach this to "signal ground " of BOB -just to the controller box itself.
    Here's perhaps a clue to the problem I can't interpret: On one or two of the switches, all of which are wired normally closed, when I test with a continuity tester, the tester lights brightly, and when I hit the switch, it only fades about 80% -it doesn't go off completely the way it does on other switches. I actually don't see where this should create a problem. This circuit should only be tripped by a switch losing its continuity, and I have the reverse problem, right? But when I check with continuity tester, all switches seem closed at rest. As you can see, I don't know a lot about these things. Mayble I should try rewiring them normally open, though I see where that's less safe, because one isn't notified of a wire torn lose.
    I have set up Mach3 soft limits and they work great, but I have so many hours into setting up the six limit switches it seems a shame to not get them working because of what's probably some minor wiring problem I can't identify. thanks!

  4. #4
    Join Date
    Apr 2003
    Posts
    307
    Which Break Out Board are you using?
    This is just a stab at the problem but it sounds like you have a floating ground. Where it's not 0 volts and is floating too close to the trip point.
    Here is a link to some grounding info:
    pminmo.com

    Chris

  5. #5
    Join Date
    May 2006
    Posts
    94

    proper grounding

    Well, maybe my two problems, inability to start spindle with relay board, and constant false limit switch trips, are related. I know very little about grounding. Should I somehow be grounding the "signal ground" lug of my BOB to my shop's AC power supply? Is this what is shown here?:

    http://pminmo.com/PMinMOwiki/index.p...=Image:Gnd.png

    Does this mean running a wire from signal ground of BOB to connect to a bare "green" wire in the AC line supplying Ac power to the system? And then, how should I be grounding the bare shield grounding wires for the shielded cable used for my steppers and the bare wires in the shielded cable used for my home and limit switches? Right now I simply have them tied to the metal controller box which simply sits on a wooden shelf. Thanks, and please excuse my ignorance on these issues, but I've got too much invested in this router to abandon the project!

  6. #6
    Join Date
    Apr 2003
    Posts
    307
    The parallel port coming from your computer has several lines that are grounded. This is assuming you are using the proper power cables to your computer. And also that your power system that you are tying into has a proper ground. Old house wiring didn't include a ground at one time. Have you checked your wiring? I'm not an electrician, but I have one of those testers that has 3 lights and tells you if your wall outlet has the correct wiring between hot , neutral and ground.
    Take it one step at a time and test each component in the chain. Does your computer case have continuity of the ground to your controller/BOB case?
    I'm hoping that pminmo or someone else will chime in here because I am wondering myself if the shielding of the cable should be tied to the case ground or the power supply ground. I've had grounding issues with my machine too.

    Chris

  7. #7
    Join Date
    Dec 2004
    Posts
    84
    You might want to try using a small capacitor between the ground and the other input lug you use on your BOB. This will filter out the noise spikes that are causing the trip to occur. I had a similar problem and a 0.01uF cap soldered across these two leads solved the problem. Also, you can try playing with the debounce in Mach3 (setting it higher) although I wouldn't go crazy with stepping it up. BTW, I didn't use shielded wires for my limits/home switches all wired on one circuit in series.

    Best of luck,
    Mike

  8. #8
    Join Date
    Apr 2003
    Posts
    307
    Alright, after thinking about this a little more and looking at the pictures of your BOB, here's my guess.
    The end of your limit switches should be connected to the signal ground since that completes the circuit to the negative side of your power supply. In other words, you want to go from the + side of the power supply thru the switches to the - side.
    The shielding of the cable should go the the case ground.

    Chris

  9. #9
    Join Date
    Dec 2003
    Posts
    24221
    Quote Originally Posted by cbcnc View Post
    The parallel port coming from your computer has several lines that are grounded. This is assuming you are using the proper power cables to your computer.
    Unfortunately that is not always the case, the three cord supply cable coming into your computer is 120v line, 120v neutral, and service ground to the case.
    The output of the PC switching supply is isolated and is not normally referenced (connected) to ground at the P.S. output.
    It depends on the PC Manufacturer if any of the MB ground plane mounting holes are connected to chassis or just mounted on insulated stand-offs.
    I use industrial style PC style units and I ensure they are mounted on metal stand offs so that the ground plane is at ground in all the mounting points.
    So your Parallel port common is not always at ground potential.
    It is your decision if you ground this at the port or at mounting or both.
    In any case all grounding should be bonded to the service ground, shields and power suplly commons , if you wish.
    Al.
    CNC, Mechatronics Integration and Custom Machine Design

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

  10. #10
    Join Date
    Apr 2003
    Posts
    307
    I'm so confused.
    Not really, it just takes a lot of mental sorting out of the different parts of the problem. Since I'm not a electronics engineer I haven't been through it a bunch of times and therefore it takes me longer.
    I think the main point is that the limit switches are part of a circuit where the + side of the supply should terminate at the - side of the power supply.
    The AC ground to the case is different or maybe the same.

    Chris

  11. #11
    Join Date
    Dec 2003
    Posts
    24221
    To start there should be a common ground point that has as a minimum, the service ground, cable shields and ground from any motors or servo's and spindle motors.
    Whether you take any power supply commons to this point, depends on whether you are adopting complete ground bonding of all systems and power supplies, or are using the total isolation technique, where all interfacing uses opto isolation or equivalent.
    Either method should be done methodically, any haphazard method usually results in spurious tripping of inputs or noise etc.
    If using common ground bonding for all systems, the ground cannot be used as a conductor.
    Where the supply neutral is grounded at the panel, you cannot ground the neutral at any other point.
    Personally, if I found my PC's power supply was at ground potential, I would also ground the PC common where it leaves the parallel port.
    As I have mentioned on many occasions before, I prefer the common grounding technique, even If I happen to use a isolated module, I will have the input and output commons, bonded to ground.
    Al.
    CNC, Mechatronics Integration and Custom Machine Design

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

  12. #12
    Join Date
    May 2006
    Posts
    94

    limit switch puzzle clues

    Well I'm afraid much of this is over my head. I did connect the shielding wires to 110 bare ground wire, with no discerniable improvement. Then I found and experimented with "debounce". That sure changed things! I had debounce interval at 0. I changed it to 500, and got no false trips, but one switch no longer trips the system at all , and another one or two only after a second or two. The others continue to work as before. I can set this number lower, and get the reluctant switches to work, but set low enough for all to work (20) I get some false trippings again. I left index debounce at 0 the whole time. How should "debounce interval" and "index debounce" be related?
    But clearly there's some very relevant information obtained here, and that the switches behave differently also suggests problems that some of you electronic geniuses out there should be able to identiy! The most reluctant switch of all had three longish wires near it (two go to it), and I wired switches not to limit total distance of wire, but to simplify wire protection due to gantry movement. I made what is probably a mistake of putting my X limits at the ends of the axis rather than on the traveling head, which requires more wire. Total wire length is an issue, even with shielded cable, right? Best to minimize? Help! Thanks!

  13. #13
    Join Date
    Nov 2003
    Posts
    244
    ...He who makes no mistakes makes nothing! ...
    Tom

  14. #14
    Join Date
    Apr 2003
    Posts
    307
    Is it possible that you have some funky switches?
    The way to check would be a continuity tester or ohm meter that will read a partial connection. They should be either fully on or fully off. No leakage in between.
    Another thought; are you soldering your connections or at least using crimp connectors? Check your connections for full continuity.
    Just some thoughts. Hope they help.

    Chris

  15. #15
    Join Date
    May 2006
    Posts
    94

    further diagnosis- basic grounding problems, my system's details

    One or two switches don't "disconnect" completely when tripped, (as indicated by continuity tester) and when power of controller box is turned off, this condition then applies to a switch on the other end of the limit switch series, and not to the ones that didn't work properly with controller power on. So what seemed like it might be a problem with the switches themselves is apparently a grounding problem, and I have a poor understanding of grounding problems. Either of two things (neither of which allow an operating system unfortunately) get all the limit switches working properly: 1) disconnecting the parallell cable from the BOB, or 2) disconnecting one end of the limit switch run of wire. Can anyone diagnose the issue, or suggest fixes from this description.

    Here's more info: I'm using a limit board in conjunction with a BOB, these two:

    breakout board:
    http://cgi.ebay.com/CNC-Emergency-St...742.m153.l1262
    I'm not using the relay-fired e-stop funcion on this because I couldn't get it to work. Instead, I"m simply usimnf pin 15 via Mach3 for e-stop, and it works fine for that.

    limit switch board:
    http://cgi.ebay.com/CNC-Limit-Switch...742.m153.l1262

    5 volts to Keling stepper drives comes from a 13.8 Volt supply which goes through the limit switch board, emerging at 5 volts. The Keling drivers (2- Kl-6050, and a KL-7880 for Z axis),
    http://www.kelinginc.net/KLDriver.html
    each take two 5V+ lines, but have no 5V- connection. The BOB receives its 5 Volt supply, via a barrel connecter, so I"m using a seperate 5 volt supply for that. I have the ground terminal of the limit switch board connected to the signal ground of the BOB. Steppers wouldn't function otherwise.

    Am I likely to solve my problem if I scrap the limit switch and BOB I"m using and use this :
    http://www.cnc4pc.com/Store/osc/prod...products_id=45
    , (which Keling also sells as its mainstay BOB) instead, with a single 5 volt power supply serving stepper drives and BOB (or even USB cable from PC providing low voltage to BOB, an option cnc4pc describes)?

  16. #16
    Join Date
    Apr 2003
    Posts
    307
    You can probably get the components you have working with some tweaking.
    One or two switches don't "disconnect" completely when tripped, (as indicated by continuity tester) and when power of controller box is turned off, this condition then applies to a switch on the other end of the limit switch series, and not to the ones that didn't work properly with controller power on.
    I don't understand, either the switches are on (continuity) or they are off (no continuity). Or they are broken or have poor connections.

    The limit switch circuit is a series connection:

    +5v ------- -Sw+ --------- -Sw+ -------- -Sw+ -------- 0v (or ground, or common, or -side of Power Supply)
    You are using Normally Closed switches. As long as no switch is pushed the signal that is sent to the parallel port pin is a ground (low). When a switch is pushed the ground side is disconnected and a 5v signal is sent to the pin.

    How many volts are you supplying the "limit switch card" with. Since that card has a voltage regulator it should be supplied with more than 5 volts since the regulator will cut off some of the input volts. Therefore you will get less than 5 volts on the output. Try it with 12 volts if it's not already.
    Keep trying. It can be sorted out.

    Chris

  17. #17
    Join Date
    Nov 2003
    Posts
    244
    each take two 5V+ lines, but have no 5V- connection
    you should have a ground to the 5v supply.
    ...He who makes no mistakes makes nothing! ...
    Tom

  18. #18
    Join Date
    Feb 2007
    Posts
    1084
    I had the same problem, limit switch's would trip even if the machine wasn't running. Wire them "low active" and you shouldn't have a problem. I think default is high active.

Similar Threads

  1. Home/Limit switch Cable HELP!!!
    By planekrazie in forum DIY CNC Router Table Machines
    Replies: 18
    Last Post: 04-28-2009, 01:40 AM
  2. Shielded versus not shielded cable.....?
    By REVCAM_Bob in forum CNC Machine Related Electronics
    Replies: 1
    Last Post: 05-23-2007, 01:55 PM
  3. Limit Switch Wiring
    By The Speaker Guy in forum CNC Machine Related Electronics
    Replies: 1
    Last Post: 01-07-2007, 11:11 AM
  4. Limit & Home Switch Wiring?
    By Willyb in forum Gecko Drives
    Replies: 0
    Last Post: 10-17-2005, 10:02 PM
  5. Home limit switch wiring.
    By DAB_Design in forum Mach Software (ArtSoft software)
    Replies: 5
    Last Post: 12-23-2004, 12:48 PM

Posting Permissions

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