Files
ecmc_plugin_safety/scripts/addAxisToSafetyGroup.cmd
2025-02-26 14:51:27 +01:00

36 lines
1.7 KiB
Batchfile

#==============================================================================
# addAxisToSafetyGroup.cmd
#-
#- !!!!!!!!!!!!! IMPORTANT !!!!!!!!!
#- This plugin has _NO_ safety rated functionalities.
#- The intended use of this plugin is only to handle interfacing with a safety PLC.
#-
#-------------- Information:
#- Description: add axis to group
#-
#- by Anders Sandström, Paul Scherrer Institute, 2023
#- email: anders.sandstroem@psi.ch
#-
#-###############################################################################
#-
#- Arguments:
#- NAME : Name of safety group
#- AX_ID : Axis ID
#- VELO_REST_LIM : Velocity at rest limit [unit same as EGU of axis]
#- VELO_MAX_LIM : Velocity maximum limit when EC_RED_VEL_CMD, set to -1 to disable [unit same as EGU of axis]
#-
#################################################################################
#- ecmcAddAxisToSafetyGroup(<group_name>, <axis_index>, <velo_limit>, <filter_time>)
#- <name> : Name of safety group to add axis to.
#- <Axis id> : Axis index to add (ecmc axis index).
#- <velo_rest_limit> : Axis at rest velo limit [unit of axis].
#- <velo_max_limit> : Velocity maximum limit when EC_RED_VEL_CMD, set to -1 to disable [unit same as EGU of axis]
#- <filter_time> : NOT USED (for future implemenation). Time for axis to be below velo limit [ms].
ecmcAddAxisToSafetyGroup("${NAME}",${AX_ID},${VELO_REST_LIM=0},0,${VELO_MAX_LIM=0.0})
#- Load SS1 axis records
dbLoadRecords("ecmcSS1Axis.template","AXIS_PREFIX=${ECMC_MOTOR_${AX_ID}_FULL_NAME=},NAME=${NAME},VEL_MAX_LIM=${VELO_MAX_LIM=0.0},VEL_REST_LIM=${VELO_REST_LIM=0.0}")