From 6c693dbf21be35e414ee0b3b7c8e33c26f9d6c62 Mon Sep 17 00:00:00 2001 From: Zachary Lentz Date: Mon, 21 Aug 2023 10:42:04 -0700 Subject: [PATCH 1/6] TST: add missing dependency that reveals failing tests from pcds-envs --- conda-recipe/meta.yaml | 1 + dev-requirements.txt | 1 + 2 files changed, 2 insertions(+) diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index 76820b98..15faefac 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -30,6 +30,7 @@ requirements: test: requires: + - blark - codecov - flake8 - happi diff --git a/dev-requirements.txt b/dev-requirements.txt index 4c63b79d..ee038d70 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -7,6 +7,7 @@ pytest-aiohttp pytest-cov # plugin dependencies +blark happi python-ldap pytmc From 1489036f8805ceaa0426dd17ae976019331923d0 Mon Sep 17 00:00:00 2001 From: Ken Lauer Date: Tue, 22 Aug 2023 09:43:49 -0700 Subject: [PATCH 2/6] FIX: fix twincat plugin with new blark + add tests --- .gitmodules | 3 + whatrecord/plugins/twincat_pytmc.py | 269 ++++-- whatrecord/tests/blark_root | 1 + whatrecord/tests/iocs/ioc_twincat/Makefile | 14 + whatrecord/tests/iocs/ioc_twincat/README.md | 7 + whatrecord/tests/iocs/ioc_twincat/st.cmd | 903 ++++++++++++++++++++ whatrecord/tests/test_twincat.py | 154 ++++ 7 files changed, 1285 insertions(+), 66 deletions(-) create mode 100644 .gitmodules create mode 160000 whatrecord/tests/blark_root create mode 100644 whatrecord/tests/iocs/ioc_twincat/Makefile create mode 100644 whatrecord/tests/iocs/ioc_twincat/README.md create mode 100644 whatrecord/tests/iocs/ioc_twincat/st.cmd create mode 100644 whatrecord/tests/test_twincat.py diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000..47f90ea9 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "whatrecord/tests/blark-twincat-root-example"] + path = whatrecord/tests/blark_root + url = https://github.com/klauer/blark-twincat-root-example diff --git a/whatrecord/plugins/twincat_pytmc.py b/whatrecord/plugins/twincat_pytmc.py index dbaacaaf..b0a37e71 100644 --- a/whatrecord/plugins/twincat_pytmc.py +++ b/whatrecord/plugins/twincat_pytmc.py @@ -1,5 +1,5 @@ """ -TwinCAT / pytmc whatrecord plugin +TwinCAT / pytmc / blark whatrecord plugin Match your TwinCAT project symbols to EPICS records. @@ -7,26 +7,31 @@ Alternatively, the plugin will query WHATRECORD_SERVER for all IOCs and attempt to find ads-ioc-based IOCs with associated TwinCAT projects. + +To annotate library-level information in dependencies (i.e., to let users "go +to the source code of dependency-library-sourced symbols"), be sure to +set ``BLARK_TWINCAT_ROOT`` per blark's documentation. """ from __future__ import annotations import argparse import asyncio +import dataclasses import json import logging import pathlib import re import typing from dataclasses import dataclass -from typing import Dict, Generator, Iterable, List, Optional, Tuple +from typing import Dict, Generator, Iterable, List, Optional, Tuple, cast import apischema import blark import blark.summary -import pytmc -import pytmc.bin.db from blark import dependency_store +import pytmc.parser + from .. import cache, client, util from ..common import AnyPath, FullLoadContext, IocMetadata, LoadContext from ..server.common import PluginResults @@ -38,23 +43,26 @@ DESCRIPTION = __doc__.strip() +def _stringify_path(path: AnyPath) -> str: + """Uniform strings from a pathlib.Path or string.""" + if isinstance(path, str): + path = pathlib.Path(path) + return str(path.resolve()) + + @dataclass -class PytmcPluginResults(PluginResults): - def merge(self, results: PytmcPluginResults) -> None: +class TwincatPluginResults(PluginResults): + def merge(self, results: TwincatPluginResults) -> None: self.files_to_monitor.update(results.files_to_monitor) self.record_to_metadata_keys.update(results.record_to_metadata_keys) self.metadata_by_key.update(results.metadata_by_key) self.execution_info.update(results.execution_info) - self.nested.update(results.nested) + if self.nested is not None: + self.nested.update(results.nested or {}) @classmethod - def from_metadata(cls, md: PlcMetadata) -> PytmcPluginResults: - def _stringify_path(path): - if isinstance(path, str): - return path - return str(path.resolve()) - - plc_results = PytmcPluginResults( + def from_metadata(cls, md: PlcMetadata) -> TwincatPluginResults: + plc_results = TwincatPluginResults( files_to_monitor={ _stringify_path(path): shasum for path, shasum in md.loaded_files.items() @@ -69,7 +77,7 @@ def _stringify_path(path): }, execution_info={}, ) - return PytmcPluginResults( + return TwincatPluginResults( nested={ md.name: plc_results } @@ -78,10 +86,10 @@ def _stringify_path(path): @classmethod def from_metadata_items( cls, mds: Iterable[PlcMetadata] - ) -> Optional[PytmcPluginResults]: + ) -> TwincatPluginResults: results = None for plc_md in mds: - single = PytmcPluginResults.from_metadata(plc_md) + single = TwincatPluginResults.from_metadata(plc_md) if results is None: results = single else: @@ -90,7 +98,7 @@ def from_metadata_items( if results is not None: return results - return PytmcPluginResults( + return TwincatPluginResults( files_to_monitor={}, record_to_metadata_keys={}, metadata_by_key={}, @@ -148,30 +156,47 @@ def from_pytmc( class NCAxes: """Top-level NC axis information.""" context: FullLoadContext - filename: str + filename: pathlib.Path hash: str axes: List[NCAxis] @classmethod def from_pytmc( cls, - plc: pytmc.parser.Plc, + project: pytmc.parser.TwincatItem, + loaded_files: Optional[Dict[str, str]] = None, ) -> Optional[NCAxes]: - """Create an NCAxes instance from a pytmc-parsed Plc.""" + """Create an NCAxes instance from a project filename.""" try: - nc = next(plc.root.find(pytmc.parser.NC)) + nc: pytmc.parser.NC = next(project.root.find(pytmc.parser.NC)) except StopIteration: - return - - filename = str(nc.filename.resolve()) + return None - return cls( - context=(LoadContext(filename, 0), ), - filename=filename, - hash=get_file_sha256(filename), + nc_filename = _stringify_path(nc.filename) + nc = cls( + context=(LoadContext(nc_filename, 0), ), + filename=nc.filename, + hash=get_file_sha256(nc_filename), axes=[NCAxis.from_pytmc(axis) for axis in nc.axes], ) + if loaded_files is not None: + loaded_files[_stringify_path(nc.filename)] = nc.hash + for axis in nc.axes: + loaded_files[_stringify_path(axis.filename)] = axis.hash + + return nc + + @classmethod + def from_project_filename( + cls, + filename: pathlib.Path, + loaded_files: Optional[Dict[str, str]] = None, + ) -> Optional[NCAxes]: + """Create an NCAxes instance from a project filename.""" + project = pytmc.parser.parse(filename) + return cls.from_pytmc(project, loaded_files) + @dataclass class PlcSymbolMetadata: @@ -217,7 +242,9 @@ def get_symbol_metadata( """Get symbol metadata given a pytmc Symbol.""" symbol_type_name = symbol.data_type.qualified_type_name for pkg in pytmc.pragmas.record_packages_from_symbol( - symbol, yield_exceptions=True, allow_no_pragma=False + symbol, + yield_exceptions=True, + allow_no_pragma=False, ): if isinstance(pkg, Exception): # Eat these up rather than raising @@ -252,14 +279,77 @@ def get_symbol_metadata( ) +@dataclass +class PytmcMetadata: + tsproj: pytmc.parser.TcSmProject + plcproj: pytmc.parser.PlcProject + tmc: Optional[pytmc.parser.TcModuleClass] = None + nc: Optional[NCAxes] = None + + @classmethod + def from_tsproj( + cls, + tsproj: blark.solution.Project, + plc_name: str, + *, + loaded_files: Optional[Dict[str, str]] = None, + ) -> PytmcMetadata: + if loaded_files is None: + loaded_files = {} + if tsproj.local_path is None: + raise ValueError("Project without path") + + try: + pytmc_tsproj = cast( + pytmc.parser.TcSmProject, + pytmc.parser.parse(tsproj.local_path) + ) + except Exception as ex: + raise ValueError(f"Failed to parse project: {tsproj.name}") from ex + + try: + pytmc_plc = cast( + pytmc.parser.PlcProject, + pytmc_tsproj.plcs_by_name[plc_name] + ) + except KeyError as ex: + raise ValueError(f"Unable to find PLC project: {tsproj.name}") from ex + + md = cls( + tsproj=pytmc_tsproj, + plcproj=pytmc_plc, + tmc=getattr(pytmc_plc, "tmc", None), + ) + + try: + md.nc = NCAxes.from_pytmc( + pytmc_tsproj, + loaded_files=loaded_files, + ) + except Exception: + logger.exception( + "Failed to load NC settings from project: %s", + tsproj.local_path, + ) + return md + + @dataclass class PlcMetadata(cache.InlineCached, PlcMetadataCacheKey): """This metadata is keyed on PlcMetadataCacheKey.""" context: FullLoadContext symbols: Dict[str, PlcSymbolMetadata] - loaded_files: Dict[pathlib.Path, str] + loaded_files: Dict[str, str] record_to_symbol: Dict[str, str] - dependencies: Dict[str, dependency_store.ResolvedDependency] + # dependencies: Dict[str, blark.solution.DependencyInformation] + # TODO + dependencies: Dict[str, dependency_store.DependencyVersion] + blark_md: blark.solution.PlcProjectMetadata = dataclasses.field( + metadata=apischema.metadata.skip + ) + tsproj: blark.solution.Project = dataclasses.field( + metadata=apischema.metadata.skip + ) nc: Optional[NCAxes] = None @classmethod @@ -296,35 +386,53 @@ def from_ioc( def from_blark( cls, blark_md: dependency_store.PlcProjectMetadata, + tsproj: blark.solution.Project, include_dependencies: bool = True, use_cache: bool = True, ) -> PlcMetadata: """Create a PlcMetadata instance from a pytmc-parsed one.""" - loaded_files = dict(blark_md.loaded_files) - nc = NCAxes.from_pytmc(blark_md.plc) + loaded_files = { + _stringify_path(path): hash_ + for path, hash_ in blark_md.loaded_files.items() + } - if nc is not None: - loaded_files[nc.filename] = nc.hash - for axis in nc.axes: - loaded_files[axis.filename] = axis.hash + pytmc_md = PytmcMetadata.from_tsproj( + tsproj, + plc_name=blark_md.name, + loaded_files=loaded_files, + ) + + # TODO: blark - not capturing tsproj + if tsproj.local_path is not None: + loaded_files[_stringify_path(tsproj.local_path)] = get_file_sha256( + tsproj.local_path + ) - tmc = blark_md.plc.tmc - if tmc is None: - logger.debug("%s: No TMC file for symbols; skipping...", blark_md.plc.name) - return PlcMetadata( + plc_fn = _stringify_path(blark_md.filename) + if blark_md.plc is None or pytmc_md.tmc is None: + logger.debug( + "%s (%s): No TMC file for symbols; skipping...", + plc_fn, + blark_md.name, + ) + return cls( name=blark_md.name, - code={}, + filename=plc_fn, + include_dependencies=include_dependencies, + context=(LoadContext(plc_fn, 0), ), + dependencies=blark_md.dependencies, symbols={}, record_to_symbol={}, nc=None, loaded_files=loaded_files, + tsproj=tsproj, + blark_md=blark_md, ) - filename = blark_md.plc.filename.resolve() if use_cache: key = PlcMetadataCacheKey( - name=blark_md.plc.name, - filename=str(filename), + name=blark_md.name, + filename=plc_fn, include_dependencies=include_dependencies, ) cached = cls.from_cache(key) @@ -332,23 +440,26 @@ def from_blark( if util.check_files_up_to_date(cached.loaded_files): return cached - loaded_files[filename] = util.get_file_sha256(filename) + loaded_files[plc_fn] = util.get_file_sha256(plc_fn) md = cls( - name=blark_md.plc.name, - filename=filename, + name=blark_md.plc.name or blark_md.name, + filename=plc_fn, include_dependencies=include_dependencies, - context=(LoadContext(filename, 0), ), + context=(LoadContext(plc_fn, 0), ), symbols={}, record_to_symbol={}, dependencies=blark_md.dependencies, loaded_files=loaded_files, - nc=nc, + nc=pytmc_md.nc, + tsproj=tsproj, + blark_md=blark_md, ) def by_name(symbol): return symbol.name + tmc = pytmc_md.tmc for symbol in sorted(pytmc.pragmas.find_pytmc_symbols(tmc), key=by_name): for symbol_md in get_symbol_metadata(blark_md, symbol): md.symbols[symbol_md.name] = symbol_md @@ -356,9 +467,8 @@ def by_name(symbol): md.record_to_symbol[record] = symbol_md.name logger.debug( - "PLC %s: Found %d symbols (%d generated metadata; %d records)", + "PLC %s: Found %d symbols which generated metadata -> %d records", blark_md.plc.name, - len(blark_md.tmc_symbols), len(md.symbols), len(md.record_to_symbol), ) @@ -373,21 +483,48 @@ def from_project_filename( project: AnyPath, include_dependencies: bool = True, plc_whitelist: Optional[List[str]] = None, + loaded_files: Optional[Dict[str, str]] = None, + use_cache: bool = True, ) -> Generator[PlcMetadata, None, None]: """Given a project/solution filename, get all PlcMetadata.""" - projects = dependency_store.load_projects( - project, - include_dependencies=include_dependencies, - plc_whitelist=plc_whitelist, + if loaded_files is None: + loaded_files = {} + solution = blark.solution.make_solution_from_files(project) + logger.debug( + "Solution path %s projects %s", solution.filename, solution.projects ) - for project in projects: - logger.debug("Found plc project %s from %s", project.name, project.filename) - plc_md = cls.from_blark( - project, - include_dependencies=include_dependencies, - ) - if plc_md is not None: - yield plc_md + for tsproj_project in solution.projects: + logger.debug("Found tsproj %s", tsproj_project.name) + try: + parsed_tsproj = tsproj_project.load() + except Exception: + logger.exception("Failed to load project %s", tsproj_project.name) + continue + + for plc_name, plc in parsed_tsproj.plcs_by_name.items(): + if plc_whitelist and plc_name not in plc_whitelist: + continue + + logger.debug("Found PLC project %s", plc_name) + plc_md = dependency_store.PlcProjectMetadata.from_plcproject( + plc, + include_dependencies=include_dependencies, + ) + if plc_md is None: + continue + + logger.debug( + "tsproj %s: Found plc project %s from %s", + tsproj_project.name, + plc_md.name, + plc_md.filename, + ) + yield cls.from_blark( + blark_md=plc_md, + tsproj=tsproj_project, + include_dependencies=include_dependencies, + use_cache=use_cache, + ) MAKEFILE_VAR_RE = re.compile(r"^([A-Z_][A-Z0-9_]+)\s*:?=\s*(.*)$", re.IGNORECASE | re.MULTILINE) @@ -446,7 +583,7 @@ async def _cli_main(): parser = _get_argparser() args = parser.parse_args() results = await main(**vars(args)) - whatrecord_results = PytmcPluginResults.from_metadata_items(results) + whatrecord_results = TwincatPluginResults.from_metadata_items(results) json_results = apischema.serialize(whatrecord_results) dump_args = {"indent": 4} if args.pretty else {} print(json.dumps(json_results, sort_keys=True, **dump_args)) diff --git a/whatrecord/tests/blark_root b/whatrecord/tests/blark_root new file mode 160000 index 00000000..0f6ff050 --- /dev/null +++ b/whatrecord/tests/blark_root @@ -0,0 +1 @@ +Subproject commit 0f6ff0507c7de186cbc1a2f9ed6a22e2b74bb7e3 diff --git a/whatrecord/tests/iocs/ioc_twincat/Makefile b/whatrecord/tests/iocs/ioc_twincat/Makefile new file mode 100644 index 00000000..e2ed1335 --- /dev/null +++ b/whatrecord/tests/iocs/ioc_twincat/Makefile @@ -0,0 +1,14 @@ +IOC_TOP = /reg/g/pcds/epics/ioc/common/ads-ioc/R0.6.1 +IOC_INSTANCE_PATH := $(shell pwd) + +# Set PRODUCTION_IOC to 1 to move from a testing to a production IOC: +PRODUCTION_IOC := 1 + +PROJECT_NAME = project_c +PROJECT_PATH := ../../blark_root/project_c/project_c/project_c.tsproj +PLC = ProjectC + +PYTMC_OPTS := +PREFIX = PROJECT:C + +include $(IOC_TOP)/iocBoot/templates/Makefile.base diff --git a/whatrecord/tests/iocs/ioc_twincat/README.md b/whatrecord/tests/iocs/ioc_twincat/README.md new file mode 100644 index 00000000..4e446161 --- /dev/null +++ b/whatrecord/tests/iocs/ioc_twincat/README.md @@ -0,0 +1,7 @@ +## Notes + +This is a non-functional TwinCAT IOC. + +The twincat-pytmc plugin provided by whatrecord, backed by pytmc and blark, +parses this project and can provide PLC source code information for EPICS +records. diff --git a/whatrecord/tests/iocs/ioc_twincat/st.cmd b/whatrecord/tests/iocs/ioc_twincat/st.cmd new file mode 100644 index 00000000..8fbf7e27 --- /dev/null +++ b/whatrecord/tests/iocs/ioc_twincat/st.cmd @@ -0,0 +1,903 @@ +#!/reg/g/pcds/epics/ioc/common/ads-ioc/R0.6.1/bin/rhel7-x86_64/adsIoc +################### AUTO-GENERATED DO NOT EDIT ################### +# +# Project: plc-lfe-motion.tsproj +# PLC name: lfe_motion (lfe_motion Instance) +# Generated using: pytmc 2.13.0+15.g35cceb1 +# Project version: dbcc588 +# Project hash: dbcc58890e6511f8db291b972aa13b8cdbd2ae09 +# PLC IP/host: 172.21.88.228 +# PLC Net ID: 172.21.88.228.1.1 +# ** Production mode IOC ** +# Using /cds/data/iocData for autosave and archiver settings. +# +# Libraries: +# +# LCLS General: * -> 2.4.2 (SLAC) +# lcls-twincat-motion: * -> 1.6.0 (SLAC) +# lcls-twincat-physics: * -> * (SLAC) +# lcls2-cc-lib: * -> 1.1.2 (SLAC) +# PMPS: * -> 2.2.0 (SLAC - LCLS) +# Tc2_MC2: * (Beckhoff Automation GmbH) +# Tc2_SerialCom: * (Beckhoff Automation GmbH) +# Tc2_Standard: * (Beckhoff Automation GmbH) +# Tc2_System: * (Beckhoff Automation GmbH) +# Tc3_Module: * (Beckhoff Automation GmbH) +# +################### AUTO-GENERATED DO NOT EDIT ################### +< envPaths + +epicsEnvSet("ADS_IOC_TOP", "$(TOP)" ) + +epicsEnvSet("ENGINEER", "klauer" ) +epicsEnvSet("LOCATION", "PLC:LFE:MOTION" ) +epicsEnvSet("IOCSH_PS1", "$(IOC)> " ) +epicsEnvSet("ACF_FILE", "$(ADS_IOC_TOP)/iocBoot/templates/unrestricted.acf") + +# Run common startup commands for linux soft IOC's +< /reg/d/iocCommon/All/pre_linux.cmd + +# Register all support components +dbLoadDatabase("$(ADS_IOC_TOP)/dbd/adsIoc.dbd") +adsIoc_registerRecordDeviceDriver(pdbbase) + +epicsEnvSet("ASYN_PORT", "ASYN_PLC") +epicsEnvSet("IPADDR", "172.21.88.228") +epicsEnvSet("AMSID", "172.21.88.228.1.1") +epicsEnvSet("AMS_PORT", "851") +epicsEnvSet("ADS_MAX_PARAMS", "10217") +epicsEnvSet("ADS_SAMPLE_MS", "50") +epicsEnvSet("ADS_MAX_DELAY_MS", "100") +epicsEnvSet("ADS_TIMEOUT_MS", "1000") +epicsEnvSet("ADS_TIME_SOURCE", "0") + +# Add a route to the PLC automatically: +system("${ADS_IOC_TOP}/scripts/add_route.sh 172.21.88.228 ^172.*") + +# adsAsynPortDriverConfigure(portName, ipaddr, amsaddr, amsport, +# asynParamTableSize, priority, noAutoConnect, defaultSampleTimeMS, +# maxDelayTimeMS, adsTimeoutMS, defaultTimeSource) +# portName Asyn port name +# ipAddr IP address of PLC +# amsaddr AMS Address of PLC +# amsport Default AMS port in PLC (851 for first PLC) +# paramTableSize Maximum parameter/variable count. (1000) +# priority Asyn priority (0) +# noAutoConnect Enable auto connect (0=enabled) +# defaultSampleTimeMS Default sample of variable (PLC ams router +# checks if variable changed, if changed then add to send buffer) (50ms) +# maxDelayTimeMS Maximum delay before variable that has changed is sent to client +# (Linux). The variable can also be sent sooner if the ams router +# send buffer is filled (100ms) +# adsTimeoutMS Timeout for adslib commands (1000ms) +# defaultTimeSource Default time stamp source of changed variable (PLC=0): +# PLC=0: The PLC time stamp from when the value was +# changed is used and set as timestamp in the EPICS record +# (if record TSE field is set to -2=enable asyn timestamp). +# This is the preferred setting. +# EPICS=1: The time stamp will be made when the updated data +# arrives in the EPICS client. +adsAsynPortDriverConfigure("$(ASYN_PORT)", "$(IPADDR)", "$(AMSID)", "$(AMS_PORT)", "$(ADS_MAX_PARAMS)", 0, 0, "$(ADS_SAMPLE_MS)", "$(ADS_MAX_DELAY_MS)", "$(ADS_TIMEOUT_MS)", "$(ADS_TIME_SOURCE)") + +cd "$(ADS_IOC_TOP)/db" + + +epicsEnvSet("MOTOR_PORT", "PLC_ADS") +epicsEnvSet("PREFIX", "PLC:LFE:MOTION:") +epicsEnvSet("NUMAXES", "54") +epicsEnvSet("MOVE_POLL_RATE", "200") +epicsEnvSet("IDLE_POLL_RATE", "1000") + +EthercatMCCreateController("$(MOTOR_PORT)", "$(ASYN_PORT)", "$(NUMAXES)", "$(MOVE_POLL_RATE)", "$(IDLE_POLL_RATE)") + +#define ASYN_TRACE_ERROR 0x0001 +#define ASYN_TRACEIO_DEVICE 0x0002 +#define ASYN_TRACEIO_FILTER 0x0004 +#define ASYN_TRACEIO_DRIVER 0x0008 +#define ASYN_TRACE_FLOW 0x0010 +#define ASYN_TRACE_WARNING 0x0020 +#define ASYN_TRACE_INFO 0x0040 +asynSetTraceMask("$(ASYN_PORT)", -1, 0x41) + +#define ASYN_TRACEIO_NODATA 0x0000 +#define ASYN_TRACEIO_ASCII 0x0001 +#define ASYN_TRACEIO_ESCAPE 0x0002 +#define ASYN_TRACEIO_HEX 0x0004 +asynSetTraceIOMask("$(ASYN_PORT)", -1, 2) + +#define ASYN_TRACEINFO_TIME 0x0001 +#define ASYN_TRACEINFO_PORT 0x0002 +#define ASYN_TRACEINFO_SOURCE 0x0004 +#define ASYN_TRACEINFO_THREAD 0x0008 +asynSetTraceInfoMask("$(ASYN_PORT)", -1, 5) + +#define AMPLIFIER_ON_FLAG_CREATE_AXIS 1 +#define AMPLIFIER_ON_FLAG_WHEN_HOMING 2 +#define AMPLIFIER_ON_FLAG_USING_CNEN 4 + +epicsEnvSet("AXIS_NO", "1") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "01") +epicsEnvSet("DESC", "Main.M1 / Axis 1") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "2") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "02") +epicsEnvSet("DESC", "Main.M2 / Axis 2") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "3") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "03") +epicsEnvSet("DESC", "Main.M3 / Axis 3") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "4") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "04") +epicsEnvSet("DESC", "Main.M4 / Axis 4") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "5") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "05") +epicsEnvSet("DESC", "Main.M5 / Axis 5") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "6") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "06") +epicsEnvSet("DESC", "Main.M6 / Axis 6") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "7") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "07") +epicsEnvSet("DESC", "Main.M7 / Axis 7") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "8") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "08") +epicsEnvSet("DESC", "Main.M8 / Axis 8") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "9") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "09") +epicsEnvSet("DESC", "Main.M9 / Axis 9") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "10") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "10") +epicsEnvSet("DESC", "Main.M10 / Axis 10") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "11") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "11") +epicsEnvSet("DESC", "Main.M11 / Axis 11") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "12") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "12") +epicsEnvSet("DESC", "Main.M12 / Axis 12") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "13") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "13") +epicsEnvSet("DESC", "Main.M13 / Axis 13") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "14") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "14") +epicsEnvSet("DESC", "Main.M14 / Axis 14") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "15") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "15") +epicsEnvSet("DESC", "Main.M15 / Axis 15") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "16") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "16") +epicsEnvSet("DESC", "Main.M16 / Axis 16") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "17") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "17") +epicsEnvSet("DESC", "Main.M17 / Axis 17") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "18") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "18") +epicsEnvSet("DESC", "Main.M18 / Axis 18") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "19") +epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") +epicsEnvSet("MOTOR_NAME", "19") +epicsEnvSet("DESC", "Main.M19 / Axis 19") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "20") +epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") +epicsEnvSet("MOTOR_NAME", "MMS") +epicsEnvSet("DESC", "Main.M20 / Axis 20 IM1L0-XTES-MMS") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "21") +epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLZ") +epicsEnvSet("DESC", "Main.M21 / Axis 21 IM1L0-XTES-CLZ") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "22") +epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLF") +epicsEnvSet("DESC", "Main.M22 / Axis 22 IM1L0-XTES-CLF") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "23") +epicsEnvSet("MOTOR_PREFIX", "IM1L1:PPM:") +epicsEnvSet("MOTOR_NAME", "MMS") +epicsEnvSet("DESC", "Main.M23 / Axis 23 IM1L1-PPM-MMS") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "24") +epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") +epicsEnvSet("MOTOR_NAME", "MMS") +epicsEnvSet("DESC", "Main.M24 / Axis 24 IM2L0-XTES-MMS") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "25") +epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLZ") +epicsEnvSet("DESC", "Main.M25 / Axis 25 IM2L0-XTES-CLZ") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "26") +epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLF") +epicsEnvSet("DESC", "Main.M26 / Axis 26 IM2L0-XTES-CLF") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "27") +epicsEnvSet("MOTOR_PREFIX", "IM3L0:PPM:") +epicsEnvSet("MOTOR_NAME", "MMS") +epicsEnvSet("DESC", "Main.M27 / Axis 27 IM3L0-PPM-MMS") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "28") +epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") +epicsEnvSet("MOTOR_NAME", "MMS") +epicsEnvSet("DESC", "Main.M28 / Axis 28 IM4L0-XTES-MMS") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "29") +epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLZ") +epicsEnvSet("DESC", "Main.M29 / Axis 29 IM4L0-XTES-CLZ") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "30") +epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") +epicsEnvSet("MOTOR_NAME", "CLF") +epicsEnvSet("DESC", "Main.M30 / Axis 30 IM4L0-XTES-CLF") +epicsEnvSet("EGU", "%") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "31") +epicsEnvSet("MOTOR_PREFIX", "PF1L0:WFS:MMS:") +epicsEnvSet("MOTOR_NAME", "Y") +epicsEnvSet("DESC", "Main.M31 / PF1L0-WFS-MMS-01") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "32") +epicsEnvSet("MOTOR_PREFIX", "PF1L0:WFS:MMS:") +epicsEnvSet("MOTOR_NAME", "Z") +epicsEnvSet("DESC", "Main.M32 / PF1L0-WFS-MMS-02") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "41") +epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "BOTTOM") +epicsEnvSet("DESC", "Main.M41 / SL1L0-BOTTOM-M41") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "42") +epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "SOUTH") +epicsEnvSet("DESC", "Main.M42 / SL1L0-SOUTH-M42") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "43") +epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "TOP") +epicsEnvSet("DESC", "Main.M43 / SL1L0-TOP-M43") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "44") +epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "NORTH") +epicsEnvSet("DESC", "Main.M44 / SL1L0-NORTH-M44") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "45") +epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "BOTTOM") +epicsEnvSet("DESC", "Main.M45 / SL2L0-BOTTOM-M45") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "46") +epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "SOUTH") +epicsEnvSet("DESC", "Main.M46 / SL2L0-SOUTH-M46") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "47") +epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "TOP") +epicsEnvSet("DESC", "Main.M47 / SL2L0-TOP-M47") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "48") +epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") +epicsEnvSet("MOTOR_NAME", "NORTH") +epicsEnvSet("DESC", "Main.M48 / SL2L0-NORTH-M48") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "49") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "XTAL_ANGLE") +epicsEnvSet("DESC", "Main.M49 / XTAL ANGLE X") +epicsEnvSet("EGU", "steps") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "50") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "XTAL_VERT") +epicsEnvSet("DESC", "Main.M50 / XTAL VERT Y") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "51") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "RET_HORIZ") +epicsEnvSet("DESC", "Main.M51 / RETICLE HORIZ X") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "52") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "RET_VERT") +epicsEnvSet("DESC", "Main.M52 / RETICLE VERT Y") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "53") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "DIODE_HORIZ") +epicsEnvSet("DESC", "Main.M53 / DIODE HORIZ X") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + +epicsEnvSet("AXIS_NO", "54") +epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") +epicsEnvSet("MOTOR_NAME", "DIODE_VERT") +epicsEnvSet("DESC", "Main.M54 / DIODE VERT Y") +epicsEnvSet("EGU", "mm") +epicsEnvSet("PREC", "3") +epicsEnvSet("AXISCONFIG", "") +epicsEnvSet("ECAXISFIELDINIT", "") +epicsEnvSet("AMPLIFIER_FLAGS", "") + +EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") +dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") +dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") +dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") + + +dbLoadRecords("iocSoft.db", "IOC=PLC:LFE:MOTION") +dbLoadRecords("save_restoreStatus.db", "P=PLC:LFE:MOTION:") +dbLoadRecords("caPutLog.db", "IOC=$(IOC)") + +## TwinCAT task, application, and project information databases ## +dbLoadRecords("TwinCAT_TaskInfo.db", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION,IDX=1") +dbLoadRecords("TwinCAT_AppInfo.db", "PORT=$(ASYN_PORT), PREFIX=PLC:LFE:MOTION") + +dbLoadRecords("TwinCAT_Project.db", "PREFIX=PLC:LFE:MOTION,PROJECT=plc-lfe-motion.tsproj,HASH=dbcc588,VERSION=dbcc588,PYTMC=2.13.0+15.g35cceb1,PLC_HOST=172.21.88.228") + +# LCLS General: * -> 2.4.2 (SLAC) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=LCLS_General,VERSION=2.4.2,VENDOR=SLAC") +# lcls-twincat-motion: * -> 1.6.0 (SLAC) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls-twincat-motion,VERSION=1.6.0,VENDOR=SLAC") +# lcls-twincat-physics: * -> * (SLAC) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls-twincat-physics,VERSION=*,VENDOR=SLAC") +# lcls2-cc-lib: * -> 1.1.2 (SLAC) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls2-cc-lib,VERSION=1.1.2,VENDOR=SLAC") +# PMPS: * -> 2.2.0 (SLAC - LCLS) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=PMPS,VERSION=2.2.0,VENDOR=SLAC - LCLS") +# Tc2_MC2: * (Beckhoff Automation GmbH) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_MC2,VERSION=*,VENDOR=Beckhoff Automation GmbH") +# Tc2_SerialCom: * (Beckhoff Automation GmbH) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_SerialCom,VERSION=*,VENDOR=Beckhoff Automation GmbH") +# Tc2_Standard: * (Beckhoff Automation GmbH) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_Standard,VERSION=*,VENDOR=Beckhoff Automation GmbH") +# Tc2_System: * (Beckhoff Automation GmbH) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_System,VERSION=*,VENDOR=Beckhoff Automation GmbH") +# Tc3_Module: * (Beckhoff Automation GmbH) +dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc3_Module,VERSION=*,VENDOR=Beckhoff Automation GmbH") + +cd "$(IOC_TOP)" + +## PLC Project Database files ## +dbLoadRecords("lfe_motion.db", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") + +# Total records: 9217 +callbackSetQueueSize(20434) + +# Load user-specified database: a +dbLoadRecords("a", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") +# Load user-specified database: b +dbLoadRecords("b", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") +# Load user-specified database: c +dbLoadRecords("c", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") + +# Autosave and archive settings: +save_restoreSet_status_prefix("PLC:LFE:MOTION:") +save_restoreSet_IncompleteSetsOk(1) +save_restoreSet_DatedBackupFiles(1) +set_pass0_restoreFile("info_positions.sav") +set_pass1_restoreFile("info_settings.sav") + +# ** Production IOC Settings ** +set_savefile_path("$(IOC_DATA)/$(IOC)/autosave") +set_requestfile_path("$(IOC_DATA)/$(IOC)/autosave") + +# Production IOC autosave files go in iocData: +cd "$(IOC_DATA)/$(IOC)/autosave" + +# Create info_positions.req and info_settings.req +makeAutosaveFiles() + +cd "$(IOC_DATA)/$(IOC)/archive" + +# Create $(IOC).archive +makeArchiveFromDbInfo("$(IOC).archive", "archive") +cd "$(IOC_TOP)" + +# Configure access security: this is required for caPutLog. +asSetFilename("$(ACF_FILE)") + +# Initialize the IOC and start processing records +iocInit() + +# Enable logging +iocLogInit() + +# Configure and start the caPutLogger after iocInit +epicsEnvSet(EPICS_AS_PUT_LOG_PV, "$(IOC):caPutLog:Last") + +# caPutLogInit("HOST:PORT", config) +# config options: +# caPutLogNone -1: no logging (disable) +# caPutLogOnChange 0: log only on value change +# caPutLogAll 1: log all puts +# caPutLogAllNoFilter 2: log all puts no filtering on same PV +caPutLogInit("$(EPICS_CAPUTLOG_HOST):$(EPICS_CAPUTLOG_PORT)", 0) + +# Start autosave backups +create_monitor_set( "info_positions.req", 10, "" ) +create_monitor_set( "info_settings.req", 60, "" ) + +# All IOCs should dump some common info after initial startup. +< /reg/d/iocCommon/All/post_linux.cmd diff --git a/whatrecord/tests/test_twincat.py b/whatrecord/tests/test_twincat.py new file mode 100644 index 00000000..9fe4bac7 --- /dev/null +++ b/whatrecord/tests/test_twincat.py @@ -0,0 +1,154 @@ +import pathlib + +import blark.dependency_store +import pytest + +from ..common import IocMetadata +from ..plugins import twincat_pytmc +from . import conftest + +BLARK_ROOT = conftest.MODULE_PATH / "blark_root" + +if not (BLARK_ROOT / "README.md").exists(): + pytest.fail( + f"{BLARK_ROOT} is missing: whatrecord was likely not cloned with " + "--recursive for this test suite submodule" + ) + +twincat_projects = list(BLARK_ROOT.glob("**/*.tsproj")) +twincat_ioc_path = conftest.MODULE_PATH / "iocs" / "ioc_twincat" +project_a_path = BLARK_ROOT / "project_a" / "project_a" / "project_a.tsproj" +project_c_path = BLARK_ROOT / "project_c" / "project_c" / "project_c.tsproj" + + +@pytest.fixture +def project_c_md() -> IocMetadata: + return IocMetadata(name="ioc_twincat", script=twincat_ioc_path / "st.cmd") + + +@pytest.fixture +def depstore( + monkeypatch: pytest.MonkeyPatch, +) -> blark.dependency_store.DependencyStore: + depstore = blark.dependency_store.DependencyStore(root=BLARK_ROOT) + + def _get_dep_store(): + return depstore + + monkeypatch.setattr(blark.dependency_store, "get_dependency_store", _get_dep_store) + return depstore + + +def test_get_project_from_ioc(project_c_md: IocMetadata): + _, makefile_contents, _ = twincat_pytmc.get_ioc_makefile(project_c_md) + info = twincat_pytmc.get_project_from_ioc(project_c_md, makefile_contents) + assert info is not None + + path, plc_name = info + assert plc_name == "ProjectC" + assert path == project_c_path + + +def test_plc_metadata_with_tmc( + project_c_md: IocMetadata, + depstore: blark.dependency_store.DependencyStore, +): + # logging.getLogger("blark").setLevel("DEBUG") + plc_md, = list(twincat_pytmc.PlcMetadata.from_ioc(project_c_md)) + + assert plc_md.context[0].name == str(plc_md.filename) + assert plc_md.name == "ProjectC" + assert plc_md.include_dependencies + expected_files = { + 'MAIN.TcPOU', + 'ProjectC.plcproj', + 'project_c.tsproj', + } + loaded_names = {pathlib.Path(file).name for file in plc_md.loaded_files} + for fn in expected_files: + assert fn in loaded_names + + assert plc_md.record_to_symbol == { + # Simple pragma'd LREAL + "PREFIX:fOutput": "ProjectC:MAIN.fOutput", + "PREFIX:fOutput_RBV": "ProjectC:MAIN.fOutput", + # Function block instance which refers back to SampleLibraryA + "PREFIX:fbTest:fInput": "ProjectC:MAIN.fbTest.fInput", + "PREFIX:fbTest:fInput_RBV": "ProjectC:MAIN.fbTest.fInput", + "PREFIX:fbTest:fOutput_RBV": "ProjectC:MAIN.fbTest.fOutput", + } + + assert plc_md.nc is not None + assert len(plc_md.nc.axes) == 1 + axis = plc_md.nc.axes[0] + assert axis.name == "Axis 1" + assert pathlib.Path(axis.context[0].name).name == "Axis 1.xti" + assert axis.units == "mm" + + assert set(plc_md.dependencies) == {"SampleLibraryA"} + assert plc_md.dependencies["SampleLibraryA"] == blark.solution.DependencyVersion( + name="SampleLibraryA", + version="*", + vendor="blark-testing", + namespace="SampleLibraryA", + ) + + def check_context(md: twincat_pytmc.PlcSymbolMetadata, expected_files: list[str]): + files = [pathlib.Path(ctx.name).name for ctx in md.context] + assert set(files) == set(expected_files) + + # Simple symbol, with I/O records: + sym = plc_md.symbols["ProjectC:MAIN.fOutput"] + check_context(sym, ["MAIN.TcPOU"]) + assert sym.name == "ProjectC:MAIN.fOutput" + assert sym.type == "LREAL" + assert sym.records == ["PREFIX:fOutput_RBV", "PREFIX:fOutput"] + + # Symbol generated from a library FB input, with setpoint/rbv records: + sym = plc_md.symbols['ProjectC:MAIN.fbTest.fInput'] + check_context(sym, ["MAIN.TcPOU", "FB_SampleA_Test.TcPOU"]) + assert sym.name == "ProjectC:MAIN.fbTest.fInput" + assert sym.type == "LREAL (SampleLibraryA.FB_SampleA_Test)" + assert sym.records == ["PREFIX:fbTest:fInput_RBV", "PREFIX:fbTest:fInput"] + + # Symbol generated from a library FB output, with only readback record: + sym = plc_md.symbols['ProjectC:MAIN.fbTest.fOutput'] + check_context(sym, ["MAIN.TcPOU", "FB_SampleA_Test.TcPOU"]) + assert sym.name == "ProjectC:MAIN.fbTest.fOutput" + assert sym.type == "LREAL (SampleLibraryA.FB_SampleA_Test)" + assert sym.records == ["PREFIX:fbTest:fOutput_RBV"] + + assert depstore.get_dependency("project_c") is not None + assert depstore.get_dependency("SampleLibraryA") is not None + + +def test_plc_metadata_without_tmc(): + (project_a,) = list( + twincat_pytmc.PlcMetadata.from_project_filename( + project_a_path, + include_dependencies=False, + ) + ) + assert not project_a.record_to_symbol + assert not project_a.symbols + assert "ProjectA.plcproj" in project_a.context[0].name + + +def test_empty_plugin_results(): + results = twincat_pytmc.TwincatPluginResults.from_metadata_items([]) + assert not results.nested + + +def test_plugin_results(project_c_md: IocMetadata): + plc_md, = list(twincat_pytmc.PlcMetadata.from_ioc(project_c_md)) + results = twincat_pytmc.TwincatPluginResults.from_metadata_items( + # Loading it twice to smoke test the 'merge' function + [plc_md, plc_md] + ) + assert results is not None + + # The TwinCAT Plugin uses "nested" metadata, allowing the server to + # only give you per-project information if you want. So not everything is + # in the top-level dictionary. + assert "PREFIX:fOutput_RBV" in results.nested["ProjectC"].record_to_metadata_keys + assert "ProjectC:MAIN.fOutput" in results.nested["ProjectC"].metadata_by_key From 07fc4944d41270037fc719c2fa4a9fc0b4c4e28a Mon Sep 17 00:00:00 2001 From: Ken Lauer Date: Tue, 22 Aug 2023 10:41:50 -0700 Subject: [PATCH 3/6] FIX: serialization tests related to pytmc plugin --- whatrecord/plugins/twincat_pytmc.py | 6 ++++-- whatrecord/tests/test_serialization.py | 5 +++++ whatrecord/tests/test_twincat.py | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/whatrecord/plugins/twincat_pytmc.py b/whatrecord/plugins/twincat_pytmc.py index b0a37e71..e80ec482 100644 --- a/whatrecord/plugins/twincat_pytmc.py +++ b/whatrecord/plugins/twincat_pytmc.py @@ -344,10 +344,12 @@ class PlcMetadata(cache.InlineCached, PlcMetadataCacheKey): # dependencies: Dict[str, blark.solution.DependencyInformation] # TODO dependencies: Dict[str, dependency_store.DependencyVersion] - blark_md: blark.solution.PlcProjectMetadata = dataclasses.field( + blark_md: Optional[dependency_store.PlcProjectMetadata] = dataclasses.field( + default=None, metadata=apischema.metadata.skip ) - tsproj: blark.solution.Project = dataclasses.field( + tsproj: Optional[blark.solution.Project] = dataclasses.field( + default=None, metadata=apischema.metadata.skip ) nc: Optional[NCAxes] = None diff --git a/whatrecord/tests/test_serialization.py b/whatrecord/tests/test_serialization.py index 050228e6..02db1913 100644 --- a/whatrecord/tests/test_serialization.py +++ b/whatrecord/tests/test_serialization.py @@ -11,11 +11,13 @@ from typing import Dict, List, Optional, Union import apischema +import blark import pytest from .. import (access_security, asyn, autosave, cache, common, ioc_finder, motor, shell, snl) from ..common import FullLoadContext, LoadContext +from ..plugins import twincat_pytmc MODULE_PATH = Path(__file__).parent @@ -25,6 +27,7 @@ cache.Cached, ioc_finder.IocScriptStaticInfoList, ioc_finder.IocScriptStaticList, + twincat_pytmc.PytmcMetadata, # should not serialize ) SKIP_DESERIALIZATION = { @@ -114,6 +117,8 @@ def sort_key(cls): Optional[common.RecordType]: None, Union[snl.Declarator, snl.Variable]: snl.Variable(context=[], name="test"), snl.OptionalExpression: None, + blark.dependency_store.PlcProjectMetadata: None, # non-serialized + blark.solution.Project: None, # non-serialized } diff --git a/whatrecord/tests/test_twincat.py b/whatrecord/tests/test_twincat.py index 9fe4bac7..77a081cc 100644 --- a/whatrecord/tests/test_twincat.py +++ b/whatrecord/tests/test_twincat.py @@ -150,5 +150,6 @@ def test_plugin_results(project_c_md: IocMetadata): # The TwinCAT Plugin uses "nested" metadata, allowing the server to # only give you per-project information if you want. So not everything is # in the top-level dictionary. + assert results.nested is not None assert "PREFIX:fOutput_RBV" in results.nested["ProjectC"].record_to_metadata_keys assert "ProjectC:MAIN.fOutput" in results.nested["ProjectC"].metadata_by_key From ca6dad33fecb8d90ffe3b1ba0990da14fa14ac69 Mon Sep 17 00:00:00 2001 From: Ken Lauer Date: Tue, 22 Aug 2023 10:51:34 -0700 Subject: [PATCH 4/6] MNT: make twincat IOC partially load --- .../tests/iocs/ioc_twincat/ioc_twincat.db | 55 ++ whatrecord/tests/iocs/ioc_twincat/st.cmd | 719 +----------------- 2 files changed, 62 insertions(+), 712 deletions(-) create mode 100644 whatrecord/tests/iocs/ioc_twincat/ioc_twincat.db diff --git a/whatrecord/tests/iocs/ioc_twincat/ioc_twincat.db b/whatrecord/tests/iocs/ioc_twincat/ioc_twincat.db new file mode 100644 index 00000000..149da651 --- /dev/null +++ b/whatrecord/tests/iocs/ioc_twincat/ioc_twincat.db @@ -0,0 +1,55 @@ +record(ai, "PREFIX:fOutput_RBV") { + field(DESC, "MAIN.fOutput") + field(SCAN, "I/O Intr") + field(PINI, "1") + field(TSE, "-2") + field(DTYP, "asynFloat64") + field(INP, "@asyn($(PORT),0,1)ADSPORT=851/POLL_RATE=1/MAIN.fOutput?") + field(PREC, "3") + info(autosaveFields_pass0, "DESC DISS HHSV HIGH HIHI HSV LLSV LOLO LOW LSV PREC SIMS UDFS") + info(archive, "VAL") +} + +record(ao, "PREFIX:fOutput") { + field(DESC, "MAIN.fOutput") + field(DTYP, "asynFloat64") + field(UDFS, "0") + field(OUT, "@asyn($(PORT),0,1)ADSPORT=851/MAIN.fOutput=") + field(PREC, "3") + info(autosaveFields_pass0, "DESC DISS DRVH DRVL HHSV HIGH HIHI HSV LLSV LOLO LOW LSV PREC SIMS UDFS VAL") + info(archive, "VAL") +} + +record(ai, "PREFIX:fbTest:fInput_RBV") { + field(DESC, "MAIN.fbTest.fInput") + field(SCAN, "I/O Intr") + field(PINI, "1") + field(TSE, "-2") + field(DTYP, "asynFloat64") + field(INP, "@asyn($(PORT),0,1)ADSPORT=851/POLL_RATE=1/MAIN.fbTest.fInput?") + field(PREC, "3") + info(autosaveFields_pass0, "DESC DISS HHSV HIGH HIHI HSV LLSV LOLO LOW LSV PREC SIMS UDFS") + info(archive, "VAL") +} + +record(ao, "PREFIX:fbTest:fInput") { + field(DESC, "MAIN.fbTest.fInput") + field(DTYP, "asynFloat64") + field(UDFS, "0") + field(OUT, "@asyn($(PORT),0,1)ADSPORT=851/MAIN.fbTest.fInput=") + field(PREC, "3") + info(autosaveFields_pass0, "DESC DISS DRVH DRVL HHSV HIGH HIHI HSV LLSV LOLO LOW LSV PREC SIMS UDFS VAL") + info(archive, "VAL") +} + +record(ai, "PREFIX:fbTest:fOutput_RBV") { + field(DESC, "MAIN.fbTest.fOutput") + field(SCAN, "I/O Intr") + field(PINI, "1") + field(TSE, "-2") + field(DTYP, "asynFloat64") + field(INP, "@asyn($(PORT),0,1)ADSPORT=851/POLL_RATE=1/MAIN.fbTest.fOutput?") + field(PREC, "3") + info(autosaveFields_pass0, "DESC DISS HHSV HIGH HIHI HSV LLSV LOLO LOW LSV PREC SIMS UDFS") + info(archive, "VAL") +} diff --git a/whatrecord/tests/iocs/ioc_twincat/st.cmd b/whatrecord/tests/iocs/ioc_twincat/st.cmd index 8fbf7e27..3e7e26b2 100644 --- a/whatrecord/tests/iocs/ioc_twincat/st.cmd +++ b/whatrecord/tests/iocs/ioc_twincat/st.cmd @@ -30,7 +30,7 @@ epicsEnvSet("ADS_IOC_TOP", "$(TOP)" ) epicsEnvSet("ENGINEER", "klauer" ) -epicsEnvSet("LOCATION", "PLC:LFE:MOTION" ) +epicsEnvSet("LOCATION", "TST:TWINCAT" ) epicsEnvSet("IOCSH_PS1", "$(IOC)> " ) epicsEnvSet("ACF_FILE", "$(ADS_IOC_TOP)/iocBoot/templates/unrestricted.acf") @@ -38,7 +38,7 @@ epicsEnvSet("ACF_FILE", "$(ADS_IOC_TOP)/iocBoot/templates/unrestricted.acf") < /reg/d/iocCommon/All/pre_linux.cmd # Register all support components -dbLoadDatabase("$(ADS_IOC_TOP)/dbd/adsIoc.dbd") +dbLoadDatabase("../softIoc.dbd") adsIoc_registerRecordDeviceDriver(pdbbase) epicsEnvSet("ASYN_PORT", "ASYN_PLC") @@ -83,7 +83,7 @@ cd "$(ADS_IOC_TOP)/db" epicsEnvSet("MOTOR_PORT", "PLC_ADS") -epicsEnvSet("PREFIX", "PLC:LFE:MOTION:") +epicsEnvSet("PREFIX", "TST:TWINCAT:") epicsEnvSet("NUMAXES", "54") epicsEnvSet("MOVE_POLL_RATE", "200") epicsEnvSet("IDLE_POLL_RATE", "1000") @@ -130,730 +130,25 @@ dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") -epicsEnvSet("AXIS_NO", "2") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "02") -epicsEnvSet("DESC", "Main.M2 / Axis 2") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "3") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "03") -epicsEnvSet("DESC", "Main.M3 / Axis 3") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "4") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "04") -epicsEnvSet("DESC", "Main.M4 / Axis 4") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "5") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "05") -epicsEnvSet("DESC", "Main.M5 / Axis 5") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "6") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "06") -epicsEnvSet("DESC", "Main.M6 / Axis 6") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "7") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "07") -epicsEnvSet("DESC", "Main.M7 / Axis 7") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "8") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "08") -epicsEnvSet("DESC", "Main.M8 / Axis 8") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "9") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "09") -epicsEnvSet("DESC", "Main.M9 / Axis 9") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "10") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "10") -epicsEnvSet("DESC", "Main.M10 / Axis 10") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "11") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "11") -epicsEnvSet("DESC", "Main.M11 / Axis 11") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "12") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "12") -epicsEnvSet("DESC", "Main.M12 / Axis 12") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "13") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "13") -epicsEnvSet("DESC", "Main.M13 / Axis 13") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "14") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "14") -epicsEnvSet("DESC", "Main.M14 / Axis 14") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "15") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "15") -epicsEnvSet("DESC", "Main.M15 / Axis 15") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "16") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "16") -epicsEnvSet("DESC", "Main.M16 / Axis 16") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "17") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "17") -epicsEnvSet("DESC", "Main.M17 / Axis 17") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "18") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "18") -epicsEnvSet("DESC", "Main.M18 / Axis 18") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "19") -epicsEnvSet("MOTOR_PREFIX", "AT2L0:XTES:MMS:") -epicsEnvSet("MOTOR_NAME", "19") -epicsEnvSet("DESC", "Main.M19 / Axis 19") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "20") -epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") -epicsEnvSet("MOTOR_NAME", "MMS") -epicsEnvSet("DESC", "Main.M20 / Axis 20 IM1L0-XTES-MMS") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "21") -epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLZ") -epicsEnvSet("DESC", "Main.M21 / Axis 21 IM1L0-XTES-CLZ") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "22") -epicsEnvSet("MOTOR_PREFIX", "IM1L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLF") -epicsEnvSet("DESC", "Main.M22 / Axis 22 IM1L0-XTES-CLF") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "23") -epicsEnvSet("MOTOR_PREFIX", "IM1L1:PPM:") -epicsEnvSet("MOTOR_NAME", "MMS") -epicsEnvSet("DESC", "Main.M23 / Axis 23 IM1L1-PPM-MMS") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "24") -epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") -epicsEnvSet("MOTOR_NAME", "MMS") -epicsEnvSet("DESC", "Main.M24 / Axis 24 IM2L0-XTES-MMS") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "25") -epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLZ") -epicsEnvSet("DESC", "Main.M25 / Axis 25 IM2L0-XTES-CLZ") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "26") -epicsEnvSet("MOTOR_PREFIX", "IM2L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLF") -epicsEnvSet("DESC", "Main.M26 / Axis 26 IM2L0-XTES-CLF") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "27") -epicsEnvSet("MOTOR_PREFIX", "IM3L0:PPM:") -epicsEnvSet("MOTOR_NAME", "MMS") -epicsEnvSet("DESC", "Main.M27 / Axis 27 IM3L0-PPM-MMS") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "28") -epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") -epicsEnvSet("MOTOR_NAME", "MMS") -epicsEnvSet("DESC", "Main.M28 / Axis 28 IM4L0-XTES-MMS") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "29") -epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLZ") -epicsEnvSet("DESC", "Main.M29 / Axis 29 IM4L0-XTES-CLZ") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "30") -epicsEnvSet("MOTOR_PREFIX", "IM4L0:XTES:") -epicsEnvSet("MOTOR_NAME", "CLF") -epicsEnvSet("DESC", "Main.M30 / Axis 30 IM4L0-XTES-CLF") -epicsEnvSet("EGU", "%") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "31") -epicsEnvSet("MOTOR_PREFIX", "PF1L0:WFS:MMS:") -epicsEnvSet("MOTOR_NAME", "Y") -epicsEnvSet("DESC", "Main.M31 / PF1L0-WFS-MMS-01") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "32") -epicsEnvSet("MOTOR_PREFIX", "PF1L0:WFS:MMS:") -epicsEnvSet("MOTOR_NAME", "Z") -epicsEnvSet("DESC", "Main.M32 / PF1L0-WFS-MMS-02") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "41") -epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "BOTTOM") -epicsEnvSet("DESC", "Main.M41 / SL1L0-BOTTOM-M41") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "42") -epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "SOUTH") -epicsEnvSet("DESC", "Main.M42 / SL1L0-SOUTH-M42") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "43") -epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "TOP") -epicsEnvSet("DESC", "Main.M43 / SL1L0-TOP-M43") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "44") -epicsEnvSet("MOTOR_PREFIX", "SL1L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "NORTH") -epicsEnvSet("DESC", "Main.M44 / SL1L0-NORTH-M44") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "45") -epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "BOTTOM") -epicsEnvSet("DESC", "Main.M45 / SL2L0-BOTTOM-M45") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "46") -epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "SOUTH") -epicsEnvSet("DESC", "Main.M46 / SL2L0-SOUTH-M46") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "47") -epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "TOP") -epicsEnvSet("DESC", "Main.M47 / SL2L0-TOP-M47") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "48") -epicsEnvSet("MOTOR_PREFIX", "SL2L0:POWER:MMS:") -epicsEnvSet("MOTOR_NAME", "NORTH") -epicsEnvSet("DESC", "Main.M48 / SL2L0-NORTH-M48") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "49") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "XTAL_ANGLE") -epicsEnvSet("DESC", "Main.M49 / XTAL ANGLE X") -epicsEnvSet("EGU", "steps") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "50") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "XTAL_VERT") -epicsEnvSet("DESC", "Main.M50 / XTAL VERT Y") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "51") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "RET_HORIZ") -epicsEnvSet("DESC", "Main.M51 / RETICLE HORIZ X") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "52") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "RET_VERT") -epicsEnvSet("DESC", "Main.M52 / RETICLE VERT Y") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "53") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "DIODE_HORIZ") -epicsEnvSet("DESC", "Main.M53 / DIODE HORIZ X") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - -EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") -dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") -dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") -dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") - -epicsEnvSet("AXIS_NO", "54") -epicsEnvSet("MOTOR_PREFIX", "SP1L0:KMONO:MMS:") -epicsEnvSet("MOTOR_NAME", "DIODE_VERT") -epicsEnvSet("DESC", "Main.M54 / DIODE VERT Y") -epicsEnvSet("EGU", "mm") -epicsEnvSet("PREC", "3") -epicsEnvSet("AXISCONFIG", "") -epicsEnvSet("ECAXISFIELDINIT", "") -epicsEnvSet("AMPLIFIER_FLAGS", "") - EthercatMCCreateAxis("$(MOTOR_PORT)", "$(AXIS_NO)", "$(AMPLIFIER_FLAGS)", "$(AXISCONFIG)") dbLoadRecords("EthercatMC.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC), EGU=$(EGU) $(ECAXISFIELDINIT)") dbLoadRecords("EthercatMCreadback.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), R=$(MOTOR_NAME)-, MOTOR_PORT=$(MOTOR_PORT), ASYN_PORT=$(ASYN_PORT), AXIS_NO=$(AXIS_NO), DESC=$(DESC), PREC=$(PREC) ") dbLoadRecords("EthercatMCdebug.template", "PREFIX=$(MOTOR_PREFIX), MOTOR_NAME=$(MOTOR_NAME), MOTOR_PORT=$(MOTOR_PORT), AXIS_NO=$(AXIS_NO), PREC=3") -dbLoadRecords("iocSoft.db", "IOC=PLC:LFE:MOTION") -dbLoadRecords("save_restoreStatus.db", "P=PLC:LFE:MOTION:") +dbLoadRecords("iocSoft.db", "IOC=TST:TWINCAT") +dbLoadRecords("save_restoreStatus.db", "P=TST:TWINCAT:") dbLoadRecords("caPutLog.db", "IOC=$(IOC)") -## TwinCAT task, application, and project information databases ## -dbLoadRecords("TwinCAT_TaskInfo.db", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION,IDX=1") -dbLoadRecords("TwinCAT_AppInfo.db", "PORT=$(ASYN_PORT), PREFIX=PLC:LFE:MOTION") - -dbLoadRecords("TwinCAT_Project.db", "PREFIX=PLC:LFE:MOTION,PROJECT=plc-lfe-motion.tsproj,HASH=dbcc588,VERSION=dbcc588,PYTMC=2.13.0+15.g35cceb1,PLC_HOST=172.21.88.228") - -# LCLS General: * -> 2.4.2 (SLAC) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=LCLS_General,VERSION=2.4.2,VENDOR=SLAC") -# lcls-twincat-motion: * -> 1.6.0 (SLAC) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls-twincat-motion,VERSION=1.6.0,VENDOR=SLAC") -# lcls-twincat-physics: * -> * (SLAC) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls-twincat-physics,VERSION=*,VENDOR=SLAC") -# lcls2-cc-lib: * -> 1.1.2 (SLAC) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=lcls2-cc-lib,VERSION=1.1.2,VENDOR=SLAC") -# PMPS: * -> 2.2.0 (SLAC - LCLS) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=PMPS,VERSION=2.2.0,VENDOR=SLAC - LCLS") -# Tc2_MC2: * (Beckhoff Automation GmbH) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_MC2,VERSION=*,VENDOR=Beckhoff Automation GmbH") -# Tc2_SerialCom: * (Beckhoff Automation GmbH) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_SerialCom,VERSION=*,VENDOR=Beckhoff Automation GmbH") -# Tc2_Standard: * (Beckhoff Automation GmbH) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_Standard,VERSION=*,VENDOR=Beckhoff Automation GmbH") -# Tc2_System: * (Beckhoff Automation GmbH) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc2_System,VERSION=*,VENDOR=Beckhoff Automation GmbH") -# Tc3_Module: * (Beckhoff Automation GmbH) -dbLoadRecords("TwinCAT_Dependency.db", "PREFIX=PLC:LFE:MOTION,DEPENDENCY=Tc3_Module,VERSION=*,VENDOR=Beckhoff Automation GmbH") - cd "$(IOC_TOP)" -## PLC Project Database files ## -dbLoadRecords("lfe_motion.db", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") +dbLoadRecords("ioc_twincat.db", "PORT=$(ASYN_PORT),PREFIX=TST:TWINCAT:,IOCNAME=$(IOC),IOC=$(IOC)") # Total records: 9217 callbackSetQueueSize(20434) -# Load user-specified database: a -dbLoadRecords("a", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") -# Load user-specified database: b -dbLoadRecords("b", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") -# Load user-specified database: c -dbLoadRecords("c", "PORT=$(ASYN_PORT),PREFIX=PLC:LFE:MOTION:,IOCNAME=$(IOC),IOC=$(IOC)") - # Autosave and archive settings: -save_restoreSet_status_prefix("PLC:LFE:MOTION:") +save_restoreSet_status_prefix("TST:TWINCAT:") save_restoreSet_IncompleteSetsOk(1) save_restoreSet_DatedBackupFiles(1) set_pass0_restoreFile("info_positions.sav") From 22ad19d320c8c518cdbec12ae0debf64cb1a50d4 Mon Sep 17 00:00:00 2001 From: Ken Lauer Date: Tue, 22 Aug 2023 11:19:49 -0700 Subject: [PATCH 5/6] MNT: avoid isort confusion by using full package name --- whatrecord/plugins/twincat_pytmc.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/whatrecord/plugins/twincat_pytmc.py b/whatrecord/plugins/twincat_pytmc.py index e80ec482..dc67deb0 100644 --- a/whatrecord/plugins/twincat_pytmc.py +++ b/whatrecord/plugins/twincat_pytmc.py @@ -27,8 +27,8 @@ import apischema import blark +import blark.dependency_store import blark.summary -from blark import dependency_store import pytmc.parser @@ -234,7 +234,7 @@ def load_context_from_path(path: List[blark.summary.Summary]) -> FullLoadContext def get_symbol_metadata( - blark_md: dependency_store.PlcMetadata, + blark_md: blark.dependency_store.PlcMetadata, symbol: pytmc.parser.Symbol, require_records: bool = True, add_project_prefix: bool = True, @@ -343,8 +343,8 @@ class PlcMetadata(cache.InlineCached, PlcMetadataCacheKey): record_to_symbol: Dict[str, str] # dependencies: Dict[str, blark.solution.DependencyInformation] # TODO - dependencies: Dict[str, dependency_store.DependencyVersion] - blark_md: Optional[dependency_store.PlcProjectMetadata] = dataclasses.field( + dependencies: Dict[str, blark.dependency_store.DependencyVersion] + blark_md: Optional[blark.dependency_store.PlcProjectMetadata] = dataclasses.field( default=None, metadata=apischema.metadata.skip ) @@ -387,7 +387,7 @@ def from_ioc( @classmethod def from_blark( cls, - blark_md: dependency_store.PlcProjectMetadata, + blark_md: blark.dependency_store.PlcProjectMetadata, tsproj: blark.solution.Project, include_dependencies: bool = True, use_cache: bool = True, @@ -508,7 +508,7 @@ def from_project_filename( continue logger.debug("Found PLC project %s", plc_name) - plc_md = dependency_store.PlcProjectMetadata.from_plcproject( + plc_md = blark.dependency_store.PlcProjectMetadata.from_plcproject( plc, include_dependencies=include_dependencies, ) From fc913d5256ec922670550973fe64972c9e266bc2 Mon Sep 17 00:00:00 2001 From: Ken Lauer Date: Tue, 22 Aug 2023 12:04:21 -0700 Subject: [PATCH 6/6] STY: pre-commit isort confusion --- whatrecord/plugins/twincat_pytmc.py | 1 - 1 file changed, 1 deletion(-) diff --git a/whatrecord/plugins/twincat_pytmc.py b/whatrecord/plugins/twincat_pytmc.py index dc67deb0..06e0f1ba 100644 --- a/whatrecord/plugins/twincat_pytmc.py +++ b/whatrecord/plugins/twincat_pytmc.py @@ -29,7 +29,6 @@ import blark import blark.dependency_store import blark.summary - import pytmc.parser from .. import cache, client, util