Whats New in UPG 2

Download as pdf or txt
Download as pdf or txt
You are on page 1of 60

What’s New in UPG-2 for CAMWorks

WHAT’S NEW IN
UNIVERSAL
POST
PROCESSOR
FOR

Geometric Americas Inc. is a fully owned subsidiary of HCLTech (HCL Technologies Ltd.).
Geometric Americas Inc. makes no warranties, either expressed or implied with respect to this
document. Geometric reserves the right to revise and improve products as it sees fit, and to revise
the specifications and information contained herein without prior notice. Due to continuing product
development, specifications and capabilities described in this document are subject to change
without notice.

Copyright © 2022-2023 Geometric Americas Inc. All Rights Reserved.


March 2023
Table of Contents

Table of Contents
(Click a link below or use the bookmarks on the left.)

About UPG-2 (Enhanced UPG App) 7


What’s New in UPG-2 for CAMWorks 2023 SP0 8
HEADER COMMANDS .............................................................................................. 8
1. :POST_SUPPORTS_EULER_ANGLES 8
2. :POST_SUPPORTS_EULER_TNDC 8
SYSTEM VARIABLES ............................................................................................... 8
1. EULER_TYPE 8
2. EULER_FIRST_ROT 8
3. EULER_SECOND_ROT 9
4. EULER_THIRD_ROT 9
5. OVERRIDING_EULER_ANGLES 9
6. PROBE_MEASURE_TYPE 9
7. N_PROBE_MEASURE_TYPE 9
8. P_PROBE_MEASURE_TYPE 10
9. PROBE_CYCLE_X_TYPE 10
10. P_PROBE_CYCLE_X_TYPE 10
11. N_PROBE_CYCLE_X_TYPE 10
12. PROBE_CYCLE_Y_TYPE 10
13. P_PROBE_CYCLE_Y_TYPE 10
14. N_PROBE_CYCLE_Y_TYPE 10
15. PROBE_CYCLE_Z_TYPE 10
16. P_PROBE_CYCLE_Z_TYPE 11
17. N_PROBE_CYCLE_Z_TYPE 11
18. PROBE_UNPROTECTED_Z_DOWN 11
19. PROBE_UNPROTECTED_Z_UP 11
20. PROBE_PNT_X1 11
21. PROBE_PNT_Y1 11
22. PROBE_PNT_Z1 11
23. PROBE_PNT_X2 11
24. PROBE_PNT_Y2 12
25. PROBE_PNT_Z2 12
26. PROBE_PNT_X3 12
27. PROBE_PNT_Y3 12
28. PROBE_PNT_Z3 12
29. PROBE_REF_NORM_X 12
30. PROBE_REF_NORM_Y 12
31. PROBE_REF_NORM_Z 12
32. PROBE_START_ANGLE 13
33. PROBE_STEPPING_ANGLE 13
34. PROBE_STOP_IF_TOL_EXCEEDED 13
35. PROBE_CLEARANCE 13
36. PROBE_LIB_TYPE 13
37. CURR_FILE_NUM 13
SYSTEM COMMANDS ............................................................................................ 14
1. GET_EULER_ANGLES 14
QUERY COMMANDS .............................................................................................. 14
1. QUERY_INT_5AXIS_KEEP_INITIAL_ORIENTATION 14
2. QUERY_POST_SUPPORTS_EULER_ANGLES 15
3. QUERY_POST_SUPPORTS_EULER_TNDC 15

2
Table of Contents

4. QUERY_MACRO_ROTATE_Z 15
SYSTEM CONSTANTS ........................................................................................... 16
What’s New in UPG-2 for CAMWorks 2022 SP1 17
HEADER COMMANDS ............................................................................................ 17
1. : SET_FIRST_Z_POS_ON_MILL_TC 17
QUERY COMMANDS .............................................................................................. 17
1. QUERY_MILL_FEATURE_NAME 17
What’s New in UPG-2 for CAMWorks 2022 18
POST HEADER COMMANDS ................................................................................. 18
1. :POST_FROM_PART_SETUP_ORIGIN_WHEN_USING_PART_REF_POINT=TRUE or FALSE 18
2. :USE_COMBINATION_ID_AS_NAME_WHEN_AVAILABLE = TRUE OR FALSE 18
SYSTEM VARIABLES ............................................................................................. 18
1. TOOL_PROFILE_RADIUS 18
2. N_TOOL_PROFILE_RADIUS 18
3. TOOL_CONVEX_RADIUS 18
4. N_TOOL_CONVEX_RADIUS 19
5. NC_TOOL_CONVEX_RADIUS 19
6. NC_TOOL_PROFILE_RADIUS 19
7. TOOL_Z_CENTER 19
8. N_Z_CENTER 19
9. NC_Z_CENTER 19
10. HOST_SYSTEM 19
11. RUNNING_SYSTEM 19
12. CANNED_CYCLE_FIRST_CUT 20
13. CANNED_CYCLE_FINAL_CUT 20
14. STOCK_TYPE 20
SYSTEM CONSTANTS ........................................................................................... 21
What’s New in UPG-2 for CAMWorks 2021 PLUS 22
QUERY COMMAND ................................................................................................ 22
1. QUERY_FEATURE_NAME 22
POST VARIABLES .................................................................................................. 23
1. :OPR_FROM_PART_SETUP_ORIGIN 23
2. :NEXT_OPR_FROM_PART_SETUP_ORIGIN 23
MAX STRING LENGTH FOR SYSTEM POST CHARACTER VARIABLES .......... 24
What’s New in UPG-2 for CAMWorks 2021 SP1 25
QUERY COMMANDS .............................................................................................. 25
1. QUERY_ARC_OVERRIDE_FEEDRATE 25
2. QUERY_CORNER_SLOWDOWN_FEEDRATE 25
What’s New in UPG-2 for CAMWorks 2021 SP0 26
Post Variables ......................................................................................................... 26
1. NEXT_NON_POSTOP_SYSTEM 26
2. TOOL_SHOULDER_LENGTH 26
3. TAB 26
4. MCS_OFFSET_TYPE 26
5. WORLD_WCS_TO_SETUP_OFFSET_X 26
6. WORLD_WCS_TO_SETUP_ OFFSET_Y 27
7. WORLD_WCS_TO_SETUP_ OFFSET_Z 27
8. WCS_TO_SETUP_SCS_OFFSET_X 27
9. WCS_TO_SETUP_SCS_OFFSET_Y 27
10. WCS_TO_SETUP_SCS_OFFSET_Z 27
3
Table of Contents

11. MCS_X_WORK_OFFSET ; N_MCS_X_WORK_OFFSET ; P_MCS_X_WORK_OFFSET 27


12. MCS_Y_WORK_OFFSET ; N_MCS_Y_WORK_OFFSET ; P_MCS_Y_WORK_OFFSET 27
13. MCS_Z_WORK_OFFSET ; N_MCS_Z_WORK_OFFSET ; P_MCS_Z_WORK_OFFSET 28
14. MACRO_4TH_AXIS_OFFSET_ANGLE 28
15. MACRO_5TH_AXIS_OFFSET_ANGLE 28
16. MACRO_U; MACRO_V; MACRO_W 28
17. MACRO_X; MACRO_Y; MACRO_Z 28
System Header Commands ................................................................................... 29
1. OUTPUT_5AXIS_TOOLPATHS_FROM_SETUP_WCS 29
CALC SECTION ...................................................................................................... 29
1. CALC_CLEANUP_AFTER_POSTING 29
QUERY COMMANDS .............................................................................................. 29
1. QUERY_TOOL_ASSEMBLY_COMMENT 29
2. QUERY_TOOL_ASSEMBLY_DESCRIPTION 30
System Constants .................................................................................................. 30
Support for Probing Cycles in Mill-Turn Post Source Files ............................... 30
1. Add Probing Header Command in Header section of Post 30
2. Add New Library Command Line in Mill-Turn Post Source Files 30
3. Add New Attribute Names 31
4. Adding Probe CALC Section in Post Library 31
5. Adding Probe Template Section in Mill-Turn Post Source 32
What’s New in UPG-2 for CAMWorks 2020 SP3 34
System Constant ‘CAM_REV2020_SP3’ .............................................................. 34
Parameters added to System Command ‘TRANSFORM’ ................................... 34
What’s New in UPG-2 for CAMWorks 2020 SP2 36
Post Variable ........................................................................................................... 36
1. WRAPPED_AXIS 36
2. Adding Wrapped Cylindrical to Mill Posts 36
What’s New in UPG-2 for CAMWorks 2020 SP1 39
System Variables .................................................................................................... 39
1. MACH_IS_4TH_AXIS_REV_DIR 39
2. MACH_IS_5TH_AXIS_REV_DIR 39
What’s New in UPG-2 for CAMWorks 2020 SP0 40
System Header Commands ................................................................................... 40
1. :ALLOW_PROBING 40
System Variables for Probing Cycles .................................................................. 40
2. PROBE_A_1ST_ANGLE 40
3. PROBE_B_2ND_ANGLE_OR_TOL 40
4. PROBE_C_3RD_ANGLE 40
5. PROBE_D_NOMINAL_SIZE 40
6. PROBE_E_EXPERIENCE_VALUE 40
7. PROBE_F_PERCENT_FEEDBACK 41
8. PROBE_H_TOL_VALUE 41
9. PROBE_I_CYCLE_SPEC_DIST_X 41
10. PROBE_J_CYCLE_SPEC_DIST_Y 41
11. PROBE_K_CYCLE_SPEC_DIST_Z 41
12. PROBE_M_POS_TOL 41
13. PROBE_Q_OVERTRAVEL_DIST 41
14. PROBE_R_CLEARANCE 41
15. PROBE_T_TOOL_OFFSET_NUMBER 42
16. PROBE_U_UPPER_TOL_LIMIT 42
4
Table of Contents

17. PROBE_V_NULL_BAND 42
18. PROBE_W_PRINT_DATA 42
19. PROBE_X_POS_OR_SIZE_X 42
20. PROBE_Y_POS_OR_SIZE_Y 42
21. PROBE_Z_POS_OR_SIZE_Z 42
22. PROBE_CYCLE_FEEDRATE 42
23. PROBE_WORK_SUB_OFFSET_NUM 43
24. PROBE_WORK_OFFSET_NUM 43
25. PROBE_UPDATE_WCS_OFFSET 43
26. PROBE_FIXTURE_OFFSET_NUM 43
27. PROBE_UPDATE_OFFSET_TYPE 43
28. HAVE_PROBE_CYCLE 43
29. PROBE_CYCLE_TYPE 44
System Variables .................................................................................................... 44
1. OPR_IS_PRIMARY 44
2. CL_COMMENT 44
3. CL_COMMAND 44
4. IS_SUB_SPINDLE_REVERSE_Z 45
5. MACH_NUMBER_AXIS 45
6. MACH_ROTARY_4AXIS_TYPE 45
7. MACH_ROTARY_5AXIS_TYPE 45
8. MACH_ROTARY_VEC_4X 45
9. MACH_ROTARY_VEC_4Y 45
10. MACH_ROTARY_VEC_4Z 46
11. MACH_ROTARY_VEC_5X 46
12. MACH_ROTARY_VEC_5Y 46
13. MACH_ROTARY_VEC_5Z 46
System Commands ................................................................................................ 46
1. GET_SW_CUSTOM_PROP_BY_NAME 46
2. GET_SW_SUMMARY_INFO_BY_ID 47
CALC Sections for Probe Cycles .......................................................................... 47
CALC Sections for Mill ........................................................................................... 47
CALC Sections for SOLIDWORKS ........................................................................ 48
1. CALC_GET_SW_PROPERTIES 48
2. CALC_GET_SW_SUMMARY_FIELDS 48
3. CALC_GET_SW_CUSTOM_FIELDS 49
4. CALC_OUTPUT_SW_PROPERTY 49
Attribute Commands .............................................................................................. 49
1. QUERY_SW_FIELD_NAME 49
2. QUERY_SW_FIELD_VAL 50
3. QUERY_SW_FIELD_TYPE 50
System Constants .................................................................................................. 50
System Constants for SOLIDWORKS .................................................................. 51
Additional System Constants ............................................................................... 51
Query Commands .................................................................................................. 52
1. QUERY_TOOL_ID_COMMENT 52
2. QUERY_TOOL_VENDOR_COMMENT 52
3. QUERY_TOOL_DESCRIPTION_COMMENT 53
4. QUERY_HOLDER_NUM_COMMENT 53
5. QUERY_HOLDER_VENDOR_COMMENT 53
6. QUERY_HOLDER_DESCRIPTION_COMMENT 54
7. QUERY_STATION_DESCRIPTION_COMMENT 54
What’s New in UPG for CAMWorks 2019 SP2 55
5
Table of Contents

