Class ClaroControl

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.util.EventListener

    public class ClaroControl
    extends java.lang.Object
    implements java.awt.event.ActionListener

    This class encapsulates the interactions with the collection of CLAROs.

    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) int aldoEnable
      GPIO number of FEB ALDO enable
      (package private) java.util.ArrayList<Claro> claros
      List of CLARO instances
      (package private) int ec
      The EC ID of this CLARO
      (package private) int feb1Enable
      GPIO number of FEB1 enable
      (package private) int feb2Enable
      GPIO number of FEB2 enable
      static int nClaros
      Number of CLAROs per FEB
      static int nFebs
      Number of FEBs per EC per PDMDB
      (package private) int npor
      GPIO number of POR*
      (package private) java.util.prefs.Preferences prefs  
      (package private) Sc sc  
      (package private) ScaDepp sca
      The SCA interface
      (package private) int seud
      GPIO number of CLARO SEUD
      boolean testEnable  
      (package private) int writeEnable
      GPIO number of the CLARO write enable
    • Constructor Summary

      Constructors 
      Constructor Description
      ClaroControl()
      No-argument constructor called by the unmarshaller
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void actionPerformed​(java.awt.event.ActionEvent e)  
      (package private) void assertPOR()
      Asserts the EC npor (power on reset) signal.
      boolean configure()
      Configures all CLAROs
      (package private) void deassertPOR()
      Deasserts the EC npor (power on reset) signal.
      void deselectAllCLARO()
      Deselects (SPI) all CLAROs
      java.util.ArrayList<Claro> getClaros()  
      void init​(Sc sc, int ec)
      Completes the initialisation of the instance
      javax.swing.JPanel makePanel()
      Convenience method to create a GUI panel
      static boolean verify​(ScaDepp sca, java.util.ArrayList<Claro> claroList)
      Reads CLARO configuration registers and compares with mirrored register bits.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • prefs

        java.util.prefs.Preferences prefs
      • sca

        ScaDepp sca

        The SCA interface

      • sc

        Sc sc
      • claros

        java.util.ArrayList<Claro> claros

        List of CLARO instances

      • ec

        int ec

        The EC ID of this CLARO

      • writeEnable

        int writeEnable

        GPIO number of the CLARO write enable

      • feb1Enable

        int feb1Enable

        GPIO number of FEB1 enable

      • feb2Enable

        int feb2Enable

        GPIO number of FEB2 enable

      • npor

        int npor

        GPIO number of POR*

      • aldoEnable

        int aldoEnable

        GPIO number of FEB ALDO enable

      • seud

        int seud

        GPIO number of CLARO SEUD

      • testEnable

        public boolean testEnable
    • Constructor Detail

      • ClaroControl

        public ClaroControl()

        No-argument constructor called by the unmarshaller

    • Method Detail

      • getClaros

        public java.util.ArrayList<Claro> getClaros()
      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent e)
        Specified by:
        actionPerformed in interface java.awt.event.ActionListener
      • init

        public void init​(Sc sc,
                         int ec)

        Completes the initialisation of the instance

        Call after unmarshalling to complete initialisation.

        Parameters:
        sc - The SCA interface
        ec - The EC ID
      • assertPOR

        void assertPOR()

        Asserts the EC npor (power on reset) signal.

        The level is defined by a pull-up. Sets the GPIO direction to output.

      • deassertPOR

        void deassertPOR()

        Deasserts the EC npor (power on reset) signal.

        The level is defined by a pull-up. Sets the GPIO direction to input.

      • makePanel

        public javax.swing.JPanel makePanel()

        Convenience method to create a GUI panel

        Returns:
        The panel
      • configure

        public boolean configure()

        Configures all CLAROs

        Returns:
        Configuration status
      • deselectAllCLARO

        public void deselectAllCLARO()

        Deselects (SPI) all CLAROs

        Puts slave selects into safe deselected state.

      • verify

        public static boolean verify​(ScaDepp sca,
                                     java.util.ArrayList<Claro> claroList)

        Reads CLARO configuration registers and compares with mirrored register bits.

        Parameters:
        sca - The SCA interface
        claroList - List of CLAROs to check
        Returns:
        Verification status