The Pocket Calculator  

The scenario developed below is intended to show how to combine part design and shape design features to generate a simple pocket calculator. It comprises the steps and instructions required for each step.
To perform the scenario below, you need to have on hand the basic sketches from which you create your mechanical features. These basic sketches are available in the PktInitialSketch.CATPart sample. The shape design features are created from scratch.
To perform the scenario below, we use the PktInitialSketch.CATPart sample (~46KB) along with the PktPocketCalculator.CATGScript script (~8KB). Check the size of the resulting document. It must be around 250KB.
  1. Select Knowledgeware > Product Knowledge Template from the Start menu.

  2. Click the icon. The Knowledgeware Script Editor is displayed.

  3. Use the File > Open command to open the PktPocketCalculator.CATGScript document.

  4. Position the cursor after the import keyword and right-click to select Insert File Path. Navigate to the PktInitialSketch.CATPart sample, then click Generate. The document generation starts.

    This is what you get onscreen, once the generation process is over.

Back to the script:

  • The import statement below displays an input box whereby you can specify a sketch file. The pads created in the script all rely on these sketches.
import Input:FilePath "Select the PktInitialSketch.CATPart sample";


  • The script is divided into two sections:

a ) The part design features are enclosed by the BodyFeature
b )  The shape design features are enclosed by  the OpenBodyFeature.

calc isa CATPart
part1 isa Part
partbody isa BodyFeature
// your mechanical features are described here

OBody isa OpenBodyFeature
// your shape design features are described here


The fillet and pattern type features cannot be generated in one shot. You must first of all create the pad0 and pad1 objects, then add to your script the statements necessary to generate fillets and patterns. See the  Fillet Object.