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 > Fanuc


Fanuc Discuss Fanuc controllers here!


This forum is sponsored by:

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Ban this user!
Old 12-07-2010, 08:58 AM
 
Join Date: Apr 2007
Location: Thailand
Posts: 9
ixoxi999 is on a distinguished road
Question about Custom Macro AGAIN!!!!!

I have this Custom Macro Program in my

Miyano TSV-21 Controll Fanuc 0M-A

O9003
N50
N100 G65 H81 P800 Q#1000 R1;
N150 G65 H81 P800 Q#1004 R1;
N200 G91 G28 Z0 M89;
N225 G49;
N250 G65 H82 P250 Q#1001 R1;
N300 M80;
N350 G65 H82 P350 Q#1006 R1;
N400 G30 Z0;
N450 G65 H82 P450 Q#1003 R1;
N500 M82;
N550 G65 H82 P550 Q#1004 R1;
N600 G28 Z0;
N650 G65 H82 P650 Q#1002 R1;
N700 M81;
N750 G65 H82 P750 Q#1005 R1;
N800 M99;

As we know this is Custom Macro A.

First Question :

I just wanna know that where can I find the variable "#1000-#1006" in the program which are Input interface variable.

Where can I found in the controller? If they located in Diagnostic, please inform me the no. I want to check the status of them.

Last Question :

"N750 G65 H82 P750 Q#1005 R1;"

This line shows us that if #1005 is not equal to 1 jump to N750.
If #1005=2 ,this will loop only in this line. Am I right?

Thank again for all people that both help and have kindness for me.

Best Regards,
Reply With Quote

  #2   Ban this user!
Old 12-07-2010, 11:00 AM
 
Join Date: Feb 2006
Location: india
Posts: 1,187
sinha_nsit is on a distinguished road

I have never used macro A, but based on my experience with macro B, I would suggest to store the values of desired system variables in some local/common variables for reading these on macro-variable screen.

Sinha
Reply With Quote

  #3   Ban this user!
Old 12-08-2010, 03:10 AM
 
Join Date: Sep 2010
Location: Australia
Posts: 733
angelw is on a distinguished road

Originally Posted by ixoxi999 View Post

As we know this is Custom Macro A.

First Question :

I just wanna know that where can I find the variable "#1000-#1006" in the program which are Input interface variable.

Where can I found in the controller? If they located in Diagnostic, please inform me the no. I want to check the status of them.
If you set bit 5 of parameter 0011 to 1, every macro statement can be executed in single block mode. This will allow you to step through the program and be able to check the value of the macro variables, prior to and after the execution of the macro statement.

As Sinha stated, store the value of the system variable in a local or common variable, one that's not being used elsewhere, for example #1, and you will be able to see the value of the system variable by observing variable #1 you've used to store its value.

Place the following Macro statement before the Macro statement containing the system variable you're interested in.

G65 H01 P#1 Q#1000
N100 G65 H81 P800 Q#1000 R1;

Originally Posted by ixoxi999 View Post
"N750 G65 H82 P750 Q#1005 R1;"

This line shows us that if #1005 is not equal to 1 jump to N750.
If #1005=2 ,this will loop only in this line. Am I right?
Yes, that's correct.

Regards,

Bill

Last edited by angelw; 12-08-2010 at 04:56 PM.
Reply With Quote

  #4   Ban this user!
Old 04-25-2012, 02:01 AM
 
Join Date: Oct 2007
Location: sweden
Posts: 6
stoffomatic is on a distinguished road

The G65 stores values of letters:
A=#1
B=#2
C=#3

So Q#1000 is stored in #17

Try to find Nc Plot by Scott Martinez, very helpful reading.
Reply With Quote

  #5   Ban this user!
Old 04-25-2012, 03:19 AM
 
Join Date: Sep 2010
Location: Australia
Posts: 733
angelw is on a distinguished road

Originally Posted by stoffomatic View Post
The G65 stores values of letters:
A=#1
B=#2
C=#3

So Q#1000 is stored in #17

Try to find Nc Plot by Scott Martinez, very helpful reading.
When passing a value as an argument with G65 in User Macro B, the "#" character does not necessarily have to be used. The format can be:
G65 P__ Q1000
where:
P = the Macro Program Number

In the Macro program, the local variable #17 would be assigned the value 1000, or if #1000 is used in conjunction with the address Q, the value of #1000 is passed to #17 in the Macro. #17 will retain its value locally though.

The example in Post #3 is User Macro A. User Macro A does not have Local variables, only Common variables; accordingly, the variables are not passed as argumnets. In user Macro A, the G65 indicates a Macro statement and the H specifies the Macro function.
Regards,

Bill

Last edited by angelw; 04-25-2012 at 08:25 AM.
Reply With Quote

Sponsored Links
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
Need Help!- Fanuc custom Macro Question???? ixoxi999 Fanuc 9 12-08-2011 04:31 AM
"difference between Custom Macro A and Custom Macro B" arulthambi Parametric Programing 4 10-05-2009 03:34 PM
custom macro question sinha_nsit G-Code Programing 28 04-18-2009 06:44 AM
custom macro The Metal Daewoo/Doosan 2 09-28-2006 07:26 AM




All times are GMT -5. The time now is 09:33 PM.





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