System Header Commands ................................................................................... 55


1. :FORCE_UPPERCASE_OUTPUT 55
Attribute Commands .............................................................................................. 55
1. MUST_BE_LOWERCASE 55
2. MUST_BE_UPPERCASE 55
What’s New in UPG for CAMWorks 2019 SP1 56
System Header Commands ................................................................................... 56
1. :ALLOW_B_AXIS_SIMULTANEOUS_CUTTING 56
Variables ................................................................................................................. 56
1. OPR_START_APPROACH_TYPE 56
2. OPR_X_APPROACH_POS 56
3. OPR_Z_APPROACH_POS 56
4. NEXT_OPR_BAXIS_TURNING 56
5. MAX_B_AXIS_INCREMENT 57
6. NUM_OPERATIONS_FRONT1 57
7. NUM_OPERATIONS_FRONT2 58
8. NUM_OPERATIONS_Rear1 58
9. NUM_OPERATIONS_Rear2 58
10. NUM_SYNC_CODES_REAR1 58
11. NUM_SYNC_CODES_REAR2 58
12. NUM_SYNC_CODES_FRONT1 58
13. NUM_SYNC_CODES_FRONT2 59
14. OPR_BAXIS_TURNING 59
15. OPR_TOOL_TIP_CENTER 59
16. TLP_B_AXIS_OFFSET / P_TLP_B_AXIS_OFFSET 59
Query Commands .................................................................................................. 60
1. QUERY_INT_CENTER_TOUCHOFF_REG 60
System Constants .................................................................................................. 60

6
About UPG-2 (Enhanced UPG App)

About UPG-2 (Enhanced UPG App)


Introducing New UPG-2 Application and Discontinuation of Older versions of UPG
From CAMWorks 2020 SP0 version onwards, an enhanced version of Universal Post Generator
application named UPG-2 will be supported. Official support for all older versions of the Universal
Post Generator application will be discontinued.

Seamlessly upgrade to UPG-2


UPG-2 is built using technologies that ensure excellent compatibility with modern Operating
Systems. It has the same structure, concepts, and methodologies as the older versions of UPG.
If you are an existing user, you will not find any difference in the user interface of this
application with the older version of UPG.
• Existing SRC or LIB files will get compiled as before.
• Post processors compiled using UPG-2 will be compatible with older CAMWorks versions
(previous to CAMWorks 2020).
• UPG-2 will get installed as a separate installation on your system and will not overwrite
any existing older version of UPG on your system.

How UPG-2 is different from older versions of UPG


UPG-2 also comes equipped with the enhancements required to support Probing and Subroutines
in CAMWorks 2020 version as well as all future versions (including CAMWorks 2021 to CAMWorks
2023 version).
New system commands, attribute commands, miscellaneous commands, CALC sections, header
commands, variables and constants are periodically added to the Universal Post Generator
application with every new CAMWorks Service Pack release.
Note that from CAMWorks 2020 SP0 version onwards, any new commands, variables or constants
added to the Universal Post Generator application will be available only in UPG-2. For example,
UPG-2 also comes equipped with the enhancements required to support Probing and
Subroutines. Neither of these enhancements will be available in any older version of UPG as
support and maintenance for the older version has been discontinued.

New Commands, Constants and Variables added to UPG-2 for CAMWorks 2023
For a complete list of the new commands, variables and constants added to UPG-2 to ensure
compatibility with the CAMWorks 2023 version, refer the section from What’s New in UPG-2 for
CAMWorks 2023 SP0 of this document.

New Commands, Constants and Variables added to UPG-2 for CAMWorks 2022
For a complete list of the new commands, variables and constants added to UPG-2 to ensure
compatibility with the CAMWorks 2022 version, refer the section from What’s New in UPG-2 for
CAMWorks 2022 SP1 to What’s New in UPG-2 for CAMWorks 2022 of this document.

New Commands, Constants and Variables added to UPG-2 for CAMWorks 2021
For a complete list of the new commands, variables and constants added to UPG-2 to ensure
compatibility with the CAMWorks 2021 version, refer the section from What’s New in UPG-2 for
CAMWorks 2021 PLUS to What’s New in UPG-2 for CAMWorks 2021 SP0 of this document.

New Commands, Constants and Variables added to UPG-2 for CAMWorks 2020
For a complete list of the new commands, variables and constants added to UPG-2 to ensure
compatibility with the CAMWorks 2020 version, refer the section from What’s New in UPG-2 for
CAMWorks 2020 SP3 to What’s New in UPG-2 for CAMWorks 2020 SP0 of this document.

7
What’s New in UPG-2 for CAMWorks 2023 SP0

What’s New in UPG-2 for CAMWorks 2023 SP0

New - HEADER COMMANDS


1. :POST_SUPPORTS_EULER_ANGLES
When set to TRUE, the system will allow Euler angles to be passed to the
Purpose: post.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: :POST_SUPPORTS_EULER_ANGLES = TRUE or FALSE
Type: Integer
Default: FALSE

2. :POST_SUPPORTS_EULER_TNDC
When set to TRUE, the system will allow Euler Tool Normal direct control to
Purpose: be used in the post.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: :POST_SUPPORTS_EULER_TNDC = TRUE or FALSE
Type: Integer
Default: FALSE

New - SYSTEM VARIABLES


1. EULER_TYPE
Type: INTEGER
This will pass the type of Euler angle combination needed.
To be used in CAMWorks 2023 SP0 or higher versions.

Usage: EULER_TYPE=EULER_NONE
EULER_ZXZ
EULER_ZYZ

2. EULER_FIRST_ROT
Type: DECIMAL
This will pass the Euler first rotation angle.
Usage:
To be used in CAMWorks 2023 SP0 or higher versions.
The system will calculate the specified EULER_TYPE, EULER_1ST_ROT,
EULER_2ND_ROT and EULER_3RD_ROT before calling
Note: CALC_START_OPERATION.
If the user overrides the system calculated rotations, then
OVERRIDING_EULER_ANGLES will be set to TRUE.

8
What’s New in UPG-2 for CAMWorks 2023 SP0

3. EULER_SECOND_ROT
Type: DECIMAL
This will pass the Euler second rotation angle.
Usage:
To be used in CAMWorks 2023 SP0 or higher versions.
The system will calculate the specified EULER_TYPE, EULER_1ST_ROT,
EULER_2ND_ROT and EULER_3RD_ROT before calling
Note: CALC_START_OPERATION.
If the user overrides the system calculated rotations, then
OVERRIDING_EULER_ANGLES will be set to TRUE.

4. EULER_THIRD_ROT
Type: DECIMAL
This will pass the Euler third rotation angle.
Usage:
To be used in CAMWorks 2023 SP0 or higher versions.
The system will calculate the specified EULER_TYPE, EULER_1ST_ROT,
EULER_2ND_ROT and EULER_3RD_ROT before calling
Note: CALC_START_OPERATION.
If the user overrides the system calculated rotations, then
OVERRIDING_EULER_ANGLES will be set to TRUE.

5. OVERRIDING_EULER_ANGLES
Type: INTEGER

Usage: This will pass whether you are overriding the Euler Angles or not.
To be used in CAMWorks 2023 SP0 or higher versions.
The system will calculate the specified EULER_TYPE, EULER_1ST_ROT,
EULER_2ND_ROT and EULER_3RD_ROT before calling
Note: CALC_START_OPERATION.
If the user overrides the system calculated rotations, then
OVERRIDING_EULER_ANGLES will be set to TRUE.

6. PROBE_MEASURE_TYPE
Type: INTEGER

Usage: This will pass the current probe measure type either XY or Z.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax:
PROBE_MEASURE_TYPE=MEASURE_XY
PROBE_MEASURE_TYPE=MEASURE_Z

7. N_PROBE_MEASURE_TYPE
Type: INTEGER

Usage: This will pass the next probe measure type either XY or Z.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax:
N_PROBE_MEASURE_TYPE=MEASURE_XY
N_PROBE_MEASURE_TYPE=MEASURE_Z

9
What’s New in UPG-2 for CAMWorks 2023 SP0

8. P_PROBE_MEASURE_TYPE
Type: INTEGER

Usage: This will pass the previous probe measure type either XY or Z.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax:
P_PROBE_MEASURE_TYPE=MEASURE_XY
P_PROBE_MEASURE_TYPE=MEASURE_Z

9. PROBE_CYCLE_X_TYPE
Type: INTEGER

Usage: This will pass the current probe cycle X type.


To be used in CAMWorks 2023 SP0 or higher versions.

10. P_PROBE_CYCLE_X_TYPE
Type: INTEGER

Usage: This will pass the previous probe cycle X type.


To be used in CAMWorks 2023 SP0 or higher versions.

11. N_PROBE_CYCLE_X_TYPE
Type: INTEGER

Usage: This will pass the next probe cycle X type.


To be used in CAMWorks 2023 SP0 or higher versions.

12. PROBE_CYCLE_Y_TYPE
Type: INTEGER

Usage: This will pass the current probe cycle Y type.


To be used in CAMWorks 2023 SP0 or higher versions.

13. P_PROBE_CYCLE_Y_TYPE
Type: INTEGER

Usage: This will pass the previous probe cycle Y type.


To be used in CAMWorks 2023 SP0 or higher versions.

14. N_PROBE_CYCLE_Y_TYPE
Type: INTEGER

Usage: This will pass the next probe cycle Y type.


To be used in CAMWorks 2023 SP0 or higher versions.

15. PROBE_CYCLE_Z_TYPE
Type: INTEGER

Usage: This will pass the current probe cycle Z type.


To be used in CAMWorks 2023 SP0 or higher versions.

10
What’s New in UPG-2 for CAMWorks 2023 SP0

16. P_PROBE_CYCLE_Z_TYPE
Type: INTEGER

Usage: This will pass the previous probe cycle Z type.


To be used in CAMWorks 2023 SP0 or higher versions.

17. N_PROBE_CYCLE_Z_TYPE
Type: INTEGER

Usage: This will pass the next probe cycle Z type.


To be used in CAMWorks 2023 SP0 or higher versions.

18. PROBE_UNPROTECTED_Z_DOWN
Type: INTEGER

Usage: This variable will pass whether the probe rapid Z down is unprotected or not.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: PROBE_UNPROTECTED_Z_DOWN=TRUE or FALSE

19. PROBE_UNPROTECTED_Z_UP
Type: INTEGER

Usage: This variable will pass whether the probe rapid Z up is unprotected or not.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: PROBE_UNPROTECTED_Z_UP=TRUE or FALSE

20. PROBE_PNT_X1
Type: DECIMAL
This variable will pass the first X point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

21. PROBE_PNT_Y1
Type: DECIMAL
This variable will pass the first Y point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

22. PROBE_PNT_Z1
Type: DECIMAL
This variable will pass the first Z point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

23. PROBE_PNT_X2
Type: DECIMAL
This variable will pass the second X point in a three point plane toolpath
Usage: probing cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.
11
What’s New in UPG-2 for CAMWorks 2023 SP0

24. PROBE_PNT_Y2
Type: DECIMAL
This variable will pass the second Y point in a three point plane toolpath
Usage: probing cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

25. PROBE_PNT_Z2
Type: DECIMAL
This variable will pass the second Z point in a three point plane toolpath
Usage: probing cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

26. PROBE_PNT_X3
Type: DECIMAL
This variable will pass the third X point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

27. PROBE_PNT_Y3
Type: DECIMAL
This variable will pass the third Y point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

28. PROBE_PNT_Z3
Type: DECIMAL
This variable will pass the third Z point in a three point plane toolpath probing
Usage: cycle, to be used for manual output.
To be used in CAMWorks 2023 SP0 or higher versions.

29. PROBE_REF_NORM_X
Type: DECIMAL

Usage: This variable will pass the probe reference normal in X.


To be used in CAMWorks 2023 SP0 or higher versions.

30. PROBE_REF_NORM_Y
Type: DECIMAL

Usage: This variable will pass the probe reference normal in Y.


To be used in CAMWorks 2023 SP0 or higher versions.

31. PROBE_REF_NORM_Z
Type: DECIMAL

Usage: This variable will pass the probe reference normal in Z.


To be used in CAMWorks 2023 SP0 or higher versions.

12
What’s New in UPG-2 for CAMWorks 2023 SP0

32. PROBE_START_ANGLE
Type: DECIMAL

Usage: This variable will pass the probe starting angle (For Heidenhain).
To be used in CAMWorks 2023 SP0 or higher versions.

