On Wednesday 23 March 2016 09:06:30 Gene Heskett wrote:

> On Wednesday 23 March 2016 07:58:40 Tanay Gahlot wrote:
> > andy pugh <bodgesoc@...> writes:
> > > Whether you would add an extra optional parameter to G33.1 or
> > > define a G33.2 would be a decision to be made.
> >
> > Hello,
> >    I will add an optional parameter in G33.1 which will wrap it in a
> > six line utility as pointed by Gene to perform pecking. Though i am
> > not quite sure how to handle the spindle synchronization issue
> > pointed
>
> That is NOT a problem. G33.1 stops the linkage on the backout move at
> the point where it started because it has no knowledge that its in a
> loop. The spindle however must be turned around for fwd drive, which
> of course takes time.  When at speed, the next passing index pulse
> reasserts the locked status.  The only problem I am aware of is that
> IF you change the spindle speed while my script is running, there is a
> lock time lag thats not constant, growing with the rpms because of the
> accel limits for that axis, usually z, so if it locked up 50 degrees
> behind the spindle index at 200 rpm because of acceleration lag, it
> might be 180 degrees behind at 400 rpm.  Thats a tracking error and
> the threads of course will be junk.
>
> The same comment holds true for G76.  In any event I cut air first &
> when happy, turn up the rpms & do a touch off that then makes the
> thread. But I am accutely aware, particularly on the lathe, of the
> turnaround time as it reverses because that overshoots the turnaround
> point, may bottom the tap and either break it or twist in in the
> chuck.  That is generally not the desired outcome.
>
> In fact I hacked up some hal bits & pieces to monitor the turnaround
> overshoot on the lathe with a hal meter, make thousandths out of that,
> and set the end point for that much less penetration.  That has worked
> well, if I run the calculator right. :)

Having mentioned it, here is that bit of hal code from the lathe:
===============================================================
# Now, lets see if we can track the G33.1 turnaround overtravel
# first, make a sum2 a sub2
setp    sum2.ovrtrvl.gain0      -1.0000

# then net the sample holds but sample needs s32, not float so use count
net     ovrtrvl1                hm2_5i25.0.encoder.00.count     
sample.dirchg.in sample.spndlchg.in
net     spindle-ccwcmd          motion.spindle-reverse          
sample.dirchg.hold
net     spindle-reverse         abs.encdir.is-negative          
sample.spndlchg.hold

# and calc the overtravel from s32ś
net     ovrtrvl2                sample.dirchg.out               
s32_float.cmd.in
net     ovrtrvl3                s32_float.cmd.out               
sum2.ovrtrvl.in0
net     ovrtrvl4                sample.spndlchg.out             
s32_float.spndl.in
net     ovrtrvl5                s32_float.spndl.out             
sum2.ovrtrvl.in1

# the hal pin sample.ovrtrvl.out should be shown with a hal__meter
=================================================================
Now, the output you see in the hal_meter looking at sum2.ovrtrvl.out is 
in encoder counts, and hal isn't much good with floating point math, so 
you'll need to know your encoders edges per turn, so its easy to convert 
that figure to turns or fractions thereof, by dividing the number you 
see by the number of encoder edges.  I'm fond of the TI 30x or 34, so I 
keep one near each machine for that as a way to get the thread and 
fraction that you need to use as the final depth command to the final 
instance of the pecking.  That turns.whatever of course needs to be 
multiplied by the threads pitch to get how much early you can call done.

> > by Neil. Also how will i provide working example? Are there any
> > guideline to write tests? Thanks
> > Tanay
> >
> >
> > --------------------------------------------------------------------
> >-- -------- Transform Data into Opportunity.
> > Accelerate data analysis in your applications with
> > Intel Data Analytics Acceleration Library.
> > Click to learn more.
> > http://pubads.g.doubleclick.net/gampad/clk?id=278785351&iu=/4140
> > _______________________________________________
> > Emc-developers mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/emc-developers
>
> Cheers, Gene Heskett


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785351&iu=/4140
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to