Compilation procedure
The procedure that initiates a Build or Rebuild on a TwinCAT C++ project in the TwinCAT Engineering XAE is described here. This is to be taken into account, for example, if company-specific environments and building processes are to be integrated.
The configurations that are built in the case of a Build or Rebuild depend on the current selection in Visual Studio:
The correct target architecture (in this case TwinCAT RT (x64)) is set appropriately by selecting the target system.
The Configuration Manager allows the dedicated setting of the build configuration.
When selecting Build or Rebuild (and thus also Activate Configuration), the following steps are performed:
- The sources are located in the respective project directory.
- The compilations are generated according to the specific architecture in C:\TwinCAT\3.1\sdk\_products\
e.g. in C:\TwinCAT\3.1\sdk\_products\TwinCAT RT (x64)\Debug\<ProjectName> - The link process then places the .sys/.pdb file also architecture-specific in C:\TwinCAT\3.1\sdk\_products\.
e.g. in C:\TwinCAT\3.1\sdk\_products\TwinCAT RT (x64)\Debug\ - A copy of the .sys/.pdb is placed in the _Deployment/ subdirectory of the project directory, e.g. in Project Directory/_Deployment/TwinCAT RT (x64)\
- Pressing the Activate Configuration button leads to .sys/.pdb being transferred from _Deployment/ of the project directory to the target system (if applicable it is a local copy).