33. PROBE_STEPPING_ANGLE
Type: DECIMAL

Usage: This variable will pass the probe stepping angle (For Heidenhain).
To be used in CAMWorks 2023 SP0 or higher versions.

34. PROBE_STOP_IF_TOL_EXCEEDED
Type: INTEGER
This variable will pass whether tolerance has been exceeded or not (For
Usage: Heidenhain).
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: PROBE_STOP_IF_TOL_EXCEEDED=TRUE or FALSE

35. PROBE_CLEARANCE
Type: DECIMAL
This variable will pass the probe clearance value defined in the below
mentioned probe cycles:
• Angle Measurement (X Axis)
Usage: • Angle Measurement (Y Axis)
• 4th Axis Measurement (X Axis)
• 4th Axis Measurement (Y Axis)
To be used in CAMWorks 2023 SP0 or higher versions.

36. PROBE_LIB_TYPE
Type: INTEGER
This will pass the probe library type selected under the posting tab of
Usage: machine page.
To be used in CAMWorks 2023 SP0 or higher versions.
PROBE_LIB_TYPE= PROBE_TYPE_NONE
PROBE_TYPE_RENISHAW
Syntax:
PROBE_TYPE_HEIDENHAIN
PROBE_TYPE_OTHER

37. CURR_FILE_NUM
Type: INTEGER
This will pass the current File Number being used to receive output from the
Usage: post template lines. This will be used with the post variable SETTXT.
To be used in CAMWorks 2023 SP0 or higher versions.
If SETTXT(5) is used, then
:T: (CURR_FILE_NUM=<"%2LT":CURR_FILE_NUM>)<EOL>
Example:
Output is
CURR_FILE_NUM=05)

13
What’s New in UPG-2 for CAMWorks 2023 SP0

New - SYSTEM COMMANDS


1. GET_EULER_ANGLES
Allows the post to get the Euler angles of a specified type and updates the
following variables.:
• EULER_TYPE
Purpose: • EULER_1ST_ROT
• EULER_2ND_ROT
• EULER_3RD_ROT
To be used in CAMWorks 2023 SP0 or later versions.
:SECTION=CALC_START_OPERATION
Syntax:
GET_EULER_ANGLES(EULER_ZXZ)
Comments: Sets EULER_TYPE=EULER_NONE if the command fails.

New - QUERY COMMANDS


1. QUERY_INT_5AXIS_KEEP_INITIAL_ORIENTATION
This command can be used to check whether the option Keep initial orientation
until distance present under Multiaxis Mill operation is selected or not. If the
return value of QUERY_RESULT is TRUE, the system will pass whether this
Purpose: option is selected or not to the post system variable called QUERY_INT_VAL
in a Multiaxis Mill operation.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_INT_5AXIS_KEEP_INITIAL_ORIENTATION
Associated commands and variables:
The example code below indicates how this command can be used.
:SECTION=CALC_START_OPERATION
:C: QUERY_ITEM_ID=QUERY_INT_5AXIS_KEEP_INITIAL_ORIENTATION
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: CALL(OUTPUT_KEEP_INITIAL_ORIENTATION)
:C: ENDIF
Comments:
:SECTION=OUTPUT_KEEP_INITIAL_ORIENTATION
:T: IF QUERY_INT_VAL=0 THEN ( KEEP_INITIAL_ORIENTATION =
FALSE )<EOL> ENDIF
:T: IF QUERY_INT_VAL=1 THEN ( KEEP_INITIAL_ORIENTATION =
TRUE )<EOL> ENDIF

If option is selected under a Multiaxis Mill operation, then the output should
be:
( KEEP_INITIAL_ORIENTATION = TRUE )

14
What’s New in UPG-2 for CAMWorks 2023 SP0

2. QUERY_POST_SUPPORTS_EULER_ANGLES
If the return value of QUERY_RESULT is TRUE, then the system will pass
Purpose: whether post is supporting Euler angles. QUERY_INT_VAL.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_POST_SUPPORTS_EULER_ANGLES
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_POST_SUPPORTS_EULER_ANGLES
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Integer post variable=QUERY_INT_VAL
:C: ENDIF

3. QUERY_POST_SUPPORTS_EULER_TNDC
If the return value of QUERY_REdSULT is TRUE, then the system will pass
Purpose: whether post is supporting Euler angles. QUERY_INT_VAL.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_POST_SUPPORTS_EULER_TNDC
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_POST_SUPPORTS_EULER_TNDC
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Integer post variable=QUERY_INT_VAL
:C: ENDIF

4. QUERY_MACRO_ROTATE_Z
If the return value of QUERY_RESULT is TRUE, then the system will pass
Purpose: whether post is supporting rotating macros about Z. QUERY_INT_VAL.
To be used in CAMWorks 2023 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_MACRO_ROTATE_Z
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_MACRO_ROTATE_Z
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Integer post variable=QUERY_INT_VAL
:C: ENDIF

15
What’s New in UPG-2 for CAMWorks 2023 SP0

New - SYSTEM CONSTANTS


Name Value
EULER_NONE 0
EULER_ZXZ 1
EULER_YZY 2
CAM_REV2023 230
ANGLE_SINGLE_FACE_TOOLPATH 16
ANGLE_X_AXIS_TOOLPATH 17
ANGLE_Y_AXIS_TOOLPATH 18
ANGLE_4TH_X_AXIS_TOOLPATH 19
ANGLE_4TH_Y_AXIS_TOOLPATH 20
ANGLE_4TH_X_AXIS_Z_TOOLPATH 21
ANGLE_4TH_Y_AXIS_Z_TOOLPATH 22
THREE_POINT_PLANE_TOOLPATH 23
MEASURE_XY 1
MEASURE_Z 2
PROBE_TYPE_NONE 0
PROBE_TYPE_RENISHAW 1
PROBE_TYPE_HEIDENHAIN 2
PROBE_TYPE_OTHER 3

16
What’s New in UPG-2 for CAMWorks 2022 SP1

What’s New in UPG-2 for CAMWorks 2022 SP1

New - HEADER COMMANDS

1. : SET_FIRST_Z_POS_ON_MILL_TC
When set to TRUE, the system will pass the first Z move to ABS_Z_END at
Purpose: tool change.
To be used in CAMWorks 2022 SP1 or higher versions.
Syntax: :SET_FIRST_Z_POS_ON_MILL_TC = TRUE or FALSE
Type: Integer
Default: FALSE

New - QUERY COMMANDS

1. QUERY_MILL_FEATURE_NAME
If the return value of QUERY_RESULT is TRUE, then the system will pass the
Purpose: absolute value in Z axis from WCS to current feature face. QUERY_DEC_VAL.
To be used in CAMWorks 2022 SP1 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_MILL_FEATURE_FACE
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_MILL_FEATURE_FACE
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Decimal post variable=QUERY_DEC_VAL
:C: ENDIF

17
What’s New in UPG-2 for CAMWorks 2022

What’s New in UPG-2 for CAMWorks 2022

New - POST HEADER COMMANDS

1. :POST_FROM_PART_SETUP_ORIGIN_WHEN_USING_PART_REF_POINT
=TRUE or FALSE
Type: INTEGER
DEFAULT: FALSE

Usage: When set to TRUE, the system will post from part setup origin when using
part reference point. To be used in CAMWorks 2022 SP0 or higher versions.

2. :USE_COMBINATION_ID_AS_NAME_WHEN_AVAILABLE = TRUE OR
FALSE
Type: INTEGER
DEFAULT: FALSE
When this header is set to TRUE, provided that the Combination ID is blank,
the system will use Tool number. Available only in conjunction with tool
Usage: assembly mode that was added for CAMWorks Virtual Machine. This is similar
to : USE_STATION_ID_AS_NAME.
To be used in CAMWorks 2022 SP0 or higher versions.

New - SYSTEM VARIABLES

1. TOOL_PROFILE_RADIUS
Type: DECIMAL
This variable indicates the current tool parameters that define the tool profile
Usage: radius of all Barrel tool types, except for Lens type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

2. N_TOOL_PROFILE_RADIUS
Type: DECIMAL
This variable indicates the next entity tool parameters that define the tool
Usage: profile radius of all Barrel tool types, except for Lens type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

3. TOOL_CONVEX_RADIUS
Type: DECIMAL
This variable indicates the current entity tool parameters that define the tool
Usage: convex radius of a barrel lens tool.
To be used in CAMWorks 2022 SP0 or higher versions.

18
What’s New in UPG-2 for CAMWorks 2022

4. N_TOOL_CONVEX_RADIUS
Type: DECIMAL
This variable indicates the next entity tool parameters that define the tool
Usage: convex radius of a barrel lens tool.
To be used in CAMWorks 2022 SP0 or higher versions.

5. NC_TOOL_CONVEX_RADIUS
Type: DECIMAL
This variable indicates the next upcoming tool parameters that define the tool
Usage: convex radius of a barrel lens tool.
To be used in CAMWorks 2022 SP0 or higher versions.

6. NC_TOOL_PROFILE_RADIUS
Type: DECIMAL
This variable indicates the next upcoming tool parameters that define the tool
Usage: profile radius of all Barrel tool types, except for Lens type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

7. TOOL_Z_CENTER
Type: DECIMAL
This variable indicates the current tool parameters that define the tool Z
Usage: center of an Advanced type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

8. N_Z_CENTER
Type: DECIMAL
This variable indicates the next entity tool parameters that define the tool Z
Usage: center of an Advanced type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

9. NC_Z_CENTER
Type: DECIMAL
This variable indicates the next upcoming tool parameters that define the tool
Usage: Z center of an Advanced type Barrel tool.
To be used in CAMWorks 2022 SP0 or higher versions.

10. HOST_SYSTEM
Type: INTEGER
This variable passes information on the current Solids application being used.
HOST_SYSTEM=SYSTEM_TYPE_CAMWORKS_SW
Usage:
HOST_SYSTEM=SYSTEM_TYPE_CAMWORKS_SE
HOST_SYSTEM=SYSTEM_TYPE_SOLIDWORKS_CAM

11. RUNNING_SYSTEM
Type: INTEGER
This variable passes information on the current running system being used.
Usage: Uses same definitions as the CAMWORKS_VER variable. CAMWORKS_VER
only changes when new variables or changes to the posting system are
19
What’s New in UPG-2 for CAMWorks 2022

added to a new version or service pack. This variable RUNNING_SYSTEM will


always pass the current CAMWorks version and its Service Pack. To be used
in CAMWorks 2022 SP0 or higher versions.
Examples:
RUNNING_SYSTEM=CAM_REV2022_SP0
RUNNING_SYSTEM=CAM_REV2022_SP1
RUNNING_SYSTEM=CAM_REV2022_SP2

12. CANNED_CYCLE_FIRST_CUT
Type: DECIMAL
This variable will pass the first cut amount to the Turn or Mill-Turn post when
Usage: doing a canned turn roughing cycle.
To be used in CAMWorks 2022 SP0 or higher versions.

13. CANNED_CYCLE_FINAL_CUT
Type: DECIMAL
This variable will pass the final cut amount to a Turn or Mill-Turn post when
Usage: doing a canned turn roughing cycle.
To be used in CAMWorks 2022 SP0 or higher versions.

14. STOCK_TYPE
Type: INTEGER
This variable passes the current stock type being used. To be used in
CAMWorks 2022 SP0 or higher versions.
For Mill Posts:
STOCK_TYPE=MILL_STOCK_TYPE_NONE
STOCK_TYPE= MILL_STOCK_TYPE_BB
STOCK_TYPE= MILL_STOCK_TYPE_SKETCH
STOCK_TYPE= MILL_STOCK_TYPE_PART
STOCK_TYPE= MILL_STOCK_TYPE_STL
STOCK_TYPE= MILL_STOCK_TYPE_BROWSE_PART
STOCK_TYPE= MILL_STOCK_TYPE_WIP
Usage: STOCK_TYPE= MILL_STOCK_TYPE_ROUND_BAR
STOCK_TYPE= MILL_STOCK_TYPE_PREDEFINED_BOX
STOCK_TYPE= MILL_STOCK_TYPE_CYLINDRICAL

For Turn and Mill-Turn Posts:


STOCK_TYPE= TURN_STOCK_TYPE_EXTRUDED
STOCK_TYPE= TURN_STOCK_TYPE_REVOLVED
STOCK_TYPE= TURN_STOCK_TYPE_BARSTOCK
STOCK_TYPE= TURN_STOCK_TYPE_WIP
STOCK_TYPE= TURN_STOCK_TYPE_STL
STOCK_TYPE= TURN_STOCK_TYPE_PART

