Boxford 125 lathe Tool Changer Comp FERROR (SOLVED)
Please Log in or Create an account to join the conversation.
The main problem I see here is the fact that the commanded position continues to increment until it rolls over after 360 at which point it tries to reverse to get to the next location.
Please Log in or Create an account to join the conversation.
So if it backs up until the motor stalls would it not loose steps that way?
Good point. I wonder if it is resetting the count when it has finished reversing.
I am about to go and test something on the real machine.
I want to run from a fresh start. m6T1 to T8 one step at a time as I think it did more that one revolution in reverse at one point.
Re the Adir
Adir Tool-change-pos.cmd stepgen.2.counts
T2 F 20.7 1449 forward
T3 T 43.2 3024 forward
T4 F 63.9 4473 forward
T5 T 86.4 6048 forward
T6 T 101.4 7497 forward
T7 T 129.6 9072 forward
T8 F 150.3 10521 forward
T7 T 308.4 215 went forward correct
T8 T 329.1 23037 forward
T6 F 103.7 7259 went reverse
T7 T 126.2 8834 forward
T8 F 146.9 10283 forward
T1 T 169.4 11858 forward
T3 T 213.6 14952 forward
T8 T 324.7 22729 forward
T6 F 99.2989 6951 went reverse
T3 F 212.2 14854 went forward correct
T1 T 346.8 24276 forward
T3 F 31 2170 went reverse not at a tool position
T2 F 187.3 13111 forward
When it goes forward it always backs up. When it goes in reverse you can't tell if it doe the backup because it's moving in that direction.
Also this is without the pawl in the turret so won't be missing steps
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Which makes somewhat sense since that's what it does when rotates backwards to lock the toolchanger (it reduces the position value by a bit).
But the idea of using the A axis seems to be that it would rotate in which ever direction the commanded position can be reached faster (ie <180°).
Please Log in or Create an account to join the conversation.
My Rotary axis in 2.8 behaves exactly like that. If it is at 360° and I command it G0 A1 it moves backwards. I could have sworn it moves the shortest way.
Clearly I don't use it often enough.
[edit]
I just tried WRAPPED_ROTARY = 1 and while not exactly what you want could probably be used if the component was adapted. It then takes an angle and the sign determines the rotation direction. So instead of only subtracting a bit from the commanded position it would also change the sign to negative.
So clearly you are correct that something has changed how the rotary axis is handled.
Please Log in or Create an account to join the conversation.
I think I have the scale correct.
From the comp
.
param rw float odd_move = 22.2
param rw float even_move = 24
will work for TCL 160 and TCL 125 and probably other lathes with the same 'move past pawl and reverse to stall against it' methodology.
These move figures are only half the actual move in degrees. The scaling takes care of the distance actually moved.
There is a very good reason for this.
It prevents the stepgen seeing any move as being in excess of 180degrees, therefore all moves between tool stations will be forward moves.
If you command a move to a position which is say 270degrees on a angular axis, the stepgen will try to move 90degress backwards
to get to the same point by the shortest route.
In theory unlinking the stepgen dir signal and using our own should work, but it didn't and the axis wanted to go backwards all
the time despite the flag being set at TRUE (FWD).
As this worked perfectly, I preserved my sanity and just left well alone.
So I am not sure where we can go from here.
I wonder if AndyPugh linuxcnc.org/docs/2.7/html/man/man9/carousel.9.html could be get to work.
Edit: Have you seen this: It was referenced in the readme.
.TH TOOLCHANGER "9" "2011-05-10" "EMC Documentation" "HAL Component"
.de TQ
.br
.ns
.TP \\$1
..
.SH NAME
toolchanger \- This component controls the Boxford 240 Lathe Auto Tool Changer. M6 calls this
.SH SYNOPSIS
.HP
.B loadrt toolchanger
.SH FUNCTIONS
.TP
\fBtoolchanger\fR (uses floating-point)
.SH PINS
.TP
.B toolchanger.toolchange\fR bit in \fR
Receives signal from M6 that tool change required
.TP
.B toolchanger.toolnumber\fR s32 in \fR
Receives Tx data from M6 (tool number requested) Only allows 1-8
.TP
.B toolchanger.currenttoolnumber\fR s32 in \fR
Receives old tool number
.TP
.B toolchanger.position-cmd\fR float out \fR
Sends location required
.TP
.B toolchanger.toolchanged\fR bit out \fR(default: \fIfalse\fR)
Sends signal when tool change finished
.TP
.B toolchanger.ishomed\fR bit in \fR(default: \fIfalse\fR)
Status of A axis homing
.TP
.B toolchanger.jog-forward\fR bit in \fR(default: \fIfalse\fR)
Facilitate jogging of stepgen via component
.TP
.B toolchanger.jog-back\fR bit in \fR(default: \fIfalse\fR)
Facilitate jogging of stepgen via component
.TP
.B toolchanger.jog-move\fR float in \fR(default: \fI0\fR)
distance to jog
.SH PARAMETERS
.TP
.B toolchanger.odd-move\fR float rw \fR(default: \fI22.2\fR)
distance from odd tool station to even one
.TP
.B toolchanger.even-move\fR float rw \fR(default: \fI24\fR)
distance from even tool station to odd one
.TP
.B toolchanger.divisor\fR float rw \fR(default: \fI2\fR)
used in calculating reverse move to lock
.TP
.B toolchanger.fudge-factor\fR float rw \fR(default: \fI1\fR)
additional move to ensure locking
.SH AUTHOR
ArcEye schooner30@tiscali.co.uk
.SH LICENSE
GPL
Please Log in or Create an account to join the conversation.
I did butcher the toolchanger.comp a bit just a shot in dark really as my C knowledge is miniscule. But if you feel brave enough you can give it a try although I probably broke more than anything else.
The idea was to let the commanded position add up beyond 360. Note that I removed the trick with the half angles as this is now not relevant anymore. So you would need to divide your scale by two.
.
Attachments:
Please Log in or Create an account to join the conversation.
The idea was to let the commanded position add up beyond 360. Note that I removed the trick with the half angles as this is now not relevant anymore. So you would need to divide your scale by two.
.
Thanks I will certainly give it a try tomorrow morning .
Watch this space :
Please Log in or Create an account to join the conversation.
The idea was to let the commanded position add up beyond 360. Note that I removed the trick with the half angles as this is now not relevant anymore. So you would need to divide your scale by two.
.
Thanks I will certainly give it a try tomorrow morning .
Watch this space :
Ok update and a question first.
When it reverses to lock the pawl it will miss steps because it will stall the motor.
So the question is does it reset the stepgens before it moves to the next tool ?
Now for the good news. It is working but I need to do a bit more testing.
I have spent a lot of time getting the scale correct.
Between us it appears to work it certainly does not go backwards.
I am not sure yet if when locking the pawl and loses steps it keeps in sync.
Re: the fudge move is there only one place to adjust the amount of reverse or is there two values i.e. one for odd and one for even numbers.
But a massive step forward. Thanks you so much for keeping with me and sorting this out.
When I can guarantee that it is working 100% I wonder if we can get the new comp into the list for others to use.
Please Log in or Create an account to join the conversation.