From ea1838b0b6760c33d0f59e040c9a40cbed20d827 Mon Sep 17 00:00:00 2001
From: 25-ID Staff Account <25-id@list.anl.gov>
Date: Tue, 14 Mar 2023 12:57:09 -0500
Subject: [PATCH 1/5] Adding XIA PFCU serial support
---
.gitignore | 1 +
configure/RELEASE | 12 +-
iocsh/ADAM_4018.iocsh | 29 ++
iocsh/Agilent_E3631A.iocsh | 17 +
iocsh/BK_9130.iocsh | 17 +
iocsh/EXAMPLE_Pelco_CM6700.substitutions | 22 +
iocsh/Eurotherm2k.iocsh | 20 +
iocsh/Heidenhain_ND261.iocsh | 14 +
iocsh/Keithley_2k_gpib.iocsh | 17 +
iocsh/Keithley_2k_serial.iocsh | 21 +
iocsh/LakeShore_218.iocsh | 15 +
iocsh/LakeShore_330.iocsh | 15 +
iocsh/LakeShore_340.iocsh | 15 +
iocsh/Lakeshore_DRC93CA.iocsh | 17 +
iocsh/MKS651C.iocsh | 19 +
iocsh/MKS_651C.iocsh | 18 +
iocsh/Newport_LAE500.iocsh | 16 +
iocsh/Omega_DP41.iocsh | 15 +
iocsh/Oxford_CS800.iocsh | 23 +
iocsh/Oxford_CS800_status.iocsh | 18 +
iocsh/Oxford_ILM202.iocsh | 16 +
iocsh/Oxford_X1k.iocsh | 16 +
iocsh/PTC10_eth.iocsh | 41 ++
iocsh/PTC10_rtd.iocsh | 17 +
iocsh/PTC10_tc.iocsh | 23 +
iocsh/PTC10_tec.iocsh | 17 +
iocsh/Pelco_CM6700.iocsh | 19 +
iocsh/Protura_P201.iocsh | 19 +
iocsh/Queensgate_piezo.iocsh | 15 +
iocsh/SR_570.iocsh | 16 +
iocsh/SR_830.iocsh | 15 +
iocsh/USdigital_X3.iocsh | 16 +
iocsh/XIA_pfcu_filters.iocsh | 18 +
iocsh/loadIPPort.iocsh | 12 +
iocsh/loadSerialComm.iocsh | 23 +
iocsh/loadSerialPort.iocsh | 12 +
iocsh/setSerialParams.iocsh | 13 +
ipApp/Db/XIA_pfcu_filters.db | 304 ++++++++++++
ipApp/Db/XIA_pfcu_filters.proto | 57 +++
ipApp/Db/XIA_pfcu_filters_settings.req | 12 +
ipApp/iocsh/XIA_pfcu_filters.iocsh | 18 +
ipApp/op/ui/XIA_pfcu_filters_base.ui | 346 +++++++++++++
ipApp/op/ui/XIA_pfcu_filters_less.ui | 405 ++++++++++++++++
ipApp/op/ui/XIA_pfcu_filters_main.ui | 588 +++++++++++++++++++++++
44 files changed, 2374 insertions(+), 5 deletions(-)
create mode 100644 iocsh/ADAM_4018.iocsh
create mode 100644 iocsh/Agilent_E3631A.iocsh
create mode 100644 iocsh/BK_9130.iocsh
create mode 100644 iocsh/EXAMPLE_Pelco_CM6700.substitutions
create mode 100644 iocsh/Eurotherm2k.iocsh
create mode 100644 iocsh/Heidenhain_ND261.iocsh
create mode 100644 iocsh/Keithley_2k_gpib.iocsh
create mode 100644 iocsh/Keithley_2k_serial.iocsh
create mode 100644 iocsh/LakeShore_218.iocsh
create mode 100644 iocsh/LakeShore_330.iocsh
create mode 100644 iocsh/LakeShore_340.iocsh
create mode 100644 iocsh/Lakeshore_DRC93CA.iocsh
create mode 100644 iocsh/MKS651C.iocsh
create mode 100644 iocsh/MKS_651C.iocsh
create mode 100644 iocsh/Newport_LAE500.iocsh
create mode 100644 iocsh/Omega_DP41.iocsh
create mode 100644 iocsh/Oxford_CS800.iocsh
create mode 100644 iocsh/Oxford_CS800_status.iocsh
create mode 100644 iocsh/Oxford_ILM202.iocsh
create mode 100644 iocsh/Oxford_X1k.iocsh
create mode 100644 iocsh/PTC10_eth.iocsh
create mode 100644 iocsh/PTC10_rtd.iocsh
create mode 100644 iocsh/PTC10_tc.iocsh
create mode 100644 iocsh/PTC10_tec.iocsh
create mode 100644 iocsh/Pelco_CM6700.iocsh
create mode 100644 iocsh/Protura_P201.iocsh
create mode 100644 iocsh/Queensgate_piezo.iocsh
create mode 100644 iocsh/SR_570.iocsh
create mode 100644 iocsh/SR_830.iocsh
create mode 100644 iocsh/USdigital_X3.iocsh
create mode 100644 iocsh/XIA_pfcu_filters.iocsh
create mode 100644 iocsh/loadIPPort.iocsh
create mode 100644 iocsh/loadSerialComm.iocsh
create mode 100644 iocsh/loadSerialPort.iocsh
create mode 100644 iocsh/setSerialParams.iocsh
create mode 100644 ipApp/Db/XIA_pfcu_filters.db
create mode 100644 ipApp/Db/XIA_pfcu_filters.proto
create mode 100644 ipApp/Db/XIA_pfcu_filters_settings.req
create mode 100644 ipApp/iocsh/XIA_pfcu_filters.iocsh
create mode 100644 ipApp/op/ui/XIA_pfcu_filters_base.ui
create mode 100644 ipApp/op/ui/XIA_pfcu_filters_less.ui
create mode 100644 ipApp/op/ui/XIA_pfcu_filters_main.ui
diff --git a/.gitignore b/.gitignore
index 37cbf09b..caf59a66 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,6 +5,7 @@ O.*
bin/
/db/
dbd/
+iocsh/
html/
include/
lib/
diff --git a/configure/RELEASE b/configure/RELEASE
index f1908cec..59171a2a 100644
--- a/configure/RELEASE
+++ b/configure/RELEASE
@@ -9,14 +9,16 @@
#
# Add your declarations here
+
+
# SUPPORT=/home/oxygen/MOONEY/epics/synAppsSVN/support
-SUPPORT=/APSshare/epics/synApps_6_1/support-v7
+SUPPORT=/APSshare/epics/synApps_6_2_1/support
-ASYN=$(SUPPORT)/asyn-R4-36
-IPAC=$(SUPPORT)/ipac-2-15
-SNCSEQ=$(SUPPORT)/seq-2-2-6
+ASYN=$(SUPPORT)/asyn-R4-42
+IPAC=$(SUPPORT)/ipac-2-16
+SNCSEQ=$(SUPPORT)/seq-2-2-9
-EPICS_BASE=/APSshare/epics/base-7.0.3
+EPICS_BASE=/APSshare/epics/base-7.0.4.1
# These lines allow developers to override these RELEASE settings
# without having to modify this file directly.
diff --git a/iocsh/ADAM_4018.iocsh b/iocsh/ADAM_4018.iocsh
new file mode 100644
index 00000000..c19b5f02
--- /dev/null
+++ b/iocsh/ADAM_4018.iocsh
@@ -0,0 +1,29 @@
+# ### ADAM_4018.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- A - Module address (2-char string representation of the number)
+#- IP - Location of IP module
+#- ###################################################
+
+# Note: the ADAM-4018 uses a 2-wire RS-485 connection
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=$(BAUD=9600), BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+# Controller-specific records
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018.db", "P=$(PREFIX),R=$(INSTANCE=adam1),PORT=$(PORT),A=$(A=01)")
+# Channel-specific records
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=0")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=1")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=2")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=3")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=4")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=5")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=6")
+dbLoadRecords("$(IP)/ipApp/Db/ADAM_4018_chan.db", "P=$(PREFIX),R=$(INSTANCE=adam1),C=7")
+# Dedicated asyn record (for troubleshooting)
+dbLoadRecords("$(ASYN)/db/asynRecord.db","P=$(PREFIX),R=$(INSTANCE=adam1)asyn,PORT=$(PORT),ADDR=0,OMAX=256,IMAX=256")
diff --git a/iocsh/Agilent_E3631A.iocsh b/iocsh/Agilent_E3631A.iocsh
new file mode 100644
index 00000000..3c65e37f
--- /dev/null
+++ b/iocsh/Agilent_E3631A.iocsh
@@ -0,0 +1,17 @@
+# ### Agilent_E3631A.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+
+#- Agilent E3631A triple output power supply
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=2, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\r\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/Agilent_E3631A.db", "P=$(PREFIX),S=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/BK_9130.iocsh b/iocsh/BK_9130.iocsh
new file mode 100644
index 00000000..cb0d6bf0
--- /dev/null
+++ b/iocsh/BK_9130.iocsh
@@ -0,0 +1,17 @@
+# ### BK_9130.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix (power supply number)
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+
+#- Agilent E3631A triple output power supply
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=2, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/BK9130.db", "P=$(PREFIX),PS=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/EXAMPLE_Pelco_CM6700.substitutions b/iocsh/EXAMPLE_Pelco_CM6700.substitutions
new file mode 100644
index 00000000..9f4e371a
--- /dev/null
+++ b/iocsh/EXAMPLE_Pelco_CM6700.substitutions
@@ -0,0 +1,22 @@
+file "$(IP)/ipApp/Db/Pelco_CM6700_names.db"
+{
+pattern
+{STR}
+{ZRST}
+{ONST}
+{TWST}
+{THST}
+{FRST}
+{FVST}
+{SXST}
+{SVST}
+{EIST}
+{NIST}
+{TEST}
+{ELST}
+{TVST}
+{TTST}
+{FTST}
+{FFST}
+}
+
diff --git a/iocsh/Eurotherm2k.iocsh b/iocsh/Eurotherm2k.iocsh
new file mode 100644
index 00000000..019fc327
--- /dev/null
+++ b/iocsh/Eurotherm2k.iocsh
@@ -0,0 +1,20 @@
+# ### Eurotherm2k.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- GAD - Optional: GAD Value
+#- Default: 0
+#-
+#- LAD - Optional: LAD Value
+#- Default: 1
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=7, STOP=1, PARITY=even")
+
+asynOctetSetInputEos( "$(PORT)", -1, "")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/Eurotherm2k.db", "P=$(PREFIX),TC=$(INSTANCE),PORT=$(PORT),GAD=$(GAD=0),LAD=$(LAD=1)")
diff --git a/iocsh/Heidenhain_ND261.iocsh b/iocsh/Heidenhain_ND261.iocsh
new file mode 100644
index 00000000..47af696a
--- /dev/null
+++ b/iocsh/Heidenhain_ND261.iocsh
@@ -0,0 +1,14 @@
+# ### Heidenhain_ND261.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=7, STOP=2, PARITY=even")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/heidND261.db", "P=$(PREFIX),PORT=$(PORT)")
diff --git a/iocsh/Keithley_2k_gpib.iocsh b/iocsh/Keithley_2k_gpib.iocsh
new file mode 100644
index 00000000..f9704f41
--- /dev/null
+++ b/iocsh/Keithley_2k_gpib.iocsh
@@ -0,0 +1,17 @@
+# ### Keithley_2k_gpib.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - gpib port name
+#- ADDR - gpib address
+#- NUM_CHANNELS - Number of channels (10, 20, 22)
+#- MODEL - Keithley model number (2700, 2000)
+#- IP - Location of IP module
+#- ###################################################
+
+asynOctetSetInputEos("$(PORT)", $(ADDR), "\n")
+asynOctetConnect("$(PORT):$(ADDR)", "$(PORT)", $(ADDR), 1, 80)
+
+dbLoadRecords("$(IP)/ipApp/Db/Keithley2kDMM_mf.db","P=$(PREFIX),Dmm=$(INSTANCE),PORT=$(PORT):$(ADDR)")
+doAfterIocInit("seq &Keithley2kDMM,('P=$(PREFIX), Dmm=$(INSTANCE), channels=$(NUM_CHANNELS), model=$(MODEL)')")
diff --git a/iocsh/Keithley_2k_serial.iocsh b/iocsh/Keithley_2k_serial.iocsh
new file mode 100644
index 00000000..8d00185e
--- /dev/null
+++ b/iocsh/Keithley_2k_serial.iocsh
@@ -0,0 +1,21 @@
+# ### Keithley_2k_serial.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- NUM_CHANNELS - Number of channels (10, 20, 22)
+#- MODEL - Keithley model number (2700, 2000)
+#- IP - Location of IP module
+#- BAUD - Optional: Baud rate you have set the
+#- Keithley to operate at.
+#- Default: 9600
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=$(BAUD=9600), BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/Keithley2kDMM_mf.db","P=$(PREFIX),Dmm=$(INSTANCE),PORT=$(PORT)")
+doAfterIocInit("seq &Keithley2kDMM,('P=$(PREFIX), Dmm=$(INSTANCE), channels=$(NUM_CHANNELS), model=$(MODEL)')")
diff --git a/iocsh/LakeShore_218.iocsh b/iocsh/LakeShore_218.iocsh
new file mode 100644
index 00000000..99bc4599
--- /dev/null
+++ b/iocsh/LakeShore_218.iocsh
@@ -0,0 +1,15 @@
+# ### LakeShore_218.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=7, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/LakeShore218.vdb", "P=$(PREFIX),R=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/LakeShore_330.iocsh b/iocsh/LakeShore_330.iocsh
new file mode 100644
index 00000000..8910bd13
--- /dev/null
+++ b/iocsh/LakeShore_330.iocsh
@@ -0,0 +1,15 @@
+# ### LakeShore_330.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=1200, BITS=7, STOP=1, PARITY=odd")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/LakeShore330.db", "P=$(PREFIX),Q=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/LakeShore_340.iocsh b/iocsh/LakeShore_340.iocsh
new file mode 100644
index 00000000..0104f259
--- /dev/null
+++ b/iocsh/LakeShore_340.iocsh
@@ -0,0 +1,15 @@
+# ### LakeShore_340.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/LakeShore340.db", "P=$(PREFIX),Q=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/Lakeshore_DRC93CA.iocsh b/iocsh/Lakeshore_DRC93CA.iocsh
new file mode 100644
index 00000000..be4c0690
--- /dev/null
+++ b/iocsh/Lakeshore_DRC93CA.iocsh
@@ -0,0 +1,17 @@
+# ### Lakeshore_DRC93CA.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- BAUD - Optional: What the baud rate is set to
+#- Default: 300
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=$(BAUD=300), BITS=7, STOP=1, PARITY=odd")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\r\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/LakeShoreDRC-93CA.db", "P=$(PREFIX),Q=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/MKS651C.iocsh b/iocsh/MKS651C.iocsh
new file mode 100644
index 00000000..83be66c0
--- /dev/null
+++ b/iocsh/MKS651C.iocsh
@@ -0,0 +1,19 @@
+# ### MKS651C.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- BAUD - Baud Rate (Optional)
+#- Default: 9600
+#- TERMINATOR - EOS Terminator (Optional)
+#- Default: CRLF
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=$(BAUD=9600), BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "$(TERMINATOR=\r\n)")
+asynOctetSetOutputEos("$(PORT)", -1, "$(TERMINATOR=\r\n)")
+
+dbLoadRecords("$(IP)/db/MKS651C.db", "P=$(PREFIX), R=$(INSTANCE), PORT=$(PORT)"
diff --git a/iocsh/MKS_651C.iocsh b/iocsh/MKS_651C.iocsh
new file mode 100644
index 00000000..fe20ebe9
--- /dev/null
+++ b/iocsh/MKS_651C.iocsh
@@ -0,0 +1,18 @@
+# ### MKS_651C.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- BAUD - Optional: Baud rate you have set the
+#- MKS to operate at.
+#- Default: 9600
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=$(BAUD=9600), BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\r\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/MKS651C.db","P=$(PREFIX),R=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/Newport_LAE500.iocsh b/iocsh/Newport_LAE500.iocsh
new file mode 100644
index 00000000..cdf9778d
--- /dev/null
+++ b/iocsh/Newport_LAE500.iocsh
@@ -0,0 +1,16 @@
+# ### Newport_LAE500.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+#- Newport LAE500 autocollimator support
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/Newport_LAE500.db", "P=$(PREFIX),R=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/Omega_DP41.iocsh b/iocsh/Omega_DP41.iocsh
new file mode 100644
index 00000000..2f51c684
--- /dev/null
+++ b/iocsh/Omega_DP41.iocsh
@@ -0,0 +1,15 @@
+# ### Omega_DP41.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=odd")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/OmegaDP41.db", "P=$(PREFIX),S=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/Oxford_CS800.iocsh b/iocsh/Oxford_CS800.iocsh
new file mode 100644
index 00000000..de3e406c
--- /dev/null
+++ b/iocsh/Oxford_CS800.iocsh
@@ -0,0 +1,23 @@
+
+# file: Oxford_CS800.iocsh
+# purpose: Status and commands for a specific CS800 controller
+
+# MACRO PARAMETERS
+#
+# MACRO | EXAMPLE | DEFINITION
+# ------------- | --------------------- | ----------------------
+# PREFIX | xxx: | IOC prefix
+# R | CS0: | CS800 controller database prefix
+# CID | 411 | Controller Number (use 0 if unknown and only 1 CS800)
+# COMMAND_IP | 192.168.0.144 | IP number of CS800 controller
+# CS800_STATUS | xxx:CS:status_packets | asyn PV with status packet data
+
+epicsEnvSet("CS800_ASYN_CMD_PORT", "CS800_CMD_$(CID)")
+epicsEnvSet("STREAM_PROTOCOL_PATH", "$(STREAM_PROTOCOL_PATH):$(IP)/db")
+
+# To support multiple controllers, we use UDP& for each
+# Requires asyn including https://github.com/epics-modules/asyn/pull/109
+drvAsynIPPortConfigure("$(CS800_ASYN_CMD_PORT)", "$(COMMAND_IP):30305 UDP&")
+
+dbLoadRecords("$(IP)/db/Oxford_CS800.db", "P=$(PREFIX),R=$(R),CP=$(CS800_ASYN_CMD_PORT)",SP=$(CS800_STATUS))
+doAfterIocInit("seq Oxford_CS800,'name=cs800_$(CID),CID=$(CID),P=$(PREFIX),R=$(R),SP=$(CS800_STATUS)'")
diff --git a/iocsh/Oxford_CS800_status.iocsh b/iocsh/Oxford_CS800_status.iocsh
new file mode 100644
index 00000000..0310c363
--- /dev/null
+++ b/iocsh/Oxford_CS800_status.iocsh
@@ -0,0 +1,18 @@
+
+# file: Oxford_CS800_status.iocsh
+# purpose: UDP status packet data from all CS800 controllers in asyn record
+
+# MACRO PARAMETERS
+#
+# MACRO | EXAMPLE | DEFINITION
+# ------------- | --------------- | ----------------------
+# PREFIX | xxx: | IOC prefix
+# R | CS: | CS800 shared asyn status database prefix
+# STATUS_IP | 192.168.0.176 | IP number of this IOC
+
+# common status port for all CS800 controllers
+
+drvAsynIPPortConfigure("CS800_UDP_STATUS", "$(STATUS_IP):30304:30304 UDP")
+dbLoadRecords("$(IP)/db/Oxford_CS800_status.db", "P=$(PREFIX),R=$(R),SP=CS800_UDP_STATUS")
+epicsEnvSet("CS800_STATUS", "$(PREFIX)$(R)status_packet") # for use with each controller
+epicsEnvSet("STREAM_PROTOCOL_PATH", ".:$(TOP)/iocBoot/$(IOC)")
diff --git a/iocsh/Oxford_ILM202.iocsh b/iocsh/Oxford_ILM202.iocsh
new file mode 100644
index 00000000..c2fa727c
--- /dev/null
+++ b/iocsh/Oxford_ILM202.iocsh
@@ -0,0 +1,16 @@
+# ### Oxford_ILM202.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+#- Oxford ILM202 Cryogen Level Meter
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/Oxford_ILM202.db", "P=$(PREFIX),S=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/Oxford_X1k.iocsh b/iocsh/Oxford_X1k.iocsh
new file mode 100644
index 00000000..3b14c0d9
--- /dev/null
+++ b/iocsh/Oxford_X1k.iocsh
@@ -0,0 +1,16 @@
+# ### Oxford_X1k.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+#- Oxford Cyberstar X1000 Scintillation detector and pulse processing unit
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\n")
+asynOctetSetOutputEos("$(PORT)", -1, "\n")
+
+dbLoadRecords("$(IP)/ipApp/Db/Oxford_X1k.db", "P=$(PREFIX),S=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/PTC10_eth.iocsh b/iocsh/PTC10_eth.iocsh
new file mode 100644
index 00000000..53a6e672
--- /dev/null
+++ b/iocsh/PTC10_eth.iocsh
@@ -0,0 +1,41 @@
+# ### PTC10_eth.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- IP_ADDR - IP address of the PTC10
+#- IP_PORT - IP port number (default: 23)
+#- PORT - Name of asyn port to be created
+#- PREC - Number of digits after the decimal (default = 3)
+#- ### I/O channel names
+#- A1 - Analog I/O channel 1 name (default = 5A)
+#- A2 - Analog I/O channel 2 name (default = 5B)
+#- A3 - Analog I/O channel 3 name (default = 5C)
+#- A4 - Analog I/O channel 4 name (default = 5D)
+#- ### Module locations shouldn't need to be passed explicitly
+#- IP - Location of IP module
+#- ASYN - Location of ASYN module
+#- ###################################################
+
+drvAsynIPPortConfigure("$(PORT)","$(IP_ADDR):$(IP_PORT=23)", 0, 0, 0)
+
+# Only show errors
+asynSetTraceMask("$(PORT)", 0, 1)
+# Leave ascii selected so debug messages can be turned on with a single click
+asynSetTraceIOMask("$(PORT)", 0, 1)
+
+# Set end-of-string terminators
+asynOctetSetInputEos( "$(PORT)", 0, "\r\n")
+asynOctetSetOutputEos("$(PORT)", 0, "\r\n")
+
+# PTC10
+dbLoadRecords("$(IP)/db/PTC10.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0")
+
+# PTC10 Analog I/O
+dbLoadRecords("$(IP)/db/PTC10_aio_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,N=1,C=$(A1=5A),EGU=V,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_aio_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,N=2,C=$(A2=5B),EGU=V,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_aio_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,N=3,C=$(A3=5C),EGU=V,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_aio_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,N=4,C=$(A4=5D),EGU=V,PREC=$(PREC=3)")
+
+# Asyn record for troubleshooting
+dbLoadRecords("$(ASYN)/db/asynRecord.db","P=$(PREFIX),R=$(INSTANCE):asyn,PORT=$(PORT),ADDR=0,OMAX=0,IMAX=0")
diff --git a/iocsh/PTC10_rtd.iocsh b/iocsh/PTC10_rtd.iocsh
new file mode 100644
index 00000000..824326a9
--- /dev/null
+++ b/iocsh/PTC10_rtd.iocsh
@@ -0,0 +1,17 @@
+# ### PTC10_rtd.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Name of asyn port to be created
+#- PREC - Number of digits after the decimal (default = 3)
+#- ### I/O channel names
+#- R1 - RTD channel 1 name
+#- R2 - RTD channel 2 name
+#- ### Module locations shouldn't need to be passed explicitly
+#- IP - Location of IP module
+#- ###################################################
+
+# PTC323 thermister/diode/RTD card
+dbLoadRecords("$(IP)/db/PTC10_rtd_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(R1),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_rtd_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(R2),EGU=C,PREC=$(PREC=3)")
diff --git a/iocsh/PTC10_tc.iocsh b/iocsh/PTC10_tc.iocsh
new file mode 100644
index 00000000..32f362e5
--- /dev/null
+++ b/iocsh/PTC10_tc.iocsh
@@ -0,0 +1,23 @@
+# ### PTC10_tc.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Name of asyn port to be created
+#- PREC - Number of digits after the decimal (default = 3)
+#- ### I/O channel names
+#- T1 - Thermcouple channel 1 name
+#- T2 - Thermcouple channel 2 name
+#- T3 - Thermcouple channel 3 name
+#- T4 - Thermcouple channel 4 name
+#- CJ - Cold Junction channel name (default = ColdJ2)
+#- ### Module locations shouldn't need to be passed explicitly
+#- IP - Location of IP module
+#- ###################################################
+
+# PTC330 Thermocouple reader
+dbLoadRecords("$(IP)/db/PTC10_tc_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(T1),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_tc_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(T2),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_tc_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(T3),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_tc_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(T4),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_coldj_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(CJ=ColdJ2),EGU=C,PREC=$(PREC=3)")
diff --git a/iocsh/PTC10_tec.iocsh b/iocsh/PTC10_tec.iocsh
new file mode 100644
index 00000000..e2faff7b
--- /dev/null
+++ b/iocsh/PTC10_tec.iocsh
@@ -0,0 +1,17 @@
+# ### PTC10_tec.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Name of asyn port to be created
+#- PREC - Number of digits after the decimal (default = 3)
+#- ### I/O channel names
+#- TI - TEC input channel name
+#- TO - TEC output channel name
+#- ### Module locations shouldn't need to be passed explicitly
+#- IP - Location of IP module
+#- ###################################################
+
+# PTC440 TEC driver
+dbLoadRecords("$(IP)/db/PTC10_tec_in_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(TI),EGU=C,PREC=$(PREC=3)")
+dbLoadRecords("$(IP)/db/PTC10_tec_out_chan.db","P=$(PREFIX),T=$(INSTANCE),PORT=$(PORT),ADDR=0,C=$(TO),EGU=A,PREC=$(PREC=3)")
diff --git a/iocsh/Pelco_CM6700.iocsh b/iocsh/Pelco_CM6700.iocsh
new file mode 100644
index 00000000..787271ac
--- /dev/null
+++ b/iocsh/Pelco_CM6700.iocsh
@@ -0,0 +1,19 @@
+# ### Pelco_CM6700.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- SUB - Optional: Names substitution file (Pelco_CM6700_names.db)
+#- Macros P and R will be set automatically.
+#- Default: $(IP)/iocsh/EXAMPLE_Pelco_CM6700.substitutions
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=odd")
+
+asynOctetSetInputEos( "$(PORT)", -1, "")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/Pelco_CM6700.db", "P=$(PREFIX),R=$(INSTANCE),PORT=$(PORT)")
+dbLoadTemplate("$(SUB=$(IP)/iocsh/EXAMPLE_Pelco_CM6700.substitutions)", "P=$(PREFIX),R=$(INSTANCE)")
diff --git a/iocsh/Protura_P201.iocsh b/iocsh/Protura_P201.iocsh
new file mode 100644
index 00000000..bef0f372
--- /dev/null
+++ b/iocsh/Protura_P201.iocsh
@@ -0,0 +1,19 @@
+# ### Protura_P201.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- DEVPATH - Serial Device Filepath
+#- MOTOR - Associated Motor
+#- IP - Location of IP module
+#-
+#- BITS - Optional: Encoder Bitdepth
+#- Default: 32
+#- ###################################################
+
+drvAsynSerialPortConfigure("serial_$(INSTANCE)", "$(DEVPATH)", 0, 0, 0)
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=serial_$(INSTANCE), BAUD=115200, BITS=8, STOP=1")
+asynOctetConnect("serial_$(INSTANCE)", "serial_$(INSTANCE)")
+
+dbLoadRecords("$(IP)/db/Protura_P201.db","P=$(PREFIX),ENC=$(INSTANCE),PORT=serial_$(INSTANCE), BITS=$(BITS=32), M=$(MOTOR)")
diff --git a/iocsh/Queensgate_piezo.iocsh b/iocsh/Queensgate_piezo.iocsh
new file mode 100644
index 00000000..855385fd
--- /dev/null
+++ b/iocsh/Queensgate_piezo.iocsh
@@ -0,0 +1,15 @@
+# ### Queensgate_piezo.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+# Queensgate piezo driver
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=7, STOP=2, PARITY=odd")
+
+asynOctetSetInputEos( "$(PORT)", -1, "")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/pzt.db","P=$(PREFIX),PORT=$(PORT)")
diff --git a/iocsh/SR_570.iocsh b/iocsh/SR_570.iocsh
new file mode 100644
index 00000000..a8cc8e9f
--- /dev/null
+++ b/iocsh/SR_570.iocsh
@@ -0,0 +1,16 @@
+# ### SR_570.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+#- Stanford Research Systems SR570 Current Preamplifier
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=2, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/SR570.db", "P=$(PREFIX),A=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/SR_830.iocsh b/iocsh/SR_830.iocsh
new file mode 100644
index 00000000..ec92c330
--- /dev/null
+++ b/iocsh/SR_830.iocsh
@@ -0,0 +1,15 @@
+# ### SR_830.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=9600, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "\r")
+asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+dbLoadRecords("$(IP)/ipApp/Db/SR830.vdb", "P=$(PREFIX),N=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/USdigital_X3.iocsh b/iocsh/USdigital_X3.iocsh
new file mode 100644
index 00000000..e911f648
--- /dev/null
+++ b/iocsh/USdigital_X3.iocsh
@@ -0,0 +1,16 @@
+# ### USdigital_X3.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- PORT - Serial port name
+#- IP - Location of IP module
+#- ###################################################
+
+#- US Digital X3 Inclinometer
+iocshLoad("$(IP)/iocsh/setSerialParams.iocsh", "PORT=$(PORT), BAUD=19200, BITS=8, STOP=1, PARITY=none")
+
+asynOctetSetInputEos( "$(PORT)", -1, "")
+asynOctetSetOutputEos("$(PORT)", -1, "")
+
+dbLoadRecords("$(IP)/ipApp/Db/USdigital_X3.vdb", "P=$(PREFIX),S=$(INSTANCE),PORT=$(PORT)")
diff --git a/iocsh/XIA_pfcu_filters.iocsh b/iocsh/XIA_pfcu_filters.iocsh
new file mode 100644
index 00000000..8231b348
--- /dev/null
+++ b/iocsh/XIA_pfcu_filters.iocsh
@@ -0,0 +1,18 @@
+# ### XIA_pfcu_filters.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- ADDRESS - PFCU Address
+#- PORT - Port name of moxa serial server
+#- OPTICS - Location of OPTICS module
+#- ###################################################
+
+#asynOctetSetInputEos( "$(PORT)", -1, "\r")
+#asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+epicsEnvSet("STREAM_PROTOCOL_PATH","$(STREAM_PROTOCOL_PATH):$(IP)/ipApp/Db")
+dbLoadRecords("$(IP)/ipApp/Db/XIA_pfcu_filters.db", "P=$(PREFIX),F=$(FILTERNAM=pfcu0),PORT=$(PORT),ADDR=$(ADDRESS=00)")
+
+
+
diff --git a/iocsh/loadIPPort.iocsh b/iocsh/loadIPPort.iocsh
new file mode 100644
index 00000000..2ccebe01
--- /dev/null
+++ b/iocsh/loadIPPort.iocsh
@@ -0,0 +1,12 @@
+#- ###################################################
+#- PREFIX - IOC prefix
+#- PORT - asyn port name
+#- IP - IP address and port
+#- IN_BUFF - Input buffer size (Default: 1000),
+#- OUT_BUFF - Output buffer size (Default:1000)
+#- INSTANCE - Instance name for asyn record (Default: asyn_$(PORT))
+#- ###################################################
+
+drvAsynIPPortConfigure("$(PORT)", "$(IP)", 0, 0, 0)
+asynOctetConnect("$(PORT)", "$(PORT)")
+dbLoadRecords("$(ASYN)/db/asynRecord.db", "P=$(PREFIX), R=$(INSTANCE=asyn_$(PORT)), PORT=$(PORT), ADDR=0, OMAX=$(OUT_BUFF=1000), IMAX=$(IN_BUFF=1000)")
diff --git a/iocsh/loadSerialComm.iocsh b/iocsh/loadSerialComm.iocsh
new file mode 100644
index 00000000..1bea444b
--- /dev/null
+++ b/iocsh/loadSerialComm.iocsh
@@ -0,0 +1,23 @@
+#- ###################################################
+#- PREFIX - IOC prefix
+#- PORT - Port prefix used to initialize Octal module
+#- PORT0 - Port for first asyn record (Default: $(PORT)0)
+#- PORT1 - Port for second asyn record (Default: $(PORT1=$(PORT)1))
+#- ...
+#- PORT7 - Port for last asyn record (Default: $(PORT7=$(PORT)7))
+#- IN_BUFF - Input buffer size (Default: 1000),
+#- OUT_BUFF - Output buffer size (Default:1000)
+#- INSTANCE0 - Instance name for first asyn record (Default: asyn_$(PORT0=$(PORT)0))
+#- ...
+#- INSTANCE7 - Instance name for last asyn record (Default: asyn_$(PORT7=$(PORT)7))
+#- ###################################################
+
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT0=$(PORT='')0), INSTANCE=$(INSTANCE0=asyn_$(PORT0=$(PORT='')0)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT1=$(PORT='')1), INSTANCE=$(INSTANCE1=asyn_$(PORT1=$(PORT='')1)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT2=$(PORT='')2), INSTANCE=$(INSTANCE2=asyn_$(PORT2=$(PORT='')2)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT3=$(PORT='')3), INSTANCE=$(INSTANCE3=asyn_$(PORT3=$(PORT='')3)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT4=$(PORT='')4), INSTANCE=$(INSTANCE4=asyn_$(PORT4=$(PORT='')4)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT5=$(PORT='')5), INSTANCE=$(INSTANCE5=asyn_$(PORT5=$(PORT='')5)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT6=$(PORT='')6), INSTANCE=$(INSTANCE6=asyn_$(PORT6=$(PORT='')6)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+iocshLoad("$(IP)/iocsh/loadSerialPort.iocsh", "PORT=$(PORT7=$(PORT='')7), INSTANCE=$(INSTANCE7=asyn_$(PORT7=$(PORT='')7)), IN_BUFF=$(IN_BUFF=1000), OUT_BUFF=$(OUT_BUFF=1000)")
+
diff --git a/iocsh/loadSerialPort.iocsh b/iocsh/loadSerialPort.iocsh
new file mode 100644
index 00000000..b45f7620
--- /dev/null
+++ b/iocsh/loadSerialPort.iocsh
@@ -0,0 +1,12 @@
+#- ###################################################
+#- PREFIX - IOC prefix
+#- PORT - IPAC Dev Port
+#- DEVICE - Hardware Dev Port, ex: /dev/tty0 (Default: $(PORT))
+#- IN_BUFF - Input buffer size (Default: 1000),
+#- OUT_BUFF - Output buffer size (Default:1000)
+#- INSTANCE - Instance name for asyn record (Default: asyn_$(PORT))
+#- ###################################################
+
+drvAsynSerialPortConfigure("$(PORT)", "$(DEVICE=$(PORT))", 0, 0, 0)
+asynOctetConnect("$(PORT)", "$(PORT)")
+dbLoadRecords("$(ASYN)/db/asynRecord.db", "P=$(PREFIX), R=$(INSTANCE=asyn_$(PORT)), PORT=$(PORT), ADDR=0, OMAX=$(OUT_BUFF=1000), IMAX=$(IN_BUFF=1000)")
diff --git a/iocsh/setSerialParams.iocsh b/iocsh/setSerialParams.iocsh
new file mode 100644
index 00000000..db020922
--- /dev/null
+++ b/iocsh/setSerialParams.iocsh
@@ -0,0 +1,13 @@
+#- ###################################################
+#- BAUD=baudrate, BITS=data bits, STOP=stop bits,
+#- PARITY=none/odd/even, HANDSHAKE=none/hardware
+#- ###################################################
+
+asynSetOption("$(PORT)", -1, "baud", "$(BAUD=9600)")
+asynSetOption("$(PORT)", -1, "bits", "$(BITS=8)")
+asynSetOption("$(PORT)", -1, "stop", "$(STOP=2)")
+asynSetOption("$(PORT)", -1, "parity", "$(PARITY=none)")
+
+#clocal=Y is software handshaking, clocal=N is hardware handshaking
+iocshRun('asynSetOption("$(PORT)", -1, "clocal", "$(VALUE_$(HANDSHAKE=none)=Y)"', "VALUE_hardware=N")
+asynSetOption("$(PORT)", -1, "crtscts", "N")
diff --git a/ipApp/Db/XIA_pfcu_filters.db b/ipApp/Db/XIA_pfcu_filters.db
new file mode 100644
index 00000000..6d17efe6
--- /dev/null
+++ b/ipApp/Db/XIA_pfcu_filters.db
@@ -0,0 +1,304 @@
+########################################################################
+#
+# XIA PFCU 4-filter stream support
+#
+#
+# Author: M. Wyman (APS)
+# Date: March 2023
+########################################################################
+
+########################################################################
+# Mode configuration PVs
+########################################################################
+
+record(bo, "$(P)$(F):mode"){
+ field(ZNAM,"Filter")
+ field(ONAM,"Shutter")
+ field(PINI, "YES")
+ field(VAL, "0")
+}
+
+record(calcout, "$(P)$(F):calcMode"){
+ field(INPA, "$(P)$(F):setMode CP")
+ field(CALC, "A=0?4:2")
+ field(DTYP, "stream")
+ field(OUT, "@XIA_pfcu_filters.proto setMode($(ADDR), $(P)$(F):calcModeRBV.AA) $(PORT)")
+# field(OUT, "$(P)$(F):setMode PP")
+ field(FLNK, "$(P)$(F):calcModeRBV PP")
+}
+
+#record(bo, "$(P)$(F):setMode"){
+# field(DTYP, "stream")
+# field(OUT, "@XIA_pfcu_filters.proto setMode($(ADDR), $(P)$(F):calcModeRBV.AA) $(PORT)")
+# field(FLNK, "$(P)$(F):calcModeRBV PP")
+#}
+
+record(scalcout, "$(P)$(F):calcModeRBV"){
+ field(BB, "Disabled")
+ field(CALC, "AA=BB?0:1")
+ field(OUT, "$(P)$(F):modeRBV PP")
+}
+
+record(bi, "$(P)$(F):modeRBV") {
+ field(ZNAM,"Filter")
+ field(ONAM,"Shutter")
+}
+
+########################################################################
+# Filter configuration PVs
+########################################################################
+
+record(calcout, "$(P)$(F):calcConfig")
+{
+ field(INPA, "$(P)$(F):filter1 CP")
+ field(INPB, "$(P)$(F):filter2 CP")
+ field(INPC, "$(P)$(F):filter3 CP")
+ field(INPD, "$(P)$(F):filter4 CP")
+ field(CALC, "A*8+B*4+C*2+D")
+ field(OUT, "$(P)$(F):setConfig PP")
+}
+
+record(mbbo, "$(P)$(F):setConfig"){
+ field(DTYP, "stream")
+ field(ZRST, "0000")
+ field(ONST, "0001")
+ field(TWST, "0010")
+ field(THST, "0011")
+ field(FRST, "0100")
+ field(FVST, "0101")
+ field(SXST, "0110")
+ field(SVST, "0111")
+ field(EIST, "1000")
+ field(NIST, "1001")
+ field(TEST, "1010")
+ field(ELST, "1011")
+ field(TVST, "1100")
+ field(TTST, "1101")
+ field(FTST, "1110")
+ field(FFST, "1111")
+ field(OUT, "@XIA_pfcu_filters.proto setState($(ADDR), $(P)$(F):) $(PORT)")
+ field(FLNK, "$(P)$(F):calcConfigRBV")
+}
+
+record(calcout, "$(P)$(F):readConfig") {
+ field(DTYP, "stream")
+ field(CALC, "0")
+ field(OUT, "@XIA_pfcu_filters.proto getState($(ADDR), $(P)$(F):) $(PORT)")
+ field(PINI, "YES")
+ field(FLNK, "$(P)$(F):calcConfigRBV")
+}
+
+record(scalcout, "$(P)$(F):calcConfigRBV"){
+ field(INPA, "$(P)$(F):filter1_RBV PP")
+ field(INPB, "$(P)$(F):filter2_RBV PP")
+ field(INPC, "$(P)$(F):filter3_RBV PP")
+ field(INPD, "$(P)$(F):filter4_RBV PP")
+ field(CALC, "AA:=PRINTF('%i',A)+PRINTF('%i',B)+PRINTF('%i',C)+PRINTF('%i',D);AA")
+ field(OUT, "$(P)$(F):config_RBV PP")
+}
+
+record(mbbi, "$(P)$(F):config_RBV"){
+ field(ZRST, "0000")
+ field(ONST, "0001")
+ field(TWST, "0010")
+ field(THST, "0011")
+ field(FRST, "0100")
+ field(FVST, "0101")
+ field(SXST, "0110")
+ field(SVST, "0111")
+ field(EIST, "1000")
+ field(NIST, "1001")
+ field(TEST, "1010")
+ field(ELST, "1011")
+ field(TVST, "1100")
+ field(TTST, "1101")
+ field(FTST, "1110")
+ field(FFST, "1111")
+}
+
+record(bo, "$(P)$(F):filter1"){
+ field(ZNAM,"OUT")
+ field(ONAM,"IN")
+}
+
+record(bo, "$(P)$(F):filter2"){
+ field(ZNAM,"OUT")
+ field(ONAM,"IN")
+}
+
+record(bo, "$(P)$(F):filter3"){
+ field(ZNAM,"OUT")
+ field(ONAM,"IN")
+}
+
+record(bo, "$(P)$(F):filter4"){
+ field(ZNAM,"OUT")
+ field(ONAM,"IN")
+}
+
+record(mbbi, "$(P)$(F):filter1_RBV"){
+ field(ZRST,"Out")
+ field(ONST,"In")
+ field(TWST,"Short Circuit")
+ field(THST,"Open Circuit")
+}
+
+record(mbbi, "$(P)$(F):filter2_RBV"){
+ field(ZRST,"Out")
+ field(ONST,"In")
+ field(TWST,"Short Circuit")
+ field(THST,"Open Circuit")
+}
+
+record(mbbi, "$(P)$(F):filter3_RBV"){
+ field(ZRST,"Out")
+ field(ONST,"In")
+ field(TWST,"Short Circuit")
+ field(THST,"Open Circuit")
+}
+
+record(mbbi, "$(P)$(F):filter4_RBV"){
+ field(ZRST,"Out")
+ field(ONST,"In")
+ field(TWST,"Short Circuit")
+ field(THST,"Open Circuit")
+}
+
+record(ao,"$(P)$(F):filter1_thick")
+{
+ field(VAL,"0.1626")
+ field(DESC,"filter 1")
+ field(EGU, "mm")
+ field(PREC,"3")
+}
+
+record(ao,"$(P)$(F):filter2_thick")
+{
+ field(VAL,"0.3226")
+ field(DESC,"filter 2")
+ field(EGU, "mm")
+ field(PREC,"3")
+}
+
+record(ao,"$(P)$(F):filter3_thick")
+{
+ field(VAL,"0.6325")
+ field(DESC,"filter 3")
+ field(EGU, "mm")
+ field(PREC,"3")
+}
+
+record(ao,"$(P)$(F):filter4_thick")
+{
+ field(VAL,"1.27")
+ field(DESC,"filter 4")
+ field(EGU, "mm")
+ field(PREC,"3")
+}
+
+record(mbbo, "$(P)$(F):filter1_mat"){
+ field(VAL,"0")
+ field(ZRST,"Al")
+ field(ONST,"Ti")
+ field(TWST,"Glass")
+ field(THST,"Other")
+ field(DESC,"material filter 1")
+}
+
+record(mbbo, "$(P)$(F):filter2_mat"){
+ field(VAL,"0")
+ field(ZRST,"Al")
+ field(ONST,"Ti")
+ field(TWST,"Glass")
+ field(THST,"Other")
+ field(DESC,"material filter 2")
+}
+
+record(mbbo, "$(P)$(F):filter3_mat"){
+ field(VAL,"0")
+ field(ZRST,"Al")
+ field(ONST,"Ti")
+ field(TWST,"Glass")
+ field(THST,"Other")
+ field(DESC,"material filter 3")
+}
+
+record(mbbo, "$(P)$(F):filter4_mat"){
+ field(VAL,"0")
+ field(ZRST,"Al")
+ field(ONST,"Ti")
+ field(TWST,"Glass")
+ field(THST,"Other")
+ field(DESC,"material filter 4")
+}
+
+record(stringout,"$(P)$(F):filter1_other") {
+}
+record(stringout,"$(P)$(F):filter2_other") {
+}
+record(stringout,"$(P)$(F):filter3_other") {
+}
+record(stringout,"$(P)$(F):filter4_other") {
+}
+
+
+
+
+########################################################################
+# Admistrative PVs
+########################################################################
+
+record(calcout, "$(P)$(F):readFault") {
+ field(DTYP, "stream")
+ field(CALC, "0")
+ field(OUT, "@XIA_pfcu_filters.proto fault($(ADDR), $(P)$(F):) $(PORT)")
+# field(PINI, "YES")
+ field(SCAN, "2 second")
+}
+
+record(calcout, "$(P)$(F):clearFault") {
+ field(DTYP, "stream")
+ field(CALC, "0")
+ field(OUT, "@XIA_pfcu_filters.proto clear($(ADDR), $(P)$(F):) $(PORT)")
+ field(SCAN, "Passive")
+}
+
+record(bo, "$(P)$(F):control"){
+ field(ZNAM,"Locked")
+ field(ONAM,"Unlocked")
+ field(PINI, "YES")
+ field(VAL, "1")
+}
+
+record(scalcout, "$(P)$(F):calcControlMode")
+{
+ field(INPA, "$(P)$(F):control CP")
+ field(AA, "L")
+ field(BB, "U")
+ field(CALC, "A=0?AA:BB")
+ field(DTYP, "stream")
+ field(OUT, "@XIA_pfcu_filters.proto setControl($(ADDR), $(P)$(F):calcControlRBV.AA) $(PORT)")
+ field(FLNK, "$(P)$(F):calcControlRBV PP")
+}
+
+record(scalcout, "$(P)$(F):calcControlRBV")
+{
+ field(BB, "Disabled")
+ field(CALC, "AA=BB?0:1")
+ field(OUT, "$(P)$(F):modeRBV PP")
+}
+
+record(bi, "$(P)$(F):controlRBV")
+{
+ field(ZNAM,"Locked")
+ field(ONAM,"Unlocked")
+}
+
+record(waveform, "$(P)$(F):sysReport")
+{
+ field(DTYP, "stream")
+ field(INP, "@XIA_pfcu_filters.proto sysReport($(ADDR)) $(PORT)")
+ field(PINI, "YES")
+ field(FTVL, "CHAR")
+ field(NELM, "1000")
+}
diff --git a/ipApp/Db/XIA_pfcu_filters.proto b/ipApp/Db/XIA_pfcu_filters.proto
new file mode 100644
index 00000000..96ee715d
--- /dev/null
+++ b/ipApp/Db/XIA_pfcu_filters.proto
@@ -0,0 +1,57 @@
+########################################################################
+# Protocol file for the XIA PFCU 4 filter controller
+#
+# Author: M. Wyman (APS)
+# Date: March 2023
+########################################################################
+
+Terminator = CR;
+ExtraInput = Ignore;
+timeout = 2000;
+ReadTimeout = 500;
+
+setMode {
+ out "!PFCU\$1 {4|2}";
+ in "\%PFCU\$1 OK Shutter Mode %{Disabled|Enabled} DONE\;";
+}
+
+stateRead {
+ in "\%PFCU\$1 OK %(\$2filter1_RBV)1s%(\$2filter2_RBV)1s%(\$2filter3_RBV)1s%(\$2filter4_RBV)1s DONE\;";
+}
+
+setState {
+ out "!PFCU\$1 W %4.4s";
+ stateRead;
+# stateRead(\$1, \$2);
+# in "\%PFCU\$1 OK %(\$2filter1_RBV)1.1s%(\$2filter2_RBV)1.1s%(\$2filter3_RBV)1.1s%(\$2filter4_RBV)1.1s DONE\;";
+}
+
+getState {
+ out "!PFCU\$1 P";
+ stateRead;
+# stateRead(\$1, \$2);
+# in "\%PFCU\$1 OK %(\$2filter1_RBV)1.1s%(\$2filter2_RBV)1.1s%(\$2filter3_RBV)1.1s%(\$2filter4_RBV)1.1s DONE\;";
+}
+
+
+setControl {
+ out "!PFCU\$1 {L|U}";
+ in "\%PFCU\$1 OK %{Locked|Unlocked} DONE\;";
+}
+
+sysReport {
+ out "\!PFCU\$1 S";
+ in "\%PFCU\$1 OK %100c";
+}
+
+fault {
+ out "!PFCU\$1 F";
+ stateRead;
+# stateRead(\$1, \$2);
+}
+
+clear {
+ out "!PFCU\$1 Z";
+ stateRead;
+# stateRead(\$1, \$2);
+}
diff --git a/ipApp/Db/XIA_pfcu_filters_settings.req b/ipApp/Db/XIA_pfcu_filters_settings.req
new file mode 100644
index 00000000..b3d2893b
--- /dev/null
+++ b/ipApp/Db/XIA_pfcu_filters_settings.req
@@ -0,0 +1,12 @@
+$(P)$(F):filter1_thick
+$(P)$(F):filter2_thick
+$(P)$(F):filter3_thick
+$(P)$(F):filter4_thick
+$(P)$(F):filter1_mat
+$(P)$(F):filter2_mat
+$(P)$(F):filter3_mat
+$(P)$(F):filter4_mat
+$(P)$(F):filter1_other
+$(P)$(F):filter2_other
+$(P)$(F):filter3_other
+$(P)$(F):filter4_other
diff --git a/ipApp/iocsh/XIA_pfcu_filters.iocsh b/ipApp/iocsh/XIA_pfcu_filters.iocsh
new file mode 100644
index 00000000..8231b348
--- /dev/null
+++ b/ipApp/iocsh/XIA_pfcu_filters.iocsh
@@ -0,0 +1,18 @@
+# ### XIA_pfcu_filters.iocsh ###
+
+#- ###################################################
+#- PREFIX - IOC Prefix
+#- INSTANCE - Instance Prefix
+#- ADDRESS - PFCU Address
+#- PORT - Port name of moxa serial server
+#- OPTICS - Location of OPTICS module
+#- ###################################################
+
+#asynOctetSetInputEos( "$(PORT)", -1, "\r")
+#asynOctetSetOutputEos("$(PORT)", -1, "\r")
+
+epicsEnvSet("STREAM_PROTOCOL_PATH","$(STREAM_PROTOCOL_PATH):$(IP)/ipApp/Db")
+dbLoadRecords("$(IP)/ipApp/Db/XIA_pfcu_filters.db", "P=$(PREFIX),F=$(FILTERNAM=pfcu0),PORT=$(PORT),ADDR=$(ADDRESS=00)")
+
+
+
diff --git a/ipApp/op/ui/XIA_pfcu_filters_base.ui b/ipApp/op/ui/XIA_pfcu_filters_base.ui
new file mode 100644
index 00000000..091f84a0
--- /dev/null
+++ b/ipApp/op/ui/XIA_pfcu_filters_base.ui
@@ -0,0 +1,346 @@
+
+
+ Form
+
+
+
+ 0
+ 0
+ 736
+ 33
+
+
+
+ Form
+
+
+
+
+ 0
+ 0
+ 731
+ 31
+
+
+
+
+ 5
+
+
+ 2
+
+
+ 2
+
+ -
+
+
+ $(N)
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ $(P)$(F):filter$(N)_thick
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::Channel
+
+
+ caLineEdit::Channel
+
+
+ 1.000000000000000
+
+
+ 0.000000000000000
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(F):filter$(N)_thick.EGU
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ $(P)$(F):filter$(N)_other
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::Channel
+
+
+ caLineEdit::Channel
+
+
+ 1.000000000000000
+
+
+ 0.000000000000000
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ EPushButton::WidthAndHeight
+
+
+ $(P)$(F):filter$(N)
+
+
+ In
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ 1
+
+
+ caMessageButton::Static
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ EPushButton::WidthAndHeight
+
+
+ $(P)$(F):filter$(N)
+
+
+ Out
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ 0
+
+
+ caMessageButton::Static
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(F):filter$(N)_RBV
+
+
+
+ 10
+ 0
+ 179
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+
+
+
+ caMenu
+ QComboBox
+
+
+
+ caTextEntry
+ caLineEdit
+
+
+
+ caMessageButton
+ QPushButton
+
+
+
+ caLabel
+ QLabel
+
+
+
+ caLineEdit
+ QLineEdit
+
+
+
+
+
+
diff --git a/ipApp/op/ui/XIA_pfcu_filters_less.ui b/ipApp/op/ui/XIA_pfcu_filters_less.ui
new file mode 100644
index 00000000..ec5c96ff
--- /dev/null
+++ b/ipApp/op/ui/XIA_pfcu_filters_less.ui
@@ -0,0 +1,405 @@
+
+
+ MainWindow
+
+
+
+ 0
+ 0
+ 362
+ 279
+
+
+
+ MainWindow
+
+
+
+
+
+ 0
+ 0
+ 361
+ 31
+
+
+
+
+ 0
+ 0
+
+
+
+ 0
+
+
+
+ 0
+ 53
+ 132
+
+
+
+ caFrame::Filled
+
+
+
+ 5
+
+
+ 10
+
+
+ 2
+
+
+ 0
+
+
+ 2
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+
+ Verdana
+ 16
+ 75
+ true
+
+
+
+ XIA PFCU - $(P)$(F)
+
+
+ Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
+
+
+ ESimpleLabel::Height
+
+
+
+ 228
+ 228
+ 228
+
+
+
+
+ 160
+ 160
+ 164
+
+
+
+
+
+
+
+
+
+ 230
+ 220
+ 121
+ 31
+
+
+
+ -More
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+ 40
+ 147
+ 21
+
+
+
+ Less info
+
+
+ XIA_pfcu_filters_main.ui
+
+
+ P=$(P),F=$(F);
+
+
+ caRowColMenu::Menu
+
+
+ true
+
+
+
+
+
+ 100
+ 40
+ 161
+ 171
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+
+ 15
+
+
+
+ Simple Control
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
-
+
+
+ 1
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 2
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 3
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 4
+
+
+ Qt::AlignCenter
+
+
+
+
+
+ -
+
+
-
+
+
+ $(P)$(F):filter1_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter2_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter3_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter4_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+
+
+ -
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
+
+
+ $(P)$(F):config_RBV
+
+
+
+ 10
+ 0
+ 179
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+
+
+
+
+
+ caMenu
+ QComboBox
+
+
+
+ caRelatedDisplay
+ QWidget
+
+
+
+ caFrame
+ QFrame
+
+ 1
+
+
+ caLabel
+ QLabel
+
+
+
+ caLed
+ QWidget
+
+
+
+ caLineEdit
+ QLineEdit
+
+
+
+
+
+
diff --git a/ipApp/op/ui/XIA_pfcu_filters_main.ui b/ipApp/op/ui/XIA_pfcu_filters_main.ui
new file mode 100644
index 00000000..1133fbb4
--- /dev/null
+++ b/ipApp/op/ui/XIA_pfcu_filters_main.ui
@@ -0,0 +1,588 @@
+
+
+ MainWindow
+
+
+
+ 0
+ 0
+ 745
+ 487
+
+
+
+ MainWindow
+
+
+
+
+
+ 0
+ 0
+ 741
+ 31
+
+
+
+
+ 0
+ 0
+
+
+
+ 0
+
+
+
+ 0
+ 53
+ 132
+
+
+
+ caFrame::Filled
+
+
+
+ 5
+
+
+ 10
+
+
+ 2
+
+
+ 0
+
+
+ 2
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+
+ Verdana
+ 16
+ 75
+ true
+
+
+
+ $(P)$(F) XIA PFCU filter set
+
+
+ Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
+
+
+ ESimpleLabel::Height
+
+
+
+ 228
+ 228
+ 228
+
+
+
+
+ 160
+ 160
+ 164
+
+
+
+
+
+
+
+
+
+ 0
+ 70
+ 741
+ 191
+
+
+
+ P=$(P),F=$(F),N=1;P=$(P),F=$(F),N=2;P=$(P),F=$(F),N=3;P=$(P),F=$(F),N=4
+
+
+ XIA_pfcu_filters_base.ui
+
+
+ 4
+
+
+
+
+
+ 310
+ 270
+ 161
+ 191
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+
+ 15
+
+
+
+ Simple Control
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
-
+
+
+ 1
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 2
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 3
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ 4
+
+
+ Qt::AlignCenter
+
+
+
+
+
+ -
+
+
-
+
+
+ $(P)$(F):filter1_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter2_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter3_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+ -
+
+
+ $(P)$(F):filter4_RBV
+
+
+
+ 0
+ 255
+ 0
+
+
+
+
+ 255
+ 0
+ 0
+
+
+
+
+
+
+ -
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
+
+
+ $(P)$(F):config_RBV
+
+
+
+ 10
+ 0
+ 179
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+
+
+
+ 620
+ 420
+ 121
+ 31
+
+
+
+ -Less
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+ 40
+ 147
+ 21
+
+
+
+ Less info
+
+
+ XIA_pfcu_filters_less.ui
+
+
+ P=$(P),F=$(F);
+
+
+ caRowColMenu::Menu
+
+
+ true
+
+
+
+
+
+ 0
+ 40
+ 731
+ 31
+
+
+
+
+ 5
+
+
+ 2
+
+
+ 2
+
+ -
+
+
+ Filter #
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ Material
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ Thickness
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ Notes
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ Control
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
+ Status
+
+
+ Qt::AlignCenter
+
+
+
+
+
+
+
+
+ 10
+ 400
+ 127
+ 25
+
+
+
+ -Calcs
+
+
+
+ 228
+ 228
+ 228
+
+
+
+
+ 53
+ 132
+ 0
+
+
+
+ Mode Calc;Config Calc;Read Config;Clear Fault;Read Fault
+
+
+ yyCalcoutRecord_full.ui;yyCalcoutRecord_full.ui;yyCalcoutRecord_full.ui;yyCalcoutRecord_full.ui;yyCalcoutRecord_full.ui
+
+
+ P=$(P)$(F):, C=calcMode;P=$(P)$(F):, C=calcConfig;P=$(P)$(F):, C=readConfig;P=$(P)$(F):, C=clearFault;P=$(P)$(F):, C=readFault
+
+
+ caRowColMenu::Menu
+
+
+
+
+
+ 10
+ 430
+ 127
+ 25
+
+
+
+ -String Calcs
+
+
+
+ 228
+ 228
+ 228
+
+
+
+
+ 53
+ 132
+ 0
+
+
+
+ Mode RBV calc;Config RBV calc;Control Mode calc;Control RBV calc
+
+
+ yysCalcoutRecord_full.ui;yysCalcoutRecord_full.ui;yysCalcoutRecord_full.ui;yysCalcoutRecord_full.ui
+
+
+ P=$(P)$(F):, C=calcModeRBV;P=$(P)$(F):, C=calcConfigRBV;P=$(P)$(F):, C=calcControlMode;P=$(P)$(F):, C=calcControlRBV
+
+
+ caRowColMenu::Menu
+
+
+
+
+
+
+
+ caMenu
+ QComboBox
+
+
+
+ caRelatedDisplay
+ QWidget
+
+
+
+ caFrame
+ QFrame
+
+ 1
+
+
+ caLabel
+ QLabel
+
+
+
+ caInclude
+ QWidget
+
+
+
+ caLed
+ QWidget
+
+
+
+ caLineEdit
+ QLineEdit
+
+
+
+
+
+
From 0527b001bd5a224b2bf5d681845805874be812b2 Mon Sep 17 00:00:00 2001
From: 25-ID Staff Account <25-id@list.anl.gov>
Date: Fri, 19 Jan 2024 09:53:03 -0600
Subject: [PATCH 2/5] Updated XIA filter (stream) support. Added support for
Thorlabs and Uniblitz shutter controllers.
---
.loglogin | 2 +
ipApp/Db/Thorlabs_SC10.db | 247 +++++
ipApp/Db/Thorlabs_SC10.proto | 125 +++
ipApp/Db/Thorlabs_SC10_settings.req | 8 +
ipApp/Db/XIA_pfcu_filters.db | 60 +-
ipApp/Db/XIA_pfcu_filters.proto | 2 +-
ipApp/Db/uniblitz.proto | 38 +
ipApp/Db/uniblitz_d122.db | 20 +
ipApp/Db/uniblitz_vcm-d1.db | 52 +
ipApp/op/ui/Thorlabs_SC10.ui | 1328 ++++++++++++++++++++++++++
ipApp/op/ui/XIA_pfcu_filters_base.ui | 82 +-
ipApp/op/ui/XIA_pfcu_filters_less.ui | 2 +-
ipApp/op/ui/XIA_pfcu_filters_main.ui | 8 +-
ipApp/op/ui/uniblitz_d122.ui | 300 ++++++
ipApp/op/ui/uniblitz_vcm-d1.ui | 518 ++++++++++
15 files changed, 2707 insertions(+), 85 deletions(-)
create mode 100644 ipApp/Db/Thorlabs_SC10.db
create mode 100644 ipApp/Db/Thorlabs_SC10.proto
create mode 100644 ipApp/Db/Thorlabs_SC10_settings.req
create mode 100644 ipApp/Db/uniblitz.proto
create mode 100644 ipApp/Db/uniblitz_d122.db
create mode 100644 ipApp/Db/uniblitz_vcm-d1.db
create mode 100644 ipApp/op/ui/Thorlabs_SC10.ui
create mode 100644 ipApp/op/ui/uniblitz_d122.ui
create mode 100644 ipApp/op/ui/uniblitz_vcm-d1.ui
diff --git a/.loglogin b/.loglogin
index f989b568..d002103b 100644
--- a/.loglogin
+++ b/.loglogin
@@ -1,2 +1,4 @@
02/17/2021 - 08:26:06 - bm17-bluesky
02/17/2021 - 08:34:14 - bm17-bluesky
+03/27/2023 - 14:57:39 - konstantinov
+01/19/2024 - 09:52:06 - ravioli
diff --git a/ipApp/Db/Thorlabs_SC10.db b/ipApp/Db/Thorlabs_SC10.db
new file mode 100644
index 00000000..dd96b53c
--- /dev/null
+++ b/ipApp/Db/Thorlabs_SC10.db
@@ -0,0 +1,247 @@
+# Database for the Thorlabs SC10 shutter controller
+
+
+###############################################################################
+# Binary control and readbacks
+#
+# Note: baud control is not implemented but only has two options 0 (9600) and 1
+# (115k)
+###############################################################################
+
+record(bo, "$(P)$(S):Enable")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setEnable $(PORT)")
+ field(DESC, "Shutter enable")
+ field(ZNAM, "Disabled")
+ field(ONAM, "Enabled")
+ field(FLNK, "$(P)$(S):Enable_RBV PP")
+}
+
+record(bi, "$(P)$(S):Enable_RBV")
+{
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getEnable $(PORT)")
+ field(DESC, "Shutter enable status")
+ field(ZNAM, "Disabled")
+ field(ONAM, "Enabled")
+}
+
+record(bo, "$(P)$(S):TriggerMode")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setTrig $(PORT)")
+ field(DESC, "Shutter trigger mode")
+ field(ZNAM, "Internal")
+ field(ONAM, "External")
+ field(FLNK, "$(P)$(S):TriggerMode_RBV PP")
+}
+
+record(bi, "$(P)$(S):TriggerMode_RBV")
+{
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getTrig $(PORT)")
+ field(DESC, "Shutter trigger mode status")
+ field(ZNAM, "Internal")
+ field(ONAM, "External")
+}
+
+record(bo, "$(P)$(S):ExtTriggerOutMode")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setXTO $(PORT)")
+ field(DESC, "External trigger out mode")
+ field(ZNAM, "Shutter")
+ field(ONAM, "Controller")
+ field(FLNK, "$(P)$(S):ExtTriggerOutMode_RBV PP")
+}
+
+record(bi, "$(P)$(S):ExtTriggerOutMode_RBV")
+{
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getXTO $(PORT)")
+ field(DESC, "External trigger out mode")
+ field(ZNAM, "Shutter")
+ field(ONAM, "Controller")
+}
+
+record(bi, "$(P)$(S):ClosedStatus_RBV")
+{
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getClosed $(PORT)")
+ field(DESC, "Shutter Closed status")
+ field(ZNAM, "Open")
+ field(ONAM, "Closed")
+}
+
+record(bi, "$(P)$(S):InterlockStatus_RBV")
+{
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getInterlock $(PORT)")
+ field(DESC, "Shutter Closed status")
+ field(ZNAM, "Un-tripped")
+ field(ONAM, "Tripped")
+}
+
+###############################################################################
+# Multi-bit Binary control and readbacks
+###############################################################################
+
+record(mbbo, "$(P)$(S):Mode"){
+ field(DTYP, "Soft Channel")
+ field(ZRST, "Manual")
+ field(ONST, "Auto")
+ field(TWST, "Single")
+ field(THST, "Repeat")
+ field(FRST, "External Gate")
+}
+
+record(calcout, "$(P)$(S):ModeCalc"){
+ field(INPA, "$(P)$(S):Mode CP")
+ field(CALC, "A+1")
+ field(OUT, "$(P)$(S):ModeSet PP")
+}
+
+record(ao, "$(P)$(S):ModeSet") {
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setMode $(PORT)")
+ field(PREC, "0")
+ field(FLNK, "$(P)$(S):ModeSet_RBV PP")
+}
+
+record(ai, "$(P)$(S):ModeSet_RBV") {
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getMode $(PORT)")
+ field(PREC, "0")
+}
+
+record(calcout, "$(P)$(S):ModeRBVCalc"){
+ field(INPA, "$(P)$(S):ModeSet_RBV CP")
+ field(CALC, "A-1")
+ field(OUT, "$(P)$(S):Mode_RBV PP")
+}
+
+record(mbbi, "$(P)$(S):Mode_RBV"){
+ field(DTYP, "Soft Channel")
+ field(ZRST, "Manual")
+ field(ONST, "Auto")
+ field(TWST, "Single")
+ field(THST, "Repeat")
+ field(FRST, "External Gate")
+}
+
+###############################################################################
+# Integer control and readbacks
+###############################################################################
+
+record(ao, "$(P)$(S):Reps") {
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setRep $(PORT)")
+ field(PREC, "0")
+ field(DRVH, "99")
+ field(DRVL, "1")
+ field(FLNK, "$(P)$(S):Reps_RBV PP")
+}
+
+record(ai, "$(P)$(S):Reps_RBV") {
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getRep $(PORT)")
+ field(PREC, "0")
+}
+
+record(ao, "$(P)$(S):OpenTime") {
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setOpen $(PORT)")
+ field(PREC, "0")
+ field(DRVH, "999999")
+ field(DRVL, "1")
+ field(EGU, "ms")
+ field(FLNK, "$(P)$(S):OpenTime_RBV PP")
+}
+
+record(ai, "$(P)$(S):OpenTime_RBV") {
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getOpen $(PORT)")
+ field(PREC, "0")
+ field(EGU, "ms")
+}
+
+record(ao, "$(P)$(S):ShutTime") {
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto setShut $(PORT)")
+ field(PREC, "0")
+ field(DRVH, "999999")
+ field(DRVL, "1")
+ field(EGU, "ms")
+ field(FLNK, "$(P)$(S):ShutTime_RBV PP")
+}
+
+record(ai, "$(P)$(S):ShutTime_RBV") {
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getShut $(PORT)")
+ field(PREC, "0")
+ field(EGU, "ms")
+}
+
+###############################################################################
+# Stream Commands
+###############################################################################
+
+#save (save baud rate and output mode)
+record(bo, "$(P)$(S):Save")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto saveComm $(PORT)")
+ field(DESC, "Shutter trigger mode")
+}
+
+#savp (save settings [ex mode, open time, closed time] to EEPROM)
+record(bo, "$(P)$(S):SaveProg")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto saveProg $(PORT)")
+ field(DESC, "Shutter trigger mode")
+}
+
+#resp (load settings [ex mode, open time, closed time] from EEPROM)
+record(bo, "$(P)$(S):RestoreProg")
+{
+ field(DTYP, "stream")
+ field(OUT, "@Thorlabs_SC10.proto restoreProg $(PORT)")
+ field(DESC, "Shutter trigger mode")
+}
+
+###############################################################################
+# Readback updates
+###############################################################################
+
+# seq for updates of all RBVs
+record(seq, "$(P)$(S):UpdateRBVs") {
+ field(SCAN, "1 second")
+ field(LNK1, "$(P)$(S):Enable_RBV.PROC PP")
+ field(DLY2, "0.1")
+ field(LNK2, "$(P)$(S):TriggerMode_RBV.PROC PP")
+ field(DLY3, "0.1")
+ field(LNK3, "$(P)$(S):ExtTriggerOutMode_RBV.PROC PP")
+ field(DLY4, "0.1")
+ field(LNK4, "$(P)$(S):ClosedStatus_RBV.PROC PP")
+ field(DLY5, "0.1")
+ field(LNK5, "$(P)$(S):InterlockStatus_RBV.PROC PP")
+ field(DLY6, "0.1")
+ field(LNK6, "$(P)$(S):ModeSet_RBV.PROC PP")
+ field(DLY7, "0.1")
+ field(LNK7, "$(P)$(S):Reps_RBV.PROC PP")
+ field(DLY8, "0.1")
+ field(LNK8, "$(P)$(S):OpenTime_RBV.PROC PP")
+ field(DLY9, "0.1")
+ field(LNK9, "$(P)$(S):ShutTime_RBV.PROC PP")
+}
+
+###############################################################################
+# Other
+###############################################################################
+record(stringin, "$(P)$(S):ID"){
+ field(SCAN, "Passive")
+ field(DTYP, "stream")
+ field(INP, "@Thorlabs_SC10.proto getID $(PORT)")
+}
diff --git a/ipApp/Db/Thorlabs_SC10.proto b/ipApp/Db/Thorlabs_SC10.proto
new file mode 100644
index 00000000..9e1a8375
--- /dev/null
+++ b/ipApp/Db/Thorlabs_SC10.proto
@@ -0,0 +1,125 @@
+########################################################################
+# Protocol file for the Thorlabs SC10 shutter controller
+#
+# Author: M. Wyman (APS)
+# Date: July 2023
+########################################################################
+
+
+ExtraInput = Ignore;
+timeout = 2000;
+ReadTimeout = 500;
+
+#Terminator set to be \r for output and \r> for input in asyn options
+#Terminator = CR;
+
+
+#######################################
+getID {
+ out "id?";
+ in "id?\x0d%s"
+}
+
+#######################################
+
+setEnable{
+ out "ens";
+ in "ens";
+}
+
+getEnable{
+ out "ens?";
+ in "ens?\x0d%{0|1}";
+}
+
+setTrig{
+ out "trig=%{0|1}";
+ in "trig=%{0|1}";
+}
+
+getTrig{
+ out "trig?";
+ in "trig?\x0d%{0|1}";
+}
+
+setXTO{
+ out "xto=%{0|1}";
+ in "xto=%{0|1}";
+}
+
+getXTO{
+ out "xto?";
+ in "xto?\x0d%{0|1}";
+}
+
+getClosed{
+ out "closed?";
+ in "closed?\x0d%{0|1}";
+}
+
+getInterlock{
+ out "interlock?";
+ in "interlock?\x0d%{0|1}";
+}
+
+#######################################
+#multi-bit binary
+
+setMode{
+ out "mode=%i";
+ in "mode=%i";
+}
+
+getMode{
+ out "mode?";
+ in "mode?\x0d%i";
+}
+
+#######################################
+
+setRep{
+ out "rep=%i";
+ in "rep=%i";
+}
+
+getRep{
+ out "rep?";
+ in "rep?\x0d%i";
+}
+
+setOpen{
+ out "open=%i";
+ in "open=%i";
+}
+
+getOpen{
+ out "open?";
+ in "open?\x0d%i";
+}
+
+setShut{
+ out "shut=%i";
+ in "shut=%i";
+}
+
+getShut{
+ out "shut?";
+ in "shut?\x0d%i";
+}
+
+#######################################
+
+saveComm{
+ out "save";
+ in "save";
+}
+
+saveProg{
+ out "savp";
+ in "savp";
+}
+
+restoreProg{
+ out "resp";
+ in "resp";
+}
diff --git a/ipApp/Db/Thorlabs_SC10_settings.req b/ipApp/Db/Thorlabs_SC10_settings.req
new file mode 100644
index 00000000..aeeccbbc
--- /dev/null
+++ b/ipApp/Db/Thorlabs_SC10_settings.req
@@ -0,0 +1,8 @@
+$(P)(S):UpdateRBVs.SCAN
+$(P)$(S):ShutTime
+$(P)$(S):OpenTime
+$(P)$(S):Reps
+$(P)$(S):Mode
+$(P)$(S):ExtTriggerOutMode
+$(P)$(S):TriggerMode
+$(P)$(S):Enable
diff --git a/ipApp/Db/XIA_pfcu_filters.db b/ipApp/Db/XIA_pfcu_filters.db
index 6d17efe6..fd4a1ade 100644
--- a/ipApp/Db/XIA_pfcu_filters.db
+++ b/ipApp/Db/XIA_pfcu_filters.db
@@ -48,6 +48,38 @@ record(bi, "$(P)$(F):modeRBV") {
# Filter configuration PVs
########################################################################
+record(mbbo, "$(P)$(F):config"){
+ field(DTYP, "Soft Channel")
+ field(ZRST, "0000")
+ field(ONST, "0001")
+ field(TWST, "0010")
+ field(THST, "0011")
+ field(FRST, "0100")
+ field(FVST, "0101")
+ field(SXST, "0110")
+ field(SVST, "0111")
+ field(EIST, "1000")
+ field(NIST, "1001")
+ field(TEST, "1010")
+ field(ELST, "1011")
+ field(TVST, "1100")
+ field(TTST, "1101")
+ field(FTST, "1110")
+ field(FFST, "1111")
+}
+
+record(transform, "$(P)$(F):configTransform"){
+ field(INPA, "$(P)$(F):config CP")
+ field(CLCB, "(A>>3)%2")
+ field(OUTB, "$(P)$(F):filter1 PP")
+ field(CLCC, "(A>>2)%2")
+ field(OUTC, "$(P)$(F):filter2 PP")
+ field(CLCD, "(A>>1)%2")
+ field(OUTD, "$(P)$(F):filter3 PP")
+ field(CLCE, "A%2")
+ field(OUTE, "$(P)$(F):filter4 PP")
+}
+
record(calcout, "$(P)$(F):calcConfig")
{
field(INPA, "$(P)$(F):filter1 CP")
@@ -199,36 +231,40 @@ record(ao,"$(P)$(F):filter4_thick")
record(mbbo, "$(P)$(F):filter1_mat"){
field(VAL,"0")
field(ZRST,"Al")
- field(ONST,"Ti")
- field(TWST,"Glass")
- field(THST,"Other")
+ field(ONST,"Mo")
+ field(TWST,"Ti")
+ field(THST,"Glass")
+ field(FRST,"Other")
field(DESC,"material filter 1")
}
record(mbbo, "$(P)$(F):filter2_mat"){
field(VAL,"0")
field(ZRST,"Al")
- field(ONST,"Ti")
- field(TWST,"Glass")
- field(THST,"Other")
+ field(ONST,"Mo")
+ field(TWST,"Ti")
+ field(THST,"Glass")
+ field(FRST,"Other")
field(DESC,"material filter 2")
}
record(mbbo, "$(P)$(F):filter3_mat"){
field(VAL,"0")
field(ZRST,"Al")
- field(ONST,"Ti")
- field(TWST,"Glass")
- field(THST,"Other")
+ field(ONST,"Mo")
+ field(TWST,"Ti")
+ field(THST,"Glass")
+ field(FRST,"Other")
field(DESC,"material filter 3")
}
record(mbbo, "$(P)$(F):filter4_mat"){
field(VAL,"0")
field(ZRST,"Al")
- field(ONST,"Ti")
- field(TWST,"Glass")
- field(THST,"Other")
+ field(ONST,"Mo")
+ field(TWST,"Ti")
+ field(THST,"Glass")
+ field(FRST,"Other")
field(DESC,"material filter 4")
}
diff --git a/ipApp/Db/XIA_pfcu_filters.proto b/ipApp/Db/XIA_pfcu_filters.proto
index 96ee715d..a02e4590 100644
--- a/ipApp/Db/XIA_pfcu_filters.proto
+++ b/ipApp/Db/XIA_pfcu_filters.proto
@@ -40,7 +40,7 @@ setControl {
}
sysReport {
- out "\!PFCU\$1 S";
+ out "!PFCU\$1 S";
in "\%PFCU\$1 OK %100c";
}
diff --git a/ipApp/Db/uniblitz.proto b/ipApp/Db/uniblitz.proto
new file mode 100644
index 00000000..4e143f96
--- /dev/null
+++ b/ipApp/Db/uniblitz.proto
@@ -0,0 +1,38 @@
+# Protocol file for the Uniblitz shutter controllers
+# Developed and tested with the VDM1000
+
+############ SVN Repository information #############
+# $Date$
+# $Author$
+# $Revision$
+# $HeadURL$
+# $Id$
+#######################################################
+
+Terminator = LF;
+
+checkSync {
+ out "?";
+ in "%{K|J}";
+}
+
+setShutter {
+ out "%{A|@}";
+ @init { checkSync; }
+}
+
+setGate {
+ out "%{F|G}";
+}
+
+setAuxOut {
+ out "%{D|E}";
+}
+
+setTrigger {
+ out "B";
+}
+
+setReset {
+ out "C";
+}
diff --git a/ipApp/Db/uniblitz_d122.db b/ipApp/Db/uniblitz_d122.db
new file mode 100644
index 00000000..7d1eb7d4
--- /dev/null
+++ b/ipApp/Db/uniblitz_d122.db
@@ -0,0 +1,20 @@
+# Database for the Uniblitz shutter controllers
+# Developed and tested with the D-122
+
+
+
+record(bo, "$(P)$(S):Control")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setShutter $(PORT)")
+ field(DESC, "Uniblitz shutter control")
+ field(ZNAM, "Close")
+ field(ONAM, "Open")
+}
+
+record(bo, "$(P)$(S):Reset")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setReset $(PORT)")
+ field(DESC, "Uniblitz Reset")
+}
diff --git a/ipApp/Db/uniblitz_vcm-d1.db b/ipApp/Db/uniblitz_vcm-d1.db
new file mode 100644
index 00000000..29bd973e
--- /dev/null
+++ b/ipApp/Db/uniblitz_vcm-d1.db
@@ -0,0 +1,52 @@
+# Database for the Uniblitz shutter controllers
+# Developed and tested with the VCM-D1
+
+record(bi, "$(P)$(S):Status")
+{
+ field(DTYP, "stream")
+ field(INP, "@uniblitz.proto checkSync $(PORT)")
+ field(DESC, "Uniblitz sync status")
+ field(ZNAM, "Off")
+ field(ONAM, "On")
+}
+
+record(bo, "$(P)$(S):Control")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setShutter $(PORT)")
+ field(DESC, "Uniblitz shutter control")
+ field(ZNAM, "Close")
+ field(ONAM, "Open")
+}
+
+record(bo, "$(P)$(S):Gate")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setGate $(PORT)")
+ field(DESC, "Uniblitz gate control")
+ field(ZNAM, "Close")
+ field(ONAM, "Open")
+}
+
+record(bo, "$(P)$(S):AuxOut")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setAuxOut $(PORT)")
+ field(DESC, "Uniblitz Aux Out Enable")
+ field(ZNAM, "Disable")
+ field(ONAM, "Enable")
+}
+
+record(bo, "$(P)$(S):Trigger")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setTrigger $(PORT)")
+ field(DESC, "Uniblitz Trigger")
+}
+
+record(bo, "$(P)$(S):Reset")
+{
+ field(DTYP, "stream")
+ field(OUT, "@uniblitz.proto setReset $(PORT)")
+ field(DESC, "Uniblitz Reset")
+}
diff --git a/ipApp/op/ui/Thorlabs_SC10.ui b/ipApp/op/ui/Thorlabs_SC10.ui
new file mode 100644
index 00000000..126eeaf1
--- /dev/null
+++ b/ipApp/op/ui/Thorlabs_SC10.ui
@@ -0,0 +1,1328 @@
+
+
+ MainWindow
+
+
+
+ 0
+ 0
+ 721
+ 504
+
+
+
+
+
+QWidget#centralWidget {background: rgba(187, 187, 187, 255);}
+QPushButton::menu-indicator {image: url(none.png); width: 0}
+
+caTable {
+ font: 10pt;
+ background: cornsilk;
+ alternate-background-color: wheat;
+}
+
+caLineEdit {
+ border-radius: 1px;
+ background: lightyellow;
+ color: black;
+ }
+
+caTextEntry {
+ color: rgb(127, 0, 63);
+ background-color: cornsilk;
+ selection-color: #0a214c;
+ selection-background-color: wheat;
+ border: 1px groove black;
+ border-radius: 1px;
+ padding: 1px;
+}
+
+caTextEntry:focus {
+ padding: 0px;
+ border: 2px groove darkred;
+ border-radius: 1px;
+}
+
+QPushButton {
+ border-color: #00b;
+ border-radius: 2px;
+ padding: 3px;
+ border-width: 1px;
+
+ background: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1,
+ stop:0 rgba(224, 239, 255, 255),
+ stop:0.5 rgba(199, 215, 230, 255),
+ stop:1 rgba(184, 214, 236, 255));
+}
+QPushButton:hover {
+ background: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1,
+ stop:0 rgba(201, 226, 255, 255),
+ stop:0.5 rgba(177, 204, 230, 255),
+ stop:1 rgba(163, 205, 236, 255));
+}
+QPushButton:pressed {
+ background: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1,
+ stop:0 rgba(174, 219, 255, 255),
+ stop:0.5 rgba(165, 199, 230, 255),
+ stop:1 rgba(134, 188, 236, 255));
+}
+
+QPushButton:disabled {
+ background: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1,
+ stop:0 rgba(174, 219, 255, 255),
+ stop:0.5 rgba(165, 199, 230, 255),
+ stop:1 rgba(134, 188, 236, 255));
+}
+
+caChoice {
+ background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,
+ stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,
+ stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);
+}
+
+caChoice > QPushButton {
+ text-align: left;
+ padding: 1px;
+}
+
+/* when font specified, no font sizing is done any more, font: 10pt; is not bad. You could Enable this when you converted from .adl files
+caRelatedDisplay > QPushButton {
+font: 10pt;
+}
+
+caShellCommand > QPushButton {
+font: 10pt;
+}
+*/
+
+caSlider::groove:horizontal {
+border: 1px solid #bbb;
+background: lightgrey;
+height: 20px;
+border-radius: 4px;
+}
+
+caSlider::handle:horizontal {
+background: red;
+border: 1px solid #777;
+width: 13px;
+margin-top: -2px;
+margin-bottom: -2px;
+border-radius: 2px;
+}
+
+
+
+
+
+
+
+
+
+
+ 0
+ 0
+ 721
+ 26
+
+
+
+ 0
+
+
+
+ 0
+ 53
+ 132
+
+
+
+ caFrame::Filled
+
+
+
+ 5
+
+
+ 10
+
+
+ 2
+
+
+ 0
+
+
+ 2
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+
+ Verdana
+ 13
+ 75
+ true
+
+
+
+ Thorlabs SC10 Shutter Controller - $(P)$(S)
+
+
+ Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
+
+
+ ESimpleLabel::Height
+
+
+
+ 228
+ 228
+ 228
+
+
+
+
+ 160
+ 160
+ 164
+
+
+
+
+
+
+
+
+
+ 90
+ 40
+ 120
+ 28
+
+
+
+ Enable
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 40
+ 85
+ 171
+ 28
+
+
+
+ Trigger Mode
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 220
+ 85
+ 231
+ 31
+
+
+
+ $(P)$(S):TriggerMode
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caChoice::Static
+
+
+ caChoice::Column
+
+
+ 1
+
+
+
+
+
+ 9
+ 130
+ 201
+ 28
+
+
+
+ Ext Trigger Out Mode
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 220
+ 130
+ 231
+ 31
+
+
+
+ $(P)$(S):ExtTriggerOutMode
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caChoice::Static
+
+
+ caChoice::Column
+
+
+ 1
+
+
+
+
+
+ 220
+ 460
+ 341
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):ID
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 100
+ 460
+ 120
+ 28
+
+
+
+ Unit ID:
+
+
+ Qt::AlignCenter
+
+
+
+
+
+ 60
+ 340
+ 151
+ 28
+
+
+
+ RBV Update Rate
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 59
+ 380
+ 151
+ 28
+
+
+
+ Open/Closed?
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 60
+ 410
+ 151
+ 28
+
+
+
+ Interlocks?
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 59
+ 180
+ 151
+ 28
+
+
+
+ Shutter Mode
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+
+ 350
+ 180
+ 161
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):Mode_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 450
+ 40
+ 161
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):Enable_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 450
+ 85
+ 161
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):TriggerMode_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 450
+ 130
+ 161
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):ExtTriggerOutMode_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 220
+ 380
+ 161
+ 25
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):ClosedStatus_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 220
+ 410
+ 161
+ 25
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):InterlockStatus_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 590
+ 220
+ 120
+ 30
+
+
+
+ SAVE PROGRAM
+
+
+ $(P)$(S):SaveProg.PROC
+
+
+ SAVE PROGRAM
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ 1
+
+
+
+
+
+ 590
+ 250
+ 120
+ 30
+
+
+
+ RESTORE PROGRAM
+
+
+ $(P)$(S):RestoreProg.PROC
+
+
+ RESTORE PROGRAM
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ 1
+
+
+
+
+
+ 391
+ 220
+ 141
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):Reps_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 220
+ 220
+ 171
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ $(P)$(S):Reps
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::Channel
+
+
+ caLineEdit::Channel
+
+
+ 1.000000000000000
+
+
+ 0.000000000000000
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 40
+ 220
+ 171
+ 27
+
+
+
+ Repetitions
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 390
+ 260
+ 141
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):OpenTime_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 40
+ 260
+ 171
+ 27
+
+
+
+ Open Time (ms)
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 220
+ 260
+ 171
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ $(P)$(S):OpenTime
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::Channel
+
+
+ caLineEdit::Channel
+
+
+ 1.000000000000000
+
+
+ 0.000000000000000
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 391
+ 300
+ 141
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ Qt::AlignCenter
+
+
+ $(P)$(S):ShutTime_RBV
+
+
+
+ 10
+ 0
+ 184
+
+
+
+
+ 200
+ 200
+ 200
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 40
+ 300
+ 171
+ 27
+
+
+
+ Shut Time (ms)
+
+
+ Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
+
+
+
+
+
+ 220
+ 300
+ 171
+ 27
+
+
+
+
+ 0
+ 0
+
+
+
+ $(P)$(S):ShutTime
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ caLineEdit::Static
+
+
+ caLineEdit::Channel
+
+
+ caLineEdit::Channel
+
+
+ 1.000000000000000
+
+
+ 0.000000000000000
+
+
+ caLineEdit::WidthAndHeight
+
+
+ caLineEdit::decimal
+
+
+
+
+
+ 230
+ 40
+ 101
+ 31
+
+
+
+ caFrame::IfZero
+
+
+ A
+
+
+ $(P)$(S):Enable
+
+
+
+
+ 0
+ 0
+ 101
+ 31
+
+
+
+ $(P)$(S):Enable
+
+
+ Enable
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+ 115
+ 223
+ 255
+
+
+
+ 1
+
+
+
+
+
+
+ 340
+ 40
+ 101
+ 31
+
+
+
+ caFrame::IfNotZero
+
+
+ A
+
+
+ $(P)$(S):Enable
+
+
+
+
+ 0
+ 0
+ 101
+ 31
+
+
+
+ Disable
+
+
+ $(P)$(S):Enable
+
+
+ Enable
+
+
+
+ 228
+ 228
+ 30
+
+
+
+
+ 228
+ 30
+ 30
+
+
+
+ 0
+
+
+
+
+
+
+
+ caMenu
+ QComboBox
+
+
+
+ caChoice
+ QWidget
+
+
+
+ caTextEntry
+ caLineEdit
+
+
+
+ caMessageButton
+ QPushButton
+
+
+
+ caFrame
+ QFrame
+
+ 1
+
+
+ caLabel
+ QLabel
+
+
+
+ caLineEdit
+ QLineEdit
+
+
+
+
+
+
diff --git a/ipApp/op/ui/XIA_pfcu_filters_base.ui b/ipApp/op/ui/XIA_pfcu_filters_base.ui
index 091f84a0..1a998c0a 100644
--- a/ipApp/op/ui/XIA_pfcu_filters_base.ui
+++ b/ipApp/op/ui/XIA_pfcu_filters_base.ui
@@ -7,7 +7,7 @@
0
0
736
- 33
+ 36
@@ -22,7 +22,7 @@
31
-
+
5
@@ -195,29 +195,10 @@
-
-
-
-
- 0
- 0
-
-
-
- EPushButton::WidthAndHeight
-
+
$(P)$(F):filter$(N)
-
- In
-
-
-
- 0
- 0
- 0
-
-
115
@@ -225,50 +206,17 @@
255
-
- 1
-
- caMessageButton::Static
-
-
-
- -
-
-
-
- 0
- 0
-
+ caChoice::Static
-
- EPushButton::WidthAndHeight
+
+ caChoice::Column
-
- $(P)$(F):filter$(N)
-
-
- Out
+
+ 0
-
-
- 0
- 0
- 0
-
-
-
-
- 115
- 223
- 255
-
-
-
- 0
-
-
- caMessageButton::Static
+
+ 1
@@ -320,16 +268,16 @@
QComboBox
+
+ caChoice
+ QWidget
+
+
caTextEntry
caLineEdit
-
- caMessageButton
- QPushButton
-
-
caLabel
QLabel
diff --git a/ipApp/op/ui/XIA_pfcu_filters_less.ui b/ipApp/op/ui/XIA_pfcu_filters_less.ui
index ec5c96ff..129f1961 100644
--- a/ipApp/op/ui/XIA_pfcu_filters_less.ui
+++ b/ipApp/op/ui/XIA_pfcu_filters_less.ui
@@ -309,7 +309,7 @@
-