From 9ec4b67d8e117bdd757605ce3df70876ae12299b Mon Sep 17 00:00:00 2001 From: Dan Allan Date: Thu, 29 Aug 2024 09:11:32 -0400 Subject: [PATCH] Provide working example-config. --- tests/example-config/calc.db | 26 --------------------- tests/example-config/ioc.substitutions | 16 ------------- tests/example-config/ioc.yaml | 32 ++++++++++++++++++++++++++ tests/example-config/st.cmd | 12 ---------- 4 files changed, 32 insertions(+), 54 deletions(-) delete mode 100644 tests/example-config/calc.db delete mode 100644 tests/example-config/ioc.substitutions create mode 100644 tests/example-config/ioc.yaml delete mode 100644 tests/example-config/st.cmd diff --git a/tests/example-config/calc.db b/tests/example-config/calc.db deleted file mode 100644 index ae23846..0000000 --- a/tests/example-config/calc.db +++ /dev/null @@ -1,26 +0,0 @@ -record(calc, "EXAMPLE2:SUM") { - field(DESC, "Sum A and B") - field(CALC, "A+B") - field(INPA, "EXAMPLE2:A") - field(INPB, "EXAMPLE2:B") -} - -record(ao, "EXAMPLE2:A") { - field(DESC, "A voltage") - field(PREC, "3") - field(EGU, "Volts") - field(DRVL, "-10") - field(DRVH, "+10") - field(VAL, "0.000") - field(FLNK, "EXAMPLE2:SUM") -} - -record(ao, "EXAMPLE2:B") { - field(DESC, "B voltage") - field(PREC, "3") - field(EGU, "Volts") - field(DRVL, "-10") - field(DRVH, "+10") - field(VAL, "0.000") - field(FLNK, "EXAMPLE2:SUM") -} \ No newline at end of file diff --git a/tests/example-config/ioc.substitutions b/tests/example-config/ioc.substitutions deleted file mode 100644 index 4fa1884..0000000 --- a/tests/example-config/ioc.substitutions +++ /dev/null @@ -1,16 +0,0 @@ - -# Macros: -# IOC Device prefix -file $(IOCSTATS)/db/iocAdminSoft.db -{ -pattern { IOC } - { "test-ioc" } -} - -# Macros: -# IOC Device prefix -file $(IOCSTATS)/db/iocAdminScanMon.db -{ -pattern { IOC } - { "test-ioc" } -} \ No newline at end of file diff --git a/tests/example-config/ioc.yaml b/tests/example-config/ioc.yaml new file mode 100644 index 0000000..c566265 --- /dev/null +++ b/tests/example-config/ioc.yaml @@ -0,0 +1,32 @@ +# yaml-language-server: $schema=https://github.com/epics-containers/ioc-motorsim/releases/download/2024.9.1/ibek.ioc.schema.json + +ioc_name: "{{ _global.get_env('IOC_NAME') }}" + +description: REPLACE WITH DESCRIPTION + +entities: + - type: epics.EpicsEnvSet + name: EPICS_TZ + value: GMT0BST + + - type: devIocStats.iocAdminSoft + IOC: "{{ ioc_name | upper }}" + + - type: motorSim.simMotorController + controllerName: sim-controller1 + numAxes: 3 + P: "BL01T-MO-SIMC-01:" + + - type: motorSim.simMotorAxis + controller: sim-controller1 + ADDR: 1 + M: M1 + DESC: Motor 1 + home: 1 + + - type: motorSim.simMotorAxis + controller: sim-controller1 + ADDR: 2 + M: M2 + DESC: Motor 2 + home: 2 diff --git a/tests/example-config/st.cmd b/tests/example-config/st.cmd deleted file mode 100644 index 61720df..0000000 --- a/tests/example-config/st.cmd +++ /dev/null @@ -1,12 +0,0 @@ -# Example hand coded IOC startup script for example-config -cd "/epics/ioc" - -epicsEnvSet "EPICS_CA_MAX_ARRAY_BYTES", '6000000' - -dbLoadDatabase "dbd/ioc.dbd" -ioc_registerRecordDeviceDriver(pdbbase) - -dbLoadRecords("config/calc.db") -dbLoadRecords("/tmp/ioc.db") - -iocInit()