CATIA CAA RADE Interview Questions with Answers

 

General Information

 

What is CATIA?

CATIA is a 3d CAD Solid modeling software.

 

What is full form of CAD?

Full form of CAD is Computer Aided Design.

 

Which company has developed CATIA?

Dassault Systemes of France has made the CATIA product.

 

What is full form of CAA?

Full form of CAA is Component Application Architecture.

 

What can we do using CAA?

You can write applications on top of CATIA, Enovia, Delmia.

Essentially you can customize CATIA using CAA.

 

What is full form of RADE?

Full form of RADE is Rapid Application Development Environment.

 

How is CATIA installed?

CATIA comes on CDs/DVDs. All you need to do is ensure that the requisite prerequisites are installed before installing CATIA. You should install CATIA from CDs.

 

Where can I get the CD’s of CATIA?

  1. Check with your manager.
  2. Check with your Infosystems Team.
  3. Check in the Library for the CD installation.

Visual C++ Integrated Development Environment


You should know about the popular short cuts available in the Visual C++ IDE?

In VC++, you should know about Ctrl+a –> This is to select all.

In VC++, Alt+F8 – Will indent the code.

 

Where can I get all the Keyboard short cuts?

All the keyboard short cuts for Visual C++ are available from Help à Keyboard Map.

 

Which is a whitespace character?

Space/Blank

Tab

These are termed as whitespace characters

 

How to see the whitespace characters in Visual C++?

There is the command

Edit –> Advanced –> View Whitespaces

This is on Visual Studio 6.0

 

What is the short-cut key to View whitespace characters?

Ctrl+Shift+8

This is on Visual Studio 6.0

 

What is the newline character?

The newline character is

CR + LF on Windows

LF on Unix

CR -> Carriage Return (This comes from the type writer days)

LF -> Line Feed

 

What are the hexadecimal values of CR and LF?

CR – 0x0d

LF – 0x0a

 

How does the newline matter during the development of CAA?

If a text file is created on Unix, the new line character is just LF. Hence when you open it up on Windows, you will not see a new line. The text file would appear a single big line. The solution is to open it up in an editor, which automatically converts the LF character assuming it to be new line, and appropriately adds CR in front of LF character.

 

Version / Release Naming / Numbering


What do CATIA V5R15 mean?

V5 – stands for Version 5.

R15 – stands for Release 15.

 

What does CATIA V5R15 SP2 mean?

This means for Version 5, Release 15, the Service Pack 2.

 

In general how are the CATIA versions described?

CATIA V5Rn SPm

Where n is 1 … m is 1 onwards.

 

What is a Hot Fix?

Hot Fix is a special version, which DS gives to some of its customers.

So we can say that this is over and above the regular releases and service packs.

 

Do the fixes which have happened in Hot Fix come into regular releases?

Yes. This does happen. Normally the Hot Fixes come back in some future service packs.

 

How can I find which version of CATIA am I running?

When you are running CATIA, you can find it out from the Help –> About dialog box.

 

Licensing

Do I need some license to run CATIA?

Yes. To start / run CATIA, you need a license. If you or your team does not have the license, then CATIA won’t start. You need to get the CATIA licenses.

 

What is LUM?

LUM stands for License Use Management.

This is the licensing software which is developed by IBM. CATIA internally

uses the LUM for its licensing purpose.

 

Where can I get more information about LUM?

You can get more information on LUM by going to the IBM’s website.

http://www.ibm.com/…/lum

 

What are the two basic forms in which Licenses are available?

The two basic forms in which the Licenses are available are:

  1. Node Locked
  2. Floating License Server based.

 

What are the configurations in which CATIA comes?

CATIA comes in P1, P2, P3 configurations.

P1 is the base configuration.

P2 is the next higher configuration

P3 is the next higher configuration.

 

What does a configuration represent?

A configuration represents a collection of products, and the level of those

products. i.e. what level of functionality is exposed.

 

Build Tools

 

What are the typical command line arguments to be given to perform the build?

tck_init

tck_list

