[ create a new paste ] login | about

Link: http://codepad.org/FsWIrQwK    [ raw code | fork ]

Plain Text, pasted on Apr 17:
# Include your customized HAL commands here
# This file will not be overwritten when you run stepconf again

# my X home/limit is on pin 10 - disconnect it
unlinkp parport.0.pin-10-in
unlinkp axis.0.home-sw-in
unlinkp axis.0.neg-lim-sw-in

# my Y home/limit is on pin 11 - disconnect it
unlinkp parport.0.pin-11-in
unlinkp axis.1.home-sw-in
unlinkp axis.1.neg-lim-sw-in

# my Z home/limit is on pin 12 - disconnect it
unlinkp parport.0.pin-12-in
unlinkp axis.2.home-sw-in
unlinkp axis.2.pos-lim-sw-in

#load the debounce module with 3 debounce channels (only using 1)
loadrt debounce cfg=3


# add the debounce to the base thread
addf debounce.0 base-thread
# debounce for 10 base threads
setp debounce.0.delay 10

# connect the p-port input
net xhome-raw <= parport.0.pin-10-in => debounce.0.0.in
# link the debounced pin to the home switch
net xhome-filtered <= debounce.0.0.out => axis.0.home-sw-in
net xhome-filtered => axis.0.neg-lim-sw-in

# connect the p-port input
net yhome-raw <= parport.0.pin-11-in => debounce.0.1.in
# link the debounced pin to the home switch
net yhome-filtered <= debounce.0.1.out => axis.1.home-sw-in
net yhome-filtered => axis.1.neg-lim-sw-in

# connect the p-port input
net zhome-raw <= parport.0.pin-12-in => debounce.0.2.in
# link the debounced pin to the home switch
net zhome-filtered <= debounce.0.2.out => axis.2.home-sw-in
net zhome-filtered => axis.2.pos-lim-sw-in



Create a new paste based on this one


Comments: