Package gda.device

Interface XmapDetector

All Superinterfaces:
Configurable, Detector, Device, Findable, gda.observable.IObservable, Scannable
All Known Subinterfaces:
HardwareTriggeredNexusXmap
All Known Implementing Classes:
CallableXmap, DummyHardwareTriggeredNexusXmap, HardwareTriggeredNexusXmapImpl, NexusXmap, Xmap, XmapDetectorFromEpicsMca, XmapwithSlaveMode

public interface XmapDetector extends Detector
Interface to control the Vortex XMAP detector. This detector has a collection of MCAs which can all be triggered at the same time.
  • Method Details

    • clearAndStart

      void clearAndStart() throws DeviceException
      Clears all MCAs and starts data collection
      Throws:
      DeviceException
    • clear

      void clear() throws DeviceException
      Clear all MCA's
      Throws:
      DeviceException
    • start

      void start() throws DeviceException
      Start data acquisition in all MCA's
      Throws:
      DeviceException
    • stop

      void stop() throws DeviceException
      Stop data acquisition in all MCA's
      Specified by:
      stop in interface Scannable
      Throws:
      DeviceException
    • setNumberOfBins

      void setNumberOfBins(int numberOfBins) throws DeviceException
      Sets maximum numbers of bins/channels to use for spectrum acquisition in each MCA
      Parameters:
      numberOfBins -
      Throws:
      DeviceException
    • getNumberOfBins

      int getNumberOfBins() throws DeviceException
      Returns current number of Bins/channels for spectrum acquisition in each MCA
      Returns:
      numberOfBins
      Throws:
      DeviceException
    • setStatusRate

      void setStatusRate(double statusRate) throws DeviceException
      Sets the rate at which status is read in the Epics interface
      Parameters:
      statusRate -
      Throws:
      DeviceException
    • getStatusRate

      double getStatusRate() throws DeviceException
      Returns the current set rate at which status is read in the Epics interface
      Returns:
      status rate
      Throws:
      DeviceException
    • setReadRate

      void setReadRate(double readRate) throws DeviceException
      Sets the rate at which data is read in the Epics interface
      Parameters:
      readRate -
      Throws:
      DeviceException
    • getReadRate

      double getReadRate() throws DeviceException
      Returns the current rate at which data is read in the Epics interface
      Returns:
      readRate
      Throws:
      DeviceException
    • getRealTime

      double getRealTime() throws DeviceException
      Returns the elapsed real time after a read status operation
      Returns:
      real time
      Throws:
      DeviceException
    • getStatus

      int getStatus() throws DeviceException
      Returns the status of the detector
      Specified by:
      getStatus in interface Detector
      Returns:
      Detector.IDLE/BUSY
      Throws:
      DeviceException
    • setAcquisitionTime

      void setAcquisitionTime(double time) throws DeviceException
      Tells the detector for how many seconds to acquire data
      Parameters:
      time -
      Throws:
      DeviceException
    • getAcquisitionTime

      double getAcquisitionTime() throws DeviceException
      Returns the time for which the detector is set to acquire data
      Returns:
      time
      Throws:
      DeviceException
    • getData

      int[] getData(int mcaNumber) throws DeviceException
      Returns the data array of the specified MCA
      Parameters:
      mcaNumber -
      Returns:
      data array
      Throws:
      DeviceException
    • getData

      int[][] getData() throws DeviceException
      Returns the data array of all the MCAs
      Returns:
      array of data arrays
      Throws:
      DeviceException
    • getROIsSum

      double[] getROIsSum() throws DeviceException
      Returns the sum of the corresponding ROIs of all the MCA. For e.g if the MCAs have three ROIs each say R0, R1 and R2. This method sums up the R0 of all the MCA R1 of all the MCAs and so on
      Returns:
      ROI sum array
      Throws:
      DeviceException
    • setROIs

      void setROIs(double[][] rois) throws DeviceException
      Sets the ROIs of all the MCA. Use this method only if you want to set all the MCA with the same ROIs.To set different ROI for each of the MCA use setNthROI method.
      Parameters:
      rois - array. Each roi should have a low and high value.
      Throws:
      DeviceException
    • getNumberOfROIs

      int getNumberOfROIs() throws DeviceException
      Returns the total number of ROIs currently set
      Returns:
      number of ROIs
      Throws:
      DeviceException
    • getNumberOfMca

      int getNumberOfMca() throws DeviceException
      Returns the number of MCAs currently connected to the XMap detector
      Returns:
      number of MCA
      Throws:
      DeviceException
    • setNthROI

      void setNthROI(double[][] rois, int roiIndex) throws DeviceException
      Sets a ROI for all of the MCAs
      Parameters:
      rois - This array length should be same as the number of MCAs
      roiIndex -
      Throws:
      DeviceException
    • getChannelLabels

      List<String> getChannelLabels()
      Lightly to be only implemented on the server.
      Returns:
      the labels for the channels defined by the user.
    • getROICounts

      double[] getROICounts(int iRoi) throws DeviceException
      Gets the count for each mca for a given ROI.
      Parameters:
      iRoi -
      Returns:
      double[] of counts per mca for this roi
      Throws:
      DeviceException
    • readoutScalerData

      double readoutScalerData() throws DeviceException
      Reads out the scaler data of the roi counts, corrects for deadtime and returns the sum.
      Returns:
      The FF data
      Throws:
      DeviceException