Package xal.smf.impl

Class WireHarp

All Implemented Interfaces:
Comparable, ElementType, DataListener

public class WireHarp extends ProfileDevice

Wire Harp Hardware

Represents a harp diagnostic device, in particular such a device installed at the SNS facility. The harp has fixed, physical (carbon) wires used to measure the profile of the particle beam. This class implements the device API.

NOTES:

· There is a pretty egregious kluge on the attribute DaqConfig.cntWires. The value is hard coded with the constant DaqConfig.CNT_WIRES since there is no way to dynamically acquire this value.

Ported from XAL on Jul 15, 2014.
· Jonathan M. Freed

Since:
Jan 9, 2013
Author:
Christopher K. Allen
  • Field Details

  • Constructor Details

    • WireHarp

      public WireHarp(String strId, ChannelFactory channelFactory)
      Primary Constructor
      Parameters:
      strId - unique identifier of this node
      channelFactory - factory for generating channels for this node
    • WireHarp

      public WireHarp(String strId)
      Creates a new instance of WireHarp.
      Parameters:
      strId -
      Since:
      Feb 13, 2013
  • Method Details

    • getType

      public String getType()
      Get the device type
      Specified by:
      getType in class AcceleratorNode
      Returns:
      The type identifier of this class
    • getSoftType

      public String getSoftType()
      Derived class may furnish a unique software type
      Overrides:
      getSoftType in class AcceleratorNode
      Returns:
      the "software type" or the driver version for the hardware.
    • runCommand

      public void runCommand(WireHarp.CMD cmd) throws PutException, InterruptedException
      Issue a wire scanner command with no arguments.
      Parameters:
      cmd - wire scanner command
      Throws:
      ConnectionException - unable to find channel
      PutException - unable to set channel value
      InterruptedException - command buffer reset thread interrupted
    • getCommandResult

      public int[] getCommandResult() throws GetException
      Returns the command result code(s). These are integer valued codes for the result of a previous issued device command. See the wire scanner documentation to interpret the particular resultant code.
      Returns:
      command result array of integer codes for a command result.
      Throws:
      ConnectionException - Unable to connect to result readback channel
      GetException - Unable to read result from readback channel