Hello Guest it is December 07, 2019, 06:45:47 PM

Author Topic: G41, Strange movement, I can't figure out what dumb mistake I'm making!  (Read 7551 times)

0 Members and 1 Guest are viewing this topic.

Offline Graham Waterworth

*
  • *
  •  1,916 1,916
  • Yorkshire Dales, England
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #10 on: October 01, 2010, 07:28:22 AM »
I suspect having the G41 applied before the sub call and the rapid moves is causing the problem.  Try applying the G41 within the sub and cancelling it before it exits the sub.

Graham
 
Without engineers the world stops

Offline BR549

*
  •  6,916 6,916
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #11 on: October 01, 2010, 10:17:57 AM »
I also see some problems with the incremental code. It does not add up correctly to do loops and some of the formulas do not make sense. To actually cut that profile you have to go about it in a different approach. And yes you have to do the comp as G1 as you lead into the profile and remove it as a G1 as you pull out of the profile.


But that is just my opinion, Your milage may vary. (;-) TP

Offline Tarak

*
  •  227 227
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #12 on: October 07, 2010, 01:44:26 AM »
Hi Guys, sorry been away for a while.
Thanks for all the suggestions, but buggered if I can get it to work.
BR549, the values don't add up correctly due to the cut size being applied after each repetition.
Thanks anyway guys.

Offline BR549

*
  •  6,916 6,916
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #13 on: October 08, 2010, 02:37:25 PM »
Darc I had some time today so I took your code apart and reaaranged it both in Abs mode and Inc mode.

Abs runs just fine BUT there appears to be a BIG ole bug in the G41  INCremental side dealing with arcs. After the first pass around it will DOUBLE the arc radius for the arc so it HAS to make a big circle to get all the arc in the same space(;-)

I tried in R mode and IJ mode same thing.

So you are not crazy.  AND your code, once I took full time to draw it out and review it WAS spot on. NICE JOB on parametric Incremental code.  I DID have to move the leadin and leadouts to make it work correct AND I had it all working EXCEPT for the one arc and mach took a holiday on that move(;-)

(;-) TP
« Last Edit: October 08, 2010, 02:40:52 PM by BR549 »

Offline BR549

*
  •  6,916 6,916
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #14 on: October 08, 2010, 08:09:42 PM »
Darc it seems to be a G41 bug. IF you program the part in the opposite direction of rotation  AND use a G42 in place of the g41 it seems to work ok.

(;-) TP

Offline Tarak

*
  •  227 227
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #15 on: October 10, 2010, 04:16:18 PM »
Hi BR549, thanks for taking a closer look, also thanks for confirming I'm not a spazz (well a total spazz anyway).
I'll try it running the other way and with G42 instead.
Thanks!

Offline BR549

*
  •  6,916 6,916
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #16 on: October 10, 2010, 08:06:36 PM »
Funny , the first loop through every thing works as expected. Then in the middle of the second loop it all goes to heck.

Still playing with it, (;-) TP

Offline BR549

*
  •  6,916 6,916
    • View Profile
Re: G41, Strange movement, I can't figure out what dumb mistake I'm making!
« Reply #17 on: October 11, 2010, 03:44:00 PM »
Darc I was wrong it will do the same with G42. I have banged on it for several days now AND see the problem but I can't find any way around it as is.

The problem as I see it is that MACH is NOT carrying over the math beyond the first loop in a sub, It seems to start all over again each loop. If you run it slow and single step it you can see the problem. BUT I cannot figure a way around the problem and I have tried it 39 ways to sunday so far.

Even tried each loop being a separate function of G41/G40 same problem.

Also tried it AS a continuous SPIRAL for each loop , Same thing

The parameteric side is NOT a problem tried it with and without same thing

I can Write code that will do the job but NOT inc parametric with SUBS and G41/42.

I don't KNOW if the NEW Comp code will solve the problem. If I can find the test version I will give it a whirl to see.

(;-) TP