# # Sony CD changer protocol description file. # # Careful! This is used to both document the protocol and # is parsed to build the table of commands and messages. # Command: 00 play Response: power_on,playing Response: playing Turns on the player if it is not already on and starts playing. Unpauses if the player is currently in a paused state Command: 01 stop Response: stop Stops the player. The current position is lost; the disc restarts at the begining. Command: 02 pause_on Response: pause Pauses the player. Resume with play or pause_toggle Command: 03 pause_toggle Response: pause Response: playing Pauses the player if it is player, plays if it is paused. Just like hitting the button Command: 08 next_track Response: track_info Response: The player skips to the next track if there is one and outputs the track information. If it is currently on the last track of the disc nothing is done. Command: 09 prev_track Response: track_info The player restarts the current track, or if at the beginning of the current track it goes to the previous track. Command: 0f mode Response: mode Requests a current mode message from the player. The player responds with a very informating mode message. Command: 10 fwd Command: 11 rew Command: 12 fast_fwd Command: 13 fast_rew The player cues forward/backwards at one of two speeds. Track boundary messages are still emitted Command: 20 disable Command: 21 enable Disables/enables the front panel controls on the player. Only the Open button is still enabled once turned off. Command: 22 capacity Response: capacity Asks the player how many discs it can hold Command: 25 verbose Response: status In verbose mode the player outputs status information every second until a new disc starts. Why it doesn't stay on is beyond me. Command: 26 silent Disables per-second reporting of status. Coomand: 2e power_on Response: power_on,now_at,capacity Response: Turns on the player if it is off and causes it to output a set of status information. If it is already on, no output is sent. Command: 2f power_off Response: power_off Response: Turns off the player if it is on. If it is already off no output is sent. Command: 40 get_memo disc Response: memo_text Error: no_memo Retrieves the memo text for the specified disc Command: 42 get_group group Response: group_id Error: already_did_that Returns a string that represents the group's name. Command: 43 group_list group Response: disc_list1, disc_list2 Error: already_did_that Error: error13 Requests a bit vector of which discs are in a certain group Command: 44 disc_info disc Response: disc_info Error: invalid_disc Requests the information on the requested disc, which must be the currently loaded one. Otherwise the invalid_disc error is returned. Command: 45 track_length disc track Response: track_length Error: invalid_track Requests the length of a track of the current disc. invalid_track is returned for a track that is out of range or if the specified disc is not currently loaded. Command: 46 unknown46 Error: already_did_that Command: 47 unknown46 Error: already_did_that Command: 48 get_memo2 disc Response: memo_text2 Error: no_memo I don't know how memo_text2 differs from memo_text. Maybe for CD Text volumes... Command: 4a unknown4a byte Response: msg5d, msg1d Don't know what this ones does. The 0x5d response has a byte that is the same as the argument to 0x4a. Command: 50 play_track disc track Error: no_such_disc,no_such_disc2 Response: going_to, unloading, now_at, toc_read, ready, track_info Response: track_info Loads and plays the requested track. If the track index is not present then track 1 is played instead. If the disc is not present the no_such_disc error is returned (followed by the no_such_disc2 error for somereason). Command: 51 cue_track disc track Error: no_such_disc,no_such_disc2 Response: going_to, unloading, now_at, toc_read, ready, track_info Response: track_info The same semantics as the play_track command Command: 5e fade seconds Error: already_did_that Response: Fades out the audio over the specified number of seconds. The disc continues playing, but is muted. If the audio is already faded the player emits the already_did_that error. Command: 5f ramp seconds Error: already_did_that Response: Ramps the audio back up over the specified number of seconds. If the audio is already at full the player emits the already_did_that error. Command: 63 unknown63 disc Response: msg63 Response: msg19 Error: already_did_that Requests something about the current disc. msg63 has a null byte followed by six bytes of data. Not sure what they mean... already_did_that is returned if this is not the current disc. Sometimes responds with a msg19 Command: 64 unknown64 Response: msg1a Response: msg64 No clue what this does... Sometimes it is a simple msg1a, sometimes a msg64 with nine bytes of data that vary based on which track is playing. Command: 6a type Response: type Requests a type message from the player. The type encodes an ID string for the model of the player. Useful! Command: 72 disc_list Response: disc_list1, disc_list2 Requests a bit vector of which discs are present. Very, very cool. Command: 80 set_memo disc string Response: memo_written Error: already_did_that Writes the string of up to 14 characters for the specified disc. If the disc has CD Text information the player will not allow it to be overwritten. Command: 81 unknown81 Error: already_did_that Command: 90 dump_memo Causes the player to dump memo texts for each disc in order. # # Messages are either sent in response to S-Link commands or generated # by someone pressing a button on the front panel # Message: 00 playing Sent by the player when it resumes playing. Message: 01 stop The player has stopped. Message: 02 pause The player has paused. Message: 05 no_such_disc2 The requested disc does not exists. I believe that this is a backwards compatible message. Message: 06 unloading The current disc is being returned to the carrosel. Message: 08 ready The player has read the table of contents and is now going to start playing? Message: 0c 30_seconds There are 30 seconds left in the current track, not counting pregap. Message: 0f error Something you did caused an error. Message: 10 no_memo There is no memo text for the disc that was requested. Message: 13 invalid_group Very few operations reference groups. I don't remember how I found this one. Message: 14 invalid_disc The disc you wanted is out of range or not loaded. Message: 15 invalid_track The track you requested is out of range. Message: 19 msg19 Error response to unknown63? Message: 1d msg1d The player received an unknown4a command. Message: 1f memo_written The set_memo command succedded Message: 40 memo_text disc string The memo text for the disc that was requested. Message: 42 group_id group string The name of the specified disc group. I don't know how to change this yet. Message: 43 group_list1 group disc_vector1 Message: 44 group_list2 group disc_vector2 A bit vector of all discs in a specified group. vector1 is discs up to 104, vector2 is 105 up to 200. Message: 48 memo_text2 disc string I don't know what the difference is between these two. Message: 50 track_info disc track min sec When the player crosses a track boundary or begins playing a new track it outputs this message. Message: 51 status track index min sec When verbose mode is turned on these messages are output every second. I don't know what index means and am bothered by the lack of a disc number. Grr. Additionally, there are bugs with the way this handles crossing a minute boundary. Usually four or five copies of the status message for x:00 are output in the second. Weird. Additionally, this count does not include pregap; it is what is displayed on the LCD. However, the track_length message does include pregap. Go figure. Message: 52 toc_read disc The player had read the table of contents from the disc and can answer queries about it now. Message: 53 no_such_disc disc The requested disc does not exist. Message: 54 going_to disc When the player is told to go to another disc, this is the message that it outputs. Message: 58 now_at disc The player has rotated the carosel to the specified disc and is going to load it. Message: 5d msg5d byte The player received a unknown4a command. Message: 60 disc_info disc index tracks min sec frames The current disc, the number of tracks and the overall length in m:s:f. I don't know how accurate this value is for CDDB calculations. Message: 61 capacity disc The capacity of the player in discs. Message: 62 track_length disc track min sec The length of the requested track in min:sec. Message: 63 msg63 @bytes Who knows? Sometimes sent in response to unknown63 commands. Message: 64 msg64 @bytes Message: 6a type string The model ID of the player Message: 70 mode playing program unknown2 disc track In response to a mode command the player responds with this message. Playing is 1 for playing, 2 for paused. program has something to do with which program is currently playing. I don't know what unknown2 is. Message: 72 disc_list1 disc_vector1 Message: 73 disc_list2 disc_vector2 A bit vector of all discs present in the changer. vector1 is up to 104. Vector2 is 105 up to 200. # # Data types sent to the player are defined here # type disc { my $disc =