20
What’s New in UPG-2 for CAMWorks 2022

New - SYSTEM CONSTANTS


Name Value
SYSTEM_TYPE_CAMWORKS_SW 1
SYSTEM_TYPE_CAMWORKS_SE 2
SYSTEM_TYPE_SOLIDWORKS_CAM 3
CAM_REV2021_SP1 211
CAM_REV2021_SP2 212
CAM_REV2021_SP3 213
CAM_REV2021_SP4 214
CAM_REV2021_SP5 215
CAM_REV2021_PLUS 216
CAM_REV2021_PLUS_SP1 217
CAM_REV2021_PLUS_SP2 218
CAM_REV2021_PLUS_SP3 219
CAM_REV2022 220
CAM_REV2022_SP0 220
CAM_REV2022_SP1 221
CAM_REV2022_SP2 222
CAM_REV2022_SP3 223
CAM_REV2022_SP4 224
CAM_REV2022_SP5 225
MILL_STOCK_TYPE_NONE 0
MILL_STOCK_TYPE_BB 1
MILL_STOCK_TYPE_SKETCH 2
MILL_STOCK_TYPE_PART 3
MILL_STOCK_TYPE_STL 4
MILL_STOCK_TYPE_BROWSE_PART 5
MILL_STOCK_TYPE_WIP 6
MILL_STOCK_TYPE_ROUND_BAR 7
MILL_STOCK_TYPE_PREDEFINED_BOX 8
MILL_STOCK_TYPE_CYLINDRICAL 9
TURN_STOCK_TYPE_NONE 0
TURN_STOCK_TYPE_EXTRUDED 1
TURN_STOCK_TYPE_REVOLVED 2
TURN_STOCK_TYPE_BARSTOCK 3
TURN_STOCK_TYPE_WIP 4
TURN_STOCK_TYPE_STL 5
TURN_STOCK_TYPE_PART 6

21
What’s New in UPG-2 for CAMWorks 2021 PLUS

What’s New in UPG-2 for CAMWorks 2021 PLUS

New - QUERY COMMAND

1. QUERY_FEATURE_NAME
If the return value of QUERY_RESULT is TRUE, then the system will pass the feature
Purpose: name to QUERY_CHAR_VAL.
To be used in CAMWorks 2021Plus SP2 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_FEATURE_NAME
Associated commands and variables:
The example code below shows the other variables used with this command.
:ATTRNAME=POST FEATURE NAME
:ATTRTYPE=POST
:CODETYPE=FORMAT
:ATTRCFUNC=CALC_QUERY_ADDITIONAL_TOOL_COMMENT(QUERY_FEATURE
_NAME)
:WORD_ADDRESS_BEF=|(|Feature Name:
:VAR=QUERY_CHAR_VAL
:WORD_ADDRESS_AFT=|)
:LEFT_PLACES=0
:RIGHT_PLACES=0
:UNITFLAG=NON_CONVERT
:ATTRSPACES=YES
:MODAL=YES
Comments: :ATTRUSED=1
:ATTREND

: *-----------------------------------
:SECTION=CALC_QUERY_ADDITIONAL_TOOL_COMMENT(QUERYID)
*
:C: QUERY_CHAR_VAL={}
:C: IF CAMWORKS_VER<CAM_REV2020 THEN SETOFF() RETURN ENDIF
*
:C: SETON()
:C: QUERY_ITEM_ID=QUERYID
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=0 OR QUERY_CHAR_VAL={} THEN SETOFF()
ENDIF
:C: IF ATTROVERRIDE=YES THEN SETON() ENDIF

22
What’s New in UPG-2 for CAMWorks 2021 PLUS

New - POST VARIABLES

1. :OPR_FROM_PART_SETUP_ORIGIN
Type: INTEGER
Syntax: :OPR_FROM_PART_SETUP_ORIGIN=TRUE or FALSE
Defines whether user selected Part Setup Origin in the Mill Assembly Setup
Usage: Origin page of current operation.
To be used in CAMWorks 2021 Plus and later versions.

2. :NEXT_OPR_FROM_PART_SETUP_ORIGIN
Type: INTEGER
Syntax: :NEXT_OPR_FROM_PART_SETUP_ORIGIN=TRUE or FALSE
Defines whether user selected Part Setup Origin in the Mill Assembly Setup
Usage: Origin page of the next operation.
To be used in CAMWorks 2021 Plus and later versions.

23
What’s New in UPG-2 for CAMWorks 2021 PLUS

Additional Notes - MAX STRING LENGTH FOR SYSTEM POST


CHARACTER VARIABLES

Sr. No. Character Length Note


1. Char Length = SubStationID[100]
2. Char Length = NextChangeSubStationID[100]
3. Char Length = NextSubStationID[100]
4. Char Length = Sync_Code_Comment[100]
5. Char Length = tlp_part_name[100]
6. Char Length = tlp_setup_name[100]
7. Char Length = tlp_setup_desc[100]
8. Char Length = tlp_feat_name[100]
9. Char Length = tlp_feat_desc[100]
10. Char Length = tlp_oper_name[100]
11. Char Length = tlp_oper_desc[100]
12. Char Length = tlp_part_desc[100]
13. Char Length = InsertComment[100]
14. Char Length = NextInsertComment[100]
15. Char Length = NextMoveInsertComment[100]
16. Char Length = HolderComment[100]
17. Char Length = NextHolderComment[100]
18. Char Length = NextMoveHolderComment[100]
19. Char Length = sys_file_name[200]
20. Char Length = tlp_feat_setup_name[100]
21. Char Length = tlp_feat_setup_desc[100]
22. Char Length = ToolDescription[100]
23. Char Length = HolderDescription[100]
24. Char Length = ToolPartID[100]
25. Char Length = ToolVendor[100]
26. Char Length = HolderVendor[100]
27. Char Length = HolderPartID[100]
28. Char Length = StationDescription[100]
29. Char Length = ToolAssemblyComment[100]
30. Char Length = ToolAssemblyDescription[100]

24
What’s New in UPG-2 for CAMWorks 2021 SP1

What’s New in UPG-2 for CAMWorks 2021 SP1

New - QUERY COMMANDS

1. QUERY_ARC_OVERRIDE_FEEDRATE
If the return value of QUERY_RESULT is TRUE, then the system will pass the
arc override feedrate value to post system variable named QUERY_DEC_VAL
Purpose:
in a Mill operation.
To be used in CAMWorks 2021 SP1 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_ARC_OVERRIDE_FEEDRATE
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: IF OPR_IS_ARC_FEEDRATE_OVERRIDE_ENABLED=TRUE
THEN
Comments: :C: QUERY_ITEM_ID=QUERY_ARC_OVERRIDE_FEEDRATE
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Defined Post Variable=QUERY_DEC_VAL
:C: ENDIF
:C: ENDIF

2. QUERY_CORNER_SLOWDOWN_FEEDRATE
If the return value of QUERY_RESULT is TRUE, then the system will pass the
corner slowdown feedrate value to post system variable named
Purpose: QUERY_DEC_VAL in a Mill operation.
To be used in CAMWorks 2021 SP1 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_CORNER_SLOWDOWN_FEEDRATE
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: IF OPR_IS_CORNER_SLOWDOWN_ENABLED=TRUE THEN
QUERY_ITEM_ID=QUERY_CORNER_SLOWDOWN_FEEDRATE
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Defined Post Variable=QUERY_DEC_VAL
:C: ENDIF
:C: ENDIF

25
What’s New in UPG-2 for CAMWorks 2021 SP0

What’s New in UPG-2 for CAMWorks 2021 SP0


New - Post Variables

1. NEXT_NON_POSTOP_SYSTEM
Type Integer
Stores the next system excluding the post operations. A new constant can be
used with this variable to determine if you are at the end of a channel or tape
Purpose: (NO_NEXT_SYSTEM).
To be used in CAMWorks 2021 SP0 or higher versions.

2. TOOL_SHOULDER_LENGTH
Type Decimal
Stores the Tool Shoulder Length.
Purpose:
To be used in CAMWorks 2021 SP0 or higher versions.

3. TAB
Type Character
Used for outputting a tab character to the posted output ASCII (09) values.
Purpose:
To be used in CAMWorks 2021 SP0 or higher versions.
Example: :T:<TAB><EOL>

4. MCS_OFFSET_TYPE
MCS_OFFSET_TYPE= OFFSET_TYPE_FROM_FCS
Syntax OFFSET_TYPE_FROM_REF_POINT
OFFSET_TYPE_FROM_SETUP
Type Integer
Stores the MCS Offset Types
Purpose:
To be used in CAMWorks 2021 SP0 or higher versions.

5. WORLD_WCS_TO_SETUP_OFFSET_X
Type Decimal
Stores the X offset distance from WCS to Setup (in Fixture Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

26
What’s New in UPG-2 for CAMWorks 2021 SP0

6. WORLD_WCS_TO_SETUP_ OFFSET_Y
Type Decimal
Stores the Y offset distance from WCS to Setup (in Fixture Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

7. WORLD_WCS_TO_SETUP_ OFFSET_Z
Type Decimal
Stores the Z offset distance from WCS to Setup (in Fixture Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

8. WCS_TO_SETUP_SCS_OFFSET_X
Type Decimal
Stores the X offset distance from WCS to Setup (in Setup Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

9. WCS_TO_SETUP_SCS_OFFSET_Y
Type Decimal
Stores the Y offset distance from WCS to Setup (in Setup Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

10. WCS_TO_SETUP_SCS_OFFSET_Z
Type Decimal
Stores the Z offset distance from WCS to Setup (in Setup Coordinate
Purpose: system).
To be used in CAMWorks 2021 SP0 or higher versions.

11. MCS_X_WORK_OFFSET ; N_MCS_X_WORK_OFFSET ;


P_MCS_X_WORK_OFFSET
Type Decimal
Stores the X Work Coordinate offset from WCS to Setup Origin (after rotation
Purpose: in Machine Coordinate System) in current, next, and previous respectively.
To be used in CAMWorks 2021 SP0 or higher versions.

12. MCS_Y_WORK_OFFSET ; N_MCS_Y_WORK_OFFSET ;


P_MCS_Y_WORK_OFFSET
Type Decimal
Stores the Y Work Coordinate offset from WCS to Setup Origin (after rotation
Purpose: in Machine Coordinate System) in current, next, and previous respectively.
To be used in CAMWorks 2021 SP0 or higher versions.

27
What’s New in UPG-2 for CAMWorks 2021 SP0

13. MCS_Z_WORK_OFFSET ; N_MCS_Z_WORK_OFFSET ;


P_MCS_Z_WORK_OFFSET
Type Decimal
Stores the X Work Coordinate offset from WCS to Setup Origin (after rotation
Purpose: in Machine Coordinate System) in current, next, and previous respectively.
To be used in CAMWorks 2021 SP0 or higher versions.

14. MACRO_4TH_AXIS_OFFSET_ANGLE
Type Decimal
Stores the subroutine (macro) 4th axis offset angle at the subroutine (macro)
Purpose: call sections.
To be used in CAMWorks 2021 SP0 or higher versions.

15. MACRO_5TH_AXIS_OFFSET_ANGLE
Type Decimal
Stores the subroutine (macro) 5th axis offset angle at the subroutine (macro)
Purpose: call sections.
To be used in CAMWorks 2021 SP0 or higher versions.

16. MACRO_U; MACRO_V; MACRO_W


Type Decimal
Internal macro variable used to pass information from the defined subroutine
to the main calling program.
Purpose:
Only MACRO_A and MACRO_B can be used to pass information from the main
calling program to the defined subroutine.

17. MACRO_X; MACRO_Y; MACRO_Z


Type Decimal
Internal macro variable used to pass information from the defined subroutine
to the main calling program.
Purpose:
Only MACRO_A and MACRO_B can be used to pass information from the main
calling program to the defined subroutine.

28
What’s New in UPG-2 for CAMWorks 2021 SP0

New - System Header Commands


1. OUTPUT_5AXIS_TOOLPATHS_FROM_SETUP_WCS
Type Integer
Default False
When set to TRUE, the system will output 5 axis toolpaths from the Setup
Usage: location when a Setup is used as WCS.
To be used in CAMWorks 2021 SP0 or higher versions.

New - CALC SECTION


1. CALC_CLEANUP_AFTER_POSTING
CALC_CLEANUP_AFTER_POSTING gets called when posting has completed
and the main file (0) is closed and the SET file is closed. This CALC section is
intended for any file cleanup that is needed like KILLSYSFILE. You may
need to do this if using OPENTXT command and you are outputting code to
Purpose:
other external files. If you are using “:NO_SET_FILE=TRUE” then the only
place you can delete the main file (0) is in this section. It is not
recommended to use this section to call other sections that might call
template sections for outputting code as all files are closed at this time.

New - QUERY COMMANDS


1. QUERY_TOOL_ASSEMBLY_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2021 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_TOOL_ASSEMBLY_COMMENT
The max character length allowed for the string value assigned to this
Max.
parameter is 100 characters. Any extra character after this allowed number
Character
of characters will not be passed on to post system variable named
Length
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_TOOL_ASSEMBLY_COMMENT
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

29
What’s New in UPG-2 for CAMWorks 2021 SP0

2. QUERY_TOOL_ASSEMBLY_DESCRIPTION
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2021 SP0 or higher versions.
Syntax: QUERY_ITEM_ID=QUERY_TOOL_ASSEMBLY_DESCRIPTION
The max character length allowed for the string value assigned to this
Max.
parameter is 100 characters. Any extra character after this allowed number
Character
of characters will not be passed on to post system variable named
Length
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID =QUERY_TOOL_ASSEMBLY_DESCRIPTION
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

New - System Constants


Name Value
NO_NEXT_SYSTEM -1
CAM_REV2021 210
OFFSET_TYPE_FROM_FCS 2
OFFSET_TYPE_FROM_REF_POINT 1
OFFSET_TYPE_FROM_SETUP 0

New - Support for Probing Cycles in Mill-Turn Post Source Files


From CAMWorks 2021 version onwards, the support for Probing Cycles has been extended to Mill-
Turn post processors in addition to the existing Mill post processors.
Refer the document Tutorial_on_Adding_Probing_Support_in_Existing_Post_Processors.pdf for details
on how to add the necessary code for ensuring Probing support in existing Mill-Turn Post
Processors.
Details of the necessary coding to be added in Mill-Turn Post Processors are given below:
1. Add Probing Header Command in Header section of Post
Add the header command ALLOW_PROBING in the header section of Mill-Turn post to
enable support for Probe Cycles.
: ALLOW_PROBING=TRUE

2. Add New Library Command Line in Mill-Turn Post Source Files


Add the new library command line for MILLTURN_PROBE.LIB in Mill-Turn Post Source files.
MILLTURN_PROBE.LIB is located in the same directory as MILLTURN.LIB, viz.:
C:\CAMWorksData\UPG-2\MasterLibraryFiles
The main advantage of this method is that your existing lib file doesn’t need to be edited.
Also, the MILLTURN_PROBE.LIB can be referred in various other lib files. It is important to
ensure that MILLTURN_PROBE.LIB is the first lib in the list of lib files.

30
What’s New in UPG-2 for CAMWorks 2021 SP0

:LIBRARY=PATH\MILLTURN_PROBE.LIB
:LIBRARY=PATH\POST-LIBRARY-FILE.LIB
:LIBRARY=PATH\MILLTURN.LIB

3. Add New Attribute Names


Add the following attribute names. These are to be defined in MILLTURN.LIB and
MILLTURN_PROBE.LIB.
:ATTRNAME=DEBUG PROBE
:ATTRNAME=PROBE ERROR
:ATTRNAME=P

4. Adding Probe CALC Section in Post Library


New Calc sections are needed to support Mill-Turn. These are to be defined in MILLTURN.LIB
and MILLTURN_PROBE.LIB. Alternatively, they can be added to your post LIB file.
• CALC_LINE_MOVE_PROBE_MILL
• CALC_LINE_MOVE_PROBE_MILL_BAXIS
• CALC_LINE_MOVE_OD_FIXED_PROBE
• CALC_LINE_MOVE_OD_FREE_PROBE
• CALC_LINE_MOVE_FACE_FIXED_PROBE
• CALC_LINE_MOVE_FACE_FREE_PROBE
• CALC_RAPID_MOVE_PROBE_MILL
• CALC_RAPID_MOVE_BAXIS_PROBE
• CALC_RAPID_MOVE_OD_FIXED_PROBE
• CALC_RAPID_MOVE_OD_FREE_PROBE
• CALC_RAPID_MOVE_FACE_FIXED_PROBE
• CALC_RAPID_MOVE_FACE_FREE_PROBE
• CALC_RAPID_Z_UP_PROBE_MILL
• CALC_RAPID_UP_BAXIS_PROBE
• CALC_RAPID_X_UP_OD_FIXED_PROBE
• CALC_RAPID_X_UP_OD_FREE_PROBE
• CALC_RAPID_Z_UP_FACE_FIXED_PROBE
• CALC_RAPID_Z_UP_FACE_FREE_PROBE
• CALC_RAPID_Z_DOWN_PROBE_MILL
• CALC_RAPID_DOWN_BAXIS_PROBE
• CALC_RAPID_X_DOWN_OD_FIXED_PROBE
• CALC_RAPID_X_DOWN_OD_FREE_PROBE
• CALC_RAPID_Z_DOWN_FACE_FIXED_PROBE
• CALC_RAPID_Z_DOWN_FACE_FREE_PROBE
• CALC_FEED_Z_PROBE_MILL
• CALC_FEED_DOWN_BAXIS_PROBE
• CALC_FEED_X_OD_FIXED_PROBE
• CALC_FEED_X_OD_FREE_PROBE
• CALC_FEED_Z_FACE_FIXED_PROBE
• CALC_FEED_Z_FACE_FREE_PROBE
• CALC_FEED_Z_PROBE_UP_MILL
• CALC_OUTPUT_PROBE_CYCLE_MILL

31
What’s New in UPG-2 for CAMWorks 2021 SP0

5. Adding Probe Template Section in Mill-Turn Post Source


Following new template sections are required SRC (Mill-Turn Post Source files). These will
be available in the latest Mill-Turn tutorial posts.
• RAPID_FROM_TC_BAXIS_PROBE
• RAPID_FROM_TC_OD_FIXED_PROBE
• RAPID_FROM_TC_OD_FREE_PROBE
• RAPID_FROM_TC_FACE_FIXED_PROBE
• RAPID_FROM_TC_FACE_FREE_PROBE
• RAPID_MOVE_BAXIS_PROBE
• RAPID_OD_FIXED_PROBE
• RAPID_OD_FREE_PROBE
• RAPID_FACE_FIXED_PROBE
• RAPID_FACE_FREE_PROBE
• RAPID_UP_BAXIS_PROBE
• RAPID_X_UP_OD_FIXED_PROBE
• RAPID_X_UP_OD_FREE_PROBE
• RAPID_Z_UP_FACE_FIXED_PROBE
• RAPID_Z_UP_FACE_FREE_PROBE
• LAST_RAPID_UP_BAXIS_PROBE
• LAST_RAPID_X_UP_OD_FIXED_PROBE
• LAST_RAPID_X_UP_OD_FREE_PROBE
• LAST_RAPID_Z_UP_FACE_FIXED_PROBE
• LAST_RAPID_Z_UP_FACE_FREE_PROBE
• FIRST_RAPID_DOWN_BAXIS_PROBE
• FIRST_RAPID_X_DOWN_OD_FIXED_PROBE
• FIRST_RAPID_X_DOWN_OD_FREE_PROBE
• FIRST_RAPID_Z_DOWN_FACE_FIXED_PROBE
• FIRST_RAPID_Z_DOWN_FACE_FREE_PROBE
• RAPID_DOWN_BAXIS_PROBE
• RAPID_X_DOWN_OD_FIXED_PROBE
• RAPID_X_DOWN_OD_FREE_PROBE
• RAPID_Z_DOWN_FACE_FIXED_PROBE
• RAPID_Z_DOWN_FACE_FREE_PROBE
• FEED_DOWN_BAXIS_PROBE
• FEED_X_OD_FIXED_PROBE
• FEED_X_OD_FREE_PROBE
• FEED_Z_FACE_FIXED_PROBE
• FEED_Z_FACE_FREE_PROBE
• FEED_Z_PROBE_UP_BAXIS
• FEED_X_UP_OD_FIXED_PROBE
• FEED_X_UP_OD_FREE_PROBE
• FEED_X_UP_FACE_FIXED_PROBE
• FEED_X_UP_FACE_FREE_PROBE
• LINE_MOVE_PROBE_MILL_BAXIS
• LINE_OD_FIXED_PROBE

32
What’s New in UPG-2 for CAMWorks 2021 SP0

• LINE_OD_FREE_PROBE
• LINE_FACE_FIXED_PROBE
• LINE_FACE_FREE_PROBE
• PROBE_SURFACE_X_TOOLPATH
• PROBE_SURFACE_Y_TOOLPATH
• PROBE_SURFACE_Z_TOOLPATH
• PROBE_WEB_X_TOOLPATH
• PROBE_WEB_Y_TOOLPATH
• PROBE_POCKET_X_TOOLPATH
• PROBE_POCKET_Y_TOOLPATH
• PROBE_ISLAND_POCKET_X_TOOLPATH
• PROBE_ISLAND_POCKET_Y_TOOLPATH
• PROBE_BOSS_TOOLPATH
• PROBE_BORE_TOOLPATH
• PROBE_ISLAND_BORE_TOOLPATH
• PROBE_3POINT_BOSS_TOOLPATH
• PROBE_3POINT_BORE_TOOLPATH
• PROBE_3POINT_ISLAND_BORE_TOOLPATH
• DEBUG_PROBE
• OUTPUT_PROBE_ERROR

33
What’s New in UPG-2 for CAMWorks 2020 SP3

What’s New in UPG-2 for CAMWorks 2020 SP3

New - System Constant ‘CAM_REV2020_SP3’


Name Value
CAM_REV2020_SP3 203

New - Parameters added to System Command ‘TRANSFORM’


KIN_ROTAXISBASE_4X
KIN_ROTAXISBASE_4Y
New Parameters KIN_ROTAXISBASE_4Z
from Kinematics
File KIN_ROTAXISBASE_5X
KIN_ROTAXISBASE_5Y
KIN_ROTAXISBASE_5Z
TRANS_ROTAXISBASE_PNT_4X
TRANS_ROTAXISBASE_PNT_4Y
TRANS_ROTAXISBASE_PNT_4Z

TRANS_ROTAXISBASE_PNT_5X
TRANS_ROTAXISBASE_PNT_5Y
TRANS_ROTAXISBASE_PNT_5Z

Example
:C: TRANS_START_X=0
:C: TRANS_START_Y=0
:C: TRANS_START_Z=0
:C: IF KIN_HAVE_KINEMATICS=TRUE THEN
:C: TRANS_ROTAXISDIR_4X=KIN_ROTAXISDIR_4X
:C: TRANS_ROTAXISDIR_4Y=KIN_ROTAXISDIR_4Y
New Parameters
:C: TRANS_ROTAXISDIR_4Z=KIN_ROTAXISDIR_4Z
supported by
Transform :C: TRANS_ROTAXISDIR_5X=KIN_ROTAXISDIR_5X
:C: TRANS_ROTAXISDIR_5Y=KIN_ROTAXISDIR_5Y
:C: TRANS_ROTAXISDIR_5Z=KIN_ROTAXISDIR_5Z
*
:C: TRANS_ROTAXISBASE_PNT_4X=KIN_ROTAXISBASE_4X
:C: TRANS_ROTAXISBASE_PNT_4Y=KIN_ROTAXISBASE_4Y
:C: TRANS_ROTAXISBASE_PNT_4Z=KIN_ROTAXISBASE_4Z
:C: TRANS_ROTAXISBASE_PNT_5X=KIN_ROTAXISBASE_5X
:C: TRANS_ROTAXISBASE_PNT_5Y=KIN_ROTAXISBASE_5Y
:C: TRANS_ROTAXISBASE_PNT_5Z=KIN_ROTAXISBASE_5Z
:C: TRANS_ROTANGLE_A=ROT_TILT_A
:C: TRANS_ROTANGLE_B=ROT_TILT_B
:C: TRANSFORM
:C: ENDIF

34
What’s New in UPG-2 for CAMWorks 2020 SP3

0 * 5 Axis Type 0-TABLE_TABLE,1-HEAD_HEAD,2-HEAD_TABLE, 3-


TABLE_TABLE_TOOLCOMP, 4-HEAD_HEAD_NOTOOLCOMP,
5-HEAD_TABLE_NOTOOLCOMP
1 * XYZ Coordinate Type 0-Part , 1-Machine
0.000000 * Spindle Direction X
0.000000 * Spindle Direction Y
1.000000 * Spindle Direction Z
0.000000 * 1st Rotary Axis Direction X
0.000000 * 1st Rotary Axis Direction Y
-1.000000 * 1st Rotary Axis Direction Z
0.000000 * 2nd Rotary Axis Direction X
-1.000000 * 2nd Rotary Axis Direction Y
KIN File Parameters
0.000000 * 2nd Rotary Axis Direction Z
-60.000000 * Rotation 5th Axis Base Point X (Millimeters Only)
0.000000 * Rotation 5th Axis Base Point Y (Millimeters Only)
-154.2491* Rotation 5th Axis Base Point Z (Millimeters Only)
-100000.000000 * 1st Rotation Axis Limit Min
100000.000000 * 1st Rotation Axis Limit Max
-180.000000 * 2nd Rotation Axis Limit Min
180.000000 * 2nd Rotation Axis Limit Max
Mill_Tutorial * Default Machine Simulation
0.000000 * Rotation 4th Axis Base Point X (Millimeters Only)
0.000000 * Rotation 4th Axis Base Point Y (Millimeters Only)
0.000000 * Rotation 4th Axis Base Point Z (Millimeters Only)

35
What’s New in UPG-2 for CAMWorks 2020 SP2

What’s New in UPG-2 for CAMWorks 2020 SP2

New - Post Variable


1. WRAPPED_AXIS
Type Integer
Stores whether a Mill Wrapped feature is about X or Y axis. Available in Mill
Purpose: mode only.
To be used in CAMWorks 2020 SP2 or higher versions.
Syntax: MACH_IS_4TH_AXIS_REV_DIR=TRUE or FALSE

2. Adding Wrapped Cylindrical to Mill Posts


Purpose: Stores To support Wrapped Cylindrical in Mill Posts.
Information Added or Modified in MILL.LIB:
The following has been added/modified in Mill.lib:
1. Attributes Added
i. Added WHICH_AXIS attribute.
ii. Added CYLINDRICAL attribute.
2. Attributes Modified
Modified DEBUG attribute to handle main cylindrical sections.
3. CALC sections Added.
CALC sections listed below have been added:
• CALC_RAPID_MOVE_MILL_CYLINDRICAL
• CALC_RAPID_FROM_TOOL_CHANGE_MILL_CYLINDRICAL
• CALC_RAPID_TO_TOOL_CHANGE_MILL_CYLINDRICAL
• CALC_RAPID_Z_UP_MILL_CYLINDRICAL
• CALC_RAPID_Z_MOVE_UP_LEN_COMP_MILL_CYLINDRICAL
• CALC_RAPID_Z_DOWN_MACRO_CYLINDRICAL
• CALC_FIRST_RAPID_Z_PRELOAD_DOWN_MILL_CYLINDRICAL
• CALC_FIRST_RAPID_Z_MOVE_DOWN_MILL_CYLINDRICAL
• CALC_FEED_Z_MOVE_DOWN_MILL_CYLINDRICAL
• CALC_LINE_MOVE_MILL_CYLINDRICAL
• CALC_LINE_LEADOUT_MOVE_CYLINDRICAL
• CALC_LINE_LEADIN_MOVE_CYLINDRICAL
• CALC_ARC_MOVE_MILL_CYLINDRICAL
• CALC_BREAK_ARC_CYLINDRICAL
• CALC_RADIAL_ARCS_CYLINDRICAL
• CALC_DO_MACRO_CALL_MILL_WRAPPED
• CALC_DO_MACRO_CALL_WORK_COORD_MILL_WRAPPED
• CALC_CYLINDRICAL

36
What’s New in UPG-2 for CAMWorks 2020 SP2

4. CALC Sections Modified


CALC sections listed below have been modified:
• CALC_RAPID_Z_DOWN_MILL
• CALC_RAPID_Z_UP_MILL
• CALC_RAPID_MOVE_MILL
• CALC_FEED_Z_MILL
• CALC_LINE_MOVE_MILL
• CALC_ARC_MOVE_MILL
• CALC_START_OPERATION
• CALC_DO_MACRO_CALL_MILL
• CALC_DO_MACRO_CALL_WORK_COORD_MILL

Information needed in SRC file for Adding Wrapped Cylindrical to Mill Posts:
1. Header command required
Header command ":MILL_OD_CYLINDRICAL=TRUE"
2. Line to be added
Added this line in CALC_INIT_CODES ":C: CYLINDRICAL=999"
3. Added below Template Sections.

• RAPID_MOVE_MILL_CYLINDRICAL
• RAPID_LEADOUT_MOVE_MILL_CYLINDRICAL
• RAPID_LEADIN_MOVE_MILL_CYLINDRICAL
• RAPID_FROM_TOOL_CHANGE_MILL_CYLINDRICAL
• RAPID_Z_MOVE_UP_MILL_CYLINDRICAL
• LAST_RAPID_Z_MOVE_UP_MILL_CYLINDRICAL
• FIRST_RAPID_Z_MOVE_DOWN_MILL_CYLINDRICAL
• RAPID_Z_MOVE_DOWN_MILL_CYLINDRICAL
• FEED_Z_MOVE_DOWN_MILL_CYLINDRICAL
• LINE_MOVE_MILL_CYLINDRICAL
• LINE_LEADIN_MOVE_CYLINDRICAL
• LINE_LEADOUT_MOVE_CYLINDRICAL
• ARC_MOVE_MILL_CYLINDRICAL
• RADIUS_MOVE_MILL_CYLINDRICAL
• CYLINDRICAL_ON
• CYLINDRICAL_OFF
• ROTATE_X_CYLINDRICAL
• ROTATE_Y_CYLINDRICAL
• ROTATE_X_WRAPPED
• ROTATE_Y_WRAPPED
• ROTATE_MULTIAXIS

4. Optional template Sections.


Following are the optional template sections:
• RAPID_LEADOUT_TO_TOOL_CHANGE_MILL_CYLINDRICAL
• MACRO_RAPID_CALL_MILL_CYLINDRICAL
• RAPID_Z_MOVE_UP_LEN_COMP_MILL_CYLINDRICAL
37
What’s New in UPG-2 for CAMWorks 2020 SP2

• LAST_RAPID_Z_MOVE_UP_LEN_COMP_MILL_CYLINDRICAL
• FIRST_RAPID_Z_PRELOAD_DOWN_MILL_CYLINDRICAL
• RAPID_Z_MOVE_DOWN_LEN_COMP_MILL_CYLINDRICAL
• FEED_Z_MOVE_DOWN_LEN_COMP_MILL_CYLINDRICAL
• FIRST_FEED_Z_DOWN_MILL_CYLINDRICAL

38
What’s New in UPG-2 for CAMWorks 2020 SP1

What’s New in UPG-2 for CAMWorks 2020 SP1

New - System Variables


1. MACH_IS_4TH_AXIS_REV_DIR
Type Integer
Stores whether the reverse checkbox has been checked in the Rotary tab of
Purpose: the Machine dialog box in the CAMWorks user interface.
To be used in CAMWorks 2020 SP1 or higher versions.
Syntax: MACH_IS_4TH_AXIS_REV_DIR=TRUE or FALSE

2. MACH_IS_5TH_AXIS_REV_DIR
Type Integer
Stores whether the reverse checkbox has been checked in the Tilt tab of the
Purpose: Machine dialog box in the CAMWorks user interface.
To be used in CAMWorks 2020 SP1 or higher versions.
Syntax: MACH_IS_5TH_AXIS_REV_DIR=TRUE or FALSE

39
What’s New in UPG-2 for CAMWorks 2020 SP0

What’s New in UPG-2 for CAMWorks 2020 SP0


New - System Header Commands
1. :ALLOW_PROBING
Type Integer
Sets the post to support probing cycles.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: :ALLOW_PROBING=TRUE or FALSE

New - System Variables for Probing Cycles


2. PROBE_A_1ST_ANGLE
Type Decimal
Stores the Probe Cycle’s 1st rotary angle.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

3. PROBE_B_2ND_ANGLE_OR_TOL
Type Decimal
Stores the Probe Cycle’s 2nd rotary angle or tolerance.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

4. PROBE_C_3RD_ANGLE
Type Decimal
Stores the Probe Cycle’s 3rd rotary angle.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

5. PROBE_D_NOMINAL_SIZE
Type Decimal
Stores the Probe Cycle’s 3rd nominal size.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

6. PROBE_E_EXPERIENCE_VALUE
Type Integer
Stores the Probe Cycle’s experience value.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

40
What’s New in UPG-2 for CAMWorks 2020 SP0

7. PROBE_F_PERCENT_FEEDBACK
Type Decimal
Stores the Probe Cycle’s percentage feedback.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

8. PROBE_H_TOL_VALUE
Type Decimal
Stores the Probe Cycle’s tolerance value.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

9. PROBE_I_CYCLE_SPEC_DIST_X
Type Decimal
Stores the Probe Cycle’s spec distance in X.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

10. PROBE_J_CYCLE_SPEC_DIST_Y
Type Decimal
Stores the Probe Cycle’s spec distance in Y.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

11. PROBE_K_CYCLE_SPEC_DIST_Z
Type Decimal
Stores the Probe Cycle’s spec distance in Z.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

12. PROBE_M_POS_TOL
Type Decimal
Stores the Probe Cycle’s Spec Position Tolerance Z.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

13. PROBE_Q_OVERTRAVEL_DIST
Type Decimal
Stores the Probe Cycle’s Overtravel Distance.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

14. PROBE_R_CLEARANCE
Type Decimal
Stores the Probe Cycle’s Retract Clearance.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

41
What’s New in UPG-2 for CAMWorks 2020 SP0

15. PROBE_T_TOOL_OFFSET_NUMBER
Type Integer
Stores the Probe Cycle’s Tool Offset Number.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

16. PROBE_U_UPPER_TOL_LIMIT
Type Decimal
Stores the Probe Cycle’s Upper Tolerance.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

17. PROBE_V_NULL_BAND
Type Decimal
Stores the Probe Cycle’s Null band.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

18. PROBE_W_PRINT_DATA
Type Integer
Stores the Probe Cycle’s Print Data
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

19. PROBE_X_POS_OR_SIZE_X
Type Decimal
Stores the Probe Cycle’s X position or size.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

20. PROBE_Y_POS_OR_SIZE_Y
Type Decimal
Stores the Probe Cycle’s Y position or size.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

21. PROBE_Z_POS_OR_SIZE_Z
Type Decimal
Stores the Probe Cycle’s Z position or size.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

22. PROBE_CYCLE_FEEDRATE
Type Decimal
Stores the Probe Cycle’s feedrate.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

42
What’s New in UPG-2 for CAMWorks 2020 SP0

23. PROBE_WORK_SUB_OFFSET_NUM
Type Integer
Stores the Probe Cycle’s Work Coordinate with Sub offset number.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

24. PROBE_WORK_OFFSET_NUM
Type Integer
Stores the Probe Cycle’s Work Coordinate Offset number.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

25. PROBE_UPDATE_WCS_OFFSET
Type Integer
Stores a binary value that indicates whether the Work Coordinate Offset for a
Purpose: Probe Cycle has been updated or not.
To be used in CAMWorks 2020 SP0 or later versions.

26. PROBE_FIXTURE_OFFSET_NUM
Type Integer
Stores the Probe Cycle’s Fixture Offset number.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.

27. PROBE_UPDATE_OFFSET_TYPE
Type Integer
Stores the Probe Cycle’s Work Coordinate Offset type.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.
PROBE_UPDATE_OFFSET_TYPE=NONE
Syntax/ FIXTURE
Example: WORK_COORDINATE
WORK_AND_SUB_COORDINATE

28. HAVE_PROBE_CYCLE
Type Integer
For a Probe Cycle, this variable stores a binary value that indicates whether
Purpose: the next move is a Probe Cycle or not.
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: HAVE_PROBE_CYCLE =TRUE or FALSE

43
What’s New in UPG-2 for CAMWorks 2020 SP0

29. PROBE_CYCLE_TYPE
Type Integer
Stores the Probe Cycle’s type.
Purpose:
To be used in CAMWorks 2020 SP0 or later versions.
PROBE_CYCLE_TYPE= SURFACE_X_TOOLPATH
SURFACE_Y_TOOLPATH
SURFACE_Z_TOOLPATH
WEB_X_TOOLPATH
WEB_Y_TOOLPATHPOCKET_X_TOOLPATH
POCKET_X_TOOLPATH
POCKET_Y_TOOLPATH
Syntax/
Example:
POCKET_WITH_ISLAND_X_TOOLPATH
POCKET_WITH_ISLAND_Y_TOOLPATH
BOSS_TOOLPATH
BORE_TOOLPATH
BORE_WITH_ISLAND_TOOLPATH
THREE_POINT_BOSS_TOOLPATH
THREE_POINT_BORE_TOOLPATH
THREE_POINT_BORE_WITH_ISLAND_TOOLPATH

New - System Variables


1. OPR_IS_PRIMARY
Type Integer
For Turn or Mill-Turn posts, this variable stores a binary value indicating
which operation is primary for the purpose of syncing turrets in Simultaneous
Purpose: Turning.
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: OPR_IS_PRIMARY=TRUE or FALSE

2. CL_COMMENT
Type Character
Stores the CL comment. If comment is selected, then the string will be output
Purpose: as a comment to the controller.
To be used in CAMWorks 2020 SP0 or later versions.

3. CL_COMMAND
Type Character
Stores the CL command. If command is selected, then the string will be
Purpose: output as a command to the controller.
To be used in CAMWorks 2020 SP0 or later versions.

44
What’s New in UPG-2 for CAMWorks 2020 SP0

4. IS_SUB_SPINDLE_REVERSE_Z
Type Integer
Stores a binary value (TRUE or FALSE) that indicates if the user has flipped
Purpose: the Z direction on the Sub Spindle coordinate system.
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: IS_SUB_SPINDLE_REVERSE_Z=TRUE or FALSE

5. MACH_NUMBER_AXIS
Type Integer
Stores how many axes the system has been setup for and what was selected
Purpose: in a Multiaxis operation.
To be used in CAMWorks 2020 SP0 or higher versions.
Syntax: MACH_NUMBER_AXIS=3, 4 or 5

6. MACH_ROTARY_4AXIS_TYPE
Type Integer
Stores what 4-Axis type the system has been setup for.
To be used in CAMWorks 2020 SP0 or higher versions.
MACH_ROTARY_4AXIS_TYPE=ROTATE_ABOUT_X
Purpose:
ROTATE_ABOUT_Y
ROTATE_ABOUT_Z
ROTATE_ABOUT_MULTIPLE

7. MACH_ROTARY_5AXIS_TYPE
Type Integer
Stores what 5-Axis type the system has been setup for.
To be used in CAMWorks 2020 SP0 or higher versions.
MACH_ROTARY_5AXIS_TYPE=ROTATE_ABOUT_X
Purpose:
ROTATE_ABOUT_Y
ROTATE_ABOUT_Z
ROTATE_ABOUT_MULTIPLE

8. MACH_ROTARY_VEC_4X
Type Decimal
Stores the 4th axis rotary vector for X.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.

9. MACH_ROTARY_VEC_4Y
Type Decimal
Stores the 4th axis rotary vector for Y.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.
45
What’s New in UPG-2 for CAMWorks 2020 SP0

10. MACH_ROTARY_VEC_4Z
Type Decimal
Stores the 4th axis rotary vector for Z.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.

11. MACH_ROTARY_VEC_5X
Type Decimal
Stores the 5th axis tilt vector for X.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.

12. MACH_ROTARY_VEC_5Y
Type Decimal
Stores the 5th axis tilt vector for Y.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.

13. MACH_ROTARY_VEC_5Z
Type Decimal
Stores the 5th axis tilt vector for Z.
Purpose:
To be used in CAMWorks 2020 SP0 or higher versions.

New - System Commands


1. GET_SW_CUSTOM_PROP_BY_NAME
Gets SOLIDWORKS Custom properties. If the field is found, the system will
call one of the CALC sections listed below:
• CALC_GET_SW_PROPERTIES
• CALC_GET_SW_SUMMARY_FIELDS
Purpose: • CALC_GET_SW_CUSTOM_FIELDS
• CALC_OUTPUT_SW_PROPERTY
These Calc sections are called with the attribute parameters
QUERY_SW_FIELD_NAME and QUERY_SW_FIELD_VAL.
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: GET_SW_CUSTOM_PROP_BY_NAME({field name}, CALC_?????)
Logic to be used in CALC_START_OF_TAPE
*Outputs SOLIDWORKS Custom and Summary property fields
:C: IF SECTIONEXIST(OUTPUT_SW_PROPERTY) THEN
Logic:
:C: CALL(CALC_GET_SW_PROPERTIES)
:C: ENDIF
*_________________________

46
What’s New in UPG-2 for CAMWorks 2020 SP0

Logic to be used in *SRC File


:SECTION=OUTPUT_SW_PROPERTY
:T:<N> (<QUERY_SW_FIELD_NAME><QUERY_SW_FIELD_VAL> )<EOL>
*______________________________

2. GET_SW_SUMMARY_INFO_BY_ID
Gets SOLIDWORKS Custom properties summary information. If the field is
found, the system will call one the CALC sections listed below:
• CALC_GET_SW_PROPERTIES
Purpose: • CALC_GET_SW_SUMMARY_FIELDS
• CALC_GET_SW_CUSTOM_FIELDS
• CALC_OUTPUT_SW_PROPERTY
To be used in CAMWorks 2020 SP0 or later versions.
Syntax: GET_SW_SUMMARY_INFO_BY_ID(SW_FIELD_ID, CALC_?????)
Constants for SW_FIELD_ID
• SW_INFO_TITLE
• SW_INFO_SUBJECT
Constants: • SW_INFO_AUTHOR
• SW_INFO_KEYWORDS
• SW_INFO_COMMENTS
• SW_INFO_SAVED_BY
If a SW_FIELD_ID is found on executing this command, the system will query
Comment: the result and store the filed type in an integer parameter named
QUERY_SW_FIELD_TYPE.

New - CALC Sections for Probe Cycles


• CALC_LINE_MOVE_PROBE_MILL
• CALC_RAPID_MOVE_PROBE_MILL
• CALC_RAPID_Z_UP_PROBE_MILL
• CALC_RAPID_Z_DOWN_PROBE_MILL
• CALC_FEED_Z_PROBE_MILL
• CALC_OUTPUT_PROBE_CYCLE_MILL

New - CALC Sections for Mill


• CALC_OUTPUT_CL_COMMENT
• CALC_OUTPUT_CL_COMMAND

47
What’s New in UPG-2 for CAMWorks 2020 SP0

New - CALC Sections for SOLIDWORKS


1. CALC_GET_SW_PROPERTIES
Purpose: Used when you need to get SOLIDWORKS Properties.
Syntax: :SECTION=CALC_GET_SW_PROPERTIES
Comments: This section will be called only when it is inserted into the post source.
Logic to be used in CALC_GET_SW_PROPERTIES
:SECTION=CALC_GET_SW_PROPERTIES
:C: IF CAMWORKS_VER<CAM_REV2020 THEN RETURN ENDIF
*
:C: CALL(CALC_OUTPUT_SW_HEADER)
:C: CALL(CALC_GET_SW_SUMMARY_FIELDS)
Logic:
*
:C: CALL(CALC_OUTPUT_SW_HEADER)
:C: CALL(CALC_GET_SW_CUSTOM_FIELDS)
*
:C: CALL(CALC_OUTPUT_SW_HEADER)
*______________________________

2. CALC_GET_SW_SUMMARY_FIELDS
Purpose: Used when you need to get various SOLIDWORKS Summary fields.
Syntax: :SECTION=CALC_GET_SW_SUMMARY_FIELDS
Comments: This section will be called only when it is inserted into the post source.
Logic:
Logic to be used in CALC_GET_SW_SUMMARY_FIELDS
:SECTION=CALC_GET_SW_SUMMARY_FIELDS
:C: IF CAMWORKS_VER<CAM_REV2020 THEN RETURN ENDIF
:C: GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_AUTHOR,CALC_OUTPUT_SW_PROPERTY)
:C: GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_KEYWORDS,CALC_OUTPUT_SW_PROPERTY)
:C: GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_COMMENTS,CALC_OUTPUT_SW_PROPERTY)
:C: GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_TITLE,CALC_OUTPUT_SW_PROPERTY)
:C: GET_SW_SUMMARY_INFO_BY_IDD(SW_INFO_SUBJECT,CALC_OUTPUT_SW_PROPERTY)
:C:
GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_CREATION_DATE,CALC_OUTPUT_SW_PROPERTY)
:C:
GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_SAVED_DATE,CALC_OUTPUT_SW_PROPERTY)
:C: GET_SW_SUMMARY_INFO_BY_ID(SW_INFO_SAVED_BY,CALC_OUTPUT_SW_PROPERTY)
*______________________________

