java.lang.Object
org.mbari.vcr4j.rs422.commands.CommandToBytes
This utility class converts VideoCommand objects to the appropriate byte commands
used by RS422.
- Since:
- 2016-01-28T14:25:00
- Author:
- Brian Schlining
-
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]apply(VideoCommand cmd) static final StringbyteArrayToString(byte[] b) Converts a byte array to a nicely formatted string.static byteintToTime(int time) Convert an int value to a timecode byte that can be used in sending a seekTimecode command.static byte[]timecodeToBytes(Timecode timecode) static byte[]static byte[]toBytes(SeekTimecodeCmd cmd) static byte[]toBytes(SeekTimestampCmd cmd) static byte[]toBytes(ShuttleCmd cmd) static byte[]toBytes(VideoCommands cmd) static byte[]toBytes(PresetTimecodeCmd cmd) static byte[]toBytes(PresetUserbitsCmd cmd) static byte[]
-
Method Details
-
apply
-
toBytes
-
toBytes
-
toBytes
-
toBytes
-
toBytes
-
toBytes
-
toBytes
-
toBytes
-
timecodeToBytes
-
byteArrayToString
Converts a byte array to a nicely formatted string. Useful for debugging using System.out- Parameters:
b- A byte array to view as a string- Returns:
- The byte array formatted as a string
-
intToTime
public static byte intToTime(int time) Convert an int value to a timecode byte that can be used in sending a seekTimecode command.- Parameters:
time- An integer value representing time (hour, minute, second, or frame)- Returns:
- The byte representiation of that time as a value recognized by a VCR.
-