; Renishaw Productivity+ Custom Macro
; Do NOT remove the preceeding line or this macro will not load
; Definition File for TS27/R Contact Toolsetting Tool Length/Diameter Setting
; Version: 0.01.

[FileType]
; Do NOT remove this section or this Custom Macro will not load
Product		Renishaw Productivity+
File		Custom Macro
Version		0.07.002

[MachineType]
MACHINETYPE Siemens

[Toolsetting Type]
"Contact"

; Definition File Language - language of displayable text strings in this file
[Language]
English

; Existing Menu Item in application that Custom Macro name and its Parent Menu are to appear under
; FIELD CAN BE OMITTED
[Existing Menu]
"Tool setting"

; Parent Menu - used as parent menu item text 
; FIELD CAN BE OMITTED
[Parent Menu]
"Contact (TS27R, TS20, OTS...)"

; Custom Macro Name - used as menu item text. ID MUST BE UNIQUE FOR EACH CUSTOM MACRO!
; FIELD IS COMPULSORY
[Custom Macro]
; Name												ID
"Five-Face Broken Tool - Length (Siemens)"			48833

; This field specifies the default name given to a statement of this type
; The name must NOT include any of the following characters and cannot start with a numeric character
; {}[]/\:<>@~#-=+()*&^%$£!"`¬|;,.'?
[Default Statement Name]
"Broken_Tool_Length"

; Name or Program Number of macro
[MacroID]
9858

; Properties - Do not use IDs 1-19
; Name										ID	Datatype	Default		Range		Category	Output Parameter	Metafile ID (optional)	Help Text			
[Properties]
"Controller Type"							50	CNC_TYPE	0			{NA}			100				-			12050				"Type of target controller"

"Use the Tool Diameter (R7)"				20	YESNO		NO			{NA}		  100		-					12050				"Set this value to 'Yes' to specify the tool Diameter. Specifying the tool diameter enables the tool to be offset from the datum stylus. Without a R7 input, the tool is checked on-centre."
"Tool Diameter (R7)"						21	LINEAR		0			NE0		      100		CM_D				12050				"Applying the tool diameter causes the tool to be offset from the stylus centre line"

"Tolerance value (R11)"						22	YESNO		NO			{NA}		  100		CM_					12050				"The tolerance value when checking for a broken tool. If there is no R11=h input, then the feed rate in 'RENC[1]' is used only if the tool is on centre and only one touch is used. If the R11=h value is less than 0.5 then the standard two touch feed rates are used."
"Use Tolerance value (R11)"					23	LINEAR		0.5			{NA}		  100		CM_H				12050				"Default value 0.5."

"Use out of tolerance flag (R13)"			24	YESNO		NO			{NA}		  100		-					12050				"Tool out of tolerance flag. This is set when the measured tool is out of tolerance provided the R11 input is used."
"Prevents alarm (R13)"						25	INT			1			EQ0		   	  100		CM_M				12050				"Using R13=1 will  prevent a tool OUT OF TOLERANCE alarm from being raised NOTE 'RENC[48]' is the out of tolerance flag. It is set to 1 if the tool is out of tolerance and set to 0 if in tolerance."

"Use Current Tool Change ID (R20)"			28	YESNO		YES			{NA}		  100		-					12050				"The the tool length edge (D)offset value will be checked. By default, the current active tool edge is read.  Using R20=3 will read offset edge D3 of the active tool."
"Tool Length Offset Number (R20)"			29	INT			0			GT0:LE999	  100		CM_T				12050				"Tool length edge number(D)to be updated."

"Use Rapid position above the stylus (R25)"	30	YESNO		NO			{NA}		  100		-					12050				"Sends the tool to a position above the stylus in a rapid move. if set to NO, the tool is positioned to 'REN[15]'in the settings subroutine L9750."
"Rapid position above the stylus (R25)"		31	LINEAR		0			GT0			  100		CM_Y				12050				"Rapid to a position above the sylus."

"Use Clearance position (R26)"				32	YESNO		NO			{NA}		  100		-					12050				"Set this value to 'Yes' to specify the clearance position above the stylus after the cycle has been run. When set to 'No' the tool will retract to the home position before and after the cycle is run. IMPORTANT... The tool offset will need to be re-applied if the tool is to be used again."
"Clearance position (R26)"					33	LINEAR		0			GT0			  100		CM_Z				12050				"The tool moves to this clearance position above the stylus after the cycle is run."


[Visibility]

PROPERTIES	25
CTRL_PROPS		24 ("Use out of tolerance flag (R13)")
CTRL_VALUES		2 ("YES")

PROPERTIES	33
CTRL_PROPS		32 ("Use Clearance position (R26)")
CTRL_VALUES		2 ("YES")

PROPERTIES	23
CTRL_PROPS		22 ("Do Tolerance Check")
CTRL_VALUES		2 ("YES")


PROPERTIES	21
CTRL_PROPS		20 ("Use the Tool Diameter (R7)")
CTRL_VALUES		2 ("YES")


PROPERTIES	29
CTRL_PROPS		28 ("Use Current Tool Change ID (R20)")
CTRL_VALUES		1 ("NO")

PROPERTIES	31
CTRL_PROPS		30 ("Rapid position above the stylus (R25)")
CTRL_VALUES		2 ("YES")

[Enums]
; N.B. When post processing, the selected enum item ID will be outputted with the Output Parameter.
;	e.g.	enum type			: YESNO
;			selected enum item	: YES
;			enum item value		: 1
;			Output Parameter	: CM_B
;			Output				= B1
;												ID		Index (order in which they will appear)
ENUM_NAME		MEAS_TYPE						
ENUM_ITEM		"Broken Tool Length"			6		0

ENUM_NAME		CNC_TYPE						
ENUM_ITEM		"Siemens"						0		0


[Categories]
; Name							ID
"Nominals"						100

[Resources]
; Path and File name of resource DLL containing metafiles (optional)
PP_tsToolSettingRes.dll

; The post processor section to call when post processing occurs
[Post Section]
TOOLSETTING_CUSTOM_MACRO_CONTACT_TOOL_CHANGE
