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 > G-Code Programing


G-Code Programing Discuss G-code programing and problems here!


This forum is sponsored by:

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Ban this user!
Old 02-22-2009, 12:49 PM
 
Join Date: Feb 2009
Location: Germany
Posts: 5
sion is on a distinguished road
An example G-code for Sinumerik

Hello, Can someone post an example of a simple G-code for a Sinumerik (840D)?
Thanks
Reply With Quote

  #2   Ban this user!
Old 02-23-2009, 09:26 AM
 
Join Date: Jan 2009
Location: united states
Posts: 16
tfisher is on a distinguished road
sinumerik program

here is a simple program used on a boring bar.

T5 M6 ;TOOL CHANGE
T6 ; PRE SELECT TOOL
D1 G54 G90 G95 S500 F.012 M3
TRANS Z-10 W10
GO Z0
X0 Y0 W5 ;position cutter in middle of hole
W-1 ;position 1 inch in to hole in part
G1 X2 G41
G3 I-2 ; cut 4 inch diameter
G0 X0 G40 ;rapid back to center and turn off cutter comp
W10 ;rapid saddle out 10 inches
TRANS
M30 ; end program

if you need more examples or have something specific you need done i could probably help. i have lots of programming experience with this and have written lots of macro's for various operations.

Last edited by tfisher; 02-23-2009 at 09:43 AM.
Reply With Quote

  #3   Ban this user!
Old 02-23-2009, 11:31 AM
 
Join Date: Feb 2009
Location: Germany
Posts: 5
sion is on a distinguished road

Thanks for posting the code,
This is bit complex for me. Could you please post as simple as

Move in direction of X 10mm
Move in direction of Y 10mm

I actually want to see the exact format(headers etc) of the code for Sinumerik .
thanks
Reply With Quote

  #4   Ban this user!
Old 02-23-2009, 12:12 PM
 
Join Date: Jan 2009
Location: united states
Posts: 16
tfisher is on a distinguished road
simple program

the first few lines of the program are loading the tool and getting the offset designated.
D1 TURNS ON TOOL LENGTH
G54 OFFSET I AM USING
G90 DESIGNATES ABSOLUTE COORDINATES
G95 IS INCHES PER REV.
S IS RPM
F IS FEED IN IPR

to move the actual axis all you need to program is the following.

G0 X10 ;MOVE X ABSOLUTE 10MM FROM 0 IN RAPID G1 WOULD BE FEED
Y10 ;MOVE Y 10MM UP FROM 0

hope this is what you are looking for if not let me know. anything written after a semicolon in the program will not be read. by the control

Last edited by tfisher; 02-23-2009 at 04:02 PM.
Reply With Quote

  #5   Ban this user!
Old 02-23-2009, 12:58 PM
beege's Avatar  
Join Date: Feb 2008
Location: USA
Posts: 518
beege is on a distinguished road

Originally Posted by tfisher View Post
GO X10 ;MOVE X ABSOLUTE 10MM FROM 0 IN RAPID G1 WOULD BE FEED
Y10 ;MOVE Y 10MM UP FROM 0

hope this is what you are looking for if not let me know. anything written after a semicolon in the program will not be read. by the control
I think the GO should be G0 (difference between the word "GO" and "G ZERO")
Reply With Quote

Sponsored Links
  #6   Ban this user!
Old 02-24-2009, 01:36 AM
 
Join Date: May 2006
Location: Croatia
Age: 51
Posts: 10
Tale is on a distinguished road

Sion,
I will be glad to help you, only wish to know which kind of machine you have (turning or milling) and how many axes it have.

Down you can see an example of my code for Waldrich Coburg Multitech portal milling machine, but don't be afraid it is not so complicated as seems.

%_N_SetupNo1_MPF
;$PATH=/_N_WKS_DIR/_N_BLOK6_WPD

;recorded 11.07.2007
;cylinder head 6L23/30H
;Zero point G54: X-os...45 mm from center line
; " : Y-os...bearing center
; " : Z-os...marked machining line


;premachining, allowance +3 mm
MSG ("TECHNOLOGICAL BASE")
N10 L123
N20 ATT_NO=1
N30 L9926
N40 L9925
N50 M0 ;milling head D200, kapa45°
N60 T_NO=8
N70 L9923
N80 G54
N90 XV=0 YV=0 ZV=943
N100 L9958
N110 G0 G90 T=T_NO D1 Z200
N120 M3 M41 S250 F960

;1. pass (narrow)
N130 G0 G64 X100.499 Y595.625
N140 Z15
N150 G1 Z11 ;1. pass
N160 Y295.625
N170 X80.499
N180 X37.499
N190 G0 Z200
....
....
....
N1460 L9925
N1470 M0 ;TOOL dismounting
N1480 T_NO=0
N1490 L9923
N1500 L123
N1510 ATT_NO=1
N1520 L9926
N1530 M30

I can try to find complete Programming manual in PDF format, if you need it.
Regards,
M. Talic
Reply With Quote

  #7  
