Skip to content

Commit

Permalink
Fix TOC handling (#92)
Browse files Browse the repository at this point in the history
  • Loading branch information
uweseimet committed Jul 22, 2024
1 parent fe3a5e0 commit a0a425d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions cpp/devices/scsi_cd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,14 +98,15 @@ void ScsiCd::ReadToc()
buf[2] = 1;
// Last track number
buf[3] = 1;

// Data track, not audio track
buf[5] = 0x14;
buf[6] = track_number;

// Track address in the requested format (MSF)
if (cdb[1] & 0x02) {
LBAtoMSF(track_address + 1, &buf[8]);
LBAtoMSF(track_address, &buf[8]);
} else {
SetInt16(buf, 10, track_address + 1);
SetInt16(buf, 10, track_address);
}

DataInPhase(length);
Expand Down
2 changes: 1 addition & 1 deletion cpp/shared/s2p_version.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@

const int s2p_major_version = 3;
const int s2p_minor_version = 4;
const int s2p_revision = 0;
const int s2p_revision = 1;
const std::string s2p_suffix = "";

0 comments on commit a0a425d

Please sign in to comment.