Master - Closed Loop Stepper with XHC-HB04 Jog Issue

More
8 years 11 months ago #101817 by the_canuck
I'm trying to convert over to 2.8 from 2.7.

I'm having issues with the XHC-HB04 pendant jogging after homed. I'm open to ideas of things to try

Before homed, Jog worked on y axis with single joint. Once homed and in teleop mode jog no longer works with the pendant. z-axis which is not closed loop stepper and has a single servo works just fine not homed or homed.

x-axis is a gantry with 2 servos hence the reason for the 2.8 upgrade. Previously I was slaving the 2 motors with one encoder. Worked okay but I have 2 encoders so 2.8 should improve things I hope as I can run them more independently.

I'm open to ideas as the pendant is a must have as my machine is to big to have to rely on the keyboard at the computer for jogging.

I'm running step/dir DMM-tech servos (which are tuned through the servo drivers and are not connected closed loop to Linuxcnc) through a 5i25 to the standard DMM-tech breakout board. I semi recently added magnetic linear encoders connected through 5i25 with 7i85 breakout. Mechanics are rotating nut ball screws on x and y and normal but high lead ball screw on z.

Here's the hal file:
Code:
loadrt [KINS]KINEMATICS loadrt [EMCMOT]EMCMOT servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS loadrt hostmot2 loadrt hm2_pci config=" num_encoders=4 num_pwmgens=1 num_3pwmgens=0 num_stepgens=4 " setp hm2_5i25.0.pwmgen.pwm_frequency 200 setp hm2_5i25.0.pwmgen.pdm_frequency 3500 setp hm2_5i25.0.watchdog.timeout_ns 10000000 loadrt abs names=abs.spindle loadrt lowpass names=lowpass.spindle loadrt charge_pump loadrt pid names=pid.x,pid.x2,pid.y addf charge-pump servo-thread addf hm2_5i25.0.read servo-thread addf motion-command-handler servo-thread addf motion-controller servo-thread addf pid.x.do-pid-calcs servo-thread addf pid.x2.do-pid-calcs servo-thread addf pid.y.do-pid-calcs servo-thread addf abs.spindle servo-thread addf lowpass.spindle servo-thread addf hm2_5i25.0.write servo-thread # external output signals # --- MACHINE-IS-ENABLED --- setp hm2_5i25.0.gpio.001.is_output true net machine-is-enabled hm2_5i25.0.gpio.001.out # --- SPINDLE-ON --- setp hm2_5i25.0.gpio.005.is_output true net spindle-on hm2_5i25.0.gpio.005.out setp hm2_5i25.0.gpio.005.invert_output true # --- CHARGE-PUMP --- setp hm2_5i25.0.gpio.007.is_output true net charge-pump hm2_5i25.0.gpio.007.out # external input signals # --- ESTOP-EXT --- net estop-ext <= hm2_5i25.0.gpio.003.in_not # --- HOME-X --- net home-x <= hm2_5i25.0.gpio.013.in_not # --- HOME-Y --- net home-y <= hm2_5i25.0.gpio.014.in_not # --- HOME-Z --- net home-z <= hm2_5i25.0.gpio.015.in_not #******************* # AXIS X #******************* # Joint 0 setp pid.x.Pgain [JOINT_0]P setp pid.x.Igain [JOINT_0]I setp pid.x.Dgain [JOINT_0]D setp pid.x.bias [JOINT_0]BIAS setp pid.x.FF0 [JOINT_0]FF0 setp pid.x.FF1 [JOINT_0]FF1 setp pid.x.FF2 [JOINT_0]FF2 setp pid.x.deadband [JOINT_0]DEADBAND setp pid.x.maxoutput [JOINT_0]MAX_OUTPUT net x-index-enable <=> pid.x.index-enable net x-enable => pid.x.enable net x-output => pid.x.output net x-pos-cmd => pid.x.command net x-vel-fb => pid.x.feedback-deriv net x-pos-fb => pid.x.feedback # Step Gen signals/setup setp hm2_5i25.0.stepgen.00.dirsetup [JOINT_0]DIRSETUP setp hm2_5i25.0.stepgen.00.dirhold [JOINT_0]DIRHOLD setp hm2_5i25.0.stepgen.00.steplen [JOINT_0]STEPLEN setp hm2_5i25.0.stepgen.00.stepspace [JOINT_0]STEPSPACE setp hm2_5i25.0.stepgen.00.position-scale [JOINT_0]STEP_SCALE setp hm2_5i25.0.stepgen.00.step_type 0 # 0 - for open loop, 1 for pid setp hm2_5i25.0.stepgen.00.control-type 1 setp hm2_5i25.0.stepgen.00.maxaccel [JOINT_0]STEPGEN_MAXACCEL setp hm2_5i25.0.stepgen.00.maxvel [JOINT_0]STEPGEN_MAXVEL # ---closedloop stepper signals--- net x-pos-cmd joint.0.motor-pos-cmd net x-output => hm2_5i25.0.stepgen.00.velocity-cmd net x-enable joint.0.amp-enable-out => hm2_5i25.0.stepgen.00.enable # ---Encoder feedback signals/setup--- setp hm2_5i25.0.encoder.03.counter-mode 0 setp hm2_5i25.0.encoder.03.filter 1 setp hm2_5i25.0.encoder.03.index-invert 0 setp hm2_5i25.0.encoder.03.index-mask 0 setp hm2_5i25.0.encoder.03.index-mask-invert 0 setp hm2_5i25.0.encoder.03.scale [JOINT_0]ENCODER_SCALE net x-pos-fb <= hm2_5i25.0.encoder.03.position net x-vel-fb <= hm2_5i25.0.encoder.03.velocity net x-pos-fb => joint.0.motor-pos-fb net x-index-enable joint.0.index-enable <=> hm2_5i25.0.encoder.03.index-enable net x-pos-rawcounts <= hm2_5i25.0.encoder.03.rawcounts # ---setup home / limit switch signals--- net home-x => joint.0.home-sw-in net x-neg-limit => joint.0.neg-lim-sw-in net x-pos-limit => joint.0.pos-lim-sw-in # Joint 3 setp pid.x2.Pgain [JOINT_3]P setp pid.x2.Igain [JOINT_3]I setp pid.x2.Dgain [JOINT_3]D setp pid.x2.bias [JOINT_3]BIAS setp pid.x2.FF0 [JOINT_3]FF0 setp pid.x2.FF1 [JOINT_3]FF1 setp pid.x2.FF2 [JOINT_3]FF2 setp pid.x2.deadband [JOINT_3]DEADBAND setp pid.x2.maxoutput [JOINT_3]MAX_OUTPUT net x2-index-enable <=> pid.x2.index-enable net x2-enable => pid.x2.enable net x2-output => pid.x2.output net x2-pos-cmd => pid.x2.command net x2-vel-fb => pid.x2.feedback-deriv net x2-pos-fb => pid.x2.feedback # Step Gen signals/setup setp hm2_5i25.0.stepgen.03.dirsetup [JOINT_3]DIRSETUP setp hm2_5i25.0.stepgen.03.dirhold [JOINT_3]DIRHOLD setp hm2_5i25.0.stepgen.03.steplen [JOINT_3]STEPLEN setp hm2_5i25.0.stepgen.03.stepspace [JOINT_3]STEPSPACE setp hm2_5i25.0.stepgen.03.position-scale [JOINT_3]STEP_SCALE setp hm2_5i25.0.stepgen.03.step_type 0 # 0 - for open loop, 1 for pid setp hm2_5i25.0.stepgen.03.control-type 1 setp hm2_5i25.0.stepgen.03.maxaccel [JOINT_3]STEPGEN_MAXACCEL setp hm2_5i25.0.stepgen.03.maxvel [JOINT_3]STEPGEN_MAXVEL # ---closedloop stepper signals--- net x2-pos-cmd joint.3.motor-pos-cmd net x2-output => hm2_5i25.0.stepgen.03.velocity-cmd net x2-enable joint.3.amp-enable-out => hm2_5i25.0.stepgen.03.enable # ---Encoder feedback signals/setup--- setp hm2_5i25.0.encoder.00.counter-mode 0 setp hm2_5i25.0.encoder.00.filter 1 setp hm2_5i25.0.encoder.00.index-invert 0 setp hm2_5i25.0.encoder.00.index-mask 0 setp hm2_5i25.0.encoder.00.index-mask-invert 0 setp hm2_5i25.0.encoder.00.scale [JOINT_3]ENCODER_SCALE net x2-pos-fb <= hm2_5i25.0.encoder.00.position net x2-vel-fb <= hm2_5i25.0.encoder.00.velocity net x2-pos-fb => joint.3.motor-pos-fb net x2-index-enable joint.3.index-enable <=> hm2_5i25.0.encoder.00.index-enable net x2-pos-rawcounts <= hm2_5i25.0.encoder.00.rawcounts # ---setup home / limit switch signals--- net home-x => joint.3.home-sw-in net x2-neg-limit => joint.3.neg-lim-sw-in net x2-pos-limit => joint.3.pos-lim-sw-in #******************* # AXIS Y #******************* # Joint 1 setp pid.y.Pgain [JOINT_1]P setp pid.y.Igain [JOINT_1]I setp pid.y.Dgain [JOINT_1]D setp pid.y.bias [JOINT_1]BIAS setp pid.y.FF0 [JOINT_1]FF0 setp pid.y.FF1 [JOINT_1]FF1 setp pid.y.FF2 [JOINT_1]FF2 setp pid.y.deadband [JOINT_1]DEADBAND setp pid.y.maxoutput [JOINT_1]MAX_OUTPUT net y-index-enable <=> pid.y.index-enable net y-enable => pid.y.enable net y-output => pid.y.output net y-pos-cmd => pid.y.command net y-vel-fb => pid.y.feedback-deriv net y-pos-fb => pid.y.feedback # Step Gen signals/setup setp hm2_5i25.0.stepgen.01.dirsetup [JOINT_1]DIRSETUP setp hm2_5i25.0.stepgen.01.dirhold [JOINT_1]DIRHOLD setp hm2_5i25.0.stepgen.01.steplen [JOINT_1]STEPLEN setp hm2_5i25.0.stepgen.01.stepspace [JOINT_1]STEPSPACE setp hm2_5i25.0.stepgen.01.position-scale [JOINT_1]STEP_SCALE setp hm2_5i25.0.stepgen.01.step_type 0 # 0-open loop, 1-pid setp hm2_5i25.0.stepgen.01.control-type 1 setp hm2_5i25.0.stepgen.01.maxaccel [JOINT_1]STEPGEN_MAXACCEL setp hm2_5i25.0.stepgen.01.maxvel [JOINT_1]STEPGEN_MAXVEL # ---closedloop stepper signals--- net y-pos-cmd joint.1.motor-pos-cmd net y-output => hm2_5i25.0.stepgen.01.velocity-cmd net y-enable joint.1.amp-enable-out => hm2_5i25.0.stepgen.01.enable # ---Encoder feedback signals/setup--- setp hm2_5i25.0.encoder.01.counter-mode 0 setp hm2_5i25.0.encoder.01.filter 1 setp hm2_5i25.0.encoder.01.index-invert 0 setp hm2_5i25.0.encoder.01.index-mask 0 setp hm2_5i25.0.encoder.01.index-mask-invert 0 setp hm2_5i25.0.encoder.01.scale [JOINT_1]ENCODER_SCALE net y-pos-fb <= hm2_5i25.0.encoder.01.position net y-vel-fb <= hm2_5i25.0.encoder.01.velocity net y-pos-fb => joint.1.motor-pos-fb net y-index-enable joint.1.index-enable <=> hm2_5i25.0.encoder.01.index-enable net y-pos-rawcounts <= hm2_5i25.0.encoder.01.rawcounts # ---setup home / limit switch signals--- net home-y => joint.1.home-sw-in net y-neg-limit => joint.1.neg-lim-sw-in net y-pos-limit => joint.1.pos-lim-sw-in #******************* # AXIS Z #******************* # Joint 2 # Step Gen signals/setup setp hm2_5i25.0.stepgen.02.dirsetup [JOINT_2]DIRSETUP setp hm2_5i25.0.stepgen.02.dirhold [JOINT_2]DIRHOLD setp hm2_5i25.0.stepgen.02.steplen [JOINT_2]STEPLEN setp hm2_5i25.0.stepgen.02.stepspace [JOINT_2]STEPSPACE setp hm2_5i25.0.stepgen.02.position-scale [JOINT_2]STEP_SCALE setp hm2_5i25.0.stepgen.02.step_type 0 setp hm2_5i25.0.stepgen.02.control-type 0 setp hm2_5i25.0.stepgen.02.maxaccel [JOINT_2]STEPGEN_MAXACCEL setp hm2_5i25.0.stepgen.02.maxvel [JOINT_2]STEPGEN_MAXVEL setp hm2_5i25.0.gpio.009.invert_output true net z-pos-fb joint.2.motor-pos-fb <= hm2_5i25.0.stepgen.02.position-fb net z-pos-cmd joint.2.motor-pos-cmd => hm2_5i25.0.stepgen.02.position-cmd net z-enable joint.2.amp-enable-out => hm2_5i25.0.stepgen.02.enable # ---setup home / limit switch signals--- net home-z => joint.2.home-sw-in net z-neg-limit => joint.2.neg-lim-sw-in net z-pos-limit => joint.2.pos-lim-sw-in #******************* # SPINDLE S #******************* # ---PWM Generator signals/setup--- setp hm2_5i25.0.pwmgen.00.output-type 1 setp hm2_5i25.0.pwmgen.00.scale [SPINDLE_9]OUTPUT_SCALE net spindle-vel-cmd => hm2_5i25.0.pwmgen.00.value net machine-is-enabled => hm2_5i25.0.pwmgen.00.enable # ---setup spindle control signals--- net spindle-vel-cmd-rps <= motion.spindle-speed-out-rps net spindle-vel-cmd-rps-abs <= motion.spindle-speed-out-rps-abs net spindle-vel-cmd <= motion.spindle-speed-out net spindle-vel-cmd-rpm-abs <= motion.spindle-speed-out-abs net spindle-on <= motion.spindle-on net spindle-cw <= motion.spindle-forward #net spindle-ccw <= motion.spindle-reverse #net spindle-brake <= motion.spindle-brake net spindle-revs => motion.spindle-revs net spindle-at-speed => motion.spindle-at-speed net spindle-vel-fb => motion.spindle-speed-in net spindle-index-enable <=> motion.spindle-index-enable # ---Setup spindle at speed signals--- sets spindle-at-speed true #****************************** # connect miscellaneous signals #****************************** # ---HALUI signals--- net joint-select-a halui.axis.x.select net x-is-homed halui.joint.0.is-homed net jog-x-pos halui.axis.x.plus net jog-x-neg halui.axis.x.minus net jog-x-analog halui.axis.x.analog net joint-select-b halui.axis.y.select net y-is-homed halui.joint.1.is-homed net jog-y-pos halui.axis.y.plus net jog-y-neg halui.axis.y.minus net jog-y-analog halui.axis.y.analog net joint-select-c halui.axis.z.select net z-is-homed halui.joint.2.is-homed net jog-z-pos halui.axis.z.plus net jog-z-neg halui.axis.z.minus net jog-z-analog halui.axis.z.analog net jog-selected-pos halui.axis.selected.plus net jog-selected-neg halui.axis.selected.minus net spindle-manual-cw halui.spindle.forward net spindle-manual-ccw halui.spindle.reverse net spindle-manual-stop halui.spindle.stop net machine-is-on halui.machine.is-on net jog-speed halui.axis.jog-speed net MDI-mode halui.mode.is-mdi # ---charge pump signals--- net spindle-on => charge-pump.enable net charge-pump <= charge-pump.out # ---coolant signals--- #net coolant-mist <= iocontrol.0.coolant-mist #net coolant-flood <= iocontrol.0.coolant-flood # ---probe signal--- #net probe-in => motion.probe-input # ---motion control signals--- net in-position <= motion.in-position net machine-is-enabled <= motion.motion-enabled # ---digital in / out signals--- # ---estop signals--- net estop-out <= iocontrol.0.user-enable-out net estop-ext => iocontrol.0.emc-enable-in # ---manual tool change signals--- loadusr -W hal_manualtoolchange net tool-change-request iocontrol.0.tool-change => hal_manualtoolchange.change net tool-change-confirmed iocontrol.0.tool-changed <= hal_manualtoolchange.changed net tool-number iocontrol.0.tool-prep-number => hal_manualtoolchange.number net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared

