Package org.deepsymmetry.beatlink
Enum Util.PacketType
- java.lang.Object
-
- java.lang.Enum<Util.PacketType>
-
- org.deepsymmetry.beatlink.Util.PacketType
-
- All Implemented Interfaces:
Serializable,Comparable<Util.PacketType>
- Enclosing class:
- Util
public static enum Util.PacketType extends Enum<Util.PacketType>
The known packet types used in the protocol, along with the byte values which identify them, and the names by which we describe them, and the port on which they are received.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description BEATAnnounces a beat has been played in a rekordbox-analyzed track, with lots of useful synchronization information.CDJ_STATUSA status update from a player, with a great many status flags, pitch, tempo, and beat-within-bar details.CHANNELS_ON_AIRUsed by the mixer to tell the players which channels are on and off the air.DEVICE_KEEP_ALIVEUsed to report that a device is still present on the DJ Link network.FADER_START_COMMANDUsed by the mixer to tell a set of players to start and/or stop playing.LOAD_TRACK_ACKA response indicating that the specified track is being loaded.LOAD_TRACK_COMMANDA command to load a particular track; usually sent by rekordbox.MASTER_HANDOFF_REQUESTUsed by an incoming tempo master to ask the current tempo master to relinquish that role.MASTER_HANDOFF_RESPONSEUsed by the active tempo master to respond to a request to relinquish that role.MEDIA_QUERYUsed to ask a player for information about the media mounted in a slot.MEDIA_RESPONSEThe response sent when a Media Query is received.MIXER_STATUSA status update from the mixer, with status flags, pitch, and tempo, and beat-within-bar information.SYNC_CONTROLUsed to tell a player to turn sync on or off, or that it should become the tempo master.
-
Field Summary
Fields Modifier and Type Field Description StringnameThe name by which we describe this kind of packet.intportThe port on which this kind of packet is received.byteprotocolValueThe value that appears in the type byte which identifies this type of packet.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Util.PacketTypevalueOf(String name)Returns the enum constant of this type with the specified name.static Util.PacketType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
FADER_START_COMMAND
public static final Util.PacketType FADER_START_COMMAND
Used by the mixer to tell a set of players to start and/or stop playing.
-
CHANNELS_ON_AIR
public static final Util.PacketType CHANNELS_ON_AIR
Used by the mixer to tell the players which channels are on and off the air.
-
MEDIA_QUERY
public static final Util.PacketType MEDIA_QUERY
Used to ask a player for information about the media mounted in a slot.
-
MEDIA_RESPONSE
public static final Util.PacketType MEDIA_RESPONSE
The response sent when a Media Query is received.
-
DEVICE_KEEP_ALIVE
public static final Util.PacketType DEVICE_KEEP_ALIVE
Used to report that a device is still present on the DJ Link network.
-
CDJ_STATUS
public static final Util.PacketType CDJ_STATUS
A status update from a player, with a great many status flags, pitch, tempo, and beat-within-bar details. Sadly, the same number is used (on port 50000) as part of the CDJ startup process.
-
LOAD_TRACK_COMMAND
public static final Util.PacketType LOAD_TRACK_COMMAND
A command to load a particular track; usually sent by rekordbox.
-
LOAD_TRACK_ACK
public static final Util.PacketType LOAD_TRACK_ACK
A response indicating that the specified track is being loaded.
-
MASTER_HANDOFF_REQUEST
public static final Util.PacketType MASTER_HANDOFF_REQUEST
Used by an incoming tempo master to ask the current tempo master to relinquish that role.
-
MASTER_HANDOFF_RESPONSE
public static final Util.PacketType MASTER_HANDOFF_RESPONSE
Used by the active tempo master to respond to a request to relinquish that role.
-
BEAT
public static final Util.PacketType BEAT
Announces a beat has been played in a rekordbox-analyzed track, with lots of useful synchronization information.
-
MIXER_STATUS
public static final Util.PacketType MIXER_STATUS
A status update from the mixer, with status flags, pitch, and tempo, and beat-within-bar information.
-
SYNC_CONTROL
public static final Util.PacketType SYNC_CONTROL
Used to tell a player to turn sync on or off, or that it should become the tempo master.
-
-
Field Detail
-
protocolValue
public final byte protocolValue
The value that appears in the type byte which identifies this type of packet.
-
name
public final String name
The name by which we describe this kind of packet.
-
port
public final int port
The port on which this kind of packet is received.
-
-
Method Detail
-
values
public static Util.PacketType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Util.PacketType c : Util.PacketType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Util.PacketType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-