From 14d209e96e00f492a58c58692a379d2d4c3bc2db Mon Sep 17 00:00:00 2001
From: Andreas Persson <andreas.persson@ess.eu>
Date: Mon, 21 Oct 2024 09:33:43 +0200
Subject: [PATCH] EVR timestamps for interlock status records

---
 nblmdaq/Db/nBlmBoard.template             | 1 +
 nblmdaq/Db/nBlmChannel_interlock.template | 3 +++
 nblmdaq/Db/nBlmChannel_periodic.template  | 1 +
 3 files changed, 5 insertions(+)

diff --git a/nblmdaq/Db/nBlmBoard.template b/nblmdaq/Db/nBlmBoard.template
index bc3c4b3..3ae3173 100644
--- a/nblmdaq/Db/nBlmBoard.template
+++ b/nblmdaq/Db/nBlmBoard.template
@@ -99,6 +99,7 @@ record(bi, "$(P)$(R)FbisPermit") {
     field(OSV,  "NO_ALARM")
     field(SCAN, "I/O Intr")
     field(INP,  "@asyn($(PORT), $(ADDR=0))FbisPermitBoard")
+    field(TSE,  "-2")
 }
 
 record(bo, "$(P)$(R)DodStart") {
diff --git a/nblmdaq/Db/nBlmChannel_interlock.template b/nblmdaq/Db/nBlmChannel_interlock.template
index 7b000d2..1a7d91e 100644
--- a/nblmdaq/Db/nBlmChannel_interlock.template
+++ b/nblmdaq/Db/nBlmChannel_interlock.template
@@ -57,6 +57,7 @@ record(bi, "$(P)$(R)$(CHANNEL_ID)$(ILOCK_ID)Sticky") {
     field(ZNAM, "OFF")
     field(ONAM, "ON")
     field(INP,  "@asynMask($(PORT), $(ADDR), $(MASK))IlockSticky")
+    field(TSE,  "-2")
 }
 
 record(bi, "$(P)$(R)$(CHANNEL_ID)$(ILOCK_ID)First") {
@@ -66,6 +67,7 @@ record(bi, "$(P)$(R)$(CHANNEL_ID)$(ILOCK_ID)First") {
     field(ZNAM, "OFF")
     field(ONAM, "ON")
     field(INP,  "@asynMask($(PORT), $(ADDR), $(MASK))IlockFirst")
+    field(TSE,  "-2")
 }
 
 record(bi, "$(P)$(R)$(CHANNEL_ID)$(ILOCK_ID)Live") {
@@ -75,4 +77,5 @@ record(bi, "$(P)$(R)$(CHANNEL_ID)$(ILOCK_ID)Live") {
     field(ZNAM, "OFF")
     field(ONAM, "ON")
     field(INP,  "@asynMask($(PORT), $(ADDR), $(MASK))IlockLive")
+    field(TSE,  "-2")
 }
diff --git a/nblmdaq/Db/nBlmChannel_periodic.template b/nblmdaq/Db/nBlmChannel_periodic.template
index f52d8db..145e3cd 100644
--- a/nblmdaq/Db/nBlmChannel_periodic.template
+++ b/nblmdaq/Db/nBlmChannel_periodic.template
@@ -7,6 +7,7 @@ record(bi, "$(P)$(R)$(CHANNEL_ID)FbisPermit") {
     field(OSV,  "NO_ALARM")
     field(SCAN, "I/O Intr")
     field(INP,  "@asyn($(PORT), $(ADDR=0))FbisPermitChannel")
+    field(TSE,  "-2")
 }
 
 # Detector-specific Data (INFO = 1)
-- 
GitLab