Here's my ini:
Code:
VERSION = 1.0 MACHINE = HD_Metal_Monster_Mesa_2 DEBUG = 0 [DISPLAY] DISPLAY = axis POSITION_OFFSET = RELATIVE POSITION_FEEDBACK = ACTUAL MAX_FEED_OVERRIDE = 2.000000 MAX_SPINDLE_OVERRIDE = 1.000000 MIN_SPINDLE_OVERRIDE = 0.100000 INTRO_GRAPHIC = linuxcnc.gif INTRO_TIME = 2 PROGRAM_PREFIX = /home/canuck/linuxcnc/nc_files PYVCP = pyvcp-panel.xml INCREMENTS = .1in .05in .01in .005in .001in .0005in .0001in DEFAULT_LINEAR_VELOCITY = 2.500000 MAX_LINEAR_VELOCITY = 8.333333 MIN_LINEAR_VELOCITY = 0.016667 DEFAULT_ANGULAR_VELOCITY = 0.250000 MAX_ANGULAR_VELOCITY = 1.000000 MIN_ANGULAR_VELOCITY = 0.010000 EDITOR = gedit GEOMETRY = xyz [FILTER] PROGRAM_EXTENSION = .png,.gif,.jpg Greyscale Depth Image PROGRAM_EXTENSION = .py Python Script png = image-to-gcode gif = image-to-gcode jpg = image-to-gcode py = python [RS274NGC] PARAMETER_FILE = linuxcnc.var [EMCMOT] EMCMOT = motmod COMM_TIMEOUT = 1.0 SERVO_PERIOD = 300000 # SERVO_PERIOD = 800000 [TASK] TASK = milltask CYCLE_TIME = 0.010 [HAL] HALFILE = HD_Metal_Monster_Mesa_2.hal POSTGUI_HALFILE = postgui_call_list.hal HALFILE = LIB:xhc-hb04.tcl HALUI = halui [KINS] KINEMATICS = trivkins coordinates=XYZX JOINTS = 4 [TRAJ] COORDINATES = XYZX LINEAR_UNITS = inch ANGULAR_UNITS = degree DEFAULT_LINEAR_VELOCITY = 1.67 MAX_LINEAR_VELOCITY = 16.67 [EMCIO] EMCIO = io CYCLE_TIME = 0.100 TOOL_TABLE = tool.tbl #******************** # Axis X #******************** [AXIS_X] MIN_LIMIT = -0.01 MAX_LIMIT = 72.0 MAX_VELOCITY = 8.33333 MAX_ACCELERATION = 10 [JOINT_0] TYPE = LINEAR HOME = 0.0 FERROR = 0.5 MIN_FERROR = 1.001 MAX_VELOCITY = 8.33333 MAX_ACCELERATION = 10 # The values below should be 25% larger than MAX_VELOCITY and MAX_ACCELERATION # If using BACKLASH compensation STEPGEN_MAXACCEL should be 100% larger. STEPGEN_MAXVEL = 20 STEPGEN_MAXACCEL = 10000 BACKLASH = 0 #Velocity Mode PID P = 40 I = 0 D = 0 FF0 = 0 FF1 = 0.81 FF2 = 0.003 BIAS = 0 DEADBAND = 4e-05 MAX_OUTPUT = 0 ENCODER_SCALE = -25400 # these are in nanoseconds DIRSETUP = 1000 DIRHOLD = 1000 STEPLEN = 1000 STEPSPACE = 1000 #STEP_SCALE = 10185.92 STEP_SCALE = 10337.8 MIN_LIMIT = -0.01 MAX_LIMIT = 72.0 HOME_OFFSET = 0.0 HOME_SEARCH_VEL = -1.0000 HOME_LATCH_VEL = -0.020000 HOME_SEQUENCE = -1 #HOME_OFFSET = 0.0 #HOME_SEARCH_VEL = 0.0 #HOME_LATCH_VEL = 0.0 #HOME_SEQUENCE = 0 [JOINT_3] TYPE = LINEAR HOME = 0.0 FERROR = 0.5 MIN_FERROR = 1.001 MAX_VELOCITY = 8.33333 MAX_ACCELERATION = 10 # The values below should be 25% larger than MAX_VELOCITY and MAX_ACCELERATION # If using BACKLASH compensation STEPGEN_MAXACCEL should be 100% larger. STEPGEN_MAXVEL = 20 STEPGEN_MAXACCEL = 10000 BACKLASH = 0 #Velocity Mode PID P = 40 I = 0 D = 0 FF0 = 0 FF1 = 0.81 FF2 = 0.003 BIAS = 0 DEADBAND = 4e-05 MAX_OUTPUT = 0 ENCODER_SCALE = 25400 # these are in nanoseconds DIRSETUP = 1000 DIRHOLD = 1000 STEPLEN = 1000 STEPSPACE = 1000 #STEP_SCALE = 10185.92 STEP_SCALE = 10337.8 MIN_LIMIT = -0.01 MAX_LIMIT = 72.0 HOME_OFFSET = 0.0 HOME_SEARCH_VEL = -1.0000 HOME_LATCH_VEL = -0.020000 HOME_SEQUENCE = -1 #HOME_OFFSET = 0.0 #HOME_SEARCH_VEL = 0.0 #HOME_LATCH_VEL = 0.0 #HOME_SEQUENCE = 0 #******************** # Axis Y #******************** [AXIS_Y] MIN_LIMIT = -0.01 MAX_LIMIT = 25 MAX_VELOCITY = 8.333333 MAX_ACCELERATION = 20 [JOINT_1] TYPE = LINEAR HOME = 0.0 FERROR = 0.5 MIN_FERROR = 1.001 MAX_VELOCITY = 8.333333 MAX_ACCELERATION = 20 # The values below should be 25% larger than MAX_VELOCITY and MAX_ACCELERATION # If using BACKLASH compensation STEPGEN_MAXACCEL should be 100% larger. STEPGEN_MAXVEL = 20 STEPGEN_MAXACCEL = 10000 BACKLASH = 0 P = 90 I = 0 D = 0 FF0 = 0 FF1 = 0.81 FF2 = 0.0035 BIAS = 0 DEADBAND = 4e-05 MAX_OUTPUT = 0 ENCODER_SCALE = 25400 # these are in nanoseconds DIRSETUP = 1000 DIRHOLD = 1000 STEPLEN = 1000 STEPSPACE = 1000 #STEP_SCALE = 10185.92 STEP_SCALE = 10337.8 MIN_LIMIT = -0.01 MAX_LIMIT = 25.0 HOME_OFFSET = 0.0 HOME_SEARCH_VEL = -1.0000 HOME_LATCH_VEL = -0.020000 HOME_SEQUENCE = 2 #******************** # Axis Z #******************** [AXIS_Z] MIN_LIMIT = -5.9 MAX_LIMIT = 0.01 MAX_VELOCITY = 1.2 MAX_ACCELERATION = 5.0 [JOINT_2] TYPE = LINEAR HOME = 0.0 FERROR = 0.05 MIN_FERROR = 0.001 MAX_VELOCITY = 1.2 MAX_ACCELERATION = 5.0 # The values below should be 25% larger than MAX_VELOCITY and MAX_ACCELERATION # If using BACKLASH compensation STEPGEN_MAXACCEL should be 100% larger. STEPGEN_MAXVEL = 1.5 STEPGEN_MAXACCEL = 6.2 # these are in nanoseconds DIRSETUP = 1000 DIRHOLD = 20000 STEPLEN = 1000 STEPSPACE = 1000 STEP_SCALE = 25000 MIN_LIMIT = -5.9 MAX_LIMIT = 0.01 HOME_OFFSET = 0.0 HOME_SEARCH_VEL = 0.500000 HOME_LATCH_VEL = 0.020000 HOME_SEQUENCE = 0 [XHC_HB04_CONFIG] # specify layout = n for xhc-hb04-layout{n}.cfg files layout = 1 # coords: specify 4 letters # coords: switch labels are xyza but any unique 4 letters # from the set {xyxabcuvw) can be used (if the coord exists) coords = x y z # lowpass settings: # coef: slows rate of change of output, range: 0 < coef < 1 coefs = 1 1 1 # mpg_accels: provision for reduced acceleration for manual mode jogging mpg_accels = 2 2 20 # scale plus or minus, rotaries may require larger scale factor: scales = 1 1 1 # jogmode normal(default) or vnormal or plus-minus jogmode = normal # sequence 1: 0.001,0.010,0.100,1.000 (mm-based machine) # sequence 2: 0.001,0.005,0.010,0.020 (inch-based machine) sequence = 2 # require_pendant = no: create xhc-hb04 hal pins when pendant not connected at startup require_pendant = no # inch_or_mm = in | mm inch_or_mm = in [APPLICATIONS] APP = monitor-xhc-hb04 [XHC_HB04_BUTTONS] # use button names according to layout file xhc-hb04-layout{n}.cfg # note: "start-pause" is connected for standard behavior # controlling halui.pause/halui.resume/halui.run # these are examples, edit as required: stop = halui.program.stop start-pause = std_start_pause rewind = halui.program.step safe-z = halui.mdi-command-01 # in this sim, home-all only works first time, hold down till finished: home = halui.home-all x2 = halui.mdi-command-02 y2 = halui.mdi-command-03 # probe-input for simulating a probe: probe-z = motion.probe-input x0 = halui.mdi-command-04 y0 = halui.mdi-command-05 z0 = halui.mdi-command-06 goto-zero = halui.mdi-command-00 # synthesized per-axis buttons for goto-zero button: goto-zero-x = "" goto-zero-y = "" goto-zero-z = "" goto-zero-a = "" step = xhc-hb04.stepsize-up mode = "" spindle = halui.mdi-command-07 reset = halui.estop.activate [HOSTMOT2] # **** This is for info only **** # DRIVER0=hm2_pci # BOARD0=5i25 [HALUI] # these are examples, edit as required: # a halui hal pin is created for each MDI_COMMAND below # halui.mdi-command-00, halui.mdi-command-01,... etc MDI_COMMAND=G0 X0 Y0 Z0 MDI_COMMAND=G0 Z0 MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= MDI_COMMAND= #********** # Spindle #********** [SPINDLE_9] OUTPUT_SCALE = 24000

