rorycollins0
Plastic
- Joined
- Apr 3, 2020
Hey just wondering if anybody has a solution to this problem im having.
Im trying to adapt my fanuc B macros to work on the AB 9 control.
I frequently run into this issue
Allot of my Fanuc macros have input argument test comparing a local varialbe to #0(null)
and the Allen bradley control does not have a null value concept. all the local and volatile variable reset to 0.0000 on reset/m30/m99/power on.
heres an example of my dilema
Say your macro is g65p8001c54m2
in your macro program you have a line
o8001
IF[#3EQ#0]GOTO997
.
.
GOTO999
N997#3000=1(NO C VALUE PROGRAMMED)
N999M99
ALSO SOME OF MY MACROS RELY ON IGNORING NULL VALUES FOR EXAMPLE
G0X3.Y7.
G65P8084D3.T1.Q20.R.1Z-1.F30.
HENCE #24 & #25 ARE CONSIDERED NULL
O8084
.
.
G0X#24Y#25(IF XY ARGUMENTS WERE NULL NO MOVEMENT WOULD OCCOUR)
(WHILE DO LOOP BLAH BLAH)
END1
G0Z3.
M99
I am a pretty good programmer but i can't wrap my head around an easy solution thats not ridiculously complicated. The allen bradley manual calls it parametric programming and has no example of this in it.
any help or tips would be appreciated.
Im trying to adapt my fanuc B macros to work on the AB 9 control.
I frequently run into this issue
Allot of my Fanuc macros have input argument test comparing a local varialbe to #0(null)
and the Allen bradley control does not have a null value concept. all the local and volatile variable reset to 0.0000 on reset/m30/m99/power on.
heres an example of my dilema
Say your macro is g65p8001c54m2
in your macro program you have a line
o8001
IF[#3EQ#0]GOTO997
.
.
GOTO999
N997#3000=1(NO C VALUE PROGRAMMED)
N999M99
ALSO SOME OF MY MACROS RELY ON IGNORING NULL VALUES FOR EXAMPLE
G0X3.Y7.
G65P8084D3.T1.Q20.R.1Z-1.F30.
HENCE #24 & #25 ARE CONSIDERED NULL
O8084
.
.
G0X#24Y#25(IF XY ARGUMENTS WERE NULL NO MOVEMENT WOULD OCCOUR)
(WHILE DO LOOP BLAH BLAH)
END1
G0Z3.
M99
I am a pretty good programmer but i can't wrap my head around an easy solution thats not ridiculously complicated. The allen bradley manual calls it parametric programming and has no example of this in it.
any help or tips would be appreciated.