Class FrcI2cLEDPanel

java.lang.Object
trclib.archive.TrcI2cLEDPanel
frclib.archive.FrcI2cLEDPanel

public class FrcI2cLEDPanel extends TrcI2cLEDPanel
This class implements a platform dependent I2C LED panel device. It extends the platform independent counterpart and provides platform dependent access to the I2C device.
  • Field Details

    • DEF_I2C_PORT

      public static final edu.wpi.first.wpilibj.I2C.Port DEF_I2C_PORT
    • DEF_I2C_ADDRESS

      public static final int DEF_I2C_ADDRESS
      See Also:
  • Constructor Details

    • FrcI2cLEDPanel

      public FrcI2cLEDPanel(String instanceName, edu.wpi.first.wpilibj.I2C.Port port, int devAddress)
      Constructor: Create an instance of the object.
      Parameters:
      instanceName - specifies the instance name.
      port - specifies the I2C port on the RoboRIO.
      devAddress - specifies the I2C address of the device.
    • FrcI2cLEDPanel

      public FrcI2cLEDPanel(String instanceName, edu.wpi.first.wpilibj.I2C.Port port)
      Constructor: Create an instance of the object.
      Parameters:
      instanceName - specifies the instance name.
      port - specifies the I2C port on the RoboRIO.
  • Method Details

    • isEnabled

      public boolean isEnabled()
      This method checks if the device is enabled.
      Returns:
      true if the device is enabled, false otherwise.
    • setEnabled

      public void setEnabled(boolean enabled)
      This method enables/disables the device.
      Parameters:
      enabled - specifies true to enable the device, false to disable.
    • asyncWriteData

      public void asyncWriteData(byte[] data)
      This method writes the data buffer to the device asynchronously.
      Specified by:
      asyncWriteData in class TrcI2cLEDPanel
      Parameters:
      data - specifies the data buffer.