48
What’s New in UPG-2 for CAMWorks 2020 SP0

3. CALC_GET_SW_CUSTOM_FIELDS
Purpose: Used when you need to get SOLIDWORKS Custom fields.
Syntax: :SECTION=CALC_GET_SW_CUSTOM_FIELDS
Comments: This section will be called only when it is inserted into the post source.
Logic:
Logic to be used in CALC_GET_SW_CUSTOM_FIELDS
:SECTION=CALC_GET_SW_CUSTOM_FIELDS
:C: IF CAMWORKS_VER<CAM_REV2020 THEN RETURN ENDIF
:C: GET_SW_CUSTOM_PROP_BY_NAME({CAMWorks Machine},CALC_OUTPUT_SW_PROPERTY)
*______________________________

4. CALC_OUTPUT_SW_PROPERTY
Used when you need to output SOLIDWORKS Custom and Summary Property
Purpose:
fields.
Syntax: :SECTION=CALC_OUTUT_SW_PROPERTY
Comments: This section will be called only when it is inserted into the post source.

Logic to be used in CALC_OUTPUT_SW_PROPERTY


:SECTION=CALC_OUTPUT_SW_PROPERTY
:C: IF CAMWORKS_VER<CAM_REV2020 THEN RETURN ENDIF
:C: IF QUERY_SW_FIELD_VAL={} THEN RETURN ENDIF
Logic:
:C: IF SECTIONEXIST(OUTPUT_SW_PROPERTY) THEN
:C: CALL(OUTPUT_SW_PROPERTY)
:C: ENDIF
*______________________________

