From aae6cacd3ecc379cb2be75712d01b6bad2170993 Mon Sep 17 00:00:00 2001 From: kpetersn Date: Wed, 10 Apr 2019 15:35:57 -0500 Subject: [PATCH] Removed PhytronSrc; Added motorPhytron submodule --- .gitmodules | 3 + .../iocWithAsyn/motor.substitutions.phytron | 50 - iocBoot/iocWithAsyn/st.cmd.phytron | 24 - modules/Makefile | 1 + modules/motorPhytron | 1 + motorApp/Db/Makefile | 1 - motorApp/Db/Phytron_I1AM01.db | 1092 ------ motorApp/Db/Phytron_MCM01.db | 223 -- motorApp/Db/Phytron_motor.db | 23 - motorApp/Makefile | 3 - motorApp/PhytronSrc/Makefile | 23 - motorApp/PhytronSrc/README.txt | 447 --- motorApp/PhytronSrc/phytron.dbd | 1 - motorApp/PhytronSrc/phytronAxisMotor.cpp | 1034 ----- motorApp/PhytronSrc/phytronAxisMotor.h | 172 - motorApp/op/opi/PhytronI1AM01.opi | 3389 ----------------- motorApp/op/opi/PhytronI1AM01Status.opi | 2240 ----------- motorApp/op/opi/PhytronMCM01Status.opi | 1582 -------- motorApp/op/opi/PhytronMain.opi | 441 --- motorExApp/WithAsyn/Makefile | 2 - 20 files changed, 5 insertions(+), 10747 deletions(-) delete mode 100644 iocBoot/iocWithAsyn/motor.substitutions.phytron delete mode 100644 iocBoot/iocWithAsyn/st.cmd.phytron create mode 160000 modules/motorPhytron delete mode 100644 motorApp/Db/Phytron_I1AM01.db delete mode 100644 motorApp/Db/Phytron_MCM01.db delete mode 100644 motorApp/Db/Phytron_motor.db delete mode 100644 motorApp/PhytronSrc/Makefile delete mode 100644 motorApp/PhytronSrc/README.txt delete mode 100644 motorApp/PhytronSrc/phytron.dbd delete mode 100644 motorApp/PhytronSrc/phytronAxisMotor.cpp delete mode 100644 motorApp/PhytronSrc/phytronAxisMotor.h delete mode 100644 motorApp/op/opi/PhytronI1AM01.opi delete mode 100644 motorApp/op/opi/PhytronI1AM01Status.opi delete mode 100644 motorApp/op/opi/PhytronMCM01Status.opi delete mode 100644 motorApp/op/opi/PhytronMain.opi diff --git a/.gitmodules b/.gitmodules index 1ffc678e..e10dfc90 100644 --- a/.gitmodules +++ b/.gitmodules @@ -64,3 +64,6 @@ [submodule "modules/motorOmsAsyn"] path = modules/motorOmsAsyn url = https://github.com/epics-motor/motorOmsAsyn.git +[submodule "modules/motorPhytron"] + path = modules/motorPhytron + url = https://github.com/epics-motor/motorPhytron.git diff --git a/iocBoot/iocWithAsyn/motor.substitutions.phytron b/iocBoot/iocWithAsyn/motor.substitutions.phytron deleted file mode 100644 index dc3443f5..00000000 --- a/iocBoot/iocWithAsyn/motor.substitutions.phytron +++ /dev/null @@ -1,50 +0,0 @@ -################################################################################ -# PORT - asynPort created for the Phytron controller -# ADDR - Address of the axis - right digit represents the index of the axis -# of a I1AM01 module, the remaining digit(s) on the lef represent the -# index of the I1AM01 module -################################################################################ - -file "../../db/Phytron_motor.db" -{ -pattern -{P, N, M, DTYP, PORT, ADDR, DESC, EGU, DIR, VELO, VBAS, VMAX, ACCL, BDST, BVEL, BACC, MRES, ERES, PREC, DHLM, DLLM, INIT} -{PHYIOC:, 1, "m$(N)", "asynMotor", phyMotionPort, 11, "motor $(N)", Deg, Pos, 360, 180, 720, .5, 0, 180, .2, 1.8, 0.18, 5, 1440, -1440, ""} -{PHYIOC:, 2, "m$(N)", "asynMotor", phyMotionPort, 21, "motor $(N)", Deg, Pos, 360, 180, 720, .5, 0, 180, .2, 1.8, 0.18, 5, 1440, -1440, ""} - -} - -################################################################################ -# P - MUST MATCH Controller specific name in Phytron_MCM01.db substitution -# pattern (below) -# PORT - asynPort created for the Phytron controller -# ADDR - Address of the axis - right digit represents the index of the axis -# of a I1AM01 module, the remaining digit(s) on the lef represent the -# index of the I1AM01 module -# TIMEOUT - asyn timeout -# SCAN - Periodic scan rate of Power stage temperature and Motor temperature -# records -# INIT - If set to YES, ao records will be initialized with the values defined -# in the macros that follow INIT. If set to NO, records will not be -# initialized - this option is useful if auto save/restore is used -################################################################################ -file "../../db/Phytron_I1AM01.db" -{ -pattern -{P, N, M, PORT, ADDR, SCAN, TIMEOUT, INIT, HOMING, MODE, POS_OFFSET, NEG_OFFSET, INIT_TIME, POS_TIME, BOOST, SWITCH_TYP, PWR_STAGE, ENC_TYP, ENC_SFI, ENC_DIR, STOP_CURR, RUN_CURR, BOOST_CURR, CURRENT_DELAY, STEP_RES, PS_MON } -{PHYIOC, 1, ":m$(N)", phyMotionPort, 11, "1 second", 3, YES, 0, 1, 0, 0, 20, 20, 0, 0, 1, 1, 0, 1 20, 400, 500, 20, 0, 1} -{PHYIOC, 2, ":m$(N)", phyMotionPort, 21, "1 second", 3, YES, 0, 1, 0, 0, 20, 20, 0, 0, 1, 1, 0, 1 20, 400, 500, 20, 0, 1} -} - -################################################################################ -# P - Controller specific name -# PORT - asynPort created for the Phytron controller -# ADDR - Arbitrary value between 0 and 255 -# TIMEOUT - asyn timeout -################################################################################ -file "../../db/Phytron_MCM01.db" -{ -pattern -{P, DTYP, PORT, ADDR, TIMEOUT} -{PHYIOC, "asynMotor", phyMotionPort, 0, 10 } -} diff --git a/iocBoot/iocWithAsyn/st.cmd.phytron b/iocBoot/iocWithAsyn/st.cmd.phytron deleted file mode 100644 index 9e7079d4..00000000 --- a/iocBoot/iocWithAsyn/st.cmd.phytron +++ /dev/null @@ -1,24 +0,0 @@ -#!../../bin/linux-x86_64/phytronAxis - -## You may have to change phytronAxis to something else -## everywhere it appears in this file - -< envPaths - -## Register all support components -dbLoadDatabase("../../dbd/WithAsyn.dbd",0,0) -WithAsyn_registerRecordDeviceDriver(pdbbase) - -#drvAsynIPPortConfigure("testPort","localhost:8000",0,0,1) -drvAsynIPPortConfigure("testRemote","10.5.1.181:22222",0,0,1) - -#phytronCreateController (phytronPort, asynPort, movingPollPeriod, idlePollPeriod, timeout) -phytronCreateController ("phyMotionPort", "testRemote", 100, 100, 1000) - -#phytronCreateAxis(phytronPort, module, axis) -phytronCreateAxis("phyMotionPort", 1, 1) -phytronCreateAxis("phyMotionPort", 2, 1) - -dbLoadTemplate "motor.substitutions.phytron" - -iocInit() diff --git a/modules/Makefile b/modules/Makefile index 79155319..e9c9c951 100644 --- a/modules/Makefile +++ b/modules/Makefile @@ -23,6 +23,7 @@ SUBMODULES += motorNewFocus SUBMODULES += motorNPoint SUBMODULES += motorOmsAsyn SUBMODULES += motorOriel +SUBMODULES += motorPhytron SUBMODULES += motorPiJena SUBMODULES += motorPi SUBMODULES += motorSmartMotor diff --git a/modules/motorPhytron b/modules/motorPhytron new file mode 160000 index 00000000..cb58e209 --- /dev/null +++ b/modules/motorPhytron @@ -0,0 +1 @@ +Subproject commit cb58e209b3cb8115c43f58c002dbb86e3d009438 diff --git a/motorApp/Db/Makefile b/motorApp/Db/Makefile index f70a15d4..ef18ff14 100644 --- a/motorApp/Db/Makefile +++ b/motorApp/Db/Makefile @@ -30,7 +30,6 @@ DB += asyn_motor.db DB += profileMoveController.template DB += profileMoveAxis.template DB += PI_Support.db PI_SupportCtrl.db -DB += Phytron_motor.db Phytron_I1AM01.db Phytron_MCM01.db DB += asyn_auto_power.db DB += ScriptMotorReload.db diff --git a/motorApp/Db/Phytron_I1AM01.db b/motorApp/Db/Phytron_I1AM01.db deleted file mode 100644 index 01e1f166..00000000 --- a/motorApp/Db/Phytron_I1AM01.db +++ /dev/null @@ -1,1092 +0,0 @@ -################################################################################ -# This database contains records corresponding to additional parameters (not -# handled by the motor record) of the I1AM01 motion controller. -# -# Output records, used to set the parameter values have a suffix _SET, readback -# records, used to read the parameters have a suffix _GET. -# -# Initialization, status and reset records have no suffixes. -################################################################################ - -################################################################################ -# Reset Axis -################################################################################ -record(bo, "$(P)$(M)-RESET") -{ - field(DESC, "Reset axis") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))AXIS_RESET") -} - -################################################################################ -# Reset Axis Status -################################################################################ -record(bo, "$(P)$(M)-RESET-STATUS") -{ - field(DESC, "Reset axis status") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))AXIS_STATUS_RESET") -} - - -################################################################################ -# Initialization of _SET records -# REINIT_ is triggered every time MCM01 module is reset -################################################################################ -record(seq, "$(P)$(M)-INIT-AXIS-1") -{ - field(DESC, "Axis initialization") - field(LNK1, "$(P)$(M)-HOMING_SET PP") - field(DOL1, "$(HOMING)") - field(LNK2, "$(P)$(M)-MOVE-TYP_SET PP") - field(DOL2, "$(MODE)") - field(LNK3, "$(P)$(M)-POS-OFFSET_SET PP") - field(DOL3, "$(POS_OFFSET)") - field(LNK4, "$(P)$(M)-NEG-OFFSET_SET PP") - field(DOL4, "$(NEG_OFFSET)") - field(LNK5, "$(P)$(M)-INIT-TIMEOUT_SET PP") - field(DOL5, "$(INIT_TIME)") - field(LNK6, "$(P)$(M)-POS-TIMEOUT_SET PP") - field(DOL6, "$(POS_TIME)") - field(LNK7, "$(P)$(M)-BOOST_SET PP") - field(DOL7, "$(BOOST)") - field(LNK8, "$(P)$(M)-SWITCH-TYP_SET PP") - field(DOL8, "$(SWITCH_TYP)") - field(LNK9, "$(P)$(M)-PWR-STAGE-MODE_SET PP") - field(DOL9, "$(PWR_STAGE)") - field(SELM, "All") - field(PINI, "$(INIT)") - field(FLNK, "$(P)$(M)-INIT-AXIS-2") -} - -record(seq, "$(P)$(M)-INIT-AXIS-2") -{ - field(DESC, "Axis initialization") - field(LNK1, "$(P)$(M)-ENC-TYP_SET PP") - field(DOL1, "$(ENC_TYP)") - field(LNK2, "$(P)$(M)-ENC-SFI_SET PP") - field(DOL2, "$(ENC_SFI)") - field(LNK3, "$(P)$(M)-STOP-CURRENT_SET PP") - field(DOL3, "$(STOP_CURR)") - field(LNK4, "$(P)$(M)-RUN-CURRENT_SET PP") - field(DOL4, "$(RUN_CURR)") - field(LNK5, "$(P)$(M)-BOOST-CURRENT_SET PP") - field(DOL5, "$(BOOST_CURR)") - field(LNK6, "$(P)$(M)-CURRENT-DELAY_SET PP") - field(DOL6, "$(CURRENT_DELAY)") - field(LNK7, "$(P)$(M)-STEP-RES_SET PP") - field(DOL7, "$(STEP_RES)") - field(LNK8, "$(P)$(M)-PS-MONITOR_SET PP") - field(DOL8, "$(PS_MON)") - field(LNK9, "$(P)$(M)-ENC-DIR_SET PP") - field(DOL9, "$(ENC_DIR)") - field(SELM, "All") -} - -record(seq, "$(P)$(M)-REINIT_") -{ - field(DESC, "Reinit after reset") - field(SCAN, "Passive") - field(DOL1, "$(P)-RESET_ CPP") - field(LNK1, "$(P)$(M)-INIT-AXIS-1.PROC") - field(SELM, "All") -} - -################################################################################ -# STATUS_ record reads axis status from the device, the two mbbiDirect records -# are used to parse the status bits. STATUS_ uses I/O Intr SCAN, because the -# status value is read in phytronAxis::poll -# SHFT field is used, therefore DTYP of mbbiDirect must be set to Raw Soft Channel. -################################################################################ -record(ai, "$(P)$(M)-STATUS_") -{ - field(DESC, "Axis status") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))AXIS_STATUS") - field(SCAN, "I/O Intr") - field(FLNK, "$(P)$(M)-STATUS-1") -} - -record(mbbiDirect, "$(P)$(M)-STATUS-1") -{ - field(DESC, "Axis status bits") - field(DTYP, "Raw Soft Channel") - field(INP, "$(P)$(M)-STATUS_") - field(FLNK, "$(P)$(M)-STATUS-2") -} - -record(mbbiDirect, "$(P)$(M)-STATUS-2") -{ - field(DESC, "Axis status bits") - field(DTYP, "Raw Soft Channel") - field(INP, "$(P)$(M)-STATUS_") - field(SHFT, "16") - field(FLNK, "$(P)$(M)-AXIS-BUSY") -} - -################################################################################ -# Axis status records. See DESC field -################################################################################ -record(bi, "$(P)$(M)-AXIS-BUSY") -{ - field(DESC, "Axis busy") - field(INP, "$(P)$(M)-STATUS-1.B0") - field(ZNAM, "NOT BUSY") - field(ONAM, "BUSY") - field(FLNK, "$(P)$(M)-COMMAND") -} - -record(bi, "$(P)$(M)-COMMAND") -{ - field(DESC, "Command invalid") - field(INP, "$(P)$(M)-STATUS-1.B1") - field(ZNAM, "VALID") - field(ONAM, "INVALID") - field(FLNK, "$(P)$(M)-WAIT-SYNC") -} - -record(bi, "$(P)$(M)-WAIT-SYNC") -{ - field(DESC, "Waiting for synchronization") - field(INP, "$(P)$(M)-STATUS-1.B2") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-INITIALIZED") -} - -record(bi, "$(P)$(M)-INITIALIZED") -{ - field(DESC, "Axis initialized") - field(INP, "$(P)$(M)-STATUS-1.B3") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-LS-POS") -} - -record(bi, "$(P)$(M)-LS-POS") -{ - field(DESC, "Positive limit switch") - field(INP, "$(P)$(M)-STATUS-1.B4") - field(ZNAM, "NOT ACTIVE") - field(ONAM, "ACTIVE") - field(FLNK, "$(P)$(M)-LS-NEG") -} - -record(bi, "$(P)$(M)-LS-NEG") -{ - field(DESC, "Negative limit switch") - field(INP, "$(P)$(M)-STATUS-1.B5") - field(ZNAM, "NOT ACTIVE") - field(ONAM, "ACTIVE") - field(FLNK, "$(P)$(M)-LS-CNT") -} - -record(bi, "$(P)$(M)-LS-CNT") -{ - field(DESC, "Center switch") - field(INP, "$(P)$(M)-STATUS-1.B6") - field(ZNAM, "NOT ACTIVE") - field(ONAM, "ACTIVE") - field(FLNK, "$(P)$(M)-SWL-POS") -} - -record(bi, "$(P)$(M)-SWL-POS") -{ - field(DESC, "Positive software limit") - field(INP, "$(P)$(M)-STATUS-1.B7") - field(ZNAM, "NOT ACTIVE") - field(ONAM, "ACTIVE") - field(FLNK, "$(P)$(M)-SWL-NEG") -} - -record(bi, "$(P)$(M)-SWL-NEG") -{ - field(DESC, "Negative software limit") - field(INP, "$(P)$(M)-STATUS-1.B8") - field(ZNAM, "NOT ACTIVE") - field(ONAM, "ACTIVE") - field(FLNK, "$(P)$(M)-INT-ERR") -} - -record(bi, "$(P)$(M)-INT-ERR") -{ - field(DESC, "Axis internal error") - field(INP, "$(P)$(M)-STATUS-1.BB") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-LS-ERR") -} - -record(bi, "$(P)$(M)-LS-ERR") -{ - field(DESC, "Axis Limit switch error") - field(INP, "$(P)$(M)-STATUS-1.BC") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-PS-ERR") -} - -record(bi, "$(P)$(M)-PS-ERR") -{ - field(DESC, "Power stage error") - field(INP, "$(P)$(M)-STATUS-1.BD") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-SFI-ERR") -} - -record(bi, "$(P)$(M)-SFI-ERR") -{ - field(DESC, "Axis SFI error") - field(INP, "$(P)$(M)-STATUS-1.BE") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-ENDAT-ERR") -} - -record(bi, "$(P)$(M)-ENDAT-ERR") -{ - field(DESC, "Axis ENDAT error") - field(INP, "$(P)$(M)-STATUS-1.BF") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-RUNNING") -} - -record(bi, "$(P)$(M)-RUNNING") -{ - field(DESC, "Axis is running") - field(INP, "$(P)$(M)-STATUS-2.B0") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-RECOVERY") -} - -record(bi, "$(P)$(M)-RECOVERY") -{ - field(DESC, "Axis is in recovery") - field(INP, "$(P)$(M)-STATUS-2.B1") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-STP-DLY") -} - -record(bi, "$(P)$(M)-STP-DLY") -{ - field(DESC, "Axis in stop current delay") - field(INP, "$(P)$(M)-STATUS-2.B2") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-POSITIONED") -} - -record(bi, "$(P)$(M)-POSITIONED") -{ - field(DESC, "Axis in position") - field(INP, "$(P)$(M)-STATUS-2.B3") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-APS-READY") -} - -record(bi, "$(P)$(M)-APS-READY") -{ - field(DESC, "Axis aps ready") - field(INP, "$(P)$(M)-STATUS-2.B4") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-POSITIONING") -} - -record(bi, "$(P)$(M)-POSITIONING") -{ - field(DESC, "Axis in positioning mode") - field(INP, "$(P)$(M)-STATUS-2.B5") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-FREE-RUN") -} - -record(bi, "$(P)$(M)-FREE-RUN") -{ - field(DESC, "Axis in free running") - field(INP, "$(P)$(M)-STATUS-2.B6") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-MULTI-F") -} - -record(bi, "$(P)$(M)-MULTI-F") -{ - field(DESC, "Axis multi F run") - field(INP, "$(P)$(M)-STATUS-2.B7") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-SYNC-ALLOWED") -} - -record(bi, "$(P)$(M)-SYNC-ALLOWED") -{ - field(DESC, "Axis multi F run") - field(INP, "$(P)$(M)-STATUS-2.B8") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)$(M)-AXIS-ERR") -} - -record(calc, "$(P)$(M)-AXIS-ERR") -{ - field(DESC, "Any axis err") - field(INPA, "$(P)$(M)-COMMAND") - field(INPB, "$(P)$(M)-LS-POS") - field(INPC, "$(P)$(M)-LS-NEG") - field(INPD, "$(P)$(M)-LS-CNT") - field(INPE, "$(P)$(M)-SWL-POS") - field(INPF, "$(P)$(M)-SWL-NEG") - field(INPG, "$(P)$(M)-INT-ERR") - field(INPH, "$(P)$(M)-LS-ERR") - field(INPI, "$(P)$(M)-PS-ERR") - field(INPJ, "$(P)$(M)-SFI-ERR") - field(INPK, "$(P)$(M)-ENDAT-ERR") - field(CALC, "A||B||C||D||E||F||G||H||I||J||K") - -} - -################################################################################ -# Homing procedure type -# KEEP IN MIND PARAMETERS THAT HOMING FINISHES BY MOVING FOR AND ADDITIONAL -# OFFSET, DEFINED IN PARAMETERS P11 AND P12 -################################################################################ -record(mbbo, "$(P)$(M)-HOMING_SET") -{ - field(DESC, "Homing Type") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))HOMING_PROCEDURE") - field(ZRST, "Limit") #HOMF (R+), HOMR (R-) - field(ZRVL, "0") - field(ONST, "Center") #HOMF (R+C)-Offset P11, HOMR (R-C)+Offset P12 - field(ONVL, "1") - field(TWST, "Encoder") #HOMF (R+I), HOMR (R+I), Offsets - field(TWVL, "2") - field(THST, "Limit-Encoder") #HOMF (R+^I), HOMR (R-^I), Offsets - field(THVL, "3") - field(FRST, "Center-Encoder") #HOMF (R+C^I), HOMR (R-C^I), Offsets - field(FRVL, "4") - field(FVST, "Reference-Center") #HOMF RC+, HOMR RC-, Offsets - field(FVVL, "5") - field(SXST, "Ref-Center-Encoder") #HOMF RC+^I, HOMR RC-^I, Offsets - field(SXVL, "6") - field(FLNK, "$(P)$(M)-HOMING_GET") -} - -record(mbbi, "$(P)$(M)-HOMING_GET") -{ - field(DESC, "Homing Type") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))HOMING_PROCEDURE") - field(ZRST, "Limit") #HOMF (R+), HOMR (R-) - field(ZRVL, "0") - field(ONST, "Center") #HOMF (R+C)-Offset P11, HOMR (R-C)+Offset P12 - field(ONVL, "1") - field(TWST, "Encoder") #HOMF (R+I), HOMR (R+I), Offsets - field(TWVL, "2") - field(THST, "Limit-Encoder") #HOMF (R+^I), HOMR (R-^I), Offsets - field(THVL, "3") - field(FRST, "Center-Encoder") #HOMF (R+C^I), HOMR (R-C^I), Offsets - field(FRVL, "4") - field(FVST, "Reference-Center") #HOMF RC+, HOMR RC-, Offsets - field(FVVL, "5") - field(SXST, "Ref-Center-Encoder") #HOMF RC+^I, HOMR RC-^I, Offsets - field(SXVL, "6") - field(PINI, "YES") -} - -################################################################################ -# P01: Controller provides the following modes of movement, however software -# limits are always monitored by the motor record, so only modes 0 and 1 are -# exposed to the user -# 0: Rotational movement -# 1: Hardware limit switches are monitored -# 2: Software limit switch are monitored -# 3: Hardware and software limit switches are monitored -################################################################################ -record(mbbo, "$(P)$(M)-MOVE-TYP_SET") -{ - field(DESC, "Move type") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))AXIS_MODE") - field(ZRST, "Rotational") - field(ZRVL, "0") - field(ONST, "HW switch") - field(ONVL, "1") - field(FLNK, "$(P)$(M)-MOVE-TYP_GET") -} - -record(mbbi, "$(P)$(M)-MOVE-TYP_GET") -{ - field(DESC, "Move type") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))AXIS_MODE") - field(ZRST, "Rotational") - field(ZRVL, "0") - field(ONST, "HW switch") - field(ONVL, "1") - field(PINI, "YES") -} - -############################################################################### -# P11: Mechanical zero point offset for limit switch direction + (away from -# LIMIT+ switch, towards LIMIT- switch) -################################################################################ -record(ao, "$(P)$(M)-POS-OFFSET_SET") -{ - field(DESC, "Positive offset") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))MOP_POS") - field(FLNK, "$(P)$(M)-POS-OFFSET_GET") -} - -record(ai, "$(P)$(M)-POS-OFFSET_GET") -{ - field(DESC, "Positive offset") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))MOP_POS") - field(PINI, "YES") -} - -################################################################################ -# P12: Mechanical zero point offset for limit switch direction - (away from -# LIMIT- switch, towards LIMIT+ switch) -################################################################################ -record(ao, "$(P)$(M)-NEG-OFFSET_SET") -{ - field(DESC, "P12:Negative offset") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))MOP_NEG") - field(FLNK, "$(P)$(M)-NEG-OFFSET_GET") -} - -record(ai, "$(P)$(M)-NEG-OFFSET_GET") -{ - field(DESC, "Negative offset") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))MOP_NEG") - field(PINI, "YES") -} - -################################################################################ -# P13: Time lapse during initialization in miliseconds -################################################################################ -record(ao, "$(P)$(M)-INIT-TIMEOUT_SET") -{ - field(DESC, "Init time lapse") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))INIT_TIME") - field(EGU, "ms") - field(FLNK, "$(P)$(M)-INIT-TIMEOUT_GET") -} - -record(ai, "$(P)$(M)-INIT-TIMEOUT_GET") -{ - field(DESC, "Init time lapse") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))INIT_TIME") - field(EGU, "ms") - field(PINI, "YES") -} - -################################################################################ -# P16: Time lapse after positioning -################################################################################ -record(ao, "$(P)$(M)-POS-TIMEOUT_SET") -{ - field(DESC, "Position time lapse") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))POSITION_TIME") - field(EGU, "ms") - field(FLNK, "$(P)$(M)-POS-TIMEOUT_GET") -} - -record(ai, "$(P)$(M)-POS-TIMEOUT_GET") -{ - field(DESC, "Position time lapse") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))POSITION_TIME") - field(EGU, "ms") - field(PINI, "YES") -} - -################################################################################ -# P17: Defines when to use boost current (P42) -################################################################################ -record(mbbo, "$(P)$(M)-BOOST_SET") -{ - field(DESC, "Boost") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))BOOST") - field(ZRVL, "0") - field(ZRST, "OFF") - field(ONVL, "1") - field(ONST, "ON MOTOR RUN") - field(TWVL, "2") - field(TWST, "ON ACCELERATION") - field(FLNK, "$(P)$(M)-BOOST_GET") -} - -record(mbbi, "$(P)$(M)-BOOST_GET") -{ - field(DESC, "Boost") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))BOOST") - field(ZRVL, "0") - field(ZRST, "OFF") - field(ONVL, "1") - field(ONST, "ON MOTOR RUN") - field(TWVL, "2") - field(TWST, "ON ACCELERATION") - field(PINI, "YES") -} - -################################################################################ -# P26: Encoder data transfer rate (ONLY FOR SSI) -################################################################################ -record(mbbo, "$(P)$(M)-ENC-RATE_SET") -{ - field(DESC, "Encoder rate") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_RATE") - field(ZRVL, "1") - field(ZRST, "100 kHz") - field(ONVL, "2") - field(ONST, "200 kHz") - field(TWVL, "3") - field(TWST, "300 kHz") - field(THVL, "4") - field(THST, "400 kHz") - field(FRVL, "5") - field(FRST, "500 kHz") - field(FVVL, "6") - field(FVST, "600 kHz") - field(SXVL, "7") - field(SXST, "700 kHz") - field(SVVL, "8") - field(SVST, "800 kHz") - field(EIVL, "9") - field(EIST, "900 kHz") - field(NIVL, "10") - field(NIST, "1000 kHz") - field(FLNK, "$(P)$(M)-ENC-RATE_GET") -} - -record(mbbi, "$(P)$(M)-ENC-RATE_GET") -{ - field(DESC, "Encoder rate") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_RATE") - field(ZRVL, "1") - field(ZRST, "100 kHz") - field(ONVL, "2") - field(ONST, "200 kHz") - field(TWVL, "3") - field(TWST, "300 kHz") - field(THVL, "4") - field(THST, "400 kHz") - field(FRVL, "5") - field(FRST, "500 kHz") - field(FVVL, "6") - field(FVST, "600 kHz") - field(SXVL, "7") - field(SXST, "700 kHz") - field(SVVL, "8") - field(SVST, "800 kHz") - field(EIVL, "9") - field(EIST, "900 kHz") - field(NIVL, "10") - field(NIST, "1000 kHz") - field(PINI, "YES") -} - -################################################################################ -# P27: Limit switch type -# NCC: Normally closed contact -# NOC: Normally open contact -# STRING FIELDS ARE OF THE FORM: LIMIT-/CENTER/LIMIT+ -################################################################################ -record(mbbo, "$(P)$(M)-SWITCH-TYP_SET") -{ - field(DESC, "Switch type") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))SWITCH_TYP") - field(ZRVL, "0") - field(ZRST, "NCC/NCC/NCC") - field(ONVL, "0") - field(ONST, "NCC/NCC/NOC") - field(TWVL, "2") - field(TWST, "NOC/NCC/NCC") - field(THVL, "3") - field(THST, "NOC/NCC/NOC") - field(FRVL, "4") - field(FRST, "NCC/NOC/NCC") - field(FVVL, "5") - field(FVST, "NCC/NOC/NOC") - field(SXVL, "6") - field(SXST, "NOC/NOC/NCC") - field(SVVL, "7") - field(SVST, "NOC/NOC/NOC") - field(FLNK, "$(P)$(M)-SWITCH-TYP_GET") -} - -record(mbbi, "$(P)$(M)-SWITCH-TYP_GET") -{ - field(DESC, "Switch type") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))SWITCH_TYP") - field(ZRVL, "0") - field(ZRST, "NCC/NCC/NCC") - field(ONVL, "0") - field(ONST, "NCC/NCC/NOC") - field(TWVL, "2") - field(TWST, "NOC/NCC/NCC") - field(THVL, "3") - field(THST, "NOC/NCC/NOC") - field(FRVL, "4") - field(FRST, "NCC/NOC/NCC") - field(FVVL, "5") - field(FVST, "NCC/NOC/NOC") - field(SXVL, "6") - field(SXST, "NOC/NOC/NCC") - field(SVVL, "7") - field(SVST, "NOC/NOC/NOC") - field(PINI, "YES") -} - -################################################################################ -# P28: AXIS Options -# 0 - Power stage is deactivated -# 1 - Power stage is activated -################################################################################ -record(bo, "$(P)$(M)-PWR-STAGE-MODE_SET") -{ - field(DESC, "Power stage ON/OFF") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))PWR_STAGE_MODE") - field(ZNAM, "Deactivate") - field(ONAM, "Activate") - field(FLNK, "$(P)$(M)-PWR-STAGE-MODE_GET") -} - -record(bi, "$(P)$(M)-PWR-STAGE-MODE_GET") -{ - field(DESC, "Power stage ON/OFF") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))PWR_STAGE_MODE") - field(ZNAM, "Deactivate") - field(ONAM, "Activate") - field(PINI, "YES") -} - -################################################################################ -# P34: Encoder type: -# 0: No encoder -# 1: Incremental 5.0V -# 2: Incremental 5.5V -# 3: SSI Binary code 5.0V -# 4: SSI Binary code 5.5V -# 5: SSI Gray code 5.0V -# 6: SSI Gray code 5.5V -# 7: EnDat 5.0V -# 8: EnDat 5.5V -################################################################################ -record(mbbo, "$(P)$(M)-ENC-TYP_SET") -{ - field(DESC, "Encoder type") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENCODER_TYP") - field(ZRST, "No encoder") - field(ZRVL, "0") - field(ONST, "Incremental 5.0V") - field(ONVL, "1") - field(TWST, "Incremental 5.5V") - field(TWVL, "2") - field(THST, "SSI Binary 5.0V") - field(THVL, "3") - field(FRST, "SSI Binary 5.5V") - field(FRVL, "4") - field(FVST, "SSI Gray 5.0V") - field(FVVL, "5") - field(SXST, "SSI Gray 5.5V") - field(SXVL, "6") - field(SVST, "EnDat 5.0V") - field(SVVL, "7") - field(EIST, "EnDat 5.5V") - field(EIVL, "8") - field(FLNK, "$(P)$(M)-ENC-TYP_GET") -} - -record(mbbi, "$(P)$(M)-ENC-TYP_GET") -{ - field(DESC, "Encoder type") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENCODER_TYP") - field(ZRST, "No encoder") - field(ZRVL, "0") - field(ONST, "Incremental 5.0V") - field(ONVL, "1") - field(TWST, "Incremental 5.5V") - field(TWVL, "2") - field(THST, "SSI Binary 5.0V") - field(THVL, "3") - field(FRST, "SSI Binary 5.5V") - field(FRVL, "4") - field(FVST, "SSI Gray 5.0V") - field(FVVL, "5") - field(SXST, "SSI Gray 5.5V") - field(SXVL, "6") - field(SVST, "EnDat 5.0V") - field(SVVL, "7") - field(EIST, "EnDat 5.5V") - field(EIVL, "8") - field(PINI, "YES") -} - -################################################################################ -# P35: SSI and EnDat encoder resolution in bits. From 0b to 48b. -# 0b - the controller uses the resolution which is read from the connected instrument -################################################################################ -record(ao, "$(P)$(M)-ENC-RES_SET") -{ - field(DESC, "Encoder resolution") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_RESOLUTION") - field(EGU, "b") - field(HOPR, "48") - field(LOPR, "0") - field(FLNK, "$(P)$(M)-ENC-RES_GET") -} - -record(ai, "$(P)$(M)-ENC-RES_GET") -{ - field(DESC, "Encoder resolution") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_RESOLUTION") - field(EGU, "b") - field(HOPR, "48") - field(LOPR, "0") - field(PINI, "YES") -} - -################################################################################ -# P36: Encoder function -# 0: counter -# 1: counter + SFI -# If P37 > 0, P36 is 1 else 0 -################################################################################ -record(bo, "$(P)$(M)-ENC-FUNC_SET") -{ - field(DESC, "SFI ON/OFF") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_FUNCTION") - field(ZNAM, "Counter") - field(ONAM, "Counter+SFI") - field(OMSL, "closed_loop") - field(DOL, "$(P)$(M)-ENC-SFI_GET") - field(FLNK, "$(P)$(M)-ENC-FUNC_GET") -} - -record(bi, "$(P)$(M)-ENC-FUNC_GET") -{ - field(DESC, "SFI ON/OFF") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_FUNCTION") - field(ZNAM, "Counter") - field(ONAM, "Counter+SFI") - field(PINI, "YES") -} - -################################################################################ -# P37: Encoder tolerance for SFI -################################################################################ -record(ao, "$(P)$(M)-ENC-SFI_SET") -{ - field(DESC, "SFI tolerrance") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_SFI_WIDTH") - field(FLNK, "$(P)$(M)-ENC-SFI_GET") -} - -record(ai, "$(P)$(M)-ENC-SFI_GET") -{ - field(DESC, "SFI tolerrance") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_SFI_WIDTH") - field(PINI, "YES") - field(FLNK, "$(P)$(M)-ENC-FUNC_SET") -} - -################################################################################ -# P38: Encoder direction of rotation -################################################################################ -record(bo, "$(P)$(M)-ENC-DIR_SET") -{ - field(DESC, "Encoder direction") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_DIRECTION") - field(ZNAM, "Positive") - field(ONAM, "Negative") - field(FLNK, "$(P)$(M)-ENC-DIR_GET") -} - -record(bi, "$(P)$(M)-ENC-DIR_GET") -{ - field(DESC, "Encoder direction") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))ENC_DIRECTION") - field(ZNAM, "Positive") - field(ONAM, "Negative") -} - -################################################################################ -# P40: Stop current in mA. Can be set in 10 mA increments -################################################################################ -record(ao, "$(P)$(M)-STOP-CURRENT_SET") -{ - field(DESC, "Stop current") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))STOP_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(FLNK, "$(P)$(M)-STOP-CURRENT_GET") - -} - -record(ai, "$(P)$(M)-STOP-CURRENT_GET") -{ - field(DESC, "Stop current") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))STOP_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(PINI, "YES") - -} - -################################################################################ -# P41: Run current in mA. Can be set in 10 mA increments -################################################################################ -record(ao, "$(P)$(M)-RUN-CURRENT_SET") -{ - field(DESC, "Run current") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))RUN_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(FLNK, "$(P)$(M)-RUN-CURRENT_GET") - -} - -record(ai, "$(P)$(M)-RUN-CURRENT_GET") -{ - field(DESC, "Run current") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))RUN_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(PINI, "YES") - -} - -################################################################################ -# P42: Boost current in mA. Can be set in 10 mA increments -################################################################################ -record(ao, "$(P)$(M)-BOOST-CURRENT_SET") -{ - field(DESC, "Boost current") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))BOOST_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(FLNK, "$(P)$(M)-BOOST-CURRENT_GET") - -} - -record(ai, "$(P)$(M)-BOOST-CURRENT_GET") -{ - field(DESC, "Boost current") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))BOOST_CURRENT") - field(EGU, "mA") - field(HOPR, "2500") - field(LOPR, "0") - field(HIGH, "2200") - field(HIHI, "2400") - field(HSV, "MINOR") - field(HHSV, "MAJOR") - field(PINI, "YES") -} - -################################################################################ -# P43: Current hold time in msec -################################################################################ -record(ao, "$(P)$(M)-CURRENT-DELAY_SET") -{ - field(DESC, "Current hold time") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))CURRENT_DELAY_TIME") - field(EGU, "msec") - field(FLNK, "$(P)$(M)-CURRENT-DELAY_GET") - -} - -record(ai, "$(P)$(M)-CURRENT-DELAY_GET") -{ - field(DESC, "Current hold time") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))CURRENT_DELAY_TIME") - field(EGU, "mA") - field(PINI, "YES") -} - - -################################################################################ -# P45: Step resolution -################################################################################ -record(mbbo, "$(P)$(M)-STEP-RES_SET") -{ - field(DESC, "Step resolution") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))STEP_RES") - field(ZRST, "1") - field(ZRVL, "0") - field(ONST, "1/2") - field(ONVL, "1") - field(TWST, "1/2.5") - field(TWVL, "2") - field(THST, "1/4") - field(THVL, "3") - field(FRST, "1/5") - field(FRVL, "4") - field(FVST, "1/8") - field(FVVL, "5") - field(SXST, "1/10") - field(SXVL, "6") - field(SVST, "1/16") - field(SVVL, "7") - field(EIST, "1/20") - field(EIVL, "8") - field(NIST, "1/32") - field(NIVL, "9") - field(TEST, "1/64") - field(TEVL, "10") - field(ELST, "1/128") - field(ELVL, "11") - field(FLNK, "$(P)$(M)-STEP-RES_GET") -} - -record(mbbi, "$(P)$(M)-STEP-RES_GET") -{ - field(DESC, "Step resolution") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))STEP_RES") - field(ZRST, "1") - field(ZRVL, "0") - field(ONST, "1/2") - field(ONVL, "1") - field(TWST, "1/2.5") - field(TWVL, "2") - field(THST, "1/4") - field(THVL, "3") - field(FRST, "1/5") - field(FRVL, "4") - field(FVST, "1/8") - field(FVVL, "5") - field(SXST, "1/10") - field(SXVL, "6") - field(SVST, "1/16") - field(SVVL, "7") - field(EIST, "1/20") - field(EIVL, "8") - field(NIST, "1/32") - field(NIVL, "9") - field(TEST, "1/64") - field(TEVL, "10") - field(ELST, "1/128") - field(ELVL, "11") - field(PINI, "YES") -} - -################################################################################ -# P49: Power stage temperature -################################################################################ -record(ai, "$(P)$(M)-PS-TEMPERATURE") -{ - field(DESC, "Power stage temp") - field(DTYP, "asynFloat64") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))PS_TEMPERATURE") - field(EGU, "°C") - field(SCAN, "$(SCAN)") - field(PREC, 1) - field(PINI, "YES") -} - -################################################################################ -# P53: Power stage monitoring -################################################################################ -record(bo, "$(P)$(M)-PS-MONITOR_SET") -{ - field(DESC, "Power stage monitor") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))PS_MONITOR") - field(ZNAM, "OFF") - field(ONAM, "ON") - field(FLNK, "$(P)$(M)-PS-MONITOR_GET") -} - -record(bi, "$(P)$(M)-PS-MONITOR_GET") -{ - field(DESC, "Power stage monitor") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))PS_MONITOR") - field(ZNAM, "OFF") - field(ONAM, "ON") - field(PINI, "YES") -} - -################################################################################ -# P54: Motor temperature in 0.1 °C -################################################################################ -record(ai, "$(P)$(M)-MOTOR-TEMP") -{ - field(DESC, "Motor temperature") - field(DTYP, "asynFloat64") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))MOTOR_TEMP") - field(SCAN, "$(SCAN)") - field(EGU, "°C") - field(PREC, 1) - field(FLNK, "$(P)$(M)-MOTOR-TEMP") -} - diff --git a/motorApp/Db/Phytron_MCM01.db b/motorApp/Db/Phytron_MCM01.db deleted file mode 100644 index d53ad2ec..00000000 --- a/motorApp/Db/Phytron_MCM01.db +++ /dev/null @@ -1,223 +0,0 @@ -################################################################################ -# This database contains records used to monitor status and reset the MCM01 -# controller. -################################################################################ - -################################################################################ -#ai record reads controller status from the device, mbbiDirect is used to parse -# the status bits -################################################################################ -record(ai, "$(P)-STATUS_") -{ - field(DESC, "Status") - field(DTYP, "asynInt32") - field(INP, "@asyn($(PORT), $(ADDR), $(TIMEOUT))CONTROLLER_STATUS") - field(SCAN, "1 second") - field(FLNK, "$(P)-STATUS-BITS_") -} - -record(mbbiDirect, "$(P)-STATUS-BITS_") -{ - field(DESC, "Status bits") - field(DTYP, "Raw Soft Channel") - field(INP, "$(P)-STATUS_") - field(FLNK, "$(P)-PROGRAM") -} - -################################################################################ -#Controller status records. See DESC fields -################################################################################ -record(bi, "$(P)-PROGRAM") -{ - field(DESC, "Program in local mode") - field(INP, "$(P)-STATUS-BITS_.B0") - field(ZNAM, "DONE") - field(ONAM, "RUNNING") - field(FLNK, "$(P)-SW-REMOTE") -} - -record(bi, "$(P)-SW-REMOTE") -{ - field(DESC, "Software remote") - field(INP, "$(P)-STATUS-BITS_.B1") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-LIMIT-SWITCH") -} - -record(bi, "$(P)-LIMIT-SWITCH") -{ - field(DESC, "Axis limit switch") - field(INP, "$(P)-STATUS-BITS_.B2") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-PS-AXIS-ERR") -} - -record(bi, "$(P)-PS-AXIS-ERR") -{ - field(DESC, "Power stage axis error") - field(INP, "$(P)-STATUS-BITS_.B3") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-PROG-ERR") -} - -record(bi, "$(P)-PROG-ERR") -{ - field(DESC, "Programming error") - field(INP, "$(P)-STATUS-BITS_.B4") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-TERM-ACT") -} - -record(bi, "$(P)-TERM-ACT") -{ - field(DESC, "Terminal activated") - field(INP, "$(P)-STATUS-BITS_.B5") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-INP-SCAN") -} - -record(bi, "$(P)-INP-SCAN") -{ - field(DESC, "Input scan running") - field(INP, "$(P)-STATUS-BITS_.B6") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-REMOTE") -} - -record(bi, "$(P)-REMOTE") -{ - field(DESC, "Remote") - field(INP, "$(P)-STATUS-BITS_.B7") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-AXIS-MODULE") -} - -record(bi, "$(P)-AXIS-MODULE") -{ - field(DESC, "Axis module availability") - field(INP, "$(P)-STATUS-BITS_.B8") - field(ZNAM, "AVAILABLE") - field(ONAM, "NOT AVAILABLE") - field(FLNK, "$(P)-AXIS") -} - -record(bi, "$(P)-AXIS") -{ - field(DESC, "Axis availability") - field(INP, "$(P)-STATUS-BITS_.B9") - field(ZNAM, "AVAILABLE") - field(ONAM, "NOT AVAILABLE") - field(FLNK, "$(P)-IO-MODULE") -} - -record(bi, "$(P)-IO-MODULE") -{ - field(DESC, "I/O module availability") - field(INP, "$(P)-STATUS-BITS_.BA") - field(ZNAM, "AVAILABLE") - field(ONAM, "NOT AVAILABLE") - field(FLNK, "$(P)-IO") -} - -record(bi, "$(P)-IO") -{ - field(DESC, "I/O availability") - field(INP, "$(P)-STATUS-BITS_.BB") - field(ZNAM, "AVAILABLE") - field(ONAM, "NOT AVAILABLE") - field(FLNK, "$(P)-INT-BUS-ERR") -} - -record(bi, "$(P)-INT-BUS-ERR") -{ - field(DESC, "Internal data transf. err.") - field(INP, "$(P)-STATUS-BITS_.BC") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-INT-MOD-ERR") -} - -record(bi, "$(P)-INT-MOD-ERR") -{ - field(DESC, "Internal bus module err.") - field(INP, "$(P)-STATUS-BITS_.BD") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-AIOM-MODULE") -} - -record(bi, "$(P)-AIOM-MODULE") -{ - field(DESC, "AIOM module availability") - field(INP, "$(P)-STATUS-BITS_.BE") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-AIOM-CHANNEL") -} - -record(bi, "$(P)-AIOM-CHANNEL") -{ - field(DESC, "AIOM channel availability") - field(INP, "$(P)-STATUS-BITS_.BF") - field(ZNAM, "NO") - field(ONAM, "YES") - field(FLNK, "$(P)-CON-ERR") -} - -record(calc, "$(P)-CON-ERR") -{ - field(INPA, "$(P)-LIMIT-SWITCH") - field(INPB, "$(P)-PS-AXIS-ERR") - field(INPC, "$(P)-PROG-ERR") - field(INPD, "$(P)-INT-BUS-ERR") - field(INPE, "$(P)-INT-MOD-ERR") - field(INPF, "$(P)-AXIS-MODULE") - field(INPG, "$(P)-AXIS") - field(INPH, "$(P)-IO-MODULE") - field(INPI, "$(P)-IO") - field(INPJ, "$(P)-AIOM-MODULE") - field(INPK, "$(P)-AIOM-CHANNEL") - field(CALC, "A||B||C||D||E||F||G||H||I||J") -} - -################################################################################ -# Reset controller -# RESET_ changes value between 0 and 1, so the monitor is posted and the -# REINIT_ record in Phytron_I1AM01.db is processed -################################################################################ -record(bo, "$(P)-RESET") -{ - field(DESC, "Reset controller") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))CONTROLLER_RESET") - field(ONAM, "RESET") - field(ZNAM, "RESET") - field(FLNK, "$(P)-RESET_") -} - -record(calc, "$(P)-RESET_") -{ - field(DESC, "Reset monitor") - field(INPA, "$(P)-RESET_") - field(CALC, "(A=0)?1:0") -} - -################################################################################ -#Reset controller status -################################################################################ -record(bo, "$(P)-RESET-STATUS") -{ - field(DESC, "Reset cont. status") - field(DTYP, "asynInt32") - field(OUT, "@asyn($(PORT), $(ADDR), $(TIMEOUT))CONTROLLER_STATUS_RESET") - field(ONAM, "RESET") - field(ZNAM, "RESET") -} - diff --git a/motorApp/Db/Phytron_motor.db b/motorApp/Db/Phytron_motor.db deleted file mode 100644 index 83f85aa6..00000000 --- a/motorApp/Db/Phytron_motor.db +++ /dev/null @@ -1,23 +0,0 @@ -record(motor,"$(P)$(M)") -{ - field(DESC,"$(DESC)") - field(DTYP,"$(DTYP)") - field(DIR,"$(DIR)") - field(VELO,"$(VELO)") - field(VBAS,"$(VBAS)") - field(VMAX,"$(VMAX)") - field(ACCL,"$(ACCL)") - field(BDST,"$(BDST)") - field(BVEL,"$(BVEL)") - field(BACC,"$(BACC)") - field(OUT,"@asyn($(PORT),$(ADDR))") - field(MRES,"$(MRES)") - field(ERES,"$(ERES)") - field(PREC,"$(PREC)") - field(EGU,"$(EGU)") - field(DHLM,"$(DHLM)") - field(DLLM,"$(DLLM)") - field(INIT,"$(INIT)") - field(TWV,"1") -} - diff --git a/motorApp/Makefile b/motorApp/Makefile index 25738306..b113d47b 100644 --- a/motorApp/Makefile +++ b/motorApp/Makefile @@ -33,9 +33,6 @@ ACRSrc_DEPEND_DIRS = MotorSrc DIRS += SmarActMCSSrc SmarActMCSSrc_DEPEND_DIRS = MotorSrc -DIRS += PhytronSrc -PhytronSrc_DEPEND_DIRS = MotorSrc - DIRS += AMCISrc AMCISrc_DEPEND_DIRS = MotorSrc diff --git a/motorApp/PhytronSrc/Makefile b/motorApp/PhytronSrc/Makefile deleted file mode 100644 index 02b2589e..00000000 --- a/motorApp/PhytronSrc/Makefile +++ /dev/null @@ -1,23 +0,0 @@ -TOP=../.. - -include $(TOP)/configure/CONFIG -#---------------------------------------- -# Build the IOC application - -LIBRARY_IOC += phytronAxisMotor - -DBD += phytron.dbd - -# The following are compiled and added to the support library -phytronAxisMotor_SRCS += phytronAxisMotor.cpp - -INC += phytronAxisMotor.h - -phytronAxisMotor_LIBS += motor -phytronAxisMotor_LIBS += asyn -phytronAxisMotor_LIBS += $(EPICS_BASE_IOC_LIBS) - -#=========================== - -include $(TOP)/configure/RULES - diff --git a/motorApp/PhytronSrc/README.txt b/motorApp/PhytronSrc/README.txt deleted file mode 100644 index 9a06d717..00000000 --- a/motorApp/PhytronSrc/README.txt +++ /dev/null @@ -1,447 +0,0 @@ -******************************************************************************** -Phytron I1AM01 Stepper Motor Controller Asyn Driver Documentation - -Authors: Tom Slejko, Bor Marolt, Cosylab d.d. - tom.slejko@cosylab.com - bor.marolt@cosylab.com - -******************************************************************************** -Table of contents: -- Controller and axis configuration - - Example Application - - New Applicaion -- Database - - Supported I1AM01 Features - - Initialization records - - Status - - Homing - - Reset - - I1AM01 parameters - - Supported MCM01 Features - - Motor record - - List of remaining I1AM01 parameters handled by the motor record, - internally by controller, or not applicable -- GUI - - -Controller and axis configuration -================================= -Example application: --------------------- -Motor record includes an example Phytron application. Before using it do: - -cd $(MOTOR_ROOT)/iocBoot/iocWithAsyn/ - -where $(MOTOR_ROOT) is the location of the motor record. Open st.cmd.phytron and -modify controller's IP address. If using serial port instead of ethernet, read -"New application" section, on how to configure the serial port. Remove or add -calls to phytronCreateAxis according to the number of axes that are to be used -(read "New application" section on how to use phytronCreateAxis). -Once st.cmd is configured, run: - -../../bin/linux-x86_64/WithAsyn st.cmd.phytron - -New application: ----------------- -This section describes how to properly configure epics application in order to -use phytronAxisMotor driver. - -The following dbd files and libraries must be added to the $(APP)/src/Makefile: -test_DBD += asyn.dbd -test_DBD += motorSupport.dbd -test_DBD += drvAsynIPPort.dbd -test_DBD += phytron.dbd - -test_LIBS += asyn -test_LIBS += motor -test_LIBS += phytronAxisMotor - -An example motor.substitutions.phytron and st.cmd.phytron files are located in -the $(MOTOR_RECORD)/iocBoot/iocWithAsyn/ directory. - -******************************************************************************** -WARNING: For the controller to work properly all three database files ( -Phytron_I1AM01.db, Phytron_MCM01.db and Phytron_motor.db) must be used. -******************************************************************************** - -Start up script must perform the following: -Before configuring the controller the user must create an asyn port by running -drvAsynIPPortConfigure or drvAsynSerialPortConfigure in order to create a -communication interface to Phytron's MCM Unit which controlls the I1AM01 -modules. - -If serial port is used for communication with the controller, baud rate, number -of data bits, parity, number of stop bits and End Of Line character must be set, -e.g.: - -drvAsynSerialPortConfigure ("testRemote","/dev/ttyUSB0") -asynOctetSetInputEos("testRemote",0,"\3") -asynSetOption ("testRemote", -1, "baud", "115200") -asynSetOption ("testRemote", -1, "bits", "8") -asynSetOption ("testRemote", -1, "parity", "none") -asynSetOption ("testRemote", -1, "stop", "1") - -If ethernet is used, the IP and port must be set, e.g.: -drvAsynIPPortConfigure("testRemote","10.5.1.181:22222",0,0,1) - -Phytron (MCM) controller port is configured (and connected to previously created -asyn port) by running the following iocsh function: - -phytronCreateController(const char *phytronPortName, const char *asynPortName, - int movingPollPeriod, int idlePollPeriod, double timeout) -- phytronPortName: Name of the particular MCM unit. -- asynPortName: Name of the previously configured asyn port - interface to MCM -- movingPollPeriod: The time between polls when any axis is moving in ms -- idlePolPeriod: The time between polls when no axis is moving in ms -- Timeout: Milliseconds before timeout for I/O requests - -where poll reads the basic axis status, e.g. position of the motor and of the -encoder, checks if axis is in movement, checks if motor is at the limit -switch, ... - -Once the phytron controller is configured, user can initialize axes by running - -phytronCreateAxis(const char* phytronPortName, int module, int axis) -- phytronPortName: Previously defined name of the MCM unit -- module: index of the I1AM01 module connected to the MCM -- axis: index of the axis on the I1AM01 module - -Module index and axis index compose the axis asyn ADDR (ADDR macro) used in the -motor.substitutions file. - -PhytronCreateAxis must be called for each axis intended to be used. - -******************************************************************************** -WARNING: For every axis, the user must specify it's address (ADDR macro) in the -motor.substitutions file for Phytron_motor.db and PhytronI1AM01.db files. -The address is composed of the I1AM01 module index and the axis index. If, for -example, the startup script configures the following axis: - -drvAsynIPPortConfigure("testRemote","10.5.1.181:22222",0,0,1) -phytronCreateController ("phyMotionPort", "testRemote", 100, 100, 1000) -phytronCreateAxis("phyMotionPort", 2, 1) - -It's asyn address that must be specified in the substitutions file is 21, - -PORT macro in the substitution file must match the phytronPortName, which is in -the example above "phyMotionPort" -******************************************************************************** - -Example st.cmd: ---------------- -#!../../bin/linux-x86_64/test - -## You may have to change test to something else -## everywhere it appears in this file - -< envPaths - -## Register all support components -dbLoadDatabase("../../dbd/test.dbd",0,0) -test_registerRecordDeviceDriver(pdbbase) - -drvAsynIPPortConfigure("testRemote","10.5.1.181:22222",0,0,1) - -phytronCreateController ("phyMotionPort", "testRemote", 100, 100, 1000) - -#phytronCreateAxis(phytronPort, module, axis) -phytronCreateAxis("phyMotionPort", 1, 1) -phytronCreateAxis("phyMotionPort", 2, 1) - - -cd $(MOTOR)/iocBoot/iocWithAsyn/ -dbLoadTemplate "motor.substitutions.phytron" - -iocInit() - -Database: -========= -All three database files (Phytron_I1AM01.db, Phytron_MCM01.db, Phytron_motor.db) -in $(MOTOR_ROOT)/motorApp/Db are expanded by motor.substitutions.phytron file in -$(MOTOR_ROOT)/iocBoot/iocWithAsyn - -******************************************************************************** -WARNING: For the controller to work properly all three database files ( -Phytron_I1AM01.db, Phytron_MCM01.db and Phytron_motor.db) must be used. -******************************************************************************** - -=============================================== -I1AM01 Controller Features - Phytron_I1AM01.db: -=============================================== -Initialization: ---------------- -Database contains 2 initialization records $(P)$(M)-INIT-AXIS-1/2 which are used -to initalize output (_SET) records. Initialization values are defined in the -motor.substitutions file. - -Status: -------- -Database contains several status records. Ai record $(P)$(M)-STATUS_ reads the -status value from the I1AM01 module, 2 mbbiDirect records ($(P)$(M)-STATUS-1/2) -are provided to set the status bits - 23 bi records are provided to parse these -status bits. An additional calc record is provided ($(P)$(M)-AXIS-ERR) which -sets it's value to 1 if any of the error bits are set (if only notification -bits are set, e.g. axis-initialized, the value of $(P)$(M)-AXIS-ERR is 0). - -Homing: -------- -RECORDS mbbo/mbbi: $(P)$(M)-HOMING_SET/_GET are used to set and readback the -type of homing to be used. Homing is executed with the use of motor record's -HOMF, HOMR fields. The following options are available for $(P)$(M)-HOMING_SET, -please keep in mind that offsets defined by I1AM01 parameters P11 and P12 (see -phylogic-en.pdf and see below for records corresponding to P11 and P12) affect -the final position after the homing procedure: -<- recordValue (Homing description); Phytron commands for HOMF and HOMR> - -- Limit (Home on limit switches); HOMF - m.aR+, HOMR - m.aR- - -- Center (Home on center switch); HOMF - m.aR+C, HOMR - m.aR-C -COMMENT: If limit switch is reached, the motor will stop and start moving in the -opposite direction until center switch is reached - -- Encoder (Home on encoder zero pulse); HOMF - m.aR+I, HOMR - m.aR-I - -- Limit-Encoder (Got to limit switch, than encoder zero pulse); - HOMF - m.aR+^I, HOMR - m.aR-^I - -- Center-Encoder (Go to the center switch than to encoder zero pulse) - HOMF - m.a.R+C^I, HOMR - m.aR-C^I -COMMENT: If limit switch is reached before center switch, the motor will stop -and start moving in the opposite direction until center switch is reached - -- Reference-Center (Driving on a reference signal to center) - HOMF - m.aRC+, HOMR - m.aRC- -COMMEN: If limit switch is reached, controller goes to axis error state - -- Ref-Center-Encoder (Driving on a reference signal to center and then to -encoder zero pulse) - HOMF - m.aRC+^I, HOMR - m.aRC-^I - -Reset: ------- -Two records are provided. Record $(P)$(M)-RESET executs Phytron command: m.aC, -where m is controller index and a is the axis index. - -$(P)$(M)-RESET-STATUS resets the axis status by executing the Phytron command: -SECm.a, where m is controller index and a is the axis index. - -If user resets the MCM unit, $(P)$(M)-REINIT_ record is triggered. This record -process the initialization records $(P)$(M)-INIT-AXIS-1/2 after a DELAY time -defined by the macro DLY in the substitutions file. - - -The following I1AM01 parameters are exposed as additional EPICS records: ------------------------------------------------------------------------- -Param. index: feature; -Record name(s): -Comment: -------------------------------------- -P01: Type of movement; -RECORDS mbbo/mbbi: $(P)$(M)-MOVE-TYP_SET/_GET; -COMMENT: Software limits are always monitored by the motor record, so only 2 -types of movements are possible: - - Rotational: HW limit/center switches are ignored - - HW switches are monitored -------------------------------------- -P11: M0P offset for limit switch in direction towards LIMIT-; -RECORDS ao/ai: $(P)$(M)-POS-OFFSET_SET/_GET -------------------------------------- -P12: M0P offset for limit switch in direction towards LIMIT+; -RECORDS ao/ai: $(P)$(M)-NEG-OFFSET_SET/_GET -------------------------------------- -P13: Time lapse during initialization -RECORDS ao/ai: $(P)$(M)-INIT-TIMEOUT_SET/_GET -------------------------------------- -P16: Time lapse after positioning -RECORDS ao/ai: $(P)$(M)-POS-TIMEOUT_SET/_GET -------------------------------------- -P17: Defines when to use boost current -RECORDS mbbo/mbbi: $(P)$(M)-BOOST_SET/_GET -------------------------------------- -P26: Encoder data transfer rate (ONLY FOR SSI) -RECORDS mbbo/mbbi: $(P)$(M)-ENC-RATE_SET/_GET -------------------------------------- -P27: Limit switch type -RECORDS mbbo/mbbi: $(P)$(M)-SWITCH-TYP_SET/_GET -------------------------------------- -P28: Power stage off/on -RECORDS bo/bi: $(P)$(M)-PWR-STAGE-MODE_SET/_GET -------------------------------------- -P34: Encoder type -RECORDS mbbo/mbbi: $(P)$(M)-ENC-TYP_SET/_GET -------------------------------------- -P35: Encoder resolution - for SSI and EnDat encoders -RECORDS ao/ai: $(P)$(M)-ENC-RES_SET/_GET -------------------------------------- -P36: Encoder function: If 1, Encoder position is continuously compared to the -motor position -RECORDS: bo/bi: $(P)$(M)-ENC-FUNC_SET/_GET -COMMENT: _SET is processed when $(P)$(M)-ENC-SFI_SET corresponding to parameter -P37 is processed. If P37 > 0, then P36 is set to 1, else it is 0. -------------------------------------- -P37: If P36 is set to 1, controller will stop the motion when the difference -between motor and encoder position is > P37. -RECORDS: bo/bi: $(P)$(M)-ENC-SFI_SET/_GET -COMMENT: If value is set to > 0, then P36 is set to 1. If P37=0, then P36=0 -------------------------------------- -P38: Encoder direction of rotation: Positive/Negative -RECORDS: bo/bi: $(P)$(M)-ENC-DIR_SET/_GET -------------------------------------- -P39: Encoder direction of rotation -RECORDS: bo/bi: $(P)$(M)-ENC-DIR_SET/_GET -------------------------------------- -P40: Stop current in mA. Can be set in 10 mA increments -RECORDS: ao/ai: $(P)$(M)-STOP-CURRENT_SET/_GET -------------------------------------- -P41: Run current in mA. Can be set in 10 mA increments -RECORDS: ao/ai: $(P)$(M)-RUN-CURRENT_SET/_GET -------------------------------------- -P42: Boost current in mA. Can be set in 10 mA increments -RECORDS: ao/ai: $(P)$(M)-BOOST-CURRENT_SET/_GET -------------------------------------- -P43: Current hold time in ms. -RECORDS: ao/ai: $(P)$(M)-CURRENT-DELAY_SET/_GET -------------------------------------- -P49: Power stage temperature -RECORDS: ai: $(P)$(M)-PS-TEMPERATURE -------------------------------------- -P53: Power stage monitoring -RECORDS: bo/bi: $(P)$(M)-PS-MONITOR/_GET -------------------------------------- -P54: Motor temperature -RECORDS: ai: $(P)$(M)-MOTOR-TEMP - - - -============================================ -MC01 Controller Features - Phytron_MCM01.db: -============================================ -This database file contains records for reading MCM01 status and to reset the -MCM01 module. - -Ai record $(P)-STATUS_ reads the status value from the MCM01 module, a -mbbiDirect record is provided to set the status bits - 16 bi records are -provided to parse these bits. An additional calc record is provided -($(P)-CON-ERR) which sets it's value to 1 if any of the error bits are set (if -only noticiation bits are set, e.g. terminal-activated, the value of -$(P)-CON-ERR is 0) - -Bo record $(P)-RESET resets the MCM01 controller, every time it is processed. -$(P)-RESET_ alternates between 0 and 1, so the monitor is posted on every reset -and the axis REINIT_ record can trigger the initialization procedures. - -================================ -Motor Record - Phytron_motor.db: -================================ -This database file is similar to basic_asyn_motor.db, the only difference is, -that 2 additional fields are defined: - - field(ERES,"$(ERES)") - encoder resolution - - field(VMAX,"$(VMAX)") - maximum velocity - - -=============================================================================== -List of remaining I1AM01 parameters handled by the motor record, internally by -controller, or not applicable -=============================================================================== -P02 (Units of movemnt) - Always set to step - unit conversion is done within the -motor record. - -P03 (Conversion factor for the thread) - Always set to 1 - unit conversion is -done within the motor record. - -P04 (Start/stop frequency) - Set by phytronAxis::move, before move is executed. - -P07 (Emergency stop ramp) - Set by phytronAxis::stop, before stop is executed. - -P08 (Initialization run frequency) - Set by phytronAxis::home, before homing is -executed. - -P09 (Ramp M0P) - Set by phytronAxis::home, before homing is executed. - -P10 (Run frequency for leaving the limit switch) - Set by phytronAxis::home, -before homing is executed - -P14 (Run frequency during program operation) - Set by phytronAxis::move, before -move is executed - -P15 (Ramp for run frequency) - Set by phytronAxis::move, before move is executed - -P18 (Used internally by controller) - -P19 (Encoder deviation M0P counter) - -P20 (Mechanical 0 counter) - read by phytronAxis::poll to determine motor -position - -P21 (Absolute counter) - -P22 (Encoder counter) - read by phytronAxis::poll to determine encoder position - -P23 and P24 - Software limit switches - these parameters are ignored, because -motor record handles software limits - -P25 (Compensation for play) - Ignored, because motor records handles backlash -corrections - -P29 (Not used (by controller)) - -P30 and P31 (For I4XM01 only) - -P32 and P33 (Not used (by controller)) - -P44 (For I4XM01 only) - -P46, P47, P48 (Not used (by controller)) - -P50 and P51 (For I4XM01 only) - -P52 (Internally used for trigger position) - - -GUI: -==== -The follwoing CSS BOY GUI screens are located in motorApp/op/opi: - -PhytronMain.opi ---------------- -Motor record name is usually defined with 2 macros: -record(motor, "$(P)$(M)") - -The value of the macro $(IOC) of the PhytronMain.opi screen must match the value -of the macro $(P) which is defined in motor.substitutions. - -PhytronMain.opi has 2 action buttons to open screen PhytronI1AM01.opi for motor -$(IOC):$(M), where the default values for $(M) are "m1" for the left button -and "m2" for the right button. User must modify the values of macros $(IOC) and -$(M) according to the macro values in motor.subsititutions. - -PhytronMain.opi also contains a CONTROLLER STATUS line. The LED displays the -value of record $(P)-CON-ERR (see section MC01 Controller Features). Action -button "MORE" opens the screen PhytronMCM01Status.opi, action button "RESET" -resets the MCM01 controller and action button "RESET CONTROLLER" resets -controller status. - -PhytronI1AM01.opi ------------------ -Status line contains a LED which displays the value of the record -$(P)$(M)-AXIS-ERR, and an action button which displays the PhytronI1AM01.opi -screen. Action buttons "RESET AXIS" and "RESET STATUS" are provided. - -The remaining widgets are used to set and read back the values of supported -I1AM01 parameters (see section I1AM01 Controller Features). - -PhytronI1AM01Status.opi ------------------------ -Contains an LED for each of the 23 bi records parsing the $(P)$(M)-STATUS-1/2 -mbbiDirect records. - -PhytronMCM01Status.opi ----------------------- -Contains an LED for each of the 16 bi records parsing the $(P)-STATUS-BITS_ -mbbiDirect record - - - - - - diff --git a/motorApp/PhytronSrc/phytron.dbd b/motorApp/PhytronSrc/phytron.dbd deleted file mode 100644 index 6cd997ea..00000000 --- a/motorApp/PhytronSrc/phytron.dbd +++ /dev/null @@ -1 +0,0 @@ -registrar(phytronRegister) diff --git a/motorApp/PhytronSrc/phytronAxisMotor.cpp b/motorApp/PhytronSrc/phytronAxisMotor.cpp deleted file mode 100644 index 33231247..00000000 --- a/motorApp/PhytronSrc/phytronAxisMotor.cpp +++ /dev/null @@ -1,1034 +0,0 @@ -/* -FILENAME... phytronAxisMotor.cpp -USAGE... Motor driver support for Phytron Axis controller. - -Tom Slejko & Bor Marolt -Cosylab d.d. 2014 - -*/ - -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef _WIN32 -#include -#endif - -#include -#include -#include -#include - -#include - -#include "phytronAxisMotor.h" -#include - -using namespace std; - -#ifndef ASYN_TRACE_WARNING -#define ASYN_TRACE_WARNING ASYN_TRACE_ERROR -#endif - -//Used for casting position doubles to integers -#define NINT(f) (int)((f)>0 ? (f)+0.5 : (f)-0.5) - -/* - * Contains phytronController instances, phytronCreateAxis uses it to find and - * bind axis object to the correct controller object. - */ -static vector controllers; - -/** Creates a new phytronController object. - * \param[in] portName The name of the asyn port that will be created for this driver - * \param[in] phytronPortName The name of the drvAsynIPPort that was created previously to connect to the phytron controller - * \param[in] movingPollPeriod The time between polls when any axis is moving - * \param[in] idlePollPeriod The time between polls when no axis is moving - */ -phytronController::phytronController(const char *phytronPortName, const char *asynPortName, - double movingPollPeriod, double idlePollPeriod, double timeout) - : asynMotorController(phytronPortName, - 0xFF, - NUM_PHYTRON_PARAMS, - 0, //No additional interfaces beyond those in base class - 0, //No additional callback interfaces beyond those in base class - ASYN_CANBLOCK | ASYN_MULTIDEVICE, - 1, // autoconnect - 0, 0)// Default priority and stack size -{ - asynStatus status; - size_t response_len; - phytronStatus phyStatus; - static const char *functionName = "phytronController::phytronController"; - - //Timeout is defined in milliseconds, but sendPhytronCommand expects seconds - timeout_ = timeout/1000; - - //pyhtronCreateAxis uses portName to identify the controller - this->controllerName_ = (char *) mallocMustSucceed(sizeof(char)*(strlen(portName)+1), - "phytronController::phytronController: Controller name memory allocation failed.\n"); - - strcpy(this->controllerName_, portName); - - //Create Controller parameters - createParam(controllerStatusString, asynParamInt32, &this->controllerStatus_); - createParam(controllerStatusResetString,asynParamInt32, &this->controllerStatusReset_); - createParam(resetControllerString, asynParamInt32, &this->resetController_); - - //Create Axis parameters - createParam(axisStatusResetString, asynParamInt32, &this->axisStatusReset_); - createParam(axisResetString, asynParamInt32, &this->axisReset_); - createParam(axisStatusString, asynParamInt32, &this->axisStatus_); - createParam(homingProcedureString, asynParamInt32, &this->homingProcedure_); - createParam(axisModeString, asynParamInt32, &this->axisMode_); - createParam(mopOffsetPosString, asynParamInt32, &this->mopOffsetPos_); - createParam(mopOffsetNegString, asynParamInt32, &this->mopOffsetNeg_); - createParam(stepResolutionString, asynParamInt32, &this->stepResolution_); - createParam(stopCurrentString, asynParamInt32, &this->stopCurrent_); - createParam(runCurrentString, asynParamInt32, &this->runCurrent_); - createParam(boostCurrentString, asynParamInt32, &this->boostCurrent_); - createParam(encoderTypeString, asynParamInt32, &this->encoderType_); - createParam(initRecoveryTimeString, asynParamInt32, &this->initRecoveryTime_); - createParam(positionRecoveryTimeString, asynParamInt32, &this->positionRecoveryTime_); - createParam(boostConditionString, asynParamInt32, &this->boost_); - createParam(encoderRateString, asynParamInt32, &this->encoderRate_); - createParam(switchTypString, asynParamInt32, &this->switchTyp_); - createParam(pwrStageModeString, asynParamInt32, &this->pwrStageMode_); - createParam(encoderResolutionString, asynParamInt32, &this->encoderRes_); - createParam(encoderFunctionString, asynParamInt32, &this->encoderFunc_); - createParam(encoderSFIWidthString, asynParamInt32, &this->encoderSFIWidth_); - createParam(encoderDirectionString, asynParamInt32, &this->encoderDirection_); - createParam(powerStagetMonitorString, asynParamInt32, &this->powerStageMonitor_); - createParam(currentDelayTimeString, asynParamInt32, &this->currentDelayTime_); - createParam(powerStageTempString, asynParamFloat64, &this->powerStageTemp_); - createParam(motorTempString, asynParamFloat64, &this->motorTemp_); - - - /* Connect to phytron controller */ - status = pasynOctetSyncIO->connect(asynPortName, 0, &pasynUserController_, NULL); - if (status) { - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "%s: cannot connect to phytron controller\n", - functionName); - } else { - //phytronCreateAxis will search for the controller for axis registration - controllers.push_back(this); - - //RESET THE CONTROLLER - sprintf(this->outString_, "CR"); - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronController::phytronController: Could not reset controller %s\n", this->controllerName_); - } - - //Wait for reset to finish - epicsThreadSleep(10.0); - - startPoller(movingPollPeriod, idlePollPeriod, 5); - } - -} - -/** Creates a new phytronController object. - * Configuration command, called directly or from iocsh - * \param[in] portName The name of the asyn port that will be created for this driver - * \param[in] phytronPortName The name of the drvAsynIPPPort that was created previously to connect to the phytron controller - * \param[in] numController number of axes that this controller supports is numController*AXES_PER_CONTROLLER - * \param[in] movingPollPeriod The time in ms between polls when any axis is moving - * \param[in] idlePollPeriod The time in ms between polls when no axis is moving - */ -extern "C" int phytronCreateController(const char *phytronPortName, const char *asynPortName, - int movingPollPeriod, int idlePollPeriod, double timeout) -{ - phytronController *pphytronController = new phytronController(phytronPortName, asynPortName, movingPollPeriod/1000., idlePollPeriod/1000., timeout); - pphytronController = NULL; - return asynSuccess; -} - -/** asynUsers use this to read integer parameters - * \param[in] pasynUser asynUser structure containing the reason - * \param[out] value Parameter value - */ -asynStatus phytronController::readInt32(asynUser *pasynUser, epicsInt32 *value) -{ - phytronAxis *pAxis; - phytronStatus phyStatus; - - //Call base implementation first - asynPortDriver::readInt32(pasynUser, value); - - //Check if this is a call to read a controller parameter - if(pasynUser->reason == resetController_ || pasynUser->reason == controllerStatusReset_){ - //Called only on initialization of bo records RESET and RESET-STATUS - return asynSuccess; - } else if (pasynUser->reason == controllerStatus_){ - size_t response_len; - sprintf(this->outString_, "ST"); - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::readInt32: Reading controller %s status failed with error " - "code: %d\n", this->controllerName_, phyStatus); - return phyToAsyn(phyStatus); - } - - *value = atoi(this->inString_); - return asynSuccess; - } - - //This is an axis request, find the axis - pAxis = getAxis(pasynUser); - if(!pAxis){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::readInt32: Axis not found on the controller %s\n", this->controllerName_); - return asynError; - } - - if(pasynUser->reason == homingProcedure_){ - getIntegerParam(pAxis->axisNo_, homingProcedure_, value); - return asynSuccess; - } else if (pasynUser->reason == axisReset_ || pasynUser->reason == axisStatusReset_){ - //Called only on initialization of AXIS-RESET and AXIS-STATUS-RESET bo records - return asynSuccess; - } else if (pasynUser->reason == axisMode_){ - sprintf(this->outString_, "M%.1fP01R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == mopOffsetPos_){ - sprintf(this->outString_, "M%.1fP11R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == mopOffsetNeg_){ - sprintf(this->outString_, "M%.1fP12R", pAxis->axisModuleNo_); - } else if (pasynUser->reason == stepResolution_){ - sprintf(this->outString_, "M%.1fP45R", pAxis->axisModuleNo_); - } else if (pasynUser->reason == stopCurrent_){ - sprintf(this->outString_, "M%.1fP40R", pAxis->axisModuleNo_); - } else if (pasynUser->reason == runCurrent_){ - sprintf(this->outString_, "M%.1fP41R", pAxis->axisModuleNo_); - } else if (pasynUser->reason == boostCurrent_){ - sprintf(this->outString_, "M%.1fP42R", pAxis->axisModuleNo_); - } else if (pasynUser->reason == encoderType_){ - sprintf(this->outString_, "M%.1fP34R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == initRecoveryTime_){ - sprintf(this->outString_, "M%.1fP13R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == positionRecoveryTime_){ - sprintf(this->outString_, "M%.1fP16R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == boost_){ - sprintf(this->outString_, "M%.1fP17R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == encoderRate_){ - sprintf(this->outString_, "M%.1fP26R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == switchTyp_){ - sprintf(this->outString_, "M%.1fP27R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == pwrStageMode_){ - sprintf(this->outString_, "M%.1fP28R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == encoderRes_){ - sprintf(this->outString_, "M%.1fP35R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == encoderFunc_){ - sprintf(this->outString_, "M%.1fP36R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == encoderSFIWidth_){ - sprintf(this->outString_, "M%.1fP37R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == encoderDirection_){ - sprintf(this->outString_, "M%.1fP38R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == currentDelayTime_){ - sprintf(this->outString_, "M%.1fP43R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == powerStageMonitor_){ - sprintf(this->outString_, "M%.1fP53R", pAxis->axisModuleNo_); - } - - - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &pAxis->response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::readInt32: Failed with status %d for reason %d\n", phyStatus, pasynUser->reason); - return phyToAsyn(phyStatus); - } - - *value = atoi(this->inString_); - - //{STOP,RUN,BOOST} current records have EGU set to mA, but device returns 10mA - if(pasynUser->reason == stopCurrent_ || pasynUser->reason == runCurrent_ || - pasynUser->reason == boostCurrent_) - { - *value *= 10; - } // else if - - - return asynSuccess; -} - -/** asynUsers use this to write integer parameters - * \param[in] pasynUser asynUser structure containing the reason - * \param[in] value Parameter value to be written - */ -asynStatus phytronController::writeInt32(asynUser *pasynUser, epicsInt32 value) -{ - phytronAxis *pAxis; - phytronStatus phyStatus; - - //Call base implementation first - asynMotorController::writeInt32(pasynUser, value); - - /* - * Check if this is a call to reset the controller, else it is an axis request - */ - if(pasynUser->reason == resetController_){ - size_t response_len; - sprintf(this->outString_, "CR"); - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::writeInt32: Reseting controller %s failed with error code: %d\n", this->controllerName_, phyStatus); - } - resetAxisEncoderRatio(); - return phyToAsyn(phyStatus); - } else if(pasynUser->reason == controllerStatusReset_){ - size_t response_len; - sprintf(this->outString_, "STC"); - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::writeInt32: Reseting controller %s failed with error code: %d\n", this->controllerName_, phyStatus); - } - return phyToAsyn(phyStatus); - } - /* - * This is an axis request, find the axis - */ - pAxis = getAxis(pasynUser); - if(!pAxis){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::writeInt32: Axis not found on the controller %s\n", this->controllerName_); - return asynError; - } - - if(pasynUser->reason == homingProcedure_){ - setIntegerParam(pAxis->axisNo_, pasynUser->reason, value); - callParamCallbacks(); - return asynSuccess; - } else if(pasynUser->reason == axisReset_){ - sprintf(this->outString_, "M%.1fC", pAxis->axisModuleNo_); - } else if(pasynUser->reason == axisStatusReset_){ - sprintf(this->outString_, "SEC%.1f", pAxis->axisModuleNo_); - } else if(pasynUser->reason == axisMode_){ - sprintf(this->outString_, "M%.1fP01=%d", pAxis->axisModuleNo_,value); - } else if(pasynUser->reason == mopOffsetPos_){ - sprintf(this->outString_, "M%.1fP11=%d", pAxis->axisModuleNo_,value); - } else if(pasynUser->reason == mopOffsetNeg_){ - sprintf(this->outString_, "M%.1fP12=%d", pAxis->axisModuleNo_,value); - } else if (pasynUser->reason == stepResolution_){ - sprintf(this->outString_, "M%.1fP45=%d", pAxis->axisModuleNo_,value); - } else if (pasynUser->reason == stopCurrent_){ - value /= 10; //STOP_CURRENT record has EGU mA, device expects 10mA - sprintf(this->outString_, "M%.1fP40=%d", pAxis->axisModuleNo_,value); - } else if (pasynUser->reason == runCurrent_){ - value /= 10; //RUN_CURRENT record has EGU mA, device expects 10mA - sprintf(this->outString_, "M%.1fP41=%d", pAxis->axisModuleNo_,value); - } else if (pasynUser->reason == boostCurrent_){ - value /= 10; //BOOST_CURRENT record has EGU mA, device expects 10mA - sprintf(this->outString_, "M%.1fP42=%d", pAxis->axisModuleNo_,value); - } else if (pasynUser->reason == encoderType_){ - sprintf(this->outString_, "M%.1fP34=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == initRecoveryTime_){ - sprintf(this->outString_, "M%.1fP13=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == positionRecoveryTime_){ - sprintf(this->outString_, "M%.1fP16=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == boost_){ - sprintf(this->outString_, "M%.1fP17=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == encoderRate_){ - sprintf(this->outString_, "M%.1fP26=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == switchTyp_){ - sprintf(this->outString_, "M%.1fP27=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == pwrStageMode_){ - sprintf(this->outString_, "M%.1fP28=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == encoderRes_){ - sprintf(this->outString_, "M%.1fP35=%d", pAxis->axisModuleNo_, value); - } else if (pasynUser->reason == encoderFunc_){ - //Value is VAL field of parameter P37 record. If P37 is positive P36 is set to 1, else 0 - sprintf(this->outString_, "M%.1fP36=%d", pAxis->axisModuleNo_, value > 0 ? 1 : 0); - } else if(pasynUser->reason == encoderSFIWidth_){ - sprintf(this->outString_, "M%.1fP37=%d", pAxis->axisModuleNo_, value); - } else if(pasynUser->reason == encoderSFIWidth_){ - sprintf(this->outString_, "M%.1fP38=%d", pAxis->axisModuleNo_, value); - } else if(pasynUser->reason == powerStageMonitor_){ - sprintf(this->outString_, "M%.1fP53=%d", pAxis->axisModuleNo_, value); - } else if(pasynUser->reason == currentDelayTime_){ - sprintf(this->outString_, "M%.1fP43=%d", pAxis->axisModuleNo_, value); - } else if(pasynUser->reason == encoderDirection_){ - sprintf(this->outString_, "M%.1fP38=%d", pAxis->axisModuleNo_, value); - } - - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &pAxis->response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::writeInt32: Failed with status %d for reason %d\n", phyStatus, pasynUser->reason); - return phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -/** asynUsers use this to read float parameters - * \param[in] pasynUser asynUser structure containing the reason - * \param[out] value Parameter value - */ -asynStatus phytronController::readFloat64(asynUser *pasynUser, epicsFloat64 *value){ - phytronAxis *pAxis; - phytronStatus phyStatus; - - pAxis = getAxis(pasynUser); - if(!pAxis){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::readFloat64: Axis not found on the controller %s\n", this->controllerName_); - return asynError; - } - - //Call base implementation first - asynPortDriver::readFloat64(pasynUser, value); - - if(pasynUser->reason == powerStageTemp_){ - sprintf(this->outString_, "M%.1fP49R", pAxis->axisModuleNo_); - } else if(pasynUser->reason == motorTemp_){ - sprintf(this->outString_, "M%.1fP54R", pAxis->axisModuleNo_); - } - - phyStatus = sendPhytronCommand(this->outString_, this->inString_, MAX_CONTROLLER_STRING_SIZE, &pAxis->response_len); - if(phyStatus){ - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::readFloat64: Failed with status %d for reason %d\n", phyStatus, pasynUser->reason); - return phyToAsyn(phyStatus); - } - - *value = atof(this->inString_); - - //Power stage and motor temperature records have EGU °C, but device returns 0.1 °C - *value /= 10; - - return phyToAsyn(phyStatus); - -} -/* - * Reset the motorEncoderRatio to 1 after the reset of MCM unit - */ -void phytronController::resetAxisEncoderRatio(){ - - for(uint32_t i = 0; i < axes.size(); i++){ - setDoubleParam(axes[i]->axisNo_, motorEncoderRatio_, 1); - } -} - - -/** Reports on status of the driver - * \param[in] fp The file pointer on which report information will be written - * \param[in] level The level of report detail desired - * - * If details > 0 then information is printed about each axis. - * After printing controller-specific information it calls asynMotorController::report() - */ -void phytronController::report(FILE *fp, int level) -{ - fprintf(fp, "MCB-4B motor driver %s, numAxes=%d, moving poll period=%f, idle poll period=%f\n", - this->portName, numAxes_, movingPollPeriod_, idlePollPeriod_); - - // Call the base class method - asynMotorController::report(fp, level); -} - -/** Returns a pointer to an phytronAxis object. - * Returns NULL if the axis number encoded in pasynUser is invalid. - * \param[in] pasynUser asynUser structure that encodes the axis index number. - */ -phytronAxis* phytronController::getAxis(asynUser *pasynUser) -{ - return static_cast(asynMotorController::getAxis(pasynUser)); -} - -/** Returns a pointer to an phytronAxis object. - * Returns NULL if the axis number encoded in pasynUser is invalid. - * \param[in] axisNo Axis index number. - */ -phytronAxis* phytronController::getAxis(int axisNo) -{ - return static_cast(asynMotorController::getAxis(axisNo)); -} - -/** - * @brief implements phytron specific data fromat - * @param output - * @param input - * @param maxChars - * @param nread - * @param timeout - * @return - */ -phytronStatus phytronController::sendPhytronCommand(const char *command, char *response_buffer, size_t response_max_len, size_t *nread) -{ - char buffer[255]; - char* buffer_end=buffer; - static const char *functionName = "phytronController::sendPhytronCommand"; - - *(buffer_end++)=0x02; //STX - *(buffer_end++)='0'; //Module address TODO: add class member - buffer_end += sprintf(buffer_end,"%s",command); //Append command - *(buffer_end++)=0x3a; //Append separator - - buffer_end += sprintf(buffer_end,"%c%c",'X','X'); //XX disables checksum - *(buffer_end++)=0x03; //Append ETX - *(buffer_end)=0x0; //Null terminate message for saftey - - phytronStatus status = (phytronStatus) writeReadController(buffer,buffer,255,nread, timeout_); - if(status){ - return status; - } - - char* nack_ack = strchr(buffer,0x02); //Find STX - if(!nack_ack){ - nread=0; - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "%s: Communication failed\n", - functionName); - return phytronInvalidReturn; - } - nack_ack++; //NACK/ACK is one - //ACK, extract response - if(*nack_ack==0x06){ - char* separator = strchr(nack_ack,0x3a); //find separator - - /* Copy data from nack_ack to - * separator into buffer */ - uint32_t len = separator-nack_ack-1; //calculate length of message - if(len > response_max_len) len=response_max_len; - - memcpy(response_buffer,nack_ack+1,len); //copy payload to destination - response_buffer[separator-nack_ack-1]=0; //Add NULL terminator - - *nread=strlen(response_buffer); - } - //NAK return error - else if(*nack_ack==0x15){ - nread=0; - asynPrint(this->pasynUserSelf, ASYN_TRACE_ERROR, - "%s: Nack sent by the controller\n", - functionName); - return phytronInvalidCommand; - } - - return status; - -} - -/** Castst phytronStatus to asynStatus enumeration - * \param[in] phyStatus - */ -asynStatus phytronController::phyToAsyn(phytronStatus phyStatus){ - if(phyStatus == phytronInvalidReturn || phyStatus == phytronInvalidCommand) return asynError; - return (asynStatus) phyStatus; -} - - -//****************************************************************************** -// PHYTRON AXIS IMPLEMENTATION -//****************************************************************************** - -/** Creates a new phytronAxis object. - * Configuration command, called directly or from iocsh - * \param[in] controllerName Name of the asyn port created by calling phytronCreateController from st.cmd - * \param[in] module Index of the I1AM01 module controlling this axis - * \param[in] axis Axis index - */ -extern "C" int phytronCreateAxis(const char* controllerName, int module, int axis){ - - phytronAxis *pAxis; - - //Find the controller - uint32_t i; - for(i = 0; i < controllers.size(); i++){ - if(!strcmp(controllers[i]->controllerName_, controllerName)) { - pAxis = new phytronAxis(controllers[i], module*10 + axis); - controllers[i]->axes.push_back(pAxis); - break; - } - } - - //If controller is not found, report error - if(i == controllers.size()){ - printf("ERROR: phytronCreateAxis: Controller %s is not registered\n", controllerName); - return asynError; - } - - return asynSuccess; -} - -/** Creates a new phytronAxis object. - * \param[in] pC Pointer to the phytronController to which this axis belongs. - * \param[in] axisNo Index number of this axis, range 0 to pC->numAxes_-1. - * - * Initializes register numbers, etc. - */ -phytronAxis::phytronAxis(phytronController *pC, int axisNo) - : asynMotorAxis(pC, axisNo), - axisModuleNo_((float)axisNo/10), - pC_(pC), - response_len(0) -{ - - //Controller always supports encoder. Encoder enable/disable is set through UEIP - setIntegerParam(pC_->motorStatusHasEncoder_, 1); - - setDoubleParam(pC_->motorEncoderRatio_, 1); - -} - - -/** Reports on status of the axis - * \param[in] fp The file pointer on which report information will be written - * \param[in] level The level of report detail desired - * - * After printing device-specific information calls asynMotorAxis::report() - */ -void phytronAxis::report(FILE *fp, int level) -{ - if (level > 0) { - fprintf(fp, " axis %d\n", - axisNo_); - } - - // Call the base class method - asynMotorAxis::report(fp, level); -} - -/** Sets velocity parameters before the move is executed. Controller produces a - * trapezoidal speed profile defined by these parmeters. - * \param[in] minVelocity Start velocity - * \param[in] maxVelocity Maximum velocity - * \param[in] moveType Type of movement determines which controller speed parameters are set - */ -phytronStatus phytronAxis::setVelocity(double minVelocity, double maxVelocity, int moveType) -{ - - phytronStatus maxStatus = phytronSuccess; - phytronStatus minStatus = phytronSuccess; - maxVelocity = fabs(maxVelocity); - minVelocity = fabs(minVelocity); - - if(maxVelocity > MAX_VELOCITY){ - maxVelocity = MAX_VELOCITY; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setVelocity: Failed for axis %d - Velocity %f is to high, setting to" - "maximum velocity: %d!\n", axisNo_, maxVelocity, MAX_VELOCITY); - } else if (maxVelocity < MIN_VELOCITY){ - maxVelocity = MIN_VELOCITY; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setVelocity: Failed for axis %d - Velocity %f is to low, setting to" - "minimum velocity: %d!\n", axisNo_, maxVelocity, MIN_VELOCITY); - } - - if(minVelocity > MAX_VELOCITY){ - minVelocity = MAX_VELOCITY; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setVelocity: Failed for axis %d - Velocity %f is to high, setting to" - "maximum velocity: %d!\n", axisNo_, maxVelocity, MAX_VELOCITY); - } else if (minVelocity < MIN_VELOCITY){ - minVelocity = MIN_VELOCITY; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setVelocity: Failed for axis %d - Velocity %f is to low, setting to" - "minimum velocity: %d!\n", axisNo_, minVelocity, MIN_VELOCITY); - } - - - if(moveType == stdMove){ - //Set maximum velocity (P14) - sprintf(pC_->outString_, "M%.1fP14=%f", axisModuleNo_, maxVelocity); - maxStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - - //Set minimum velocity (P04) - sprintf(pC_->outString_, "M%.1fP04=%f", axisModuleNo_, minVelocity); - minStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - } else if (moveType == homeMove){ - //Set maximum velocity (P08) - sprintf(pC_->outString_, "M%.1fP08=%f", axisModuleNo_, maxVelocity); - maxStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - - //Set minimum velocity (P10) - sprintf(pC_->outString_, "M%.1fP10=%f", axisModuleNo_, minVelocity); - minStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - } - - return (maxStatus > minStatus) ? maxStatus : minStatus; -} - -/** Sets acceleration parameters before the move is executed. - * \param[in] acceleration Acceleration to be used in the move - * \param[in] moveType Type of movement determines which controller acceleration parameters is set - */ -phytronStatus phytronAxis::setAcceleration(double acceleration, int moveType) -{ - if(acceleration > MAX_ACCELERATION){ - acceleration = MAX_ACCELERATION; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setAcceleration: Failed for axis %d - Acceleration %f is to high, " - "setting to maximum acceleration: %d!\n", axisNo_, acceleration, MAX_ACCELERATION); - } else if(acceleration < MIN_ACCELERATION){ - acceleration = MIN_ACCELERATION; - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_WARNING, - "phytronAxis::setAcceleration: Failed for axis %d - Acceleration %f is to low, " - "setting to minimum acceleration: %d!\n", axisNo_, acceleration, MIN_ACCELERATION); - } - - if (moveType == stdMove){ - sprintf(pC_->outString_, "M%.1fP15=%f", axisModuleNo_, acceleration); - } else if(moveType == homeMove){ - sprintf(pC_->outString_, "M%.1fP09=%f", axisModuleNo_, acceleration); - } else if (moveType == stopMove){ - sprintf(pC_->outString_, "M%.1fP07=%f", axisModuleNo_, acceleration); - } - - return pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); -} - -/** Execute the move. - * \param[in] position Target position (relative or absolute). - * \param[in] relative Is the move absolute or relative - * \param[in] minVelocity Lowest velocity of the trapezoidal speed profile. - * \param[in] maxVelocity Highest velocity of the trapezoidal speed profile - * \param[in] acceleration Acceleration to be used - */ -asynStatus phytronAxis::move(double position, int relative, double minVelocity, double maxVelocity, double acceleration) -{ - phytronStatus phyStatus; - - //NOTE: Check if velocity is different, before setting it. - phyStatus = setVelocity(minVelocity, maxVelocity, stdMove); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::move: Setting the velocity for axis %d to %f failed with error " - "code: %d!\n", axisNo_, maxVelocity, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - //NOTE: Check if velocity is different, before setting it. - phyStatus = setAcceleration(acceleration, stdMove); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::move: Setting the acceleration for axis %d to %f failed with " - "error code: %d!\n", axisNo_, acceleration, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - if (relative) { - sprintf(pC_->outString_, "M%.1f%c%d", axisModuleNo_, position>0 ? '+':'-', abs(NINT(position))); - } else { - sprintf(pC_->outString_, "M%.1fA%d", axisModuleNo_, NINT(position)); - } - - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::move: Moving axis %d failed with error code: %d!\n", axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -/** Execute the homing procedure - * \param[in] minVelocity Lowest velocity of the trapezoidal speed profile. - * \param[in] maxVelocity Highest velocity of the trapezoidal speed profile - * \param[in] acceleration Acceleration to be used - * \param[in] forwards Direction of homing move - */ -asynStatus phytronAxis::home(double minVelocity, double maxVelocity, double acceleration, int forwards) -{ - phytronStatus phyStatus; - int homingType; - - pC_->getIntegerParam(axisNo_, pC_->homingProcedure_, &homingType); - - phyStatus = setVelocity(minVelocity, maxVelocity, homeMove); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::home: Setting the velocity for axis %d to %f failed with error " - "code: %d!\n", axisNo_, maxVelocity, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - phyStatus = setAcceleration(acceleration, homeMove); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::home: Setting the acceleration for axis %d to %f failed with " - "error code: %d!\n", axisNo_, acceleration, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - if(forwards){ - if(homingType == limit) sprintf(pC_->outString_, "M%.1fR+", axisModuleNo_); - else if(homingType == center) sprintf(pC_->outString_, "M%.1fR+C", axisModuleNo_); - else if(homingType == encoder) sprintf(pC_->outString_, "M%.1fR+I", axisModuleNo_); - else if(homingType == limitEncoder) sprintf(pC_->outString_, "M%.1fR+^I", axisModuleNo_); - else if(homingType == centerEncoder) sprintf(pC_->outString_, "M%.1fR+C^I", axisModuleNo_); - //Homing procedures for rotational movements (no hardware limit switches) - else if(homingType == referenceCenter) sprintf(pC_->outString_, "M%.1fRC+", axisModuleNo_); - else if(homingType == referenceCenterEncoder) sprintf(pC_->outString_, "M%.1fRC+^I", axisModuleNo_); - } else { - if(homingType == limit) sprintf(pC_->outString_, "M%.1fR-", axisModuleNo_); - else if(homingType == center) sprintf(pC_->outString_, "M%.1fR-C", axisModuleNo_); - else if(homingType == encoder) sprintf(pC_->outString_, "M%.1fR-I", axisModuleNo_); - else if(homingType == limitEncoder) sprintf(pC_->outString_, "M%.1fR-^I", axisModuleNo_); - else if(homingType == centerEncoder) sprintf(pC_->outString_, "M%.1fR-C^I", axisModuleNo_); - //Homing procedures for rotational movements (no hardware limit switches) - else if(homingType == referenceCenter) sprintf(pC_->outString_, "M%.1fRC-", axisModuleNo_); - else if(homingType == referenceCenterEncoder) sprintf(pC_->outString_, "M%.1fRC-^I", axisModuleNo_); - } - - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::home: Moving axis %d failed with error code: %d!\n", axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -/** Jog the motor. Direction is determined by sign of the maxVelocity profile - * \param[in] minVelocity Lowest velocity of the trapezoidal speed profile. - * \param[in] maxVelocity Highest velocity of the trapezoidal speed profile - * \param[in] acceleration Acceleration to be used - */ -asynStatus phytronAxis::moveVelocity(double minVelocity, double maxVelocity, double acceleration) -{ - phytronStatus phyStatus; - - phyStatus = setVelocity(minVelocity, maxVelocity, stdMove); - if(phyStatus){ - - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::moveVelocity: Setting the velocity for axis %d to %f failed with error " - "code: %d!\n", axisNo_, maxVelocity, phyStatus); - } - - phyStatus = setAcceleration(acceleration, stdMove); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::moveVelocity: Setting the acceleration for axis %d to %f failed with " - "error code: %d!\n", axisNo_, acceleration, phyStatus); - } - - if(maxVelocity < 0) { - sprintf(pC_->outString_, "M%.1fL-", axisModuleNo_); - } else { - sprintf(pC_->outString_, "M%.1fL+", axisModuleNo_); - } - - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::moveVelocity: Moving axis %d failed with error code: %d!\n", axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -/** Stop the motor - * \param[in] acceleration Deceleration to be used - */ -asynStatus phytronAxis::stop(double acceleration) -{ - phytronStatus phyStatus; - - phyStatus = setAcceleration(acceleration, stopMove); - - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::stop: Setting the acceleration for axis %d to %f failed with " - "error code: %d!\n", axisNo_, acceleration, phyStatus); - } - - sprintf(pC_->outString_, "M%.1fS", axisModuleNo_); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::stop: Stopping axis %d failed with error code: %d!\n", axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -//NOTE: Use this for step-slip check? -asynStatus phytronAxis::setEncoderRatio(double ratio){ - - phytronStatus phyStatus; - - sprintf(pC_->outString_, "M%.1fP39=%f", axisModuleNo_, 1/ratio); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::setEncoderRatio: Failed for axis %d with status %d!\n", axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - - return asynSuccess; -} - -//NOTE: Keep this for step-slip check? -asynStatus phytronAxis::setEncoderPosition(double position){ - - - return asynError; -} - -/** Set the new position of the motor on the controller - * \param[in] position New absolute motor position - */ -asynStatus phytronAxis::setPosition(double position) -{ - phytronStatus phyStatus = phytronSuccess; - - sprintf(pC_->outString_, "M%.1fP20=%f", axisModuleNo_, position); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::setPosition: Setting position %f on axis %d failed with error code: %d!\n", position, axisNo_, phyStatus); - return pC_->phyToAsyn(phyStatus); - } - - return asynSuccess; -} - -/** Polls the axis. - * This function reads the motor position, the limit status, the home status, the moving status, - * and the drive power-on status. - * It calls setIntegerParam() and setDoubleParam() for each item that it polls, - * and then calls callParamCallbacks() at the end. - * \param[out] moving A flag that is set indicating that the axis is moving (true) or done (false). - */ -asynStatus phytronAxis::poll(bool *moving) -{ - int axisStatus; - double position; - double encoderPosition; - double encoderRatio; - phytronStatus phyStatus; - - // Read the current motor position - sprintf(pC_->outString_, "M%.1fP20R", axisModuleNo_); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - setIntegerParam(pC_->motorStatusProblem_, 1); - callParamCallbacks(); - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::poll: Reading axis position failed for axis: %d!\n", axisNo_); - return pC_->phyToAsyn(phyStatus); - } - position = atof(pC_->inString_); - setDoubleParam(pC_->motorPosition_, position); - - // Read the current encoder value - sprintf(pC_->outString_, "M%.1fP22R", axisModuleNo_); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - setIntegerParam(pC_->motorStatusProblem_, 1); - callParamCallbacks(); - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::poll: Reading encoder value failed for axis: %d!\n", axisNo_); - return pC_->phyToAsyn(phyStatus); - } - encoderPosition = atof(pC_->inString_); - - /* - * The encoder position returned by the controller is weighted by the controller - * resolutio. To get absolute encoder position, the received position must be - * multiplied by the encoder resolution. - */ - pC_->getDoubleParam(axisNo_, pC_->motorEncoderRatio_, &encoderRatio); - setDoubleParam(pC_->motorEncoderPosition_, encoderPosition*encoderRatio); - - // Read the moving status of this motor - sprintf(pC_->outString_, "M%.1f==H", axisModuleNo_); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - setIntegerParam(pC_->motorStatusProblem_, 1); - callParamCallbacks(); - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::poll: Reading axis moving status failed for axis: %d!\n", axisNo_); - return pC_->phyToAsyn(phyStatus); - } - *moving = (pC_->inString_[0] == 'E') ? 0:1; - setIntegerParam(pC_->motorStatusDone_, !*moving); - - sprintf(pC_->outString_, "M%.1fSE", axisModuleNo_); - phyStatus = pC_->sendPhytronCommand(pC_->outString_, pC_->inString_, MAX_CONTROLLER_STRING_SIZE, &this->response_len); - if(phyStatus){ - setIntegerParam(pC_->motorStatusProblem_, 1); - callParamCallbacks(); - asynPrint(pC_->pasynUserSelf, ASYN_TRACE_ERROR, - "phytronAxis::poll: Reading axis status failed for axis: %d!\n", axisNo_); - return pC_->phyToAsyn(phyStatus); - } - axisStatus = atoi(pC_->inString_); - setIntegerParam(pC_->motorStatusHighLimit_, (axisStatus & 0x10)/0x10); - setIntegerParam(pC_->motorStatusLowLimit_, (axisStatus & 0x20)/0x20); - setIntegerParam(pC_->motorStatusAtHome_, (axisStatus & 0x40)/0x40); - - setIntegerParam(pC_->motorStatusHomed_, (axisStatus & 0x08)/0x08); - setIntegerParam(pC_->motorStatusHome_, (axisStatus & 0x08)/0x08); - - setIntegerParam(pC_->motorStatusSlip_, (axisStatus & 0x4000)/0x4000); - - //Update the axis status record ($(P)$(M)_STATUS) - setIntegerParam(pC_->axisStatus_, axisStatus); - - //No problem occurred - setIntegerParam(pC_->motorStatusProblem_, 0); - - callParamCallbacks(); - return asynSuccess; -} - -/** Parameters for iocsh phytron axis registration*/ -static const iocshArg phytronCreateAxisArg0 = {"Controller Name", iocshArgString}; -static const iocshArg phytronCreateAxisArg1 = {"Module index", iocshArgInt}; -static const iocshArg phytronCreateAxisArg2 = {"Axis index", iocshArgInt}; -static const iocshArg* const phytronCreateAxisArgs[] = {&phytronCreateAxisArg0, - &phytronCreateAxisArg1, - &phytronCreateAxisArg2}; - -/** Parameters for iocsh phytron controller registration */ -static const iocshArg phytronCreateControllerArg0 = {"Port name", iocshArgString}; -static const iocshArg phytronCreateControllerArg1 = {"PhytronAxis port name", iocshArgString}; -static const iocshArg phytronCreateControllerArg2 = {"Moving poll period (ms)", iocshArgInt}; -static const iocshArg phytronCreateControllerArg3 = {"Idle poll period (ms)", iocshArgInt}; -static const iocshArg phytronCreateControllerArg4 = {"Idle poll period (ms)", iocshArgDouble}; -static const iocshArg * const phytronCreateControllerArgs[] = {&phytronCreateControllerArg0, - &phytronCreateControllerArg1, - &phytronCreateControllerArg2, - &phytronCreateControllerArg3, - &phytronCreateControllerArg4}; - -static const iocshFuncDef phytronCreateAxisDef = {"phytronCreateAxis", 3, phytronCreateAxisArgs}; -static const iocshFuncDef phytronCreateControllerDef = {"phytronCreateController", 5, phytronCreateControllerArgs}; - -static void phytronCreateControllerCallFunc(const iocshArgBuf *args) -{ - phytronCreateController(args[0].sval, args[1].sval, args[2].ival, args[3].ival, args[4].dval); -} - -static void phytronCreateAxisCallFunc(const iocshArgBuf *args) -{ - phytronCreateAxis(args[0].sval, args[1].ival, args[2].ival); -} - -static void phytronRegister(void) -{ - iocshRegister(&phytronCreateControllerDef, phytronCreateControllerCallFunc); - iocshRegister(&phytronCreateAxisDef, phytronCreateAxisCallFunc); -} - -extern "C" { -epicsExportRegistrar(phytronRegister); -} diff --git a/motorApp/PhytronSrc/phytronAxisMotor.h b/motorApp/PhytronSrc/phytronAxisMotor.h deleted file mode 100644 index 7315e691..00000000 --- a/motorApp/PhytronSrc/phytronAxisMotor.h +++ /dev/null @@ -1,172 +0,0 @@ -/* -FILENAME... phytronAxisMotor.h -USAGE... Motor record support for Phytron Axis controller. - -Tom Slejko & Bor Marolt -Cosylab d.d. 2014 - -*/ - -#include "asynMotorController.h" -#include "asynMotorAxis.h" - - -//Number of controller specific parameters -#define NUM_PHYTRON_PARAMS 29 - -#define MAX_VELOCITY 40000 //steps/s -#define MIN_VELOCITY 1 //steps/s - -#define MAX_ACCELERATION 500000 // steps/s^2 -#define MIN_ACCELERATION 4000 // steps/s^2 - -//Controller parameters -#define controllerStatusString "CONTROLLER_STATUS" -#define controllerStatusResetString "CONTROLLER_STATUS_RESET" -#define resetControllerString "CONTROLLER_RESET" - -//Axis parameters -#define axisStatusString "AXIS_STATUS" -#define homingProcedureString "HOMING_PROCEDURE" -#define axisModeString "AXIS_MODE" -#define mopOffsetPosString "MOP_POS" -#define mopOffsetNegString "MOP_NEG" -#define stepResolutionString "STEP_RES" -#define stopCurrentString "STOP_CURRENT" -#define runCurrentString "RUN_CURRENT" -#define boostCurrentString "BOOST_CURRENT" -#define encoderTypeString "ENCODER_TYP" -#define initRecoveryTimeString "INIT_TIME" -#define positionRecoveryTimeString "POSITION_TIME" -#define boostConditionString "BOOST" -#define encoderRateString "ENC_RATE" -#define switchTypString "SWITCH_TYP" -#define pwrStageModeString "PWR_STAGE_MODE" -#define encoderResolutionString "ENC_RESOLUTION" -#define encoderFunctionString "ENC_FUNCTION" -#define encoderSFIWidthString "ENC_SFI_WIDTH" -#define encoderDirectionString "ENC_DIRECTION" -#define powerStageTempString "PS_TEMPERATURE" -#define powerStagetMonitorString "PS_MONITOR" -#define motorTempString "MOTOR_TEMP" -#define currentDelayTimeString "CURRENT_DELAY_TIME" -#define axisResetString "AXIS_RESET" -#define axisStatusResetString "AXIS_STATUS_RESET" - -typedef enum { - phytronSuccess, - phytronTimeout, - phytronOverflow, - phytronError, - phytronDisconnected, - phytronDisabled, - phytronInvalidReturn, - phytronInvalidCommand -} phytronStatus; - -enum movementType{ - stdMove, - homeMove, - stopMove -}; - -enum homingType{ - limit, - center, - encoder, - limitEncoder, - centerEncoder, - referenceCenter, - referenceCenterEncoder, -}; - - -class phytronAxis : public asynMotorAxis -{ -public: - /* These are the methods we override from the base class */ - phytronAxis(class phytronController *pC, int axis); - void report(FILE *fp, int level); - asynStatus move(double position, int relative, double min_velocity, double max_velocity, double acceleration); - asynStatus moveVelocity(double min_velocity, double max_velocity, double acceleration); - asynStatus home(double min_velocity, double max_velocity, double acceleration, int forwards); - asynStatus stop(double acceleration); - asynStatus poll(bool *moving); - asynStatus setPosition(double position); - - asynStatus setEncoderRatio(double ratio); - asynStatus setEncoderPosition(double position); - - float axisModuleNo_; //Used by sprintf to form commands - -private: - phytronController *pC_; /**< Pointer to the asynMotorController to which this axis belongs. - * Abbreviated because it is used very frequently */ - - phytronStatus setVelocity(double minVelocity, double maxVelocity, int moveType); - phytronStatus setAcceleration(double acceleration, int movementType); - - size_t response_len; - -friend class phytronController; -}; - -class phytronController : public asynMotorController { -public: - phytronController(const char *portName, const char *phytronPortName, double movingPollPeriod, double idlePollPeriod, double timeout); - asynStatus readInt32(asynUser *pasynUser, epicsInt32 *value); - asynStatus writeInt32(asynUser *pasynUser, epicsInt32 value); - asynStatus readFloat64(asynUser *pasynUser, epicsFloat64 *value); - - void report(FILE *fp, int level); - phytronAxis* getAxis(asynUser *pasynUser); - phytronAxis* getAxis(int axisNo); - - phytronStatus sendPhytronCommand(const char *command, char *response_buffer, size_t response_max_len, size_t *nread); - - void resetAxisEncoderRatio(); - - //casts phytronStatus to asynStatus - asynStatus phyToAsyn(phytronStatus phyStatus); - - char * controllerName_; - std::vector axes; - -protected: - //Additional parameters used by additional records - int axisStatus_; - int controllerStatus_; - int homingProcedure_; - int axisMode_; - int mopOffsetPos_; - int mopOffsetNeg_; - int stepResolution_; - int stopCurrent_; - int runCurrent_; - int boostCurrent_; - int encoderType_; - int initRecoveryTime_; - int positionRecoveryTime_; - int boost_; - int encoderRate_; - int switchTyp_; - int pwrStageMode_; - int encoderRes_; - int encoderFunc_; - int encoderSFIWidth_; - int encoderDirection_; - int powerStageTemp_; - int powerStageMonitor_; - int motorTemp_; - int currentDelayTime_; - int resetController_; - int axisReset_; - int axisStatusReset_; - int controllerStatusReset_; - -private: - double timeout_; - - -friend class phytronAxis; -}; diff --git a/motorApp/op/opi/PhytronI1AM01.opi b/motorApp/op/opi/PhytronI1AM01.opi deleted file mode 100644 index 69cedcfb..00000000 --- a/motorApp/op/opi/PhytronI1AM01.opi +++ /dev/null @@ -1,3389 +0,0 @@ - - - false - - true - - 2da4dada:138bb0b2666:-7ff6 - 3.2.16.20140409 - - true - 650 - Display - true - false - - - - - - - Display - true - 800 - - true - 6 - - false - -1 - -1 - - - -1 - -1 - - true - 1 - -3ea02a50:1499f605597:-7ef5 - false - - 26 - Label - - true - true - false - - true - false - - - - - - - Label - true - AXIS MODE - - Default - - 80 - 0 - - 1 - - - - 0 - - 129 - true - - 17 - - - false - true - true - -3ea02a50:1499f605597:-7ef1 - - 23 - Menu Button - false - - true - true - false - - false - $(IOC)$(M)-MOVE-TYP_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 132 - $(pv_name) -$(pv_value) - 116 - - - true - 1 - -319a9108:1499f67a49e:-7efc - false - - 26 - Label_1 - - true - true - false - - true - false - - - - - - - Label - true - HOMING MODE - - Default - - 100 - 0 - - 1 - - - - 0 - - 168 - true - - 17 - - - false - true - true - -319a9108:1499f67a49e:-7efb - - 23 - Menu Button_1 - false - - true - true - false - - false - $(IOC)$(M)-HOMING_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 170 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -319a9108:1499f67a49e:-7ed7 - false - 0.0 - - 26 - Text Update - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-MOVE-TYP_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 132 - false - $(pv_name) -$(pv_value) - 260 - - - true - true - 1 - true - -319a9108:1499f67a49e:-7eb7 - false - 0.0 - - 26 - Text Update_1 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-HOMING_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 170 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -319a9108:1499f67a49e:-7eab - false - - 26 - Label_2 - - true - true - false - - true - false - - - - - - - Label - true - POSITIVE OFFSET - - Default - - 111 - 0 - - 1 - - - - 0 - - 56 - true - - 419 - - - true - 1 - -319a9108:1499f67a49e:-7e9d - false - - 26 - Label_3 - - true - true - false - - true - false - - - - - - - Label - true - NEGATIVE OFFSET - - Default - - 111 - 0 - - 1 - - - - 0 - - 94 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -319a9108:1499f67a49e:-7e8b - - Text_1 - 0 - - true - true - false - - $(IOC)$(M)-POS-OFFSET_SET - - - - 0 - false - - - false - 0 - - - - 56 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -319a9108:1499f67a49e:-7e71 - false - 0.0 - - 26 - Text Update_2 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-POS-OFFSET_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 56 - false - $(pv_name) -$(pv_value) - 662 - - - true - true - 1 - true - -319a9108:1499f67a49e:-7e70 - false - 0.0 - - 26 - Text Update_3 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-NEG-OFFSET_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 94 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -319a9108:1499f67a49e:-7e5e - false - - 26 - Label_4 - - true - true - false - - true - false - - - - - - - Label - true - STOP CURRENT - - Default - - 111 - 0 - - 1 - - - - 0 - - 245 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -319a9108:1499f67a49e:-7e5d - - Text_2 - 0 - - true - true - false - - $(IOC)$(M)-STOP-CURRENT_SET - - - - 0 - false - - - false - 0 - - - - 245 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -319a9108:1499f67a49e:-7e5c - false - 0.0 - - 26 - Text Update_4 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-STOP-CURRENT_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 245 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -319a9108:1499f67a49e:-7e42 - false - - 26 - Label_5 - - true - true - false - - true - false - - - - - - - Label - true - RUN CURRENT - - Default - - 111 - 0 - - 1 - - - - 0 - - 283 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -319a9108:1499f67a49e:-7e41 - - Text_3 - 0 - - true - true - false - - $(IOC)$(M)-RUN-CURRENT_SET - - - - 0 - false - - - false - 0 - - - - 283 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -319a9108:1499f67a49e:-7e40 - false - 0.0 - - 26 - Text Update_5 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-RUN-CURRENT_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 283 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -319a9108:1499f67a49e:-7e16 - false - - 26 - Label_6 - - true - true - false - - true - false - - - - - - - Label - true - BOOST CURRENT - - Default - - 111 - 0 - - 1 - - - - 0 - - 321 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -319a9108:1499f67a49e:-7e15 - - Text_4 - 0 - - true - true - false - - $(IOC)$(M)-BOOST-CURRENT_SET - - - - 0 - false - - - false - 0 - - - - 321 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -319a9108:1499f67a49e:-7e14 - false - 0.0 - - 26 - Text Update_6 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-BOOST-CURRENT_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 321 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -319a9108:1499f67a49e:-7de2 - false - - 26 - Label_7 - - true - true - false - - true - false - - - - - - - Label - true - STEP RES. - - Default - - 80 - 0 - - 1 - - - - 0 - - 206 - true - - 17 - - - false - true - true - -319a9108:1499f67a49e:-7de1 - - 23 - Menu Button_2 - false - - true - true - false - - false - $(IOC)$(M)-STEP-RES_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 208 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -319a9108:1499f67a49e:-7de0 - false - 0.0 - - 26 - Text Update_7 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-STEP-RES_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 208 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -319a9108:1499f67a49e:-7d5a - false - - 26 - Label_8 - - true - true - false - - true - false - - - - - - - Label - true - STATUS - - Default - - 56 - 0 - - 1 - - - - 0 - - 56 - true - - 17 - - - false - true - -319a9108:1499f67a49e:-7d22 - - 26 - - Action Button - false - - true - true - false - - - - - - - - - Action Button - true - MORE - false - - Default - - 105 - 0 - 0 - - - - false - 1 - - - - 56 - - - PhytronI1AM01Status.opi - - true - - 0 - - - - $(pv_name) -$(pv_value) - 145 - - - true - 1 - -319a9108:1499f67a49e:-78b7 - false - - 26 - Label_9 - - true - true - false - - true - false - - - - - - - Label - true - ENCODER TYPE - - Default - - 100 - 0 - - 1 - - - - 0 - - 277 - true - - 17 - - - false - true - true - -319a9108:1499f67a49e:-78b6 - - 23 - Menu Button_3 - false - - true - true - false - - false - $(IOC)$(M)-ENC-TYP_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 284 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -319a9108:1499f67a49e:-78b5 - false - 0.0 - - 26 - Text Update_9 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-ENC-TYP_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 284 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7eb6 - false - - 33 - Label_10 - - true - true - false - - true - false - - - - - - - Label - true - INITIALIZATION -TIME LAPSE - - Default - - 111 - 0 - - 1 - - - - 0 - - 129 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -1ff6f9c8:149bd1daaa4:-7eb5 - - Text_5 - 0 - - true - true - false - - $(IOC)$(M)-INIT-TIMEOUT_SET - - - - 0 - false - - - false - 0 - - - - 132 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7eb4 - false - 0.0 - - 26 - Text Update_10 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-INIT-TIMEOUT_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 132 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7e8e - false - - 33 - Label_11 - - true - true - false - - true - false - - - - - - - Label - true - POSITIONING -TIME LAPSE - - Default - - 111 - 0 - - 1 - - - - 0 - - 170 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -1ff6f9c8:149bd1daaa4:-7e8d - - Text_6 - 0 - - true - true - false - - $(IOC)$(M)-POS-TIMEOUT_SET - - - - 0 - false - - - false - 0 - - - - 170 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7e8c - false - 0.0 - - 26 - Text Update_11 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-POS-TIMEOUT_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 170 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7e36 - false - - 48 - Label_13 - - true - true - false - - true - false - - - - - - - Label - true - SSI ENC DATA TRANSFER RATE - - Default - - 100 - 0 - - 1 - - - - 0 - - 349 - true - - 17 - - - false - true - true - -1ff6f9c8:149bd1daaa4:-7e35 - - 23 - Menu Button_4 - false - - true - true - false - - false - $(IOC)$(M)-ENC-RATE_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 360 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7e34 - false - 0.0 - - 26 - Text Update_13 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-ENC-RATE_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 360 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7e0a - false - - 24 - Label_14 - - true - true - false - - true - false - - - - - - - Label - true - SWITCH TYPE - - Default - - 100 - 0 - - 1 - - - - 0 - - 399 - true - - 17 - - - false - true - true - -1ff6f9c8:149bd1daaa4:-7e09 - - 23 - Menu Button_5 - false - - true - true - false - - false - $(IOC)$(M)-SWITCH-TYP_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 398 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7e08 - false - 0.0 - - 26 - Text Update_14 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-SWITCH-TYP_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 398 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7dde - false - - 24 - Label_15 - - true - true - false - - true - false - - - - - - - Label - true - POWER STAGE - - Default - - 111 - 0 - - 1 - - - - 0 - - 436 - true - - 17 - - - false - true - true - -1ff6f9c8:149bd1daaa4:-7ddd - - 23 - Menu Button_6 - false - - true - true - false - - false - $(IOC)$(M)-PWR-STAGE-MODE_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 436 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7ddc - false - 0.0 - - 26 - Text Update_15 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-PWR-STAGE-MODE_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 436 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7daa - false - - 40 - Label_16 - - true - true - false - - true - false - - - - - - - Label - true - SSI/enDAT RESOLUTION - - Default - - 121 - 0 - - 1 - - - - 0 - - 348 - true - - 419 - - - false - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -1ff6f9c8:149bd1daaa4:-7da9 - - Text_8 - 0 - - true - true - false - - $(IOC)$(M)-ENC-RES_SET - - - - 0 - false - - - false - 0 - - - - 359 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7da8 - false - 0.0 - - 26 - Text Update_16 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-ENC-RES_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 359 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7d41 - false - - 33 - Label_18 - - true - true - false - - true - false - - - - - - - Label - true - CURRENT HOLD TIME - - Default - - 111 - 0 - - 1 - - - - 0 - - 393 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -1ff6f9c8:149bd1daaa4:-7d40 - - Text_10 - 0 - - true - true - false - - $(IOC)$(M)-CURRENT-DELAY_SET - - - - 0 - false - - - false - 0 - - - - 397 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7d3f - false - 0.0 - - 26 - Text Update_19 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-CURRENT-DELAY_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 397 - false - $(pv_name) -$(pv_value) - 662 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7d0a - false - - 33 - Label_19 - - true - true - false - - true - false - - - - - - - Label - true - POWER STAGE -TEMPERATURE - - Default - - 111 - 0 - - 1 - - - - 0 - - 508 - true - - 17 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7d09 - false - 0.0 - - 26 - Text Update_20 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-PS-TEMPERATURE - - - - - - - Text Update - true - - false - 0 - - Default - - 134 - 0 - - - 1 - - - - 0 - - 512 - false - $(pv_name) -$(pv_value) - 116 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7ce6 - false - - 40 - Label_20 - - true - true - false - - true - false - - - - - - - Label - true - POWER STAGE -MONITORING - - Default - - 111 - 0 - - 1 - - - - 0 - - 467 - true - - 17 - - - false - true - true - -1ff6f9c8:149bd1daaa4:-7ce5 - - 23 - Menu Button_7 - false - - true - true - false - - false - $(IOC)$(M)-PS-MONITOR_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 474 - $(pv_name) -$(pv_value) - 116 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7ce4 - false - 0.0 - - 26 - Text Update_21 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-PS-MONITOR_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 474 - false - $(pv_name) -$(pv_value) - 260 - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7cca - false - - 33 - Label_21 - - true - true - false - - true - false - - - - - - - Label - true - MOTOR TEMPERATURE - - Default - - 111 - 0 - - 1 - - - - 0 - - 546 - true - - 17 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7cc9 - false - 0.0 - - 26 - Text Update_22 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-MOTOR-TEMP - - - - - - - Text Update - true - - false - 0 - - Default - - 134 - 0 - - - 1 - - - - 0 - - 550 - false - $(pv_name) -$(pv_value) - 116 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - -1ff6f9c8:149bd1daaa4:-7ca3 - - Text_11 - 0 - - true - true - false - - $(IOC)$(M)-NEG-OFFSET_SET - - - - 0 - false - - - false - 0 - - - - 94 - - 539 - $(pv_name) -$(pv_value) - - - true - 1 - -1ff6f9c8:149bd1daaa4:-7b46 - false - - 26 - Label_12 - - true - true - false - - true - false - - - - - - - Label - true - BOOST - - Default - - 111 - 0 - - 1 - - - - 0 - - 241 - true - - 17 - - - true - true - 1 - true - -1ff6f9c8:149bd1daaa4:-7b44 - false - 0.0 - - 26 - Text Update_12 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-BOOST_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 246 - false - $(pv_name) -$(pv_value) - 260 - - - false - true - true - -1ff6f9c8:149bd1daaa4:-7b3a - - 23 - Menu Button_8 - false - - true - true - false - - false - $(IOC)$(M)-BOOST_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 246 - $(pv_name) -$(pv_value) - 116 - - - true - true - 7f2e3e4d:149c2f8c125:-7db1 - - false - - - - 26 - 0 - LED - false - false - - true - true - true - - - - - $(IOC)$(M)-AXIS-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - ON - - - - - 56 - $(pv_name) -$(pv_value) - 114 - - - true - 1 - 4b85a4d3:149ccab176a:-7eb1 - false - - 44 - Label_23 - - true - true - false - - true - false - - - - - - - Label - true - $(IOC)$(M) - - Header 1 - - 171 - 0 - - 1 - - - - 0 - - 9 - true - - 17 - - - true - 1 - 6f85ee60:149ebd1269c:-7f24 - false - - 34 - Label_24 - - true - true - false - - true - false - - - - - - - Label - true - ENCODER DIRECTION - - Default - - 97 - 0 - - 1 - - - - 0 - - 314 - true - - 18 - - - true - true - 1 - true - 6f85ee60:149ebd1269c:-7f23 - false - 0.0 - - 26 - Text Update_24 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-ENC-DIR_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 322 - false - $(pv_name) -$(pv_value) - 260 - - - false - true - true - 6f85ee60:149ebd1269c:-7f22 - - 23 - Menu Button_9 - false - - true - true - false - - false - $(IOC)$(M)-ENC-DIR_SET - - - - - - - Menu Button - true - false - - Default - - 134 - 6 - - - - 1 - - - - 322 - $(pv_name) -$(pv_value) - 116 - - - true - 1 - 6f85ee60:149ebd1269c:-7590 - false - - 26 - Label_26 - - true - true - false - - true - false - - - - - - - Label - true - RESET - - Default - - 56 - 0 - - 1 - - - - 0 - - 94 - true - - 17 - - - false - true - 6f85ee60:149ebd1269c:-755e - - 23 - - Action Button_1 - false - - true - true - false - - $(IOC)-RESET - - - - - - - Action Button - true - RESET AXIS - false - - Default - - 128 - 0 - 0 - - - - false - 1 - - - - 95 - - - $(IOC)$(M)-RESET - 1 - 10 - - - - - $(pv_name) -$(pv_value) - 260 - - - false - true - 6f85ee60:149ebd1269c:-755d - - 25 - - Action Button_4 - false - - true - true - false - - - - - - - - - Action Button - true - RESET STATUS - false - - Default - - 134 - 0 - 0 - - - - false - 1 - - - - 94 - - - $(IOC)$(M)-RESET-STATUS - 1 - 10 - - - - - $(pv_name) -$(pv_value) - 116 - - - true - 1 - 474a53:149f0353945:-7156 - false - - 26 - Label_27 - - true - true - false - - true - false - - - - - - - Label - true - ENCODER SFI - - Default - - 111 - 0 - - 1 - - - - 0 - - 208 - true - - 419 - - - true - false - true - false - false - false - - 26 - false - false - true - - - - true - Text Input - - - Default - - 100 - 3 - - 1.7976931348623157E308 - 1 - -1.7976931348623157E308 - 0 - true - 474a53:149f0353945:-7155 - - Text_12 - 0 - - true - true - false - - $(IOC)$(M)-ENC-SFI_SET - - - - 0 - false - - - false - 0 - - - - 208 - - 539 - $(pv_name) -$(pv_value) - - - true - true - 1 - true - 474a53:149f0353945:-7154 - false - 0.0 - - 26 - Text Update_25 - false - - true - true - false - - 0 - true - false - $(IOC)$(M)-ENC-SFI_GET - - - - - - - Text Update - true - - false - 0 - - Default - - 128 - 0 - - - 1 - - - - 0 - - 208 - false - $(pv_name) -$(pv_value) - 662 - - \ No newline at end of file diff --git a/motorApp/op/opi/PhytronI1AM01Status.opi b/motorApp/op/opi/PhytronI1AM01Status.opi deleted file mode 100644 index b65ed0d1..00000000 --- a/motorApp/op/opi/PhytronI1AM01Status.opi +++ /dev/null @@ -1,2240 +0,0 @@ - - - false - - true - - 2da4dada:138bb0b2666:-7ff6 - 3.2.16.20140409 - - true - 600 - $(IOC)$(M)-STATUS-1.B0 - true - false - - - - - - - Display - true - 800 - - true - 6 - - false - -1 - -1 - - - -1 - -1 - - true - true - -319a9108:1499f67a49e:-7cfe - - false - - - - 26 - 0 - LED - false - false - - true - true - true - - - - - $(IOC)$(M)-AXIS-BUSY - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 63 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cee - - false - - - - 26 - 0 - LED_1 - false - false - - true - true - true - - - - - $(IOC)$(M)-COMMAND - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 103 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7ce0 - - false - - - - 26 - 0 - LED_2 - false - false - - true - true - true - - - - - $(IOC)$(M)-WAIT-SYNC - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 143 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cdf - - false - - - - 26 - 0 - LED_3 - false - false - - true - true - true - - - - - $(IOC)$(M)-INITIALIZED - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 183 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cc9 - - false - - - - 26 - 0 - LED_4 - false - false - - true - true - true - - - - - $(IOC)$(M)-LS-POS - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 223 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cc8 - - false - - - - 26 - 0 - LED_5 - false - false - - true - true - true - - - - - $(IOC)$(M)-LS-NEG - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 263 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cc7 - - false - - - - 26 - 0 - LED_6 - false - false - - true - true - true - - - - - $(IOC)$(M)-LS-CNT - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 303 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7cc6 - - false - - - - 26 - 0 - LED_7 - false - false - - true - true - true - - - - - $(IOC)$(M)-SWL-POS - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 343 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7ca0 - - false - - - - 26 - 0 - LED_8 - false - false - - true - true - true - - - - - $(IOC)$(M)-SWL-NEG - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 383 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7c9f - - false - - - - 26 - 0 - LED_9 - false - false - - true - true - true - - - - - $(IOC)$(M)-INT-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 423 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7c9e - - false - - - - 26 - 0 - LED_10 - false - false - - true - true - true - - - - - $(IOC)$(M)-LS-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 463 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7c9d - - false - - - - 26 - 0 - LED_11 - false - false - - true - true - true - - - - - $(IOC)$(M)-PS-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 503 - $(pv_name) -$(pv_value) - 147 - - - true - true - -319a9108:1499f67a49e:-7c9c - - false - - - - 26 - 0 - LED_12 - false - false - - true - true - true - - - - - $(IOC)$(M)-SFI-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 63 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c9b - - false - - - - 26 - 0 - LED_13 - false - false - - true - true - true - - - - - $(IOC)$(M)-ENDAT-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 103 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c9a - - false - - - - 26 - 0 - LED_14 - false - false - - true - true - true - - - - - $(IOC)$(M)-RUNNING - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 143 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c99 - - false - - - - 26 - 0 - LED_15 - false - false - - true - true - true - - - - - $(IOC)$(M)-RECOVERY - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 183 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c77 - - false - - - - 26 - 0 - LED_16 - false - false - - true - true - true - - - - - $(IOC)$(M)-STP-DLY - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 223 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c76 - - false - - - - 26 - 0 - LED_17 - false - false - - true - true - true - - - - - $(IOC)$(M)-POSITIONED - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 263 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c75 - - false - - - - 26 - 0 - LED_18 - false - false - - true - true - true - - - - - $(IOC)$(M)-APS-READY - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 303 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c74 - - false - - - - 26 - 0 - LED_19 - false - false - - true - true - true - - - - - $(IOC)$(M)-POSITIONING - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 343 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c73 - - false - - - - 26 - 0 - LED_20 - false - false - - true - true - true - - - - - $(IOC)$(M)-FREE-RUN - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 383 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c72 - - false - - - - 26 - 0 - LED_21 - false - false - - true - true - true - - - - - $(IOC)$(M)-MULTI-F - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 423 - $(pv_name) -$(pv_value) - 361 - - - true - true - -319a9108:1499f67a49e:-7c71 - - false - - - - 26 - 0 - LED_22 - false - false - - true - true - true - - - - - $(IOC)$(M)-SYNC-ALLOWED - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 463 - $(pv_name) -$(pv_value) - 361 - - - true - 1 - -319a9108:1499f67a49e:-7c6d - false - - 26 - Label - - true - true - false - - true - false - - - - - - - Label - true - AXIS BUSY - - Default - - 115 - 0 - - 1 - - - - 0 - - 63 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c61 - false - - 26 - Label_1 - - true - true - false - - true - false - - - - - - - Label - true - COMMAND INVALID - - Default - - 131 - 0 - - 1 - - - - 0 - - 101 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c4f - false - - 37 - Label_2 - - true - true - false - - true - false - - - - - - - Label - true - AXIS WAITS SYNCHRONIZATION - - Default - - 131 - 0 - - 1 - - - - 0 - - 142 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c3d - false - - 26 - Label_3 - - true - true - false - - true - false - - - - - - - Label - true - AXIS INITIALISED - - Default - - 131 - 0 - - 1 - - - - 0 - - 180 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c2f - false - - 26 - Label_4 - - true - true - false - - true - false - - - - - - - Label - true - LIMIT SWITCH + - - Default - - 131 - 0 - - 1 - - - - 0 - - 221 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c21 - false - - 26 - Label_5 - - true - true - false - - true - false - - - - - - - Label - true - LIMIT SWITCH - - - Default - - 131 - 0 - - 1 - - - - 0 - - 259 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c16 - false - - 26 - Label_6 - - true - true - false - - true - false - - - - - - - Label - true - LIMIT SWITCH CENTER - - Default - - 143 - 0 - - 1 - - - - 0 - - 300 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7c08 - false - - 26 - Label_7 - - true - true - false - - true - false - - - - - - - Label - true - SW LIMIT + - - Default - - 131 - 0 - - 1 - - - - 0 - - 338 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7bfa - false - - 26 - Label_8 - - true - true - false - - true - false - - - - - - - Label - true - SW LIMIT - - - Default - - 131 - 0 - - 1 - - - - 0 - - 375 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7be1 - false - - 30 - Label_10 - - true - true - false - - true - false - - - - - - - Label - true - AXIS INTERNAL ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 411 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7bc9 - false - - 33 - Label_12 - - true - true - false - - true - false - - - - - - - Label - true - AXIS LIMIT SWITCH -ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 459 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7bbb - false - - 33 - Label_13 - - true - true - false - - true - false - - - - - - - Label - true - AXIS POWER STAGE -ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 499 - true - - 5 - - - true - 1 - -319a9108:1499f67a49e:-7bad - false - - 24 - Label_14 - - true - true - false - - true - false - - - - - - - Label - true - AXIS SFI ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 64 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b9f - false - - 24 - Label_15 - - true - true - false - - true - false - - - - - - - Label - true - AXIS ENDAT ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 102 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b90 - false - - 24 - Label_16 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IS RUNNING - - Default - - 131 - 0 - - 1 - - - - 0 - - 143 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b85 - false - - 24 - Label_17 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IN RECOVERY - - Default - - 131 - 0 - - 1 - - - - 0 - - 181 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b73 - false - - 34 - Label_18 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IN STOP CURRENT TIME DELAY - - Default - - 131 - 0 - - 1 - - - - 0 - - 219 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b61 - false - - 24 - Label_19 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IN POSITION - - Default - - 131 - 0 - - 1 - - - - 0 - - 260 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b53 - false - - 24 - Label_20 - - true - true - false - - true - false - - - - - - - Label - true - AXIS APS READY - - Default - - 131 - 0 - - 1 - - - - 0 - - 298 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b45 - false - - 31 - Label_21 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IN POSITIONING MODE - - Default - - 131 - 0 - - 1 - - - - 0 - - 339 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b37 - false - - 34 - Label_22 - - true - true - false - - true - false - - - - - - - Label - true - AXIS IN FREE RUNNING MODE - - Default - - 131 - 0 - - 1 - - - - 0 - - 380 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b29 - false - - 24 - Label_23 - - true - true - false - - true - false - - - - - - - Label - true - AXIS MULTI F RUN - - Default - - 131 - 0 - - 1 - - - - 0 - - 424 - true - - 222 - - - true - 1 - -319a9108:1499f67a49e:-7b1e - false - - 24 - Label_24 - - true - true - false - - true - false - - - - - - - Label - true - AXIS SYNC ALLOWED - - Default - - 131 - 0 - - 1 - - - - 0 - - 464 - true - - 222 - - - true - 1 - 6f85ee60:149ebd1269c:-7c7b - false - - 44 - Label_25 - - true - true - false - - true - false - - - - - - - Label - true - $(IOC)$(M) - - Header 1 - - 137 - 0 - - 1 - - - - 0 - - 14 - true - - 11 - - \ No newline at end of file diff --git a/motorApp/op/opi/PhytronMCM01Status.opi b/motorApp/op/opi/PhytronMCM01Status.opi deleted file mode 100644 index c86756b7..00000000 --- a/motorApp/op/opi/PhytronMCM01Status.opi +++ /dev/null @@ -1,1582 +0,0 @@ - - - false - - true - - 2da4dada:138bb0b2666:-7ff6 - 3.2.16.20140409 - - true - 600 - - true - false - - - - - - - Display - true - 800 - - true - 6 - - false - -1 - -1 - - - -1 - -1 - - true - true - -319a9108:1499f67a49e:-7cee - - false - - - - 26 - 0 - LED_1 - false - false - - true - true - true - - - - - $(IOC)-PROGRAM - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 62 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7ce0 - - false - - - - 26 - 0 - LED_2 - false - false - - true - true - true - - - - - $(IOC)-SW-REMOTE - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 102 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7cdf - - false - - - - 26 - 0 - LED_3 - false - false - - true - true - true - - - - - $(IOC)-LIMIT-SWITCH - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 142 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7cc9 - - false - - - - 26 - 0 - LED_4 - false - false - - true - true - true - - - - - $(IOC)-PS-AXIS-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 182 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7cc8 - - false - - - - 26 - 0 - LED_5 - false - false - - true - true - true - - - - - $(IOC)-PROG-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 220 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7cc7 - - false - - - - 26 - 0 - LED_6 - false - false - - true - true - true - - - - - $(IOC)-TERM-ACT - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 262 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7cc6 - - false - - - - 26 - 0 - LED_7 - false - false - - true - true - true - - - - - $(IOC)-INP-SCAN - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 299 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7ca0 - - false - - - - 26 - 0 - LED_8 - false - false - - true - true - true - - - - - $(IOC)-REMOTE - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 342 - $(pv_name) -$(pv_value) - 150 - - - true - true - -319a9108:1499f67a49e:-7c9f - - false - - - - 26 - 0 - LED_9 - false - false - - true - true - true - - - - - $(IOC)-AXIS-MODULE - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 62 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c9e - - false - - - - 26 - 0 - LED_10 - false - false - - true - true - true - - - - - $(IOC)-AXIS - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 102 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c9d - - false - - - - 26 - 0 - LED_11 - false - false - - true - true - true - - - - - $(IOC)-IO-MODULE - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 142 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c9c - - false - - - - 26 - 0 - LED_12 - false - false - - true - true - true - - - - - $(IOC)-IO - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 182 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c9b - - false - - - - 26 - 0 - LED_13 - false - false - - true - true - true - - - - - $(IOC)-INT-BUS-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 222 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c9a - - false - - - - 26 - 0 - LED_14 - false - false - - true - true - true - - - - - $(IOC)-INT-MOD-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 262 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c99 - - false - - - - 26 - 0 - LED_15 - false - false - - true - true - true - - - - - $(IOC)-AIOM-MODULE - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 302 - $(pv_name) -$(pv_value) - 362 - - - true - true - -319a9108:1499f67a49e:-7c77 - - false - - - - 26 - 0 - LED_16 - false - false - - true - true - true - - - - - $(IOC)-AIOM-CHANNEL - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - - - - - - 342 - $(pv_name) -$(pv_value) - 362 - - - true - 1 - -319a9108:1499f67a49e:-7c61 - false - - 26 - Label_1 - - true - true - false - - true - false - - - - - - - Label - true - PROGRAM RUN - - Default - - 131 - 0 - - 1 - - - - 0 - - 62 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c4f - false - - 37 - Label_2 - - true - true - false - - true - false - - - - - - - Label - true - SOFTWARE REMOTE - - Default - - 131 - 0 - - 1 - - - - 0 - - 97 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c3d - false - - 26 - Label_3 - - true - true - false - - true - false - - - - - - - Label - true - LIMIT SWITCH - - Default - - 131 - 0 - - 1 - - - - 0 - - 141 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c2f - false - - 26 - Label_4 - - true - true - false - - true - false - - - - - - - Label - true - POWER STAGE ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 182 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c21 - false - - 34 - Label_5 - - true - true - false - - true - false - - - - - - - Label - true - ERROR PROGRAMMING - - Default - - 131 - 0 - - 1 - - - - 0 - - 220 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c16 - false - - 26 - Label_6 - - true - true - false - - true - false - - - - - - - Label - true - TERMINAL ACTIVATED - - Default - - 143 - 0 - - 1 - - - - 0 - - 261 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7c08 - false - - 34 - Label_7 - - true - true - false - - true - false - - - - - - - Label - true - INPUT SCAN RUNNING - - Default - - 131 - 0 - - 1 - - - - 0 - - 294 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7bfa - false - - 26 - Label_8 - - true - true - false - - true - false - - - - - - - Label - true - REMOTE - - Default - - 131 - 0 - - 1 - - - - 0 - - 336 - true - - 8 - - - true - 1 - -319a9108:1499f67a49e:-7be1 - false - - 30 - Label_10 - - true - true - false - - true - false - - - - - - - Label - true - AXIS MODULE NOT -AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 60 - true - - 220 - - - true - 1 - -319a9108:1499f67a49e:-7bc9 - false - - 33 - Label_12 - - true - true - false - - true - false - - - - - - - Label - true - AXIS NOT AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 99 - true - - 220 - - - true - 1 - -319a9108:1499f67a49e:-7bbb - false - - 33 - Label_13 - - true - true - false - - true - false - - - - - - - Label - true - I/O MODULE NOT AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 138 - true - - 220 - - - true - 1 - -319a9108:1499f67a49e:-7bad - false - - 24 - Label_14 - - true - true - false - - true - false - - - - - - - Label - true - I/O NOT AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 175 - true - - 223 - - - true - 1 - -319a9108:1499f67a49e:-7b9f - false - - 31 - Label_15 - - true - true - false - - true - false - - - - - - - Label - true - INTERNAL BUS DATA TRANSFER ERRROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 213 - true - - 223 - - - true - 1 - -319a9108:1499f67a49e:-7b90 - false - - 36 - Label_16 - - true - true - false - - true - false - - - - - - - Label - true - INTERNAL BUS MODULE ERROR - - Default - - 131 - 0 - - 1 - - - - 0 - - 254 - true - - 223 - - - true - 1 - -319a9108:1499f67a49e:-7b85 - false - - 33 - Label_17 - - true - true - false - - true - false - - - - - - - Label - true - AIOM MODULE NOT AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 298 - true - - 223 - - - true - 1 - -319a9108:1499f67a49e:-7b73 - false - - 34 - Label_18 - - true - true - false - - true - false - - - - - - - Label - true - AIOM CHANNEL NOT -AVAILABLE - - Default - - 131 - 0 - - 1 - - - - 0 - - 339 - true - - 223 - - - true - 1 - 6f85ee60:149ebd1269c:-7cd4 - false - - 44 - Label - - true - true - false - - true - false - - - - - - - Label - true - $(IOC) - - Header 1 - - 137 - 0 - - 1 - - - - 0 - - 10 - true - - 8 - - \ No newline at end of file diff --git a/motorApp/op/opi/PhytronMain.opi b/motorApp/op/opi/PhytronMain.opi deleted file mode 100644 index 67d3d035..00000000 --- a/motorApp/op/opi/PhytronMain.opi +++ /dev/null @@ -1,441 +0,0 @@ - - - false - - true - PHYIOC - - 2da4dada:138bb0b2666:-7ff6 - 3.2.16.20140409 - - true - 700 - Display - true - false - - - - - - - Display - true - 800 - - true - 6 - - false - -1 - -1 - - - -1 - -1 - - false - true - -3ea02a50:1499f605597:-7f01 - - 24 - - Action Button - false - - true - true - false - - - - - - - - - Action Button - true - $(IOC):m1 - false - - Default - - 86 - 0 - 0 - - - - false - 1 - - - - 52 - - - PhytronI1AM01.opi - - true - :m1 - - 0 - - - - $(pv_name) -$(pv_value) - 204 - - - true - 1 - 7f2e3e4d:149c2f8c125:-7f3d - false - - 26 - Label - - true - true - false - - true - false - - - - - - - Label - true - MCM CONTROLLER STATUS: - - Default - - 175 - 0 - - 1 - - - - 0 - - 20 - true - - 30 - - - false - true - 7f2e3e4d:149c2f8c125:-7f39 - - 23 - - Action Button_1 - false - - true - true - false - - - - - - - - - Action Button - true - RESET CONTROLLER - false - - Default - - 135 - 0 - 0 - - - - false - 1 - - - - 21 - - - $(IOC)-RESET - 1 - 10 - - - - - $(pv_name) -$(pv_value) - 411 - - - false - true - 7f2e3e4d:149c2f8c125:-7f36 - - 25 - - Action Button_2 - false - - true - true - false - - - - - - - - - Action Button - true - MORE - false - - Default - - 58 - 0 - 0 - - - - false - 1 - - - - 20 - - - PhytronMCM01Status.opi - - true - - 0 - - - - $(pv_name) -$(pv_value) - 232 - - - true - true - 7f2e3e4d:149c2f8c125:-7bf9 - - false - - - - 26 - 0 - LED - false - false - - true - true - true - - - - - $(IOC)-CON-ERR - - - - - - - OFF - LED - true - false - - Default - - 26 - 0 - true - - - 0 - 1 - ON - - - - - 20 - $(pv_name) -$(pv_value) - 204 - - - false - true - 4b85a4d3:149ccab176a:-7f7b - - 24 - - Action Button_3 - false - - true - true - false - - - - - - - - - Action Button - true - $(IOC):m2 - false - - Default - - 79 - 0 - 0 - - - - false - 1 - - - - 52 - - - PhytronI1AM01.opi - - true - :m2 - - 0 - - - - $(pv_name) -$(pv_value) - 296 - - - true - 1 - 6f85ee60:149ebd1269c:-7630 - false - - 26 - Label_1 - - true - true - false - - true - false - - - - - - - Label - true - I1AM01 CONTROLLERS: - - Default - - 160 - 0 - - 1 - - - - 0 - - 51 - true - - 30 - - - false - true - 6f85ee60:149ebd1269c:-75e0 - - 25 - - Action Button_4 - false - - true - true - false - - - - - - - - - Action Button - true - RESET STATUS - false - - Default - - 106 - 0 - 0 - - - - false - 1 - - - - 20 - - - $(IOC)-RESET-STATUS - 1 - 10 - - - - - $(pv_name) -$(pv_value) - 296 - - \ No newline at end of file diff --git a/motorExApp/WithAsyn/Makefile b/motorExApp/WithAsyn/Makefile index db1683ce..c583a9e6 100644 --- a/motorExApp/WithAsyn/Makefile +++ b/motorExApp/WithAsyn/Makefile @@ -29,7 +29,6 @@ ifdef BUSY COMMONLIBS := busy $(COMMONLIBS) endif COMMONDBDS += PI_GCS2Support.dbd -COMMONDBDS += phytron.dbd ifdef LUA COMMONDBDS += ScriptMotorDriver.dbd endif @@ -66,7 +65,6 @@ COMMONLIBS += softMotor COMMONLIBS += motorSimSupport COMMONLIBS += ACRMotor COMMONLIBS += PI_GCS2Support -COMMONLIBS += phytronAxisMotor COMMONLIBS += motor ifdef LUA COMMONLIBS += ScriptMotor