4.3 Configuration Data – BoltLengthCalculation.json
Configuration Data – BoltLengthCalculation.json
The bolt calculation engine derives its rules and parameters from the BoltLengthCalculation.json file, which is located in the Resources folder of the add-in. This file controls the logic by which bolt lengths and quantities are precisely determined in AutoCAD Plant 3D.
For user-friendly maintenance of this data, the "Load Data" command is available. This allows the import of an Excel workbook (.xlsx) in which the individual configuration sections are prepared as tabs. This allows users to edit values in a familiar spreadsheet environment before they are converted into the internal system JSON format.
Step-by-Step: Understanding the Configuration Sections
The bolt calculation control is divided into various logical tables. The following sections explain the individual parts and their significance for the calculation process.
Step 1: Configuration of the Calculation Logic ("Formula" Section)
This section defines the basic calculation logic based on the connection type. Standard end codes are FL (Flange), WF (Wafer), and LUG (Lug-type valve). Project-specific end codes can be added at any time.
Note on multiplier columns: The columns VALVE, STUBEND, FLANGE, NUT, WASHER, and ADDITIONAL control how frequently the respective contribution is included per connection. A value of 0 disables the contribution, while 1 or higher causes a corresponding multiplication.
Behavior for missing components: If a component referenced in the formula is missing at a connection (e.g., no STUBEND present), the contribution is ignored in the sum without a system error being issued.
| Column | Description |
|---|---|
| DN | Nominal diameter of the bolt set (numeric, in mm). |
| ENDTYPE | Connection type (e.g., FL for flange, WF for wafer). |
| STANDARD | Filter for the design standard (e.g., API 600). If empty, the rule applies universally. |
| WAFERTYPE | Set to TRUE for wafer connections (through-bolts) that span flanges and valve bodies. |
| THREAD_DEEP | Additional thread engagement depth in mm. |
| QUANTITY | Number of bolts in the set. Updates the NumberInSet property. |
| VALVE | Multiplier for the flange thickness of the connected valve. |
| STUBEND | Multiplier for the flange offset of the connected stub end. |
| FLANGE | Multiplier for the thickness of the connected flange. |
| NUT | Number of nuts. Multiplies the thickness from the "Nut" table. |
| WASHER | Number of washers. Multiplies the thickness from the "Washer" table. |
| ADDITIONAL | Multiplier for additional length elements from the "AdditionalLength" table. |
| ROUND | Rounding direction: UP (to next standard length) or DOWN (to previous standard length). |
| SIZE_DESCRIPTION | Template for PartSizeLongDesc. Placeholders: &&& (Size), @@@ (Length). |
| FAMILY_DESCRIPTION | Template for PartFamilyLongDesc. Same placeholders as above. |
Step 2: Definition of Nut Thicknesses ("Nut" Section)
In this area, the thicknesses of the nuts used are stored depending on the bolt size and the corresponding standard.
| Column | Description |
|---|---|
| Size | Bolt size designation (e.g., M16, M20). |
| L | Thickness of the nut in millimeters. |
| Standard | Associated bolt standard (match with the BoltCompatibleStd property). |
Step 3: Definition of Washers ("Washer" Section)
Here you define the thicknesses of the washers per bolt size and standard to ensure correct length addition.
| Column | Description |
|---|---|
| Size | Bolt size designation. |
| L | Thickness of the washer in millimeters. |
| Standard | Associated bolt standard. |
Step 4: Configure Add-on Lengths ("AdditionalLength" Section)
This section allows for the definition of an additional length contribution, which can be used, for example, for gasket seating clearance or project-specific safety margins.
| Column | Description |
|---|---|
| Size | Bolt size designation. |
| L | Additional length in millimeters. |
| Standard | Bolt standard for which this contribution applies. |
Step 5: Set Standard Lengths for Rounding ("RoundLength" Section)
In order for the calculated theoretical length to be mapped to real components, the standard lengths available on the market are stored here.
| Column | Description |
|---|---|
| Size | Bolt size designation. |
| L | A valid bolt length available on the market in millimeters. |
Multiple entries are expected per size (one entry per available length). The system automatically sorts these in ascending order and selects the appropriate value based on the configured rounding direction.
Step 6: Management of External Component Data ("ExternalData" Section)
This section serves as a fallback solution for component data if it is not directly available in the Plant 3D model or catalog (e.g., due to missing flange thickness entries).
As soon as the data source "From external data" is selected in the settings, the program compares the component properties with this table. If a match is found, the values defined here are used with priority.
| Column | Description |
|---|---|
| Property Name | Name of the Plant 3D property for identification (e.g., PartFamilyLongDesc). |
| Value | The specific value of the property on the corresponding component. |
| FlangeThickness | The flange thickness in mm to be used for the calculation. |
| Length | The component length in mm (particularly relevant for wafer components). |