New - Attribute Commands


1. QUERY_SW_FIELD_NAME
Purpose: Indicates the name of the field within SOLIDWORKS Custom Properties.
:ATTRNAME=QUERY SW FIELD NAME
:ATTRTYPE=POST
:ATTREMARK=
:CODETYPE=FORMAT
:WORD_ADDRESS_BEF=|
:VAR=QUERY_SW_FIELD_NAME
Post :WORD_ADDRESS_AFT=|:
Example: :LEFT_PLACES=0
:RIGHT_PLACES=0
:UNITFLAG=NON_CONVERT
:ATTRSPACES=YES
:MODAL=NO
:ATTRUSED=1
:ATTREND

49
What’s New in UPG-2 for CAMWorks 2020 SP0

2. QUERY_SW_FIELD_VAL
Indicates the character string value in the field within SOLIDWORKS Custom
Purpose:
Properties.
:ATTRNAME=QUERY SW FIELD VAL
:ATTRTYPE=POST
:ATTREMARK=
:CODETYPE=FORMAT
:WORD_ADDRESS_BEF=|
:VAR=QUERY_SW_FIELD_VAL
Post :WORD_ADDRESS_AFT=
Example: :LEFT_PLACES=0
:RIGHT_PLACES=0
:UNITFLAG=NON_CONVERT
:ATTRSPACES=YES
:MODAL=NO
:ATTRUSED=1
:ATTREND

3. QUERY_SW_FIELD_TYPE
If a SW Field ID is found on executing the
GET_SW_SUMMARY_INFO_BY_ID(SW_FIELD_ID,CALC_?????) command,
the system will query the result and store the filed type in an integer
parameter named QUERY_SW_FIELD_TYPE. This attribute parameter
indicates the type of field found.
Purpose:
• If the field type is a SW_NUMBER, the system will store the field integer
value in QUERY_INT_VAL.
• If the field type is a SW_DECIMAL, the system will store the field double
value in QUERY_DEC_VAL.
Constants for the QUERY_SW_FIELD_TYPE:
• SW_UNKNOWN
• SW_NUMBER
Constants: • SW_DOUBLE
• SW_YES_NO
• SW_TEXT
• SW_DATE

New - System Constants


Name Value
SURFACE_X_TOOLPATH 1
SURFACE_Y_TOOLPATH 2
SURFACE_Z_TOOLPATH 3
WEB_X_TOOLPATH 4
WEB_Y_TOOLPATH 5
POCKET_X_TOOLPATH 6
POCKET_Y_TOOLPATH 7
POCKET_WITH_ISLAND_X_TOOLPATH 8

50
What’s New in UPG-2 for CAMWorks 2020 SP0

