G'Day, all. I need to pick the hive-mind's brain for some insights.
I'm about to go to a customer site to make some modifications on an IRC5 (RW 6.09) that is running a very rigid and fully-defined software standard (which seems to have been written for S4Cs). It's a pick&place application using string-building and late binding to call each motion subroutine -- Home to Pick, Pick to Drop, Drop to Home, and so on.
The issue is, this software standard uses the same PROC names for every different part style, and actually uses UnLoad\Save and StartLoad to (as far as I can tell) "swap" different modules containing these same-named PROCs in and out of memory. Probably intended for robots with limited memory. But there's a footnote that this is obsolete for the IRC5, and I've heard the IRC5 throws errors when trying to use this code.
So, the Main module (never swapped) always calls the subroutine PickToDrop. But the "swapped" modules MOVE_1 and MOVE_2 both contain a global PROC with that name, and part of Main UnLoads one module and StartLoads the other whenever the requested Style GI from the PLC changes.
This robot is in production, but the memory-swap stuff has never come up b/c it's only had one part style so far. So of course I have to go there to add a new part style. Which, given how deeply-rooted this programming standard is, means I have to use this memory-swapping gimmick (or break the standard completely). And so far, I've had no luck getting answers from the people in charge of this standard.
So, my questions:
- do the UnLoad and StartLoad commands even work for RW 6.09?
- If not, does this software standard break entirely, or is there a workaround?
- With multiple Modules that contain PROCs with the same names, how do I prevent them from all trying to load, and having namespace collisions, during boot?
- If I need to UnLoad one Module and StartLoad another to do edits in Teach, is there a manual means to do that on the pendant? Or would I have to simply force the Style GI and then run the part of Main that does the Module swapping?
- For example, I tried creating the second Module (as a copy of the first module) in RobotStudio, and immediately got a tone of "ambiguous variable name" errors. It looks like I would need to force an UnLoad of the first module before I can load the second into memory.
ADDENDUM: I attempted to run the memory-swapping code in RS (using a virtual robot built from a backup of the real robot), and the UnLoad command just triggers the ERROR trap immediately. It doesn't seem to actually remove Module 1 from memory at all -- even after running the UnLoad command, I still can't create Module 2 with all the duplicate PROCs and RobTargets without throwing a mass of "ambiguous" errors.