CNCzone.com-The Largest Machinist Community on the net!



Home Page Mark Forums Read Today's Posts My Replies Classifieds Reviews Photo Gallery Web Links Share Files Advertise With Us Ad List
Go Back   CNCzone.com-The Largest Machinist Community on the net! > Machine Controllers Software and Solutions > Controller Cards



Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 11-14-2008, 04:59 PM
Al_The_Man's Avatar
Community Moderator
 
Join Date: Dec 2003
Location: Canada
Posts: 15,714
Al_The_Man is on a distinguished road
Buy me a Beer?
Galil Threading routine update.

This is an update on the attempt to implement a threading system using the Galil gearing routine.
This description outlines the manual procedure and the Galil equivalent is in blue text.
The object was to try and replicate the method used when a manual lathe is used with a back gearing run off the spindle to a lead screw driving the saddle.
In a manual lathe the gear ratio is selected in order to implement the ratio between the spindle and the lead screw in order to synchronize spindle to the saddle.
The Spindle motor is rotated at the selected speed. (Ditto Galil)
The spindle motor uses either the Y or W axis encoder, and can be fixed speed motor with gear box or analogue controlled from Galil (non-Servo) PID turned off.

The tool post is taken to a position in the X & Z. (Ditto Galil)
When the thread dial is in the correct position, the half-nut lever is used to engage the saddle to the lead screw.
From this point the spindle has complete control of the saddle and the manual control is not possible in the Z. (Ditto Galil)
When the Spindle encoder index mark is detected (FI), the Z axis is imediately synchronized to the spindle encoder (master), from this point in the cycle the Z axis follows the spindle encoder, regardless of spindle speed.

When the thread length is completed, the X is withdrawn and simultaneously the gearing is dis-engaged.
When the thread length is detected the X axis withdraws from the thread, at the same time the gearing is turned off, and the X axis motor reverts to normal servo control positioning.

The Z & X axis are returned to the start position and the X is fed in via the compound rest set to 29° in order to take a subsequent cut using one edge cutting of the tool.
At the appropriate point on the thread dial, the Half-huts are engaged and the routine repeated.
The Z&X return to the start and in the subsequent cut the X axis is moved in a calculated amount together with an advance in the Z once the next FI trip point is detected,
effectively simulating the compound rest 29̊° setting.

One slight difference is that due to the fact the spindle can be turning at a high rpm when the gearing is engaged to a stationary saddle, there is immediatley a large following error of the Z servo until syncronism is achieved.
If it is found there is a need for gradual engagement, there is a an application note #2440 to this effect.
In the experiments so far, I have used a Legacy card that does not have this command,
so a loop routine was written using The TL command that gradually raised the Torque from 0 to 9.999.
This is like an electronic version of mechanical synchromesh, where you try to engage a spinning gear to a stationary one.
One other benefit of using the FI command is it resets the spindle encoder count to zero, not that it is really important, as the total encoder count is irrelevant to the gearing routine.

So far the Bench set-up has worked flawlessly, Now the crunch obviously is not so much if it will work as to how the repetitive accuracy will be.
The down side is I do not have a lathe at this point to try it on until a few months time.
If nothing else, I will have come very familiar with the Galil Gearing routine.
AL.
__________________
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

  #2   Ban this user!
Old 11-14-2008, 05:56 PM
Karl_T's Avatar  
Join Date: Mar 2004
Location: Dassel,MN,USA
Posts: 1,308
Karl_T is on a distinguished road

Al,

When you get something working, I'd like to try it for gear hobbing. Electrically, hobbing is just like threading but the threads are EXTREMELY long. The fourth axis needs to turn in relation to the mill spindle.

I have a mill with a Galil 17X0 card, encoder on spindle, and fourth axis.

Will you be using a Galil input tied to the index mark?

Karl
Tweet this Post!Share on Facebook
Reply With Quote

  #3  
Old 11-14-2008, 06:08 PM
Al_The_Man's Avatar
Community Moderator
 
Join Date: Dec 2003
Location: Canada
Posts: 15,714
Al_The_Man is on a distinguished road
Buy me a Beer?