Name Value
POCKET_WITH_ISLAND_Y_TOOLPATH 9
BOSS_TOOLPATH 10
BORE_TOOLPATH 11
BORE_WITH_ISLAND_TOOLPATH 12
THREE_POINT_BOSS_TOOLPATH 13
THREE_POINT_BORE_TOOLPATH 14
THREE_POINT_BORE_WITH_ISLAND_TOOLPATH 15
FIXTURE 1
UPDATE_WORK_OFFSETS_CYCLE 1
WORK_COORDINATE 2
WORK_AND_SUB_COORDINATE 3
MILL_PROBING 1060
ROTATE_ABOUT_X 1
ROTATE_ABOUT_Y 2
ROTATE_ABOUT_Z 3
ROTATE_ABOUT_MULTIPLE 0

New - System Constants for SOLIDWORKS


Name Value
SW_INFO_TITLE 200
SW_INFO_SUBJECT 1
SW_INFO_AUTHOR 2
SW_INFO_KEYWORDS 3
SW_INFO_COMMENTS 4
SW_INFO_SAVED_BY 5
SW_INFO_CREATION_DATE 6
SW_INFO_SAVED_DATE 7
SW_UNKNOWN 0
SW_NUMBER 3
SW_DOUBLE 5
SW_YES_NO 11
SW_TEXT 30
SW_DATE 64

New - Additional System Constants


Name Value
CAM_REV2020 200

51
What’s New in UPG-2 for CAMWorks 2020 SP0

New - Query Commands


1. QUERY_TOOL_ID_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_TOOL_ID_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID=QUERY_TOOL_ID_COMMENT
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

2. QUERY_TOOL_VENDOR_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_TOOL_VENDOR_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number
Length of characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this
command.
:C: QUERY_ITEM_ID=QUERY_TOOL_VENDOR_COMMENT
Comments:
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

52
What’s New in UPG-2 for CAMWorks 2020 SP0

3. QUERY_TOOL_DESCRIPTION_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_TOOL_DESCRIPTION_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID=QUERY_TOOL_DESCRIPTION_COMMENT
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

4. QUERY_HOLDER_NUM_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_HOLDER_NUM_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID=QUERY_HOLDER_NUM_COMMENT
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

5. QUERY_HOLDER_VENDOR_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_HOLDER_VENDOR_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:
The example code below shows the other variables used with this command.
:C: QUERY_ITEM_ID=QUERY_HOLDER_VENDOR_COMMENT
Comments: :C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF
53
What’s New in UPG-2 for CAMWorks 2020 SP0

6. QUERY_HOLDER_DESCRIPTION_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_HOLDER_DESCRIPTION_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:

The example code below shows the other variables used with this
command.
Comments:
:C: QUERY_ITEM_ID=QUERY_HOLDER_DESCRIPTION_COMMENT
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

7. QUERY_STATION_DESCRIPTION_COMMENT
If the return value of QUERY_RESULT is TRUE, then the system will pass a
Purpose: string value to post system variable named QUERY_CHAR_VAL.
To be used in CAMWorks 2020 SP0 or higher versions.

Syntax: QUERY_ITEM_ID=QUERY_STATION_DESCRIPTION_COMMENT

Max. The max character length allowed for the string value assigned to this
Character parameter is 100 characters. Any extra character after this allowed number of
Length characters will not be passed on to post system variable named
QUERY_CHAR_VAL.
Associated commands and variables:

The example code below shows the other variables used with this
command.
Comments
:C: QUERY_ITEM_ID=QUERY_STATION_DESCRIPTION_COMMENT
:C: QUERY_SYSTEM()
:C: IF QUERY_RESULT=1 THEN
:C: Char post variable=QUERY_CHAR_VAL
:C: ENDIF

54
What’s New in UPG for CAMWorks 2019 SP2

What’s New in UPG for CAMWorks 2019 SP2


New - System Header Commands
1. :FORCE_UPPERCASE_OUTPUT
Type Integer
Sets the posted output to be all upper case.
Purpose:
To be used in CAMWorks 2019 SP2 or higher versions.
Syntax: :FORCE_UPPERCASE_OUTPUT= TRUE or FALSE

New - Attribute Commands


1. MUST_BE_LOWERCASE
:ATTRNAME=OPR COMMENT
:ATTRTYPE=POST
:ATTREMARK=
:CODETYPE=FORMAT
:WORD_ADDRESS_BEF=|(
:VAR=OPR COMMENT
:WORD_ADDRESS_AFT=)
Post
:LEFT_PLACES=0
Example:
:RIGHT_PLACES=0
:UNITFLAG=NON_CONVERT
:ATTRSPACES=YES
:MODAL=NO
:MUST_BE_LOWERCASE
:ATTRUSED=1
:ATTREND

2. MUST_BE_UPPERCASE
:ATTRNAME=OPR COMMENT
:ATTRTYPE=POST
:ATTREMARK=
:CODETYPE=FORMAT
:WORD_ADDRESS_BEF=|(
:VAR=OPR COMMENT
:WORD_ADDRESS_AFT=)
Post
:LEFT_PLACES=0
Example:
:RIGHT_PLACES=0
:UNITFLAG=NON_CONVERT
:ATTRSPACES=YES
:MODAL=NO
:MUST_BE_UPPERCASE
:ATTRUSED=1
:ATTREND

55
What’s New in UPG for CAMWorks 2019 SP1

What’s New in UPG for CAMWorks 2019 SP1


New - System Header Commands
1. :ALLOW_B_AXIS_SIMULTANEOUS_CUTTING
Allows Simultaneous B Axis movement in Rough and Contour Turn operations.
Purpose: If set to FALSE, this option will not be available in post.
If set to TRUE, this option will be available in post.
Syntax: :ALLOW_B_AXIS_SIMULTANEOUS_CUTTING = TRUE or FALSE
If this header is not in the post SRC file, then this option will not be available.
Comments:
To be used in CAMWorks 2019 and higher versions.

New - Variables
1. OPR_START_APPROACH_TYPE
Type Integer
Stores the Turn operations approach type for canned cycles. To be used in
Purpose:
CAMWorks 2019 SP1 or higher versions.
OPR_START_APPROACH_TYPE=AUTO
Or
Syntax: OPR_START_APPROACH_TYPE=FROM_PREVIOUS_POS
Or
OPR_START_APPROACH_TYPE=FROM_APPROACH_POS

2. OPR_X_APPROACH_POS
Type Decimal
Stores X Approach Position in Turning associated with canned cycles. To be
Purpose:
used in CAMWorks 2019 SP1 or higher versions.

3. OPR_Z_APPROACH_POS
Type Decimal
Stores Z Approach Position in Turning associated with canned cycles. To be
Purpose:
used in CAMWorks 2019 SP1 or higher versions.

4. NEXT_OPR_BAXIS_TURNING
Type Integer
Stores whether the next operation is a simultaneous X,Z, B axis turning
Purpose: operation or not. The value will be TRUE or FALSE. To be used in CAMWorks
2019 SP1 or higher versions.
Syntax: NEXT_OPR_BAXIS_TURNING=TRUE or FALSE

56
What’s New in UPG for CAMWorks 2019 SP1

5. MAX_B_AXIS_INCREMENT
Type Decimal
This needs to be set for breaking up a Turn operation's X, Z and B axis
simultaneous toolpath using the SYS_CANNED(7,????) command when in a
Purpose: line or arc move.
To be used in CAMWorks 2019 SP1 or later versions.
:SECTION=CALC_ARC_MOVE_LATHE
:C: MAX_B_AXIS_INCREMENT=Post Variable
:C: SYS_CANNED(7,CALC_BREAK_ARC_TO_ARC_LATHE)
*:C: SYS_CANNED(7, CALC_BREAK_RADIAL_ARC_TO_ARC_LATHE)
:C: RETURN

:SECTION=CALC_BREAK_ARC_TO_ARC_LATHE
:C: X_POS=ABS_X_END
:C: Z_POS=ABS_Z_END
:C: CALL(ARC_MOVE_LATHE)
*-----------------------------------
:SECTION=CALC_BREAK_RADIAL_ARC_TO_ARC_LATHE
:C: X_POS=ABS_X_END
Example: :C: Z_POS=ABS_Z_END
:C: CALL(RADIUS_MOVE_LATHE)

Lines can also be broken as follows:

:SECTION=CALC_LINE_MOVE_LATHE
:C: MAX_B_AXIS_INCREMENT=1.
:C: SYS_CANNED(7,CALC_BREAK_LINE_LATHE)
:C: RETURN

:SECTION= CALC_BREAK_LINE_LATHE
:C: X_POS=ABS_X_END
:C: Z_POS=ABS_Z_END
:C: CALL(LINE_MOVE_LATHE)

6. NUM_OPERATIONS_FRONT1
Type Integer
Stores the total number of operations in any part that are associated with
Purpose: FRONT1 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

57
What’s New in UPG for CAMWorks 2019 SP1

7. NUM_OPERATIONS_FRONT2
Type Integer
Stores the total number of operations in any part that are associated with
Purpose: FRONT2 Turret.
To be used in CAMWorks 2019 SP1 or higher versions.

8. NUM_OPERATIONS_Rear1
Type Integer
Stores the total number of operations in any part that are associated with
Purpose: REAR1 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

9. NUM_OPERATIONS_Rear2
Type Integer
Stores the total number of operations in any part that are associated with
Purpose: REAR2 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

10. NUM_SYNC_CODES_REAR1
Type Integer
Stores the total number of sync codes in any part that are associated with
Purpose: REAR1 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

11. NUM_SYNC_CODES_REAR2
Type Integer
Stores the total number of sync codes in any part that are associated with
Purpose: REAR2 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

12. NUM_SYNC_CODES_FRONT1
Type Integer
Stores the total number of sync codes in any part that are associated with
Purpose: FRONT1 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

58
What’s New in UPG for CAMWorks 2019 SP1

13. NUM_SYNC_CODES_FRONT2
Type Integer
Stores the total number of sync codes in any part that are associated with
Purpose: FRONT2 turret.
To be used in CAMWorks 2019 SP1 or higher versions.

14. OPR_BAXIS_TURNING
Type Integer
Stores whether the operation is a simultaneous X,Z, B axis turning operation
Purpose: or not. The value will be TRUE or FALSE. To be used in CAMWorks 2019 SP1
or higher versions.
Syntax: OPR_BAXIS_TURNING=TRUE or FALSE

15. OPR_TOOL_TIP_CENTER
Type Integer
Stores whether the user has selected Tool Nose Center or Tool Nose tip for a
Purpose: Turn operation.
To be used in CAMWorks 2019 SP1 and later versions.

16. TLP_B_AXIS_OFFSET / P_TLP_B_AXIS_OFFSET


Type Decimal
Stores the current and previous incremental B axis rotation of a Turn
Purpose: operation that uses simultaneous X,Z and B axis toolpath.
To be used in CAMWorks 2019 SP1 or higher versions.

59
What’s New in UPG for CAMWorks 2019 SP1

New - Query Commands


1. QUERY_INT_CENTER_TOUCHOFF_REG
This command will query whether the user has selected tool nose center or
tool nose tip in a turn operation. This is used in conjunction with IMS
Purpose: Simulator. Available in Turn and Mill-Turn.
Supported in CAMWorks 2019 SP1 and later versions. Not supported in any
ProCAM product.
Syntax: QUERY_ITEM_ID=QUERY_INT_CENTER_TOUCHOFF_REG
Comments: The example code below shows the other variables used with this command.

Logic to be used in SECTION=CALC_QUERY_POST


:C: IF OPR_TOOL_TIP_CENTER=1 THEN
:C: IF HAVE_SUB_STATIONS=FALSE THEN
:C: IF QUERY_ITEM_ID =
QUERY_INT_CENTER_TOUCHOFF_REG THEN
:C: IF SECTIONEXIST(QUERY_TOUCHOFF_CENTER)
THEN
:C: CALL(QUERY_TOUCHOFF_CENTER)
:C: ELSE
:C: QUERY_INT_VAL=(TOOL+1)
:C: ENDIF
:C: ENDIF
Logic:
:C: ELSE
:C: IF QUERY_ITEM_ID =
QUERY_INT_CENTER_TOUCHOFF_REG THEN
:C: IF
SECTIONEXIST(QUERY_TOUCHOFF_CENTER_SUB_STATIONS) THEN
:C: CALL(QUERY_TOUCHOFF_CENTER_SUB_STATIONS)
:C: ELSE
:C: QUERY_INT_VAL=((SUB_STATION*10)+2)
:C: ENDIF
:C: ENDIF
:C: ENDIF
:C: ENDIF

New - System Constants


Name Value
FROM_PREVIOUS_POS 1
FROM_APPROACH_POS 2
CAM_REV2019_SP2

60

You might also like