CNC Router - Dual Y's / Gantry

More
14 May 2021 00:13 #208771 by Jeff_in_Wa
Today, I did a test job on the cnc router and thought I noticed the Gantry not synced in front to back moves. It was so subtle, I couldn't tell for sure.

I mapped out a my spoilboard for t-nuts and started the job

The first row seemed to be doing pretty well
The second row seemed to be slightly off
The third row was clearly showing a problem, as if progressive
The fourth row was wide towards Y1 and narrow towards Y2 as compared from the previous row

But what surprised me was that homing the machine showed Y2 hit the switch before Y1 did. But about a half inch

I have compared Y1 vs Y2 code in both the .hal and .ini settings, and can't find any discrepancies between the lines.

What I truly don't understand is that I can jog this machine all over the place, do a homing run and everything is perfect. I can do this over and over again, and I can't get the error showing up when running a job. The Y's hit the two switches at the back at exactly the same time after jogging.

So I know there is something different between jogging and executing gcode.

This made me think, that the Fusion 360 post may be the problem. I am letting the post write the machine code in the header.

Lastly, I have checked that the calibration on the machine is right. It is very right in all axis.

The only other thing I can think of at this point is I'm losing steps on one of the motors, presumably Y2. Or there is a gcode translation issue.

?

Please Log in or Create an account to join the conversation.

More
14 May 2021 00:55 #208772 by PCW
Replied by PCW on topic CNC Router - Dual Y's / Gantry
Progressive loss of position without a stall may be a timing issue
insufficient direction change setup and hold times or inverted
step polarity may cause loss of steps on reversals so may not show up
until hundreds of reversals.

Please Log in or Create an account to join the conversation.

More
14 May 2021 01:17 #208773 by Jeff_in_Wa
Would you kindly lay out a plan of attack for me to fix this?

Please Log in or Create an account to join the conversation.

More
14 May 2021 01:34 #208775 by PCW
Replied by PCW on topic CNC Router - Dual Y's / Gantry
If that is the problem increasing the direction setup and direction setup and direction hold timing should fix it.

There is no real disadvantage to large direction setup and hold times
so try 20000 for both

Please Log in or Create an account to join the conversation.

More
14 May 2021 04:17 #208780 by Jeff_in_Wa
I will do this and let the group know the outcome. Thanks a ton!

Please Log in or Create an account to join the conversation.

More
14 May 2021 19:32 #208844 by Jeff_in_Wa
Would you kindly look over my .hal file and see if there is something that sticks out at you?

In your suggestion above, you stated:

"If that is the problem increasing the direction setup and direction setup and direction hold timing should fix it."

You'll notice "direction setup" is stated twice. I don't know what to do here.

What I do know is that the:

setp stepgen.3.dirhold 38000
setp stepgen.3.dirsetup 38000 settings are already at 38000, when you suggested I raise mine to 20000

So clearly, something is amiss there

I have run the gantry across the limit switches so many times, I'm really not wanting to make any changes until you look the .hal file over... Please

# Generated by stepconf 1.1 at Sat May 1 10:56:44 2021
# If you make changes to this file, they will be
# overwritten when you run stepconf again


loadrt [KINS]KINEMATICS
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
loadrt hal_parport cfg="0 out"
setp parport.0.reset-time 5000
loadrt stepgen step_type=0,0,0,0

addf parport.0.read base-thread
addf stepgen.make-pulses base-thread
addf parport.0.write base-thread
addf parport.0.reset base-thread

addf stepgen.capture-position servo-thread
addf motion-command-handler servo-thread
addf motion-controller servo-thread
addf stepgen.update-freq servo-thread
#net spindle-cmd-rpm <= spindle.0.speed-out
#net spindle-cmd-rpm-abs <= spindle.0.speed-out-abs
#net spindle-cmd-rps <= spindle.0.speed-out-rps
#net spindle-cmd-rps-abs <= spindle.0.speed-out-rps-abs
#net spindle-at-speed => spindle.0.at-speed

net probe-in => motion.probe-input

net xstep => parport.0.pin-02-out
setp parport.0.pin-02-out-reset 1
net xdir => parport.0.pin-03-out

net y1step => parport.0.pin-04-out
setp parport.0.pin-04-out-reset 1
net y1dir => parport.0.pin-05-out

net zstep => parport.0.pin-06-out
setp parport.0.pin-06-out-reset 1
net zdir => parport.0.pin-07-out

