The ASSEMBLY sample program demonstrates how to construct an assembly between two products. An assembly relationship is constructed to relate the configuration management instances as well as the geometry. The program is broken down into functions which handle portions of the complete relationship. The input file for the program must contain at least two products with geometry.
- "assembly_in.stp" contains sample input for this program.
- "assembly_out_cdsr.stp" contains the sample output from this program with an assembly that uses context_dependent_shape_representation.
- "assembly_out_cdsr.stp" contains the sample output from this program with an assembly that uses mapped_item.
The program reads the "assembly_in.stp" data set and saves two different versions of it called "output_with_mapped_item.stp" and "output_with_cdsr.stp". STEP files are text, so you can look at them with a text editor or right-click "Browse" them with the STEP Part 21 file browser to see the contents.
In the list above, select your Visual Studio version or platform, then right click on the link to save the zipped project files to your local disk. Unpack the zipfile.
On Windows, open the enclosed project file with Visual Studio and compile the program by selecting "Build All". The project creates a Console application that you can run from the command line. When using the 64bit version of ST-Developer, change the platform from "win32" to "X64" in the Visual Studio Configuration Manager before building.
On MacOS, Linux, and other Unix systems, the project directory contains a makefile that builds the sample program. The makefile uses the ROSE, ROSE_INCLUDE, and ROSE_LIB environment variables described in the ST-Developer installation notes. Compile the program by typing "make".
The Windows projects also include a makefile that you can use by typing "nmake", but you must run vcvars32.bat (found in the Visual Studio C++ bin directory) to make sure that the C++ compiler is in the command line search path.