KX3.INI configuration file |
Sample KX3.INI configuration file |
INTRO_TIME = 5 |
INTRO_TIME = 2 |
BASE_PERIOD = 29000 SERVO_PERIOD = 1000000 |
BASE_PERIOD = 30000 SERVO_PERIOD = 600000 |
MAX_ACCELERATION = 200.0 STEPGEN_MAXACCEL = 250.0 |
MAX_ACCELERATION = 400.0 STEPGEN_MAXACCEL = 500.0 |
HOME_SEARCH_VEL = -30.000000 HOME_LATCH_VEL = 1.000000 |
HOME_SEARCH_VEL = -50.000000 HOME_LATCH_VEL = 5.000000 |
MAX_ACCELERATION = 200.0 STEPGEN_MAXACCEL = 250.0 |
MAX_ACCELERATION = 400.0 STEPGEN_MAXACCEL = 500.0 |
HOME_SEARCH_VEL = -30.000000 HOME_LATCH_VEL = 1.000000 |
HOME_SEARCH_VEL = -50.000000 HOME_LATCH_VEL = 5.000000 |
MAX_ACCELERATION = 200.0 STEPGEN_MAXACCEL = 250.0 |
MAX_ACCELERATION = 400.0 STEPGEN_MAXACCEL = 500.0 |
HOME_SEARCH_VEL = 40.000000 HOME_LATCH_VEL = -1.000000 |
HOME_SEARCH_VEL = 50.000000 HOME_LATCH_VEL = -5.000000 |
|
KX3.HAL configuration file |
Sample KX3.HAL configuration file |
* This file was originally created using STEPCONF, and then modified to resolve the ESTOP issue. * Todo: I am currently cheating, and tricking the KX3 mill to run with a PWM spindle config (which works). The proper way is to add a 5th step generator for the spindle. |
* This file was originally created using STEPCONF, and then modified to resolve the ESTOP issue and to add a 5th stepper generator controlling the spindle. |
|
loadrt stepgen step_type=0,0,0 |
loadrt stepgen step_type=0,0,0,0,0 ctrl_type=p,p,p,p,v |
net estop-out iocontrol.0.user-enable-out |
loadrt scale net estop-out iocontrol.0.user-enable-out #Charge pump must not be connected to ESTOP! |
loadrt pwmgen output_type=0 |
|
addf pwmgen.make-pulses base-thread |
addf pwmgen.update servo-thread |
net spindle-cmd <= motion.spindle-speed-out => pwmgen.0.value net spindle-enable <= motion.spindle-on => pwmgen.0.enable net spindle-pwm <= pwmgen.0.pwm setp pwmgen.0.pwm-freq 500.0 setp pwmgen.0.scale 47500.0 setp pwmgen.0.offset 0.00789473684211 setp pwmgen.0.dither-pwm true net spindle-cw <= motion.spindle-forward |
setp scale.0.in 0 # adjust spindle speed here if required setp scale.0.gain 0.9 # The suggested gain was not scientifically tested, but based on the motor speed maxing out at approx S3500, which is the theoretical maximum for a KX3. setp scale.0.offset -50 # A negative offset appears to yield the best results for low speeds allowing for approx 60 rpm at S60. addf scale.0 servo-thread setp stepgen.4.position-scale 1 setp stepgen.4.maxvel 3500 # maximum for standard KX3 setp stepgen.4.steplen 1 setp stepgen.4.stepspace 0 setp stepgen.4.dirhold 20000 setp stepgen.4.dirsetup 20000 setp stepgen.4.maxaccel 2000 net spindle-enable <= motion.spindle-on => stepgen.4.enable net spindle-cmd motion.spindle-speed-out => scale.0.in net spindle-freq <= scale.0.out => stepgen.4.velocity-cmd net spindle-out <= stepgen.4.step => parport.0.pin-14-out net spindle-cw => parport.0.pin-16-out |
setp parport.0.pin-01-out-invert 1 net spindle-cw => parport.0.pin-01-out |
net spindle-pwm => parport.0.pin-14-out |
|