net y2step => parport.0.pin-08-out
setp parport.0.pin-08-out-reset 1
net y2dir => parport.0.pin-09-out
net xenable => parport.0.pin-14-out #Not sure what this is

net home-x <= parport.0.pin-10-in-not
net home-y1 <= parport.0.pin-11-in-not
net home-y2 <= parport.0.pin-12-in-not
net home-z <= parport.0.pin-13-in-not
net probe-in <= parport.0.pin-15-in

# X Axis
setp stepgen.0.position-scale [JOINT_0]SCALE
setp stepgen.0.steplen 50
setp stepgen.0.stepspace 0
setp stepgen.0.dirhold 38000
setp stepgen.0.dirsetup 38000
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
net xpos-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
net xpos-fb stepgen.0.position-fb => joint.0.motor-pos-fb
net xstep <= stepgen.0.step
net xdir <= stepgen.0.dir
net xenable joint.0.amp-enable-out => stepgen.0.enable
net home-x => joint.0.home-sw-in

# Y1 Axis
setp stepgen.1.position-scale [JOINT_1]SCALE
setp stepgen.1.steplen 50
setp stepgen.1.stepspace 0
setp stepgen.1.dirhold 38000
setp stepgen.1.dirsetup 38000
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
net y1pos-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
net y1pos-fb stepgen.1.position-fb => joint.1.motor-pos-fb
net y1step <= stepgen.1.step
net y1dir <= stepgen.1.dir
net y1enable joint.1.amp-enable-out => stepgen.1.enable
net home-y1 => joint.1.home-sw-in

# Y2 Axis
setp stepgen.2.position-scale [JOINT_2]SCALE
setp stepgen.2.steplen 50
setp stepgen.2.stepspace 0
setp stepgen.2.dirhold 38000
setp stepgen.2.dirsetup 38000
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
net y2pos-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
net y2pos-fb stepgen.2.position-fb => joint.2.motor-pos-fb
net y2step <= stepgen.2.step
net y2dir <= stepgen.2.dir
net y2enable joint.2.amp-enable-out => stepgen.2.enable
net home-y2 => joint.2.home-sw-in

# Z Axis
setp stepgen.3.position-scale [JOINT_3]SCALE
setp stepgen.3.steplen 50
setp stepgen.3.stepspace 0
setp stepgen.3.dirhold 38000
setp stepgen.3.dirsetup 38000
setp stepgen.3.maxaccel [JOINT_3]STEPGEN_MAXACCEL
net zpos-cmd joint.3.motor-pos-cmd => stepgen.3.position-cmd
net zpos-fb stepgen.3.position-fb => joint.3.motor-pos-fb
net zstep <= stepgen.3.step
net zdir <= stepgen.3.dir
net zenable joint.3.amp-enable-out => stepgen.3.enable
net home-z => joint.3.home-sw-in

net estop-out <= iocontrol.0.user-enable-out
net estop-out => iocontrol.0.emc-enable-in

net tool-number <= iocontrol.0.tool-prep-number
net tool-change-loopback iocontrol.0.tool-change => iocontrol.0.tool-changed
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared

Thank you so much!

Please Log in or Create an account to join the conversation.

More
14 May 2021 21:05 #208853 by rodw
Replied by rodw on topic CNC Router - Dual Y's / Gantry
you need to share your ini file. Its all in there, not hal

Please Log in or Create an account to join the conversation.

More
14 May 2021 21:05 #208854 by PCW
Replied by PCW on topic CNC Router - Dual Y's / Gantry
OK if the setup/hold times are already 38000 that's not likely the issue
Is the error only in one of the gantry joints?

Maybe mechanical or a drive/BOB issue

Please Log in or Create an account to join the conversation.

More
14 May 2021 21:19 #208856 by Jeff_in_Wa
At this point, the only thing I can see is that on home after a job is run, Y2 hits the home switch before Y1. So, I don't know which one is in error.

I have looked at my ball screw couplers to make sure they are tight. They seem to be fine. I was having stalling issues on the X gantry, and found that my velocity was too high. I lowered that down to 100 and the stalling stopped.

Please Log in or Create an account to join the conversation.

More
14 May 2021 21:24 #208857 by Jeff_in_Wa
Also, I can't find the problem in jogging. No matter how fast or hard I move the spindle around the x,y plane, homing returns the two Y's at the exact same time (hitting the switches)

It's when I'm running gcode

Please Log in or Create an account to join the conversation.

Time to create page: 0.082 seconds
Powered by Kunena Forum