Difference between revisions of "Studio:How can I tell which version of a workspace is used when connected to the target at runtime?"
Line 4: | Line 4: | ||
− | [[Category: | + | [[Category:Application Notes]] |
− |
Revision as of 17:37, 4 February 2008
When working with multiple targets, you may want to determine which version of a workspace is being used at runtime. To determine the target to which you are connected, add a helper function to the Intercept Module which can return something from the target (e.g., a string whose value is a target compile-time setting) that will tell the script the kind of target to which it is connected.
You can also add a preprocessor define with a version number as part of the workspace build (not the target build). The define is not used for compilation. A script will check which preprocessor define is set and act accordingly.