Class KinetDatagram

All Implemented Interfaces:
LXPath, LXSerializable, LXOutput.InetOutput, LXParameterListener

public class KinetDatagram extends LXDatagram
A datagram implementing the Kinet protocol, used by Color Kinetics devices. These datagrams have a header followed by 512 bytes of color data. A port number on the output device is specified, distinct from the UDP port. For instance, an sPDS-480 has 16 outputs.
  • Field Details

  • Constructor Details

    • KinetDatagram

      public KinetDatagram(LX lx, LXModel model, int kinetPort)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      model - Model to output points for
      kinetPort - Number of the output port on the kinet power supply
    • KinetDatagram

      public KinetDatagram(LX lx, LXModel model, int kinetPort, KinetDatagram.Version version)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      model - Model that this datagram outputs points for
      kinetPort - Number of the output port on the kinet power supply
      version - Version of Kinet Protocol
    • KinetDatagram

      public KinetDatagram(LX lx, int[] indexBuffer, int kinetPort)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      indexBuffer - A list of the point indices that should be sent on this port
      kinetPort - Number of the output port on the kinet power supply
    • KinetDatagram

      public KinetDatagram(LX lx, int[] indexBuffer, LXBufferOutput.ByteOrder byteOrder, int kinetPort)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      indexBuffer - A list of the point indices that should be sent on this port
      byteOrder - Which byte ordering to use for the output
      kinetPort - Number of the output port on the kinet power supply
    • KinetDatagram

      public KinetDatagram(LX lx, int[] indexBuffer, LXBufferOutput.ByteOrder byteOrder, int kinetPort, KinetDatagram.Version version)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      indexBuffer - Index buffer that this datagram outputs points for
      byteOrder - Which byte ordering to use for the output
      kinetPort - Number of the output port on the kinet power supply
      version - Version of Kinet Protocol
    • KinetDatagram

      public KinetDatagram(LX lx, IndexBuffer indexBuffer, int kinetPort)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      indexBuffer - Index buffer that this datagram outputs points for
      kinetPort - Number of the output port on the kinet power supply
    • KinetDatagram

      public KinetDatagram(LX lx, IndexBuffer indexBuffer, int kinetPort, KinetDatagram.Version version)
      Constructs a datagram that sends on the given kinet supply output port
      Parameters:
      lx - LX instance
      indexBuffer - Index buffer that this datagram outputs points for
      kinetPort - Number of the output port on the kinet power supply
      version - Version of Kinet Protocol
  • Method Details

    • setKinetPort

      public KinetDatagram setKinetPort(byte kinetPort)
    • getDataBufferOffset

      protected int getDataBufferOffset()
      Description copied from class: LXBufferOutput
      Offset into raw byte buffer where color data is written
      Specified by:
      getDataBufferOffset in class LXBufferOutput
      Returns:
      Offset into raw byte buffer for color data