This commit is contained in:
2024-02-15 16:50:34 +01:00
parent bbc018b19f
commit 5923babd63
3 changed files with 23 additions and 21 deletions
+2 -1
View File
@@ -17,7 +17,8 @@ OPT_CXXFLAGS_YES = -O3
# dependencies
ECmasterECMC_VERSION = v1.1.0
# motorECMC_VERSION = 7.0.7-ESS
ecmc_VERSION = v9.0.1_RC4
#ecmc_VERSION = v9.0.1_RC4
ecmc_VERSION = sandst_a
################################################################################
# THIS RELATES TO THE EtherCAT MASTER LIBRARY
+16 -15
View File
@@ -120,10 +120,10 @@ controller:
trajectory:
# type: 1 # Default 0 = trapetz, 1 = S-curve (ruckig)
axis:
velocity: 100 # Default velo for axis
acceleration: 100 # Default acc for axis
deceleration: 100 # Default dec for axis
# emergencyDeceleration: 0.05 # Deceleration when axis in error state
velocity: 500 # Default velo for axis
acceleration: 200 # Default acc for axis
deceleration: 200 # Default dec for axis
emergencyDeceleration: 500 # Deceleration when axis in error state
jerk: 10 # Default jerk for axis
jog:
velocity: 5 # Default velo fro JOG (motor record)
@@ -169,7 +169,8 @@ monitoring:
enable: true # Enable position lag monitoring (following error)
tolerance: 2 # Allowed tolerance
time: 10 # Allowed time outside tolerance target:
enable: false # Enable at target monitoring (needs to be enabled if using motor record)
target:
enable: true # Enable at target monitoring (needs to be enabled if using motor record)
tolerance: 0.5 # Allowed tolerance
time: 10 # Filter time inside tolerance to be at target
velocity:
@@ -185,16 +186,16 @@ monitoring:
# trajectory: 100 # Time allowed outside max diff velo before system init halt
# drive: 200 # Time allowed outside max diff velo before system disables drive
plc:
enable: true # Enable axis plc
externalCommands: true # Allow axis to inputs from PLC
file: ${PLC_PATH}test.plc
code: # Sync code
- "if(static.counter % ${LIMIT} == 0){println('AX PLC: Appended');static.counter:=0;};" # calculate set pos for physical axis
- "if(not(static.plc_code_loaded)) {static.counter:=static.counter+1;};"
- ec0.s$(DRV_SLAVE).ONE > 1; # Enable axis if one of master axes is enabled
- ec0.s$(DRV_SLAVE).ZERO > 1; # calculate set pos for physical axis
# velocity_filter: # Filter used to smother velocity feedforward
#plc:
# enable: true # Enable axis plc
# externalCommands: true # Allow axis to inputs from PLC
# file: ${PLC_PATH}test.plc
# code: # Sync code
# - "if(static.counter % ${LIMIT} == 0){println('AX PLC: Appended');static.counter:=0;};" # calculate set pos for physical axis
# - "if(not(static.plc_code_loaded)) {static.counter:=static.counter+1;};"
# - ec0.s$(DRV_SLAVE).ONE > 1; # Enable axis if one of master axes is enabled
# - ec0.s$(DRV_SLAVE).ZERO > 1; # calculate set pos for physical axis
# velocity_filter: # Filter used to smother velocity feedforward
# encoder: # Filter plc enc velo
# enable: false # Filter enable
# size: 100 # Filter size
+5 -5
View File
@@ -1,11 +1,11 @@
##############################################################################
## Example config for el7031
require ecmccfg v9.0.1_RC4,"ECMC_VER=v9.0.1_RC4,ENG_MODE=1"
require ecmccfg v9.0.1_RC4,"ECMC_VER=sandst_a,ENG_MODE=1"
epicsEnvSet(IOC,c6025a)
# Load components lib
require ecmccomp sandst_a
require ecmccomp
##############################################################################
## Configure hardware
@@ -16,7 +16,7 @@ ${SCRIPTEXEC} ${ecmccomp_DIR}applyComponent.cmd "COMP=Motor-Generic-2Phase-Stepp
epicsEnvSet("ENC_SLAVE", "14")
${SCRIPTEXEC} ${ecmccfg_DIR}addSlave.cmd, "SLAVE_ID=$(ENC_SLAVE), HW_DESC=EL5042"
${SCRIPTEXEC} ${ecmccomp_DIR}applyComponent.cmd "COMP=Encoder-RLS-LA11-24bit"
${SCRIPTEXEC} ${ecmccomp_DIR}applyComponent.cmd "COMP=Encoder-RLS-LA11-24bit-BISS-C"
#Apply hardware configuration
ecmcConfigOrDie "Cfg.EcApplyConfig(1)"
@@ -31,7 +31,7 @@ ${SCRIPTEXEC} ${ECMC_CONFIG_ROOT}loadYamlAxis.cmd, "FILE=./cfg/axis.yaml,LIMIT=1
##############################################################################
## PLC 1
#
${SCRIPTEXEC} ${ECMC_CONFIG_ROOT}loadYamlPlc.cmd, "FILE=./plc/plc_cfg.yaml,LIMIT=5000,TYPE=1"
#-${SCRIPTEXEC} ${ECMC_CONFIG_ROOT}loadYamlPlc.cmd, "FILE=./plc/plc_cfg.yaml,LIMIT=5000,TYPE=1"
##############################################################################
## Load safety plugin
@@ -40,7 +40,7 @@ ${SCRIPTEXEC} ${ECMC_CONFIG_ROOT}loadYamlPlc.cmd, "FILE=./plc/plc_cfg.yaml,LIMIT
require ecmc_plugin_safety sandst_a "PLUGIN_ID=0"
ecmcAddSafetyGroup("first","ec${ECMC_EC_MASTER_ID}.s${DRV_SLAVE}.ONE.0","ec${ECMC_EC_MASTER_ID}.s${DRV_SLAVE}.ONE.1",500)
ecmcAddSafetyGroup("first","ec${ECMC_EC_MASTER_ID}.s${DRV_SLAVE}.ZERO.0","ec${ECMC_EC_MASTER_ID}.s${DRV_SLAVE}.ZERO.1",500)
ecmcAddAxisToSafetyGroup("first",1,1,0)
##############################################################################