tck_profile

mkGetPreq

mkmk

mkrtv

mkrun

Also, you can use mkRemoveDo -a to remove all the intermediate objects.

 

What is full form of TCK?

TCK is Tool Configuration Key.

 

What does the tck_init command do?

tck_init command does the tools initialization.

 

In which directory is the tck_init command file located?

The tck_init command is located in the following directory.

<ToolInstallPath>\intel_a\code\command\tck_init.bat

 

What does the tck_list command do?

tck_list command lists all the currently available profiles.

We should use the tck_profile command to select one of the profiles.

 

What does the tck_profile command do?

You select one of the profile using the tck_profile. To have a look at the various profiles available, run the tck_list command.

 

What is another name for the command mkCreateRuntimeView?

mkrtv

 

What is the purpose of mkrtv command?

Mkrtv copies files from Build Time View to Run Time View.

It copies the files from the CNext folder from Build Time View to Run Time View.

 

What are the basics of each tool/command which we should know?

Each tool/command which gets executed will be in some file.

These files are text or binary files.

These files are in some particular directory.

Each tool takes / accepts command line arguments.

The command line arguments are command line options, command switches.

Each command typically writes to some log files.

Each command typically accepts Environment variables.

Where to find the commands documentation.

 

Find out in which directory is the file mkmk?

Under module directory

 

Is mkmk a Batch file, or an Executable?

mkmk is a text file

 

What does the –a option of mkmk do?

The –a command line option builds all.

If the command is given/executed from a Workspace directory, it will build all the frameworks in that workspace. This in turn would build all the modules in each of these frameworks.

If the command is given/executed from a Framework directory, it will build all the modules of that framework.

 

What does the –bsc option of mkmk do?

-bsc option is applicable on Windows platform, when compiling the files with Microsoft Visual C++ compiler.

-bsc generates the Browser File. Browser files have extension .bsc

 

Environment Variables

 

What is CNEXTOUTPUT?

CNEXTOUTPUT is an environment variable. This environment variable should be set to the value “console”.

i.e.

CNEXTOUTPUT=console


This will ensure that the intermediate output from your application, especially the one coming out of cout, goes to console.

CNEXTOUTPUT=console

should be set by the Developers, when they are developing an application using CAA. This is really useful during the debugging of your CAA application.

 

Environment Editor

  1. There are two types of environment.
  2. Global and User environment.
  3. There are separate directories Global environment and User environment.
  4. The environment variables have the name = value format.
  5. The environment variables have the extension .txt file format.
  6. CATIA à Tools à Environment Editor is how you would start CATIA’s Environment Editor.
  7. CATDefaultEnvironment=EnvName . This Runtime environment variable is checked to use which CATIA Environment file.

Object Modeler – Component, Interface, Extension

 

How to get the interface pointer to a component instance?

To get the interface pointer to a component instance:

You can call the factory to create a component instance. Factory would usually return the interface pointer.

Factory –> Create Component Instance

If you have one interface pointer, to get to another interface pointer, you need to do QueryInterface.

QueryInterface

You call some function on a interface, which will return another interface pointer of appropriate type.

SomeFunction( Interface *&ptr);

 

How do you delete a component instance?

You call the Release on the interface pointers which are held. When the reference count on the component instance reaches zero, the component instance will destroy itself.

 

What are the two types of extension?

There is Code Extension and Data Extension

 

Where do you specify that a particular extension is a Code Extension and Data Extension?

CATImplementClass macro. The 2nd argument of CATImplementClass macro specifies whether it’s a code extension on data extension or implementation class.

 

When does the Extension object get created?

  1. The extension object gets created on the first call of any interface that it supports.
  2. There is no separate factory for the Extension classes.

 

What are the three functions in IUnknown?
The three functions in IUnknown are:
QueryInterface, AddRef, Release

 

HRESULT QueryInterface( IID &iid, void ** ppi);
ULONG AddRef();
ULONG Release();

 

Common Errors / Mistakes and How to Fix them / recover from them.

 

