Limit Switch and Homing Switch configurations and how they interact with each other and EMC2. |
Limit Switch and Homing Switch configurations and how they interact with each other and LinuxCNC. |
together. In this case, it connects a parport pin to EMC. Everything |
together. In this case, it connects a parport pin to LinuxCNC. Everything |
Hall based Limit Switches At the request of folks on the mailing list I have posted the (Eagle PCB) design for the limit switches I use on my machines here: upload:CNC-Hall%20Board.sch upload:CNC-Hall%20Board.brd All passives are 0603 except for C1 which is 1206 The hall is an allegro A3213 (A3213ELHLT-T) The connector is an RJ11-6P4C Digikey A31421-ND The board is designed such that the RJ connector can be reversed at assembly time. Doug Metzler |
In the original mail Chris Barker wrote:
> Each axis has it's own home switch. The home switch also acts as > a minimum limit when home isn't being used. > 3 input pins are used. Active low. > > Maximum travel limits are combined on all axes in a serial conection. > Active low. > Only 1 pin is used on the par. port.
I don't know your actual pinout, but lets assume it is like this:
Parport pin 10 = X axis home (and min limit) Parport pin 11 = Y axis home (and min limit) Parport pin 12 = Z axis home (and min limit) Parport pin 13 = combined X,Y,Z max limit
All inputs are active low (low when on the switch)
Then the limit section of your hal file should look something like this:
# connect pin 10 to X home and min limit net X-home parport.0.pin-10-in-not => axis.0.home-sw-in axis.0.neg-lim-sw-in
# connect pin 11 to Y home and min limit net Y-home parport.0.pin-11-in-not => axis.1.home-sw-in axis.1.neg-lim-sw-in
# connect pin 12 to Z home and min limit net Z-home parport.0.pin-12-in-not => axis.2.home-sw-in axis.2.neg-lim-sw-in
# connect pin 13 to all three max limits net XYZ-max-lim parport.0.pin-13-in-not => axis.0.pos-lim-sw-in axis.1.pos-lim-sw-in axis.2.pos-lim-sw-in
Notes:
Lines beginning with # are comments, you can put whatever you want there. Write something that will make sense to you when you are troubleshooting five years from now.
Lines beginning with "net" create a HAL signal that connects things together. In this case, it connects a parport pin to LinuxCNC. Everything after "net" is on one line (my mail client is wrapping the long lines, and yours might too). "X-home", "Y-home", "Z-home", and "XYZ-max-lim" are signal names, and can be whatever makes sense to you. The remaining names on each line are the pins that the signal connects, and must be names that already exist in the system. The "=>" arrows are optional, and are used to show a human reading the file which way the signal is flowing.
Regards,
John Kasunich
Hall based Limit Switches
At the request of folks on the mailing list I have posted the (Eagle PCB) design for the limit switches I use on my machines here:
upload:CNC-Hall%20Board.sch
upload:CNC-Hall%20Board.brd
All passives are 0603 except for C1 which is 1206
The hall is an allegro A3213 (A3213ELHLT-T)
The connector is an RJ11-6P4C Digikey A31421-ND
The board is designed such that the RJ connector can be reversed at assembly time.
Doug Metzler