Hi
How can we use any variable in the definition block of UGC?
sample
LEN1=any number
DEF WORK
PS LC,[0,0],[LEN1,50]
END
Thanks
Hi
How can we use any variable in the definition block of UGC?
sample
LEN1=any number
DEF WORK
PS LC,[0,0],[LEN1,50]
END
Thanks
"Imagination is more important than knowledge."
hi, i also tried, and it failed ... but, what about creating a macro, so to handle this ?
code will be like this :
is possible to parameterize entire odraw, by creating a soubroutine that will generate linear code (g-code), starting with some numbersCode:[ main-program.min ] CALL ODRAW // program continues M02 [ odraw.ssb ] ODRAW (------<DRAWING DATA>------) NOEX VTLIN[4]=3 VTLFN[4]=1 VTLL[4]=50 VTLA2[4]=3 VTLA1[4]=80 NOEX VTLIN[6]=8 VTLFN[6]=1 VTLD[6]=12 VTLL[6]=50 VTLA2[6]=5 VTLA1[6]=80 NOEX VWKR=9999.999 VCHKL=0 VCHKD=0 VCHKX=80 VCHKZ=-38 DEF WORK PT LF,LC,[-38,0],[80,80], [38,0] END DEF WORKF PF 0,[0,0],80,D END CLEAR DRAW RTS
so you use LEN1 inside main program, generate the soubroutine, and the main program will call it; downside is that it will require to create the soubroutine before executing the main program, thus more keystrokes; if u wish, i will create an example
to do it without auxialary keystrokes, then it will be required to create the code like you wish, before sending it to the machine, and i can't do that / kindly
Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg
i mean a parametric, like this :
that generates linear code :Code:[ test.min ] NOEX LEN1 = 60 FWRITC odraw.ssb;C ( append c = rewrite existing content ) NOEX PUT 'ODRAW' PUT $0D0A $ PUT 'DEF WORK' PUT $0D0A $ PUT 'PS LC,[0,0],[' PUT LEN1 , 3 PUT ',50]' PUT $0D0A $ PUT 'END' PUT $0D0A PUT 'RTS' WRITE C ( CLOSE C ) M02
Code:[ odraw.ssb ] ODRAW DEF WORK PS LC,[0,0],[ 60,50] END RTS
Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg