I like your way of describing this. Went back and looked at how I have the knee home/limit switch set and indeed it's the same way although these are imperial measurements.
So in my case I have the max limit is 13" away from the spindle nose and the home switch is set as being in essence 12.8" away from the nose so it's seen before the physical limit even though they are the same switch. # 250 line encoderx4=1000x4:1 reduction pulley / 0.25" per Turn #STEP_SCALE = 16000.0 # 250 line encoderx4=1000x3.2:1 reduction pulley / 0.25" per Turn STEP_SCALE = 12800.0 BACKLASH = 0.0042 MIN_LIMIT = -12.5 MAX_LIMIT = 0.5 HOME_OFFSET = 0.3 HOME_SEARCH_VEL = 0.8 HOME_LATCH_VEL = 0.08 HOME_FINAL_VEL = -0.2 HOME_IGNORE_LIMITS = YES HOME_USE_INDEX = 0 HOME_SEQUENCE = 0 > -----Original Message----- > From: Luca Toniolo [mailto:[email protected]] > Sent: May 14, 2026 5:53 AM > To: Enhanced Machine Controller (EMC) > Subject: Re: [Emc-users] Combined limit/home switch > > This is mostly my opinion, but it can be done in other ways. > > HOME_OFFSET > Set to 1 or 2, this is the position where the sensor will be at, if your limit > sensor is at 0 and your max is at 0.5 you'll hit it, you want the sensor to be > above/past the limit, think of this parameter as the position of the sensor. > > > On May 14, 2026 8:37:27 PM GMT+08:00, Marco <[email protected]> > wrote: > >Hi, > > > >I've got my basic setup working and have made some cuts. Time to add > >the limit switches. For now, I've added one switch on Z+. This > >should act as a limit and homing switch. It's sort-of working but� > > > >When I'm homing the Z axes (joint 2), the machine correctly moves > >towards the switch, the machine stops and I get: > > > > joint 2 on limit switch error > > emc/task/taskintf.cc 976: Error on joint 2, command number 95 > > > >So this doesn't seem correct. It appears that it acts mainly as a > >limit switch and doesn't quite double-up as homing switch. Likely > >due to misconfiguration on my side. > > > >I also observed that it shuts off all movement, not only movement > >towards Z+ if the switch triggers. Not sure if that's by design or > >another sign of misconfiguration. > > > >I've read > > > > https://linuxcnc.org/docs/html/config/ini-homing.html > > > >but frankly, that's a lot to digest. Find my configuration attached. > >What do I need to change so I can use this single switch for homing > >as well as a limit switch? > > > >Marco > > _______________________________________________ > Emc-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/emc-users _______________________________________________ Emc-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-users
