LinuxCNC limit and home switches

New Home Forum Mostly Printed CNC – MPCNC Hardware Development – MPCNC LinuxCNC limit and home switches

This topic contains 5 replies, has 3 voices, and was last updated by  Derek P 3 weeks, 4 days ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #45079

    Derek P
    Participant

    After reading about the work Ryan has done with auto squaring I installed home and limit switches on my MPCNC. I’m using LinuxCNC and it has good support for input switches so I ended up installing 8 switches, yes 8.

    IMG_1274
    I’m using the MPCNC to learn how to set up a CNC machine so I also went overboard with the wiring and built a configuration box.

    IMG_1275
    I have wired each switch individually with the C, NO and NC contacts so I can set up the switches in just about any configuration. When using LinuxCNC with a parallel port you are essentially limited to 5 total inputs and  since I also want to play with an ESTOP input and a probe input that leaves 3 input pins for endstops. Currently I have it setup with 3 input pins, one for each axis and just a single switch that does both minimum limit and home. I have found that the normal auto homing sequence homes the three axis separately, Z then X then Y so I think I can wire all three axis in series and use a single pin. I’ll give that a try. One nice thing about LinuxCNC is that you can set an offset for the home position from the home switch. This allows the home position to be in the center of the machine if required. I was using my MPCNC with a center home without the switches so that’s what I am used to. What does everyone else do, what’s the best place for home?

    While the home switches are quite useful the limit switches just provide a safety net and work in conjunction with the LinuxCNC soft limits. If the machine gets lost and a limit switch is triggered the machine just stops, The downside is that the switches can limit the cutting area. I like Ryan’s endstop mounts, the ability to mount them after assembly has been really useful. I did have to modify one of the Z axis mounts and add an adjustment screw for the top mount.

    I plan to tackle auto squaring and follow some of the work done by Tom, LinuxCNC and machinekit both support the concept of joints so that you can separately control each stepper motor, 2 each for the X and Y axis. I was thinking how to adapt the endstop mount for micro adjustment but I notice Ryan has mentioned the concept of a software offset for an individual switch.

     

    #49349

    Alfred
    Participant

    It’s been some time – how are you finding LinuxCNC ? I’m considering jumping to it, currently using octoprint and it’s driving me up the wall.  I’m also using Fusion360, so if you have any pearls of wisdom to share with how they work together I’d be interested in reading them. Oddly you seem to be the only person on here who’s used LinuxCNC!

    #49365

    dkj4linux
    Participant

    Being, in a former time/life, an avid Linux user/advocate (hence my screen-name… dkj4linux) I used EMC2/LinuxCNC when I first started building CNC machines. You downloaded the live CD, booted, clicked the install icon, and a short time later had a full-blown Linux install, complete with appropriate real-time kernel, and CNC control software, ready to go. Mind you, I never went past basic CNC operation — no limit switches or fancy stuff — but I did a lot of neat stuff with my rather crude BuildYourCNC-based, leadscrew-driven, wooden CNC machine. With it I cut all the MDF parts for my buddy’s similar CNC machine and together we needle-cut, built, and flew numerous RC foam aircraft we drew up and CAM’ed in SketchUp/SketchUCAM. All my early needle cutter development was done on that machine. Those were some good times…

    A few years later, when I started building MPCNC’s, I already had a passing familiarity and interest in Arduino-based stuff. Being older, increasingly simple-minded, lazy, and still needing only basic CNC functionality, I readily took to Ryan’s MPCNC original design concept. Not having to set up a separate parallel-port PC and buy/build a driver board I saw as an advantage so never pursued using LinuxCNC with MPCNC. I have built several GRBL-based machines but being Arduino-based they offered me the same basic advantage as the Marlin-based ones.

    That said, there’s absolutely nothing wrong with LinuxCNC in the hands of someone who’s patient and willing to devote the time/effort to set it up and learn how to use it… it is capable of just about anything you should want to do in the world of CNC. Once you’ve built your machine and have the stepper leads hanging out there in your hands… you can hook up and use just about any controller out there.

    My $0.02.

    — David

    20120212_132632

    20120211_115820

    2012-06-04-12.17.58

     

    2 users thanked author for this post.
    #49370

    Derek P
    Participant

    Sorry I didn’t follow up sooner but some Christmas projects got in the way of my endstop experiments. I have been using my original setup with three endstops wired to 3 separate input pins set up as home detection and minimums. The endstops are working fine though the z endstop is quite low and I damaged it once. I think I would like to swap it out for a bed probe, that probably makes more sense.

    As far as the integration between Fusion 360 and LinuxCNC there is a standard post processor and the integration works well but I have found tool compensation to be annoying. I haven’t tracked down how to remove it yet so I just edit out the appropriate G code commands. There are many coordinate systems within LinuxCNC and G54 is quite handy and probably all you need to set up a part coordinate. The G54 offsets can be stored in a variable file so that even after switching off the machine you can return to a known part coordinate. I find this really handy. The problem with tool compensation is that it can drive another set of offsets and I managed to translate a z tool offset into a Y axis offset. That took me a while to track down!

    I’m surprised the MPCNC and LinuxCNC community is so small because the MPCNC is a perfect learning platform for LinuxCNC and great for makers in general.  On the other hand people have been doing some remarkable things with Marlin and GRBL and the learning curve for LinuxCNC is steeper.

    #49405

    Alfred
    Participant

    Thanks for the perspectives.

    The main motivation for the change is that long jobs cannot be paused and resumed without leaving the CNC control box powered on. There was an incident the other day when somebody shut down a PC with Octoprint open, and this somehow resumed the print with the router turned off. Needless to say that wrecked the project and caused some serious headscratching, as they swear they pressed no buttons.

    Why are tool offsets problematic, is it just that one experience? Surely it’s an essential feature, unless you manually set it up?

    Currently I set Z to the top of the workpiece manually with feeler gauges, but am I making a touchplate to replace that method.

    #49417

    Derek P
    Participant

    Actually tool offsets really only apply to automatic tool changers. Manual tool changes can make use of a touch probe and setting the z axis touch off.

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.