Old 02-24-2009, 11:06 AM
Switcher's Avatar
Moderator
 
Join Date: Apr 2005
Location: Vectorink.com
Posts: 3,660
Switcher is on a distinguished road

%_N_MAIN_MPF

INIT_NC_PROG
MACHINE_DATA


G0 X0.0
G0 Y0.0
G01 X-10.0 F=50.0
G01 Y-10.0 F=50.0
G0 X0.0
G0 Y0.0

M30

This is a sample from a Siemens 840D (NT) on a toolgrinder (5-axis). The code in red is prob. machine specific (sub programs), you can try as is, If it alarms out, just delete the code in red.

A few things you should know (840D) runs 2 folders, the Main program & the Sub programs, each machine part can only have a single main program ( %_N_MAIN_MPF ) the "MPF" defines the Main program. You can do this from the "Program" softkey (Menu Select/Program).

You can also run the same code from MDI:

G0 X0.0
G0 Y0.0
G01 X-10.0 F=50.0
G01 Y-10.0 F=50.0
G0 X0.0
G0 Y0.0

M30


*****************************************

What machine are you running , & what specific cnc Control, 840D, 840Di,810D ?


.
__________________
Free DXF Files - Vectorink.com - myDXF.blogspot.com
Reply With Quote

  #8   Ban this user!
Old 02-25-2009, 02:46 PM
 
Join Date: Feb 2009
Location: Germany
Posts: 5
sion is on a distinguished road

Thanks a lot. that was all I need.

@Tale, I use 3 axis milling machine for precesion cutting operaions.
Yes a turorial would also be a great
best wishes
Reply With Quote

  #9   Ban this user!
Old 02-26-2009, 02:10 AM
 
Join Date: May 2006
Location: Croatia
Age: 51
Posts: 10
Tale is on a distinguished road

Originally Posted by sion View Post
Thanks a lot. that was all I need.

@Tale, I use 3 axis milling machine for precesion cutting operaions.
Yes a turorial would also be a great
best wishes
Sion,
I find Sinumerik 840D Programming manual in PDF and I can send it to you,
just need your e-mail address!
Reply With Quote

  #10   Ban this user!
Old 03-09-2009, 07:00 PM
 
Join Date: Jan 2005
Location: canada
Posts: 12
gokulkavin is on a distinguished road
CANNED CYCLE FOR SINUMERIK 840D CNC LATHE

HI,


CAN YOU PLEASE HELP ME ON CANNED CYCLE FOR SINUMERIK 840D CN LATHE.CURRENT PROGRAMS EXT ARE".MPF".PLS REPLY
THANKS
GUNA












Originally Posted by tfisher View Post
here is a simple program used on a boring bar.

T5 M6 ;TOOL CHANGE
T6 ; PRE SELECT TOOL
D1 G54 G90 G95 S500 F.012 M3
TRANS Z-10 W10
GO Z0
X0 Y0 W5 ;position cutter in middle of hole
W-1 ;position 1 inch in to hole in part
G1 X2 G41
G3 I-2 ; cut 4 inch diameter
G0 X0 G40 ;rapid back to center and turn off cutter comp
W10 ;rapid saddle out 10 inches
TRANS
M30 ; end program

if you need more examples or have something specific you need done i could probably help. i have lots of programming experience with this and have written lots of macro's for various operations.
Reply With Quote

Sponsored Links
  #11   Ban this user!
Old 03-09-2009, 09:17 PM
 
Join Date: Jan 2009
Location: united states
Posts: 16
tfisher is on a distinguished road
lathe programming

what kind of machining are you trying to do with the canned cycles? i'm not too familiar with the lathe cycles but i have looked at them and they are similiar to the milling ones.
Reply With Quote

  #12   Ban this user!
Old 03-10-2009, 10:53 AM
 
Join Date: Jan 2005
Location: canada
Posts: 12
gokulkavin is on a distinguished road
sinumerik canned cycle

Originally Posted by tfisher View Post
what kind of machining are you trying to do with the canned cycles? i'm not too familiar with the lathe cycles but i have looked at them and they are similiar to the milling ones.

Hi

Thanks for your reply and this is for poreba cnc horizontal lathe.it has all work offsets like g54-g57.thks
guna
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
help - sinumerik 3n jaimeeduardo General CNC (Mill and Lathe) Control Software (NC) 1 12-02-2009 05:39 AM
SINUMERIK 810M GA1 amo General Electronics Discussion 1 11-17-2009 02:58 AM
SINUMERIK SUBROUTINES HOLOMON General CNC (Mill and Lathe) Control Software (NC) 2 07-25-2008 06:25 AM
Sinumerik 3M to pc control jgriffith66 General Electronics Discussion 0 11-05-2007 03:13 AM
G-code example for sinumerik ari vederchi G-Code Programing 5 11-08-2006 11:03 PM




All times are GMT -5. The time now is 12:11 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 354 355 356 357 358 359 360 361