What are the error categories?

  1. Preprocessor Errors
  2. Compilation Errors
  3. Linking Errors
  4. Loading Errors
  5. Run-time Errors

 

Which are the most common errors?

The most common errors for starters is Compilation Errors and Linking Errors.

 

What are the common mistakes pertaining to Imakefile?

In Imakefile, the \ has to be the last character on that line. If you have any other character after the \ character, you will get errors. Also it is difficult to find out the errors in such cases.

Hence you should View Whitespace characters.

 

What are the two broad types of errors you would encounter?

  1. Compilation/Linking errors
  2. mkmk-ERROR

 

How to find out the errors after running the mkmk command, i.e. the build command?

Press F4.
To find out the first set of errors you should press F4. This will take you to the first error.

 

When nothing seems to be working what are the things to do?

  1. Ensure that Imakefile.mk and IdentityCard.h are correctly written.
  2. Use mkRemoveDo –a to perform a clean build. Perform a clean build.
  3. Environment Variables.
    Check that CATDefaultEnvironment variable is not null. i.e. it should have some value. If the CATDefaultEnvironment variable is empty, i.e. blank, then you need to exit Visual Studio, and remove the ToolsData folder.
  4. Check if there is $(VARIOUS_…) directory created somewhere. Delete these $(VARIOUS_…) directories.
  5. Exit Visual Studio. Kill all the msdev processes and start a fresh msdev.
  6. Delete ToolsData folder and try again. ToolsData folder is in the workspace directory.
  7. Logout from the system and login the system and try again.
  8. Reboot the system and try again.

Tools Data Folder

 

What is the contents of the ToolsData folder?

The files get created in the ToolsData folder are usually, the Visual C++ project files.

For e.g.:

.dsp – DSP files – Developer Studio Project files.

.dsw – DSW files – Developer Studio Workspace files.

For Visual Studio .Net 2002/2003, the files which are kept are Solution Workspaces .sln???

 

Where is the ToolsData folder created?

The ToolsData folder is created under the Workspace directory.

 

Who creates the ToolsData folder?

The ToolsData folder is created by the CAA Wizard.

 

What should we do in case we want to find some solution?

  1. Find out for information in MSDN – Microsoft Developer Network.
  2. Find out for information in CAA Encyclopedia.

 

What does __declspec(dllexport) and __declspec(dllimport) does?

__declspec is for Declaration Specifier. This is Microsoft Visual C++ specific.

 

__declspec(dllexport) is used when we want a symbol to be exported from a DLL. i.e. we want some other DLL or EXE wants to use this symbol.

 

__declspec(dllimport) is used when we want a symbol to be imported in a DLL or EXE, where originally that symbol is exported from some other DLL.

 

What is the purpose of extern “C” in C++?
In C++, the names/identifiers are mangled. To avoid name mangling of a C++ name/identifier, we have to provide extern “C”.

 

What are precompiled header files?

On MSVC platform, this is one way to reduce the compile time.

 

What are the equivalent of Dll’s called on Unix platform?

Shared Library

 

CAA Encyclopedia

 

What is the path of starting CAA Encyclopedia?

<CAA API Install Path>\CAADoc\Doc\online\CAACenV5Default.htm


What are the three common things to be looked for when you add/use an identifier (i.e. macro, functions, classes)?

Once you add/use an identifier (i.e. macro, functions, classes):

You should include the appropriate

– header file.

– framework in IdentityCard.h

– module / library in Imakefile.mk

 

Where are the workspace dependencies specified?

Using mkGetPreq command or using mkCopyPreq command.

 

Where are the framework dependencies specified?

– Framework dependencies are specified in IdentityCard.h

 

Where are the module dependencies specified?

– Module dependencies are specified in Imakefile.mk

 

TIE

Tie is an object at run-time.

Tie objects are instances of Tie class.

Tie objects are created when the QueryInterface is called.

Tie objects are deleted when we perform Release on the interface pointers, and that the tie objects reference count becomes zero.

Tie objects have an internal reference counting mechanism.

 

