#! Generated by VisualDCT v2.5
#! DBDSTART
#! DBDEND


#
# Wire Scanner Database Entries for WIRE:$(area):$(location)
#
#
# Start or Stop Scanning WIRE:$(area):$(location)
#
record(bo, "WIRE:$(area):$(location):STARTSCAN") {
  field(DESC, "Start Wire Scan with $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "Scanning")
  field(ZNAM, "Scan Stopped")
}

#
# Normally scanning moves from inner position to outer
# position, against the force of the vacuum.  If this
# PV is set to true, then WIRE:$(area):$(location)
# will scan from the outer to inner position, moving
# with the force of the vacuum.  The scanner is expected
# to provide best results when moving against the force
# of the vacuum.
#
record(bo, "WIRE:$(area):$(location):SCANTOCENTER") {
  field(DESC, "$(mad) will scan inwards")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "Scan to Center")
  field(ZNAM, "Scan from Center")
  info(autosaveFields, "VAL")
}

#
# Angle of WIRE:$(area):$(location) from beam's point of view
#
record(ao, "WIRE:$(area):$(location):INSTALLANGLE") {
  field(DESC, "Orientation of $(mad)")
  field(ASG, "WIREADMIN")
  field(EGU, "degrees")
  field(VAL, "$(orient)")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# Repeatability of WIRE:$(area):$(location) when doing a wire scan.
# If the motion returns to the original LVDT-measured position, within
# POSNTHRESH microns, the scan is considered successful.  If not, then
# RETRIES number of scans (in total) will be attempted.
#
record(ao, "WIRE:$(area):$(location):POSNTHRESH") {
  field(DESC, "$(mad) Position Deadband")
  field(ASG, "WIREUSER")
  field(EGU, "microns")
  field(VAL, "1000")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# Calculated time for wire scan; actual time that wire is spent moving.
#
record(ao, "WIRE:$(area):$(location):SCANTIME") {
  field(DESC, "$(mad) Calc. Scan Time")
  field(ASG, "WIREUSER")
  field(EGU, "seconds")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
}

#
# The most recent scan WIRE:$(area):$(location)
# was considered to have successfully moved.
#
record(mbbo, "WIRE:$(area):$(location):HADSUCCESS") {
  field(DESC, "$(mad) Scan Successful")
  field(ASG, "$WIREUSER")
  field(OMSL, "supervisory")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(DTYP, "Raw Soft Channel")
  field(NOBT, "32")
  field(ZRST, "No Scan Attempt")
  field(ZRVL, "0")
  field(ONST, "Scan Successful")
  field(ONVL, "1")
  field(TWST, "Scan Failed")
  field(TWVL, "2")
  field(PINI, "YES")
}

#
# The total number of scans to be done by WIRE:$(area):$(location)
# for a given scan request; if the scanner motion does not return
# to POSNTHRESH microns of where it started, then a retry is made.
#
record(ao, "WIRE:$(area):$(location):RETRIES") {
  field(DESC, "$(mad) Retries to Do")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The current retry attempt of WIRE:$(area):$(location) to
# perform a scan.  Up to RETRIES attempts will be made, and this
# value indicates which attempt is currently underway.
#
record(ao, "WIRE:$(area):$(location):CURRENTRETRY") {
  field(DESC, "$(mad) Current Retry Count")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
}

#
# Does WIRE:$(area):$(location) Have a Working X Wire?
#
record(bo, "WIRE:$(area):$(location):HASXWIRE") {
  field(DESC, "Is X Wire Avail. on $(mad)")
  field(ASG, "WIREADMIN")
  field(VAL, "1")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "X Wire is Usable")
  field(ZNAM, "X Wire NOT Usable")
  info(autosaveFields, "VAL")
}

#
# Will the X Wire from WIRE:$(area):$(location) be Used?
#
record(bo, "WIRE:$(area):$(location):USEXWIRE") {
  field(DESC, "Is X Wire Used on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "1")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "X Wire Selected")
  field(ZNAM, "X Wire NOT Selected")
  info(autosaveFields, "VAL")
}

#
# Distance of WIRE:$(area):$(location) X Wire from beam centerline,
# when motor is at the 0 position.  The U Wire intersecting with the
# beam centerline is defined as 0.
#
record(ao, "WIRE:$(area):$(location):XWIREOFFSET") {
  field(DESC, "Offset of $(mad) X Wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "$(xoffs)")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The location at which the X Wire can be positioned to
# start a scan in pull-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):XWIREOUTER") {
  field(DESC, "Outer X on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(xout)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

#
# The location at which the X Wire can be positioned to
# start a scan in push-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):XWIREINNER") {
  field(DESC, "Inner X on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(xin)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

#
# Does WIRE:$(area):$(location) Have a Working Y Wire?
#
record(bo, "WIRE:$(area):$(location):HASYWIRE") {
  field(DESC, "Is Y Wire Avail. on $(mad)")
  field(ASG, "WIREADMIN")
  field(VAL, "1")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "Y Wire is Usable")
  field(ZNAM, "Y Wire NOT Usable")
  info(autosaveFields, "VAL")
}

#
# Will the Y Wire from WIRE:$(area):$(location) be Used?
#
record(bo, "WIRE:$(area):$(location):USEYWIRE") {
  field(DESC, "Is Y Wire Used on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "Y Wire Selected")
  field(ZNAM, "Y Wire NOT Selected")
  info(autosaveFields, "VAL")
}

#
# Distance of WIRE:$(area):$(location) Y Wire from beam centerline,
# when motor is at the 0 position.  The U Wire intersecting with the
# beam centerline is defined as 0.
#
record(ao, "WIRE:$(area):$(location):YWIREOFFSET") {
  field(DESC, "Offset of $(mad) Y Wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "$(yoffs)")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The location at which the Y Wire can be positioned to
# start a scan in pull-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):YWIREOUTER") {
  field(DESC, "Outer Y on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(yout)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

#
# The location at which the Y Wire can be positioned to
# start a scan in push-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):YWIREINNER") {
  field(DESC, "Inner Y on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(yin)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

# Does WIRE:$(area):$(location) Have a Working U (diagonal) Wire?
#
record(bo, "WIRE:$(area):$(location):HASUWIRE") {
  field(DESC, "Is U Wire Avail. on $(mad)")
  field(ASG, "WIREADMIN")
  field(VAL, "1")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "U Wire is Usable")
  field(ZNAM, "U Wire NOT Usable")
  info(autosaveFields, "VAL")
}

#
# Will the U Wire from WIRE:$(area):$(location) be Used?
#
record(bo, "WIRE:$(area):$(location):USEUWIRE") {
  field(DESC, "Is U Wire Used on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(ONAM, "U Wire Selected")
  field(ZNAM, "U Wire NOT Selected")
  info(autosaveFields, "VAL")
}

#
# Distance of WIRE:$(area):$(location) U Wire from beam centerline,
# when motor is at the 0 position.  The U Wire intersecting with the
# beam centerline is defined as 0.
#
record(ao, "WIRE:$(area):$(location):UWIREOFFSET") {
  field(DESC, "Offset of $(mad) U Wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The location at which the U Wire can be positioned to
# start a scan in pull-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):UWIREOUTER") {
  field(DESC, "Outer U on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(uout)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

#
# The location at which the U Wire can be positioned to
# start a scan in push-through-beam mode on WIRE:$(area):$(location)
#
record(longout, "WIRE:$(area):$(location):UWIREINNER") {
  field(DESC, "Inner U on $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "$(uin)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  field(DRVH, "46000")
  field(DRVL, "100")
  field(HOPR, "46000")
  field(LOPR, "100")
  info(autosaveFields, "VAL")
}

#
# The position at which the current scan will start, set to
# the value of :XWIREOUTER, :YWIREOUTER or UWIREOUTER if in
# pull-through-beam mode, or set to :XWIREINNER, :YWIREINNER
# or UWIREINNER if in push-through-beam mode, for WIRE:$(area):$(location)
#
record(ao, "WIRE:$(area):$(location):SCANPOSSTART") {
  field(DESC, "$(mad) Wire Start Pos")
  field(ASG, "WIREUSER")
  field(VAL, "$(xin)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The position at which the current scan will stop, set to
# the value of :XWIREOUTER, :YWIREOUTER or UWIREOUTER if in
# push-through-beam mode, or set to :XWIREINNER, :YWIREINNER
# or UWIREINNER if in pull-through-beam mode, for WIRE:$(area):$(location)
#
record(ao, "WIRE:$(area):$(location):SCANPOSSTOP") {
  field(DESC, "$(mad) Stop Position")
  field(ASG, "WIREUSER")
  field(VAL, "$(xout)")
  field(EGU, "microns")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The number of beam pulses which WIRE:$(area):$(location)
# will intercept as it moves across the total range of travel.
# This is typically selected by the user.
#
record(ao, "WIRE:$(area):$(location):SCANPULSES") {
  field(DESC, "Pulses needed by $(mad)")
  field(ASG, "WIREUSER")
  field(VAL, "100")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# The time to delay between motion stop and position readout
#
record(ao, "WIRE:$(area):$(location):SCANDELAY") {
  field(DESC, "$(mad) Position Delay Time")
  field(ASG, "WIREUSER")
  field(VAL, "1.5")
  field(EGU, "seconds")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

#
# An indication of progress in terms of percent
# completion of WIRE:$(area):$(location)
#
record(ao, "WIRE:$(area):$(location):SCANPROGRESS") {
  field(DESC, "Progress $(mad) WireScan")
  field(ASG, "WIREUSER")
  field(VAL, "0")
  field(EGU, "percent")
  field(HOPR, "100")
  field(LOPR, "0")
  field(PREC, "0")
  field(SCAN, "Passive")
  field(PINI, "YES")
}

#
# A textual indication of the status of WIRE:$(area):$(location)
#
record(stringout, "WIRE:$(area):$(location):SCANTEXT") {
  field(DESC, "$(mad) Wire Scan Status")
  field(ASG, "WIREUSER")
  field(VAL, "READY to START Wire Scan")
  field(SCAN, "Passive")
  field(PINI, "YES")
}

#! Further lines contain data used by VisualDCT
#! View(-194,-11,0.7)
#! Record("WIRE:$(area):$(location):STARTSCAN",20,23,0,0,"WIRE:$(area):$(location):STARTSCAN")
#! Record("WIRE:$(area):$(location):SCANTOCENTER",260,23,0,0,"WIRE:$(area):$(location):SCANTOCENTER")
#! Record("WIRE:$(area):$(location):INSTALLANGLE",500,18,0,0,"WIRE:$(area):$(location):INSTALLANGLE")
#! Record("WIRE:$(area):$(location):POSNTHRESH",740,18,0,0,"WIRE:$(area):$(location):POSNTHRESH")
#! Record("WIRE:$(area):$(location):SCANTIME",980,12,0,0,"WIRE:$(area):$(location):SCANTIME")
#! Record("WIRE:$(area):$(location):HADSUCCESS",1220,22,0,0,"WIRE:$(area):$(location):HADSUCCESS")
#! Record("WIRE:$(area):$(location):RETRIES",1460,12,0,0,"WIRE:$(area):$(location):RETRIES")
#! Record("WIRE:$(area):$(location):CURRENTRETRY",1700,12,0,0,"WIRE:$(area):$(location):CURRENTRETRY")
#! Record("WIRE:$(area):$(location):HASXWIRE",1940,23,0,0,"WIRE:$(area):$(location):HASXWIRE")
#! Record("WIRE:$(area):$(location):USEXWIRE",2180,23,0,0,"WIRE:$(area):$(location):USEXWIRE")
#! Record("WIRE:$(area):$(location):XWIREOFFSET",2420,18,0,0,"WIRE:$(area):$(location):XWIREOFFSET")
#! Record("WIRE:$(area):$(location):XWIREOUTER",20,19,0,0,"WIRE:$(area):$(location):XWIREOUTER")
#! Record("WIRE:$(area):$(location):XWIREINNER",260,19,0,0,"WIRE:$(area):$(location):XWIREINNER")
#! Record("WIRE:$(area):$(location):HASYWIRE",3140,23,0,0,"WIRE:$(area):$(location):HASYWIRE")
#! Record("WIRE:$(area):$(location):USEYWIRE",3380,23,0,0,"WIRE:$(area):$(location):USEYWIRE")
#! Record("WIRE:$(area):$(location):YWIREOFFSET",3620,18,0,0,"WIRE:$(area):$(location):YWIREOFFSET")
#! Record("WIRE:$(area):$(location):YWIREOUTER",3860,19,0,0,"WIRE:$(area):$(location):YWIREOUTER")
#! Record("WIRE:$(area):$(location):YWIREINNER",4100,19,0,0,"WIRE:$(area):$(location):YWIREINNER")
#! Record("WIRE:$(area):$(location):HASUWIRE",4340,23,0,0,"WIRE:$(area):$(location):HASUWIRE")
#! Record("WIRE:$(area):$(location):USEUWIRE",4580,23,0,0,"WIRE:$(area):$(location):USEUWIRE")
#! Record("WIRE:$(area):$(location):UWIREOFFSET",20,378,0,0,"WIRE:$(area):$(location):UWIREOFFSET")
#! Record("WIRE:$(area):$(location):UWIREOUTER",260,319,0,0,"WIRE:$(area):$(location):UWIREOUTER")
#! Record("WIRE:$(area):$(location):UWIREINNER",500,319,0,0,"WIRE:$(area):$(location):UWIREINNER")
#! Record("WIRE:$(area):$(location):SCANPOSSTART",740,378,0,0,"WIRE:$(area):$(location):SCANPOSSTART")
#! Record("WIRE:$(area):$(location):SCANPOSSTOP",980,378,0,0,"WIRE:$(area):$(location):SCANPOSSTOP")
#! Record("WIRE:$(area):$(location):SCANPULSES",1220,372,0,0,"WIRE:$(area):$(location):SCANPULSES")
#! Record("WIRE:$(area):$(location):SCANDELAY",1460,378,0,0,"WIRE:$(area):$(location):SCANDELAY")
#! Record("WIRE:$(area):$(location):SCANPROGRESS",1700,373,0,0,"WIRE:$(area):$(location):SCANPROGRESS")
#! Record("WIRE:$(area):$(location):SCANTEXT",1940,372,0,0,"WIRE:$(area):$(location):SCANTEXT")
#
# Angle of WIRE:$(area):$(location) from beam's point of view
#
record(ao, "WIRE:$(area):$(location):XWIRESIZE") {
  field(DESC, "Diam. of $(mad) x wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "40")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

record(ao, "WIRE:$(area):$(location):YWIRESIZE") {
  field(DESC, "Diam. of $(mad) y wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "40")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

record(ao, "WIRE:$(area):$(location):UWIRESIZE") {
  field(DESC, "Diam. of $(mad) u wire")
  field(ASG, "WIREADMIN")
  field(EGU, "microns")
  field(VAL, "40")
  field(SCAN, "Passive")
  field(PINI, "YES")
  info(autosaveFields, "VAL")
}

