tomoScan_19BM.template

# Database for EPICS PVS for tomography data collection software at APS 19-BM
# It contains the PVs that are required by the tomoscan_19bm derived class,
# as well as additional PVs used for metadata about the scan that are stored
# both in the configuration files written by tomoscan, and in the
# files written by areaDetector file plugin.
#
# This is modelled on tomoScan_7BM.template rather than tomoScan_32IDC.template,
# because 19-BM has no mctoptics server: the optics metadata records
# (ScintillatorType, ImagePixelSize and the rest) are defined locally here
# rather than read from an optics server.  The 7-BM gain-field records
# (HDF5GainsLocation, NumGainFields) are not carried over -- 19-BM does not
# collect gain fields.  Note that FrameType is NOT one of those: 7-BM
# redefines it to add gain-field states, but the record itself comes from the
# base tomoScan.template and is present here.  It is live and in use -- the
# detector_status.adl screen reads $(P)$(R)FrameType.
#
# The four fast-shutter records are not carried over either.  19-BM has only the
# front-end shutter, which is handled by OPEN_SHUTTER / CLOSE_SHUTTER in
# tomoScan.template.  This is the same edit that produced
# tomoScan_32IDC.template from tomoScan_2BM.template.
#
# Do not add them back pointing at some other PV.  The "if not ... is None"
# guards in the base class are dead code -- read_pv_file() always constructs a
# PV object -- so a macro bound to a dead PV is not skipped; it writes into a
# disconnected channel on every dark-field sequence.

####################
# Energy information
####################
#
# No Filters record.  At 2-BM that is a free-text string in which the operator
# records filters added by hand; 19-BM adds no filters by hand -- the F3-30
# unit's two banks are motorised (19bmSoft:m5, m6) and their positions are
# readable from the motor records -- so there is nothing for an operator to
# type and the record would only ever hold a stale value.

record(ao, "$(P)$(R)Energy")
{
    field(SCAN, "Passive")
    field(DTYP, "Soft Channel")
    field(PREC, 2)
    field(PINI, "YES")
}

record(mbbo, "$(P)$(R)EnergyMode")
{
   field(ZRVL, "0")
   field(ZRST, "Mono")
   field(ONVL, "1")
   field(ONST, "Pink")
   field(TWVL, "2")
   field(TWST, "White")
   field(PINI, "YES")
}

#########################
# Beam status information
#########################

record(stringout, "$(P)$(R)BeamReadyPVName")
{
   field(VAL,  "$(BEAM_READY)")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)BeamReadyValue")
{
   field(VAL,  "$(READY_VALUE)")
   field(PINI, "YES")
}

record(bo, "$(P)$(R)Testing")
{
   field(ZNAM, "No")
   field(ONAM, "Yes")
   field(PINI, "YES")
}

################
# Shutter status
################

record(stringout, "$(P)$(R)ShutterStatusPVName")
{
   field(VAL,  "$(SHUTTER_STATUS)")
   field(PINI, "YES")
}

####################
# Optics information
####################

record(stringout, "$(P)$(R)ScintillatorType")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(ao, "$(P)$(R)ScintillatorThickness")
{
   field(PREC,  "0")
   field(PINI, "YES")
}

record(ao, "$(P)$(R)ImagePixelSize")
{
   field(PREC, "2")
   field(EGU,  "microns")
   field(PINI, "YES")
}

record(ao, "$(P)$(R)DetectorPixelSize")
{
   field(PREC, "2")
   field(EGU,  "microns")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)CameraObjective")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(ao, "$(P)$(R)CameraTubeLength")
{
   field(PREC, "0")
   field(EGU,  "mm")
   field(PINI, "YES")
}

record(ao, "$(P)$(R)CameraDistance")
{
   field(PREC, "0")
   field(EGU,  "mm")
   field(VAL,  "0")
   field(PINI, "YES")
}

####################
# Sample information
####################

record(stringout, "$(P)$(R)SampleName")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)SampleDescription1")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)SampleDescription2")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)SampleDescription3")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

##################
# User information
##################

record(stringout, "$(P)$(R)UserName")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(waveform, "$(P)$(R)UserInstitution")
{
    field(SCAN, "Passive")
    field(DTYP, "Soft Channel")
    field(NELM, "256")
    field(FTVL, "CHAR")
    field(PINI, "YES")
}

record(stringout, "$(P)$(R)UserBadge")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)UserEmail")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)ProposalNumber")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(waveform, "$(P)$(R)ProposalTitle")
{
    field(SCAN, "Passive")
    field(DTYP, "Soft Channel")
    field(NELM, "256")
    field(FTVL, "CHAR")
    field(PINI, "YES")
}

record(stringout, "$(P)$(R)ESAFNumber")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)UserInfoUpdate")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

#############################
# Data management information
#############################

record(stringout, "$(P)$(R)DetectorTopDir")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)UserLastName")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)ExperimentYearMonth")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(stringout, "$(P)$(R)RemoteAnalysisDir")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}

record(bo, "$(P)$(R)CopyToAnalysisDir")
{
   field(ZNAM, "No")
   field(ONAM, "Yes")
   field(PINI, "YES")
}

#########################
# Camera External Trigger
#########################

# GenICam TriggerSource the PSO output is wired to.  The Vieworks VP-61MX on
# the Euresys grabber offers Software, UserOutput0, LinkTrigger0, Timer0Active
# and Line0; the PSO pulse arrives on Line0.
record(stringout, "$(P)$(R)ExternalTriggerSource")
{
    field(VAL, "$(LINE)")
    field(PINI, "YES")
}

############
# Scan UUID
############

record(stringout, "$(P)$(R)ScanUUID")
{
   field(VAL,  "Unknown")
   field(PINI, "YES")
}