Kind of working, but time based count doesn't work from nicos
All checks were successful
Example Action / Lint (push) Successful in 2s
Example Action / BuildAndTest (push) Successful in 41s

This commit is contained in:
2026-01-22 09:43:25 +01:00
parent 75b63dd831
commit 5ec3d905fe

View File

@@ -3,6 +3,19 @@
# This is created to be able reuse the SinqDAQ interface # This is created to be able reuse the SinqDAQ interface
# in Nicos, to avoid having more code to maintain there. # in Nicos, to avoid having more code to maintain there.
# #
# Commands that has no actual relevant value that needs to be written to them:
# * Pause
# * Continue
# * Stop
# * Full reset
# * Reset elapsed time
# * Reset the counter/monitor value
# Are all implemented as seq records. Due to how the existing
# interface worked, they were being written 1 from nicos.
# It just so turns out that seq record's VAL field triggers processing,
# but a calcout records VAL field doesn't. seq record was the only option
# to emulate these features with only 1 record per command.
#
# This requires following macros to specified: # This requires following macros to specified:
# INSTR: Instrument prefix, e.g. "SQAMOR:" # INSTR: Instrument prefix, e.g. "SQAMOR:"
# NAME: Name of the DAQ, e.g. "PROTONDAQ" # NAME: Name of the DAQ, e.g. "PROTONDAQ"
@@ -86,40 +99,36 @@ record(longout, "$(INSTR)$(NAME):PRESET-TIME-TRIG")
field(FLNK, "$(INSTR)$(NAME):COUNT-TYPE") field(FLNK, "$(INSTR)$(NAME):COUNT-TYPE")
} }
record(longout, "$(INSTR)$(NAME):PAUSE") record(seq, "$(INSTR)$(NAME):PAUSE")
{ {
field(DESC, "Pause the current count") field(DESC, "Pause the current count")
field(VAL, 3) field(SELM, "All")
field(DRVL, 3) field(DO0, 3)
field(DRVH, 3) field(LNK0, "$(INSTR)$(NAME):COMMAND-TRIG PP")
field(OUT, "$(INSTR)$(NAME):COMMAND-TRIG PP")
} }
record(longout, "$(INSTR)$(NAME):CONTINUE") record(seq, "$(INSTR)$(NAME):CONTINUE")
{ {
field(DESC, "Continue with a count that was paused") field(DESC, "Continue with a count that was paused")
field(VAL, 4) field(SELM, "All")
field(DRVL, 4) field(DO0, 4)
field(DRVH, 4) field(LNK0, "$(INSTR)$(NAME):COMMAND-TRIG PP")
field(OUT, "$(INSTR)$(NAME):COMMAND-TRIG PP")
} }
record(longout, "$(INSTR)$(NAME):STOP") record(seq, "$(INSTR)$(NAME):STOP")
{ {
field(DESC, "Stop the current counting operation") field(DESC, "Stop the current counting operation")
field(VAL, 5) field(SELM, "All")
field(DRVL, 5) field(DO0, 5)
field(DRVH, 5) field(LNK0, "$(INSTR)$(NAME):COMMAND-TRIG PP")
field(OUT, "$(INSTR)$(NAME):COMMAND-TRIG PP")
} }
record(longout, "$(INSTR)$(NAME):FULL-RESET") record(seq, "$(INSTR)$(NAME):FULL-RESET")
{ {
field(DESC, "Perform full reset") field(DESC, "Perform full reset")
field(VAL, 6) field(SELM, "All")
field(DRVL, 6) field(DO0, 6)
field(DRVH, 6) field(LNK0, "$(INSTR)$(NAME):COMMAND-TRIG PP")
field(OUT, "$(INSTR)$(NAME):COMMAND-TRIG PP")
} }
# Emulate Reset elapsed time # Emulate Reset elapsed time
@@ -190,22 +199,9 @@ record(ai,"$(INSTR)$(NAME):ELAPSED-TIME")
{ {
field(DESC, "DAQ Measured Time") field(DESC, "DAQ Measured Time")
field(EGU, "sec") field(EGU, "sec")
# We need to process ETS to signal to client
# field(FLNK, "$(INSTR)$(NAME):ETO")
} }
# Trigger a change in status as value returned to 0
#record(seq, "$(INSTR)$(NAME):ETO")
#{
# field(DESC, "Trigger Returned to 0 Status")
# field(LNK0, "$(INSTR)$(NAME):ETS PP")
# field(DO0, 0)
# field(SELM, "Specified")
# field(SELL, "$(INSTR)$(NAME):ELAPSED-TIME.VAL")
#}
# Current Status of elapsed time # Current Status of elapsed time
# This is only to satify the interface.
record(bi, "$(INSTR)$(NAME):ETS") record(bi, "$(INSTR)$(NAME):ETS")
{ {
field(DESC, "Channel Status") field(DESC, "Channel Status")