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 > Mach Software (ArtSoft software) > Mach Lathe



This forum is sponsored by:

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Ban this user!
Old 04-02-2007, 02:59 PM
cnc_swe's Avatar  
Join Date: Jan 2006
Location: sweden
Posts: 89
cnc_swe is on a distinguished road
I need make a loop in Mach

Anybody now how a loop makes in mach. I need a short g-code string to make example X 20.00 in 0.5mm/loop down to 10.00
Can I do this in any M or G-code. (I was talking about turning)
Tweet this Post!Share on Facebook
Reply With Quote

  #2   Ban this user!
Old 04-02-2007, 04:00 PM
holbieone's Avatar  
Join Date: Feb 2007
Location: usa
Posts: 421
holbieone is on a distinguished road

i don't think you are being clear enough for people to understand what you want

from what your post looks like your trying to turn a taper?
Tweet this Post!Share on Facebook
Reply With Quote

  #3   Ban this user!
Old 04-03-2007, 07:40 AM
cnc_swe's Avatar  
Join Date: Jan 2006
Location: sweden
Posts: 89
cnc_swe is on a distinguished road
Unhappy The loop I was looking for

This is not a taper or thread only normal turning from X20 to X10.

Well I donīt like write lot of code like this:

***** the sub text*******
N10 G00 Z0 X20
N20 G01 Z-10
N30 G00 X21
N40 G00 Z0
N50 G00 X 19.5
N60 G01 Z-10
and so on to X is 10.00
*********************
(if my cut on X is 0.5 I need to write this N10-N60 20 times

In some machin you are writing a sub menu as Sinumerik G901 R3=10 P1.
Like IF THEN ELSE as Pascal or Basic code.

IF <X10 call ***SUB TEXT *** again, until I have 10.00 on X

Hope this explanation is better.
Sorry about my english
Tweet this Post!Share on Facebook
Reply With Quote

  #4   Ban this user!
Old 04-03-2007, 03:14 PM
holbieone's Avatar  
Join Date: Feb 2007
Location: usa
Posts: 421
holbieone is on a distinguished road

Originally Posted by cnc_swe View Post
This is not a taper or thread only normal turning from X20 to X10.

Well I donīt like write lot of code like this:

***** the sub text*******
N10 G00 Z0 X20
N20 G01 Z-10
N30 G00 X21
N40 G00 Z0
N50 G00 X 19.5
N60 G01 Z-10
and so on to X is 10.00
*********************
(if my cut on X is 0.5 I need to write this N10-N60 20 times

In some machin you are writing a sub menu as Sinumerik G901 R3=10 P1.
Like IF THEN ELSE as Pascal or Basic code.

IF <X10 call ***SUB TEXT *** again, until I have 10.00 on X

Hope this explanation is better.
Sorry about my english
this clears up what your looking for

it all depends on the capabilities of controller your using to do stuff like that

some times i write a block of g-code in note pad then copy-paste as many times as in need then go back and edit the line that needs to be incremented

i have also written things in basic to automatically index the cuts

do you have visual basic or any other basic software

i can send you an example
Tweet this Post!Share on Facebook
Reply With Quote

  #5   Ban this user!
Old 04-04-2007, 04:53 AM
cnc_swe's Avatar  
Join Date: Jan 2006
Location: sweden
Posts: 89
cnc_swe is on a distinguished road
I found the answer

Thankīs holbieone.
I think if I hade been writing SUBROUTINE more people hade understand my question. The software I drive is Mach3. I found this on www.

www.artsoftcontrols.com/forum/index.php?
PHPSESSID=24644e697cb402c44ef2e650d300da9b&topic=310.0

S300 M3
M8
G00 G43 H3 Z1.00
G00 X1.0 Y2.0
M98 P1000
X2
M98 P1000
X3
M98P1000
M30


O1000
G01 F40 Z-.5
G01 F80 Z1.00
G04 P1.0
G00
M99

I copy this becaurse I think more people in the forum was understand my
"loop" question if they see the code from Brian Barker.
If you have another code Iīm really intressted, so holbieone please write.
Regards
cnc_swe
Tweet this Post!Share on Facebook
Reply With Quote

Sponsored Links
  #6   Ban this user!
Old 05-20-2007, 05:09 AM
 
Join Date: Jul 2004
Age: 73
Posts: 329
ozzie34231 is on a distinguished road

This is the way I do it, or just use a wizard.

%Lathe Turning Multi-Pass
#1001=0 %zero
#1002=2 %feed rate
#1003=3 %loops
#1004=0.6 %cut distance
#1005=.010 %pullback
#1006=0.020 %size of cut

F#1002
G90
G1 x#1001z#1001 %Go to 0,0
M98 P321 Q#1003 %Run Subroutine
G90
M30

O321
G0 G91 x[-1*#1006]
G1 G90 z[-1*#1004]
G1 G91 x#1005
G0 G90 z#1001
G0 G91 x[-1*#1005]
M99

Ozzie

Last edited by ozzie34231; 05-20-2007 at 05:19 AM. Reason: corrections
Tweet this Post!Share on Facebook
Reply With Quote

  #7   Ban this user!
Old 05-20-2007, 05:26 AM
 
Join Date: Jul 2004
Age: 73
Posts: 329
ozzie34231 is on a distinguished road
Not exactly correct

I just read what I posted and it's not exactly correct because it is very old, (before Mach), but you get the idea. By using relative and absolute moves you can accomplish what you're asking.
Using a wizard is much quicker.

Ozzie
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
Confused: Mach Turn, Mach Mill, Mach 2/3 ? CanSir Mach Software (ArtSoft software) 5 02-16-2007 05:41 AM
Mach 3 closed loop ? efrem Mach Mill 5 12-06-2006 08:01 PM
Lathe conversion - open loop vs closed loop bhowden General Metal Working Machines 7 03-21-2006 04:56 PM
Closed loop....open loop? DAB_Design General Electronics Discussion 10 06-26-2004 05:02 PM
Closed Loop Driver vs. Closed Loop Computer ojibberish Gecko Drives 3 06-08-2004 12:30 PM




All times are GMT -5. The time now is 06:26 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