Thanks
Andrew

Please Log in to join the conversation.

More
8 years 11 months ago #101836 by dgarrett
For the master branch with joints-axes updates (2.8~pre),
xhc-hb04.tcl handles basic identity kins machines but may
require user intervention for configs that use multiple
joints for a single axis letter.

I adapted your ini file to a sim config by replacing your
machine-dependent halfiles with [HAL]HALFILE=LIB:basic_sim.tcl
and commented-out unprovided and unrelated files
pyvcp-panel.xml,postgui_call_list.hal. I set the sim config
for immediate homing on all joints and specified
kinstype=BOTH for clarity.

Using this config, i found a bug due to a recent commit
(232d7daa3 Wed Nov 8) and pushed a fix (ba44943f9 Wed Nov
15)

With this update, the sim example (xhctest.ini ATTACHED) reproducing
your config works as expected.

So, if you were trying a recent build of the master branch,
you should 1) update to current commit (ba44943f9 or
later), 2) try the attached sim. If this sim works, i
suspect your config can work too (with proper home switch
setup).

Please Log in to join the conversation.

More
8 years 11 months ago #101854 by the_canuck
Thanks for checking out my situation.

I'll update the commit tonight and give it a retry.

Been fighting this for a couple days. I assumed it was something in my hal that was incorrect. Forced me to read up on the documentation so not completely unfruitful as I did learn quite a bit.

On homing: My dual joint x axis gantry only has one home switch. I think I found a way to make it work for now without adding a second switch. I'm relying on the gantry to be stiff enough to keep the motors in aligned on first power up and then through home sequence. 2 switches would be a better choice of course and ensure x and y return to perpendicular during homing. I will most likely add the missing switch soon.

Andrew

Please Log in to join the conversation.

More
8 years 11 months ago #101870 by the_canuck
Confirmed. Issue solved. Jog on the pendant now works correctly!

Nice catch on the int vs float math.

Andrew

Please Log in to join the conversation.

More
8 years 7 months ago #107468 by OT-CNC
I was wondering what linear encoders you are using and how well are they working? Sorry for going off topic here...

"I'm running step/dir DMM-tech servos (which are tuned through the servo drivers and are not connected closed loop to Linuxcnc) through a 5i25 to the standard DMM-tech breakout board. I semi recently added magnetic linear encoders connected through 5i25 with 7i85 breakout. Mechanics are rotating nut ball screws on x and y and normal but high lead ball screw on z"

Please Log in to join the conversation.

Time to create page: 0.090 seconds
Powered by Kunena Forum