So far I am using the FI itself, IOW with the spindle spinning, the command is GAW;FIW;AMW;GRX=(Gear ratio).
I will post the relevant code for the gearing as an examle of what I have tested so far.
If the slave was engaged before the spindle start, there would be no timing issue.
Al.
__________________
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

  #4  
Old 11-14-2008, 06:50 PM
HuFlungDung's Avatar
Moderator
 
Join Date: Mar 2003
Location: Canada
Posts: 4,823
HuFlungDung is on a distinguished road

The notes for the FI command recommend that for high accuracy, the speed during the search should be 500 counts/sec or less. So depending on what resolution the spindle encoder has, this is going to restrict the spindle speed to what? 30rpm for a 1000 count encoder?

I suppose that less accuracy would be acceptable, if the inaccuracy were repeatable at a given rpm.

Al, what are you currently using to rotate the spindle encoder on the test bench? I'm thinking if you had something like a drill motor, that you could run some sort of a mandrel (and the encoder on the outboard end of that), around which you could wrap paper, and use a pen for a tool to scribe lines on the paper. This will give you some frame of reference from which to tell if the tool is tracking the exact same path every repeat. You don't even need to program anything more than the same path to repeat over and over, at least for a start.

Then you've got to get the rpm up and see where it goes from there.
__________________
First you get good, then you get fast. Then grouchiness sets in.

(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

  #5  
Old 11-14-2008, 07:59 PM
Al_The_Man's Avatar
Community Moderator
 
Join Date: Dec 2003
Location: Canada
Posts: 15,714
Al_The_Man is on a distinguished road
Buy me a Beer?

Originally Posted by HuFlungDung View Post
The notes for the FI command recommend that for high accuracy, the speed during the search should be 500 counts/sec or less. So depending on what resolution the spindle encoder has, this is going to restrict the spindle speed to what? 30rpm for a 1000 count encoder?

I suppose that less accuracy would be acceptable, if the inaccuracy were repeatable at a given rpm.

Al, what are you currently using to rotate the spindle encoder on the test bench?
Hu.
Yes, Traditionally the FI is used to accurately register the zero reference of an axis, so the FI is usually used at very low rpm after the FE.
I am using it at high speed, so yes, I am banking on the repetition factor being consistent.
I am using a DC motor with an encoder for the spindle, run from a variable speed controller.
I have run the pseudo spindle up to 2500 rpm.
I set the code to run in a loop as it would normally on a machine, for a threading cycle.

Setting up a suitable measuring method is the problem, without an actual machine to run.
Al.
__________________
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

Sponsored Links
  #6   Ban this user!
Old 11-14-2008, 09:25 PM
 
Join Date: Jan 2007
Location: MI. USA
Posts: 201
CarbideBob is on a distinguished road

Is the spindle running as a servo axis in vel mode under the galil?
The error will be number of counts/sample time the spindle is running,,, at least that's what I've gotten.

If the Z axis is attached to a slide stop the spindle after the gearing is engaged and roll the spindle motor fwd to a fixed count.
Attach a indicator to the Z slide and zero it.
Back the spindle up start the routine and check the indicator when you roll the spindle fwd to the same position.

Hard to tell in software if you're "caught up" if you're rotating at 1000c/sample as the positions you read jump in 1000 count intervals.

I wonder if the lag will change if there are 3 other tasks running?
Bob
__________________
You can always spot the pioneers -- They're the ones with the arrows in their backs.
Tweet this Post!Share on Facebook
Reply With Quote

  #7  
Old 11-14-2008, 11:21 PM
Al_The_Man's Avatar
Community Moderator
 
Join Date: Dec 2003
Location: Canada
Posts: 15,714
Al_The_Man is on a distinguished road
Buy me a Beer?

The spindle is a vel controlled motor, the PID is set to zero, so it is an open loop motor with an encoder.
Neither motors are attached to anything yet as it is a bench test jig.
Once the gearing is engaged, TE show 0 pretty quickly, so I am not worried at this point about any gearing error, just the consistent result required between the trip point and the actual gearing engagement.
If another thread is running it could affect it I would assume.
Al.
__________________
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

  #8   Ban this user!
Old 11-15-2008, 12:30 AM
 
Join Date: Jan 2007
Location: MI. USA
Posts: 201
CarbideBob is on a distinguished road

Now that I've been thinking about it you should be able to test the engagement at different speeds just by running the routine and letting the spindle motor stop.
Then rotate the spindle motor by hand until the Z reaches a certain number.
Repeat and see how far the spindle count is off when you reach the same Z.

I was thinking about hooking the index from the spindle to the latches for the spindle and Z encoder. Since the latches are done in hardware their timing should be constant and they should not care about sample times.

Then you could compare the latched values to determine if any correction was needed.

Bob
__________________
You can always spot the pioneers -- They're the ones with the arrows in their backs.
Tweet this Post!Share on Facebook
Reply With Quote

  #9  
Old 11-15-2008, 10:27 AM
HuFlungDung's Avatar
Moderator
 
Join Date: Mar 2003
Location: Canada
Posts: 4,823
HuFlungDung is on a distinguished road

I cannot say I tried everything back when I was experimenting with getting my Galil lathe threading program working, but I did find a lot of variance in the response time of the card to using high speed latches and I don't know what else.

That was why I ended up feeding the spindle encoder index back into one of the inputs on the Galil card and used the AI command to detect the index on this input. Now whatever the Galil does between detection and initiation of motion, I don't really know, but the AI logic was the only sequence that seemed to be exactly uniform in response time.
__________________
First you get good, then you get fast. Then grouchiness sets in.

(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

  #10  
Old 11-15-2008, 11:45 AM
Al_The_Man's Avatar
Community Moderator
 
Join Date: Dec 2003
Location: Canada
Posts: 15,714
Al_The_Man is on a distinguished road
Buy me a Beer?

Originally Posted by HuFlungDung View Post
but I did find a lot of variance in the response time of the card to using high speed latches and I don't know what else.
.
Did you use through the Camsoft software or download into Galil memory and run direct?
This is a portion of the preliminary code I tested with gradual engagement.
X = 'Saddle' servo slave Z = spindle, master open loop
#GEAR
GAZ
#ENAGE
TORQUE=0
TLX=TORQUE
FIZ
AMZ
GRX=.25
#LOOP
TORQUE=TORQUE+0.1
TLX=TORQUE
WT5
JP #LOOP,TORQUE<9.9
MF1000000
GRX=0
PA0
BGX
AMX
JP#ENGAGE
EN

Al.
__________________
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

Sponsored Links
  #11  
Old 11-15-2008, 02:19 PM
HuFlungDung's Avatar
Moderator
 
Join Date: Mar 2003
Location: Canada
Posts: 4,823
HuFlungDung is on a distinguished road

After the initial failure of the VIRTINDEX, my other trials were run right from the Galil's memory. The context of my trials was only to discover the best way to create and detect any kind of 'event' that could trigger the threading cycle reliably.

What we don't know is how the Galil is eating up clock cycles as all these commands are being executed. What baffled me is that the time duration could vary as much as 30% when rerunning the same logic in a loop. Maybe the Galil has its own 'overhead' in the form of built in routines that may or may not run consecutively with the logic of a given loop.
__________________
First you get good, then you get fast. Then grouchiness sets in.

(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Tweet this Post!Share on Facebook
Reply With Quote

Reply




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Arcs to Circles Lisp Routine tahlinc Autodesk Software (Autocad, Inventor etc) 0 07-20-2008 09:36 AM
adding loop sub routine wronggrade Mastercam 3 04-21-2008 02:25 PM
ez track V6. pocket routine guy-b Bridgeport and Hardinge Mills 5 08-02-2006 08:09 PM
Activating HPCC in a sub-routine? Dawson Daewoo/Doosan 0 03-18-2006 03:04 PM
3D surface sub-routine lazza G-Code Programing 2 08-30-2005 09:58 AM




All times are GMT -5. The time now is 04:54 AM.





Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
Content Relevant URLs by vBSEO
Template-Modifications by TMS

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353