Tie object connects interface to implemention.

Interface pointers are actually address of tie objects.

 

There are two types of tie: Standard Tie, and Chain Tie.

 

One component can have two interfaces. One interface I1 can connect with the component C1, through standard tie. Another interface I2 can connect with the component C1, through chain tie.

 

The Standard Tie creates a tie object every time

For every interface which is created, it should have a TIE source file. The name of the TIE source file is the same as the Interface file, suffixed with .tsrc.

 

TIE source files have extension .tsrc.

 

For e.g. if the interface is IPoint, then the corresponding interface header file will be IPoint.h, and the tie source file will be IPoint.tsrc.

 

For interface ILine, header file is ILine.h, and tie source file is ILine.tsrc.

 

The contents of the TIE source file, is a plain and simple, inclusion of the header file.

 

So IPoint.tsrc, will have

#include “IPoint.h”

 

For ILine.tsrc, we will have

#include “ILine.h”

 

The tie source file is input to the mkmk. Mkmk uses the tie source file as input, and the output is the TIE header file.

 

For IPoint.h, the TIE header file is TIE_IPoint.h

For ILine.h, the TIE header file is TIE_ILine.h

 

Note that the tie source are text files.

 

What are the restrictions on Chain TIE?

Chain TIE can not be used with Code Extensions.

 

Can we have multiple pointers pointing to the same object?

Yes.

 

Following code shows multiple pointers pointing to the same object.

int main()

{

int i = 0;

int *pi = &i;

int *pj = &i;

 

return 0;

}

In the above code, pointer pi and pj are pointing to the same integer.

 

How will you create an variable of type HRESULT?

HRESULT rc = E_FAIL;

Or

HRESULT rc = S_OK;

 

What are the typical variable names given when we want a variable of type HRESULT?

HRESULT rc = E_FAIL;

HRESULT res = E_FAIL;

HRESULT hres = E_FAIL;

rc is short form for return code.

res is short form for result.

hres is short form for hresult.

 

What is the typical value with which you will initialize HRESULT?

E_FAIL.

e.g.

HRESULT rc = E_FAIL;

 

What are the macros used to check the HRESULT values?

Use FAILED and/or SUCCEEDED macros to check the HRESULT value.

Usage sample:

HRESULT rc = E_FAIL;

// … rc

if( FAILED( rc ) ) {

// on failure …
}

// … rc

if( SUCCEEDED( rc ) ) {
// on success
}

 

What are the three properties of Interfaces?

The three basic properties of interfaces are:

Reflexive property

Symmetry property

Transitive property

Reflexive property: Given an interface pointer, we can query back another interface pointer of the same type.

Symmetry property: If we can get interface point of type IB from IA, then we can get back IA from IB.

Transitive property: If we can get interface IA from IB, and IB from IC, then we can get IA from IC.

 

What is the problem you foresee, when you just copy interface pointers?

I1 *pi1 = NULL;

I2 *pi2 = NULL;

// get proper value of pi1.

pi2 = pi1;

In this case, we have pointer 1 copied to pointer 2.

Note that in such a case, they are both pointing to the same tie object. We haven’t done AddRef on this. Hence we should do AddRef. Once AddRef is done, we can use Release to release the pointer.

 

Small Exercise:

  1. Find out include file, framework, and module to link with for the following:

CATBaseUnknown

CATMathPoint

CATAngle
This exercise is aimed at finding information from the CAA encyclopedia.

Explore:

  • Can we create an instance of CATBaseUnknown?

Standard Tie

int f()

{

I* pi11 = NULL;

GetInterfaceFromFactory( &pi11);

return 0;

}

Another Example:

int f()

{

I* pi11 = NULL;

I* pi12 = NULL;
HRESULT rc = E_FAIL;

GetInterfaceFromFactory( &pi11);

pi11->QueryInterface( IID_I1, (void **) & pi12);

return 0;

}

 

Mkmk Commands

mkmk

The mkmk command is used to build the applications.

mkmk –a –u –ge –bsc
-a = build all
-u = update mkm internal files
-g = debug build
-ge = debug – edit and continue
-bsc = generate browse information

To generate preprocessed output on Windows platform, the VC++ compiler takes the command line arguments /P /EP.
To provide this we can use LOCAL_CCFLAGS in the Imakefile.mk

LOCAL_CCFLAGS = /P /EP

This will generate the .i file from .cpp file.
Thus if you file name is CPoint.cpp, it will generate CPoint.i

Caution: Note that when you generate the preprocessed output, the object files don’t get made, and hence linking errors come.

mkGetPreq

The mkGetPreq command is to provide workspace prerequisites.

mkGetPreq –p WorkspacePrerequisitePath

e.g.
mkGetPreq –p D:\DS\B15

 

mkRemoveDo

mkRemoveDo is a command available in CAA. The documentation of this command is available in CAA encyclopedia in mkmk section.

When we do the build, we find that there are lot of intermediate files which get created. For e.g., the .obj files, these are intermediate files.

You can perform the mkRemoveDo -a. This would delete all the intermediate files.

 

How to use mkRemoveDo?

Just give the command

mkRemoveDo –a

to remove all the intermediate files.

Why do we need mkRemoveDo?

You need this because at times you want to do a Clean Build. By clean build, we mean that there are no intermediate files.

When should we use mkRemoveDo?

Whenever you want to perform a clean build, you use the command mkRemoveDo.

What are the consequences of doing mkRemoveDo?

Once you do mkRemoveDo, the intermediate files are deleted/removed. Your subsequent build will rebuild all the files which were deleted. As a consequence, all the files will get compiled/rebuild. Hence subsequent to mkRemoveDo, the build might take long.

Where can we get more help on mkRemoveDo?

mkRemoveDo is a command available in CAA. The documentation of this command is available in CAA encyclopedia in mkmk section.

 

CAA V5 Directory Structure

Draw and explain the CAA V5 Directory Structure?

Workspace

Framework

IdentityCard

IdentityCard.h

PublicInterfaces

.h

ProtectedInterfaces

.h

PrivateInterfaces

.h

module1.m

Imakefile.mk

src

.cpp

LocalInterfaces

.h

nod2.mj
mod3.mext

mod4.mjext

CNext

code

dictionary

*.dico

*.dic

resources

graphic

*.CATfct

 

What are the various files which can be found in a CAA V5 directory structure?

.cpp – C++ source files.

.h – C/C++ header files.

Imakefile.mk – Imakefile file

IdentityCard.h – IdentityCard file

.dsp – Developer studio project files

.dsw – Developer studio workspace files

.obj – Object files

.dll – Dynamic Linked Libraries

.nls – CATNLS file – NLS stands for National Language Support files.

 

Trigram

 

What is a trigram?

Trigram is a 3 letter code.

 

What is a bigram or digram?
Bigram or digram is a 2 letter code.

 

Where are trigrams used?

Products are given trigrams.

e.g CATIA has trigram CAT, ENOVIA has VPM and also ENOV, Delmia has DNB.

Certain tools also have a trigram.
mkmk tool has a trigram MAB. MAB is full form of Multi Workspace Application Builder.

 

In CAA development, where would the trigrams be useful?

When you are doing CAA development, you will be naming different things like Workspace, Framework, Modules, Classes, and so on.

In all such cases, you can use trigram as a prefix.

For more details, when to use the trigram, refer to the naming guidelines in CAA Encyclopedia.

 

From where do I get trigram?

You should contact DS to get a trigram for your company, or for your development project. Talk to your managers/seniors before getting the trigram.

 

What can should I take when I’m on a project?

When you are already on a CAA project, or are starting one, it would be good to get the trigram. This will help you determine the prefix to be used for your project.

 

 

Module Directory

Module directories are created inside every Framework directory.

Module can not have another sub-module directory inside it. i.e. there is no concept of sub-module directory.

Module directories typically have extension.

mod1.m is an example of a module directory.

The .m specifies that it will contain C/C++ code.

The .mj specifies that it will contain Java code.

 

What are module ext directories for?

The .mext specifies that it will contain code which you have received from external source, You typically use .mext to create a module for 3rd party library code. Lets say you are integrating some code from 3rd party. This you can keep in .mext.

The .mjext is similar to .mext, except that it contains Java code.

Module directories have LocalInterfaces and src directory under them.

 

Interfaces Directory


Which are the typical 4 directories where the interfaces are kept?

The interfaces directory are:

PublicInterfaces

ProtectedInterfaces

PrivateInterfaces

LocalInterfaces

 


In which directories do you find PublicInterfaces, ProtectedInterfaces, PrivateInterfaces and LocalInterfaces directories?

Every framework has PublicInterfaces, ProtectedInterfaces and PrivateInterfaces directory.

Every module has LocalInterfaces directory.


Which is the most restrictive and less restrictive of these 4 directories, i.e. PublicInterfaces, ProtectedInterfaces, PrivateInterfaces and LocalInterfaces?

The order starting from most restrictive to least restrictive is as follows:

LocalInterfaces

PrivateInterfaces

ProtectedInterfaces

PublicInterfaces

 

What is the order in which the header files from one directory can include the header files from other directory?

Principle: The header file in most restrictive interfaces directory can include files from less restrictive interfaces directory.

 

File in Can include files from

======================================================================

LocalInterfaces à PrivateInterfaces, ProtectedInterfaces, PublicInterfaces

PrivateInterfaces à ProtectedInterfaces, PublicInterfaces

ProtectedInterfaces à PublicInterfaces

PublicInterfaces à PublicInterfaces of same or other frameworks.

 

Can we include one header file from LocalInterfaces of one module, into a header file of another module?

No.

 

File Difference and Directory Difference

  1. WinDiff and other tools like Araxis Merge
  2. Use Windiff to find out the difference between directories, when we use CAA Wizard. This way we will come to know what are the files created by the CAA Wizard during one of the commands.

 

Dictionary File

 

The dictionary file keeps track of

Dictionary files are needed by the customer. Hence they have to be in the run time view. The files are copies from the build time view to run time view, i.e. mkrtv.

 

What is the extension of the dictionary files?

The dictionary files have extension .dico, or .dic.

 

What is the comment character in dictionary files?

The comment character is #

 

What is the format of the dictionary files?

The dictionary files have the following format:

Component-Name Interface-Name Library-Name

The library name does not have any extension, i.e. .dll or some such thing.

The library name has the prefix lib.

So if the library is mod1.dll, then it is entered as libmod1

 

How / where we can edit Dictionary files?

The dictionary files can be edited / modified in Notepad, or any other text editor available in Integrated Development Environment.

 

How are dictionary files used?

Given a component name, we can find out all the interfaces which are implemented by it.

Given an interface name, we can find out which call components implement it.

Given a library name, we can find out which all components are implemented in it.

Thus we can navigate between component name, interface name, and library name.

CAA V5 Object Browser uses the Dictionary files in finding the information the various interfaces implemented by a component.

 

What is the path of the dictionary files?

The dictionary files are kept in CNext folder.

CNext
\code
\dictionary

These dictionary files are copied from Build Time View to Run Time View, using mkrtv.

 

Keyboard Short Cuts

In Visual C++, go to Help -> About. Here you will find the keyboard shortcuts.

Ctrl+Shift+F – Find the path of the currently open active file.

 

Glossary

TCK – Tool configuration key

Mkmk – make make – Tool to build the application.

————————————————–
🌍 For PLM / CAD Training Visit

https://plmcoach.com

Follow PLM Coach on Social Media:

YouTube | LinkedIn | Facebook

Twitter | Pinterest

📧 Contact PLM Coach:

Follow the link to Training Inquiry Form to provide your details

https://plmcoach.com/inquiry

Follow the link to Text PLM Coach on WhatsApp

https://wa.me/917989703878

☏ Mobile Number ► +91-7989703878

💌 Email ► info@plmcoach.com

————————————————–