Hey everybody. Matt here.
I'm working on a fairly long program (about 3000 lines and climbing). What is the line limit for a src file?
Hey everybody. Matt here.
I'm working on a fairly long program (about 3000 lines and climbing). What is the line limit for a src file?
Not sure if there is one, I've hit over 5000 lines without issue. I think it's more of a display buffer size / file size question if any.
If I were you I would try and split the program up a little bit better, your customer's technicians will hate you
Long story short, the customer wants one long program for now (this is their first robot). Once they get going and start programming some additional parts, they will see the wisdom of splitting a long program into sub-programs.
the customer is allways right, even if he wrong
but you can allways convince him the benefits of the splitted program nicely
it's their first robot and already have idea how it should be programmed? nice...
I am happy to report that the customer has now seen the error in their thinking and has agreed to splitting the program up.
We have flip flopped again. Now I'm back to having a very long program this time for Kuka reasons.
In this application, I have to use Touch Sense to find the part. As far as I can tell, the Touch Sense correction data (CD) is only available in the module where it was created. If this is true, then I am forced to keep all of the welding seams I have to do in one long program (I was hoping to split them up into small, more manageable chunks).
Can anyone verify that the CD's are only available in the module they were created in?
Also, any words of wisdom when working with long programs on the SmartPad. (I have already seen it slow down to a crawl while cutting & pasting.)
There's nothing stopping you from copying that CD data to a Global variable.
When copy&pasting looong programs, the SmartPad is a pain. Using Remote Virtual Pendant can help, but usually I just do everything offline with a text editor.
I looked in the .dat file for the CD data and for CD4, I found this:
DECL TSg_PCollCD_T VCD4={CD_IPO_MODE #BASE,Mastered TRUE,SDir_W {X 0.0,Y 0.0,Z -100.000,A 0.0,B 0.0,C 0.0},Ref_W {X -153.457489,Y
-1287.33289,Z 132.456833,A -112.388405,B 88.3614,C 156.566},Meas_W {X -153.461166,Y -1287.37585,Z 131.362442,A -112.352661,B
88.3573532,C 156.602020},Diff_W {X -0.00367736816,Y -0.0429687500,Z -1.09439087,A 0.0357437134,B -0.00404357910,C
0.0360260},VecLenDiff_W 1.09524024,MEnum #CDCalcOK,MC 1
I'm not sure how I would copy this to a global variable.
Simply declare your own variable of the same type, Globally, then copy.
;in the .DAT file
DECL GLOBAL TSg_PCollCD_T MyCDVariable = {CD_IPO_MODE #BASE} ; fill in some initial value just as a placeholder. Only one value of the Structure is necessary
; in the .SRC file
myCDVariable = VCD4
That's about all there is to it.