mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-22 22:05:38 +00:00
CDROM: Last sector header is already in BCD - fix for GetLocP
This commit is contained in:
parent
2b6ebf9955
commit
f285f26ec2
|
@ -542,8 +542,8 @@ void CDROM::ExecuteCommand()
|
||||||
m_setloc.second = BCDToDecimal(m_param_fifo.Peek(1));
|
m_setloc.second = BCDToDecimal(m_param_fifo.Peek(1));
|
||||||
m_setloc.frame = BCDToDecimal(m_param_fifo.Peek(2));
|
m_setloc.frame = BCDToDecimal(m_param_fifo.Peek(2));
|
||||||
m_setloc_dirty = true;
|
m_setloc_dirty = true;
|
||||||
Log_DebugPrintf("CDROM setloc command (%u, %u, %u)", ZeroExtend32(m_setloc.minute), ZeroExtend32(m_setloc.second),
|
Log_DebugPrintf("CDROM setloc command (%02X, %02X, %02X)", ZeroExtend32(m_param_fifo.Peek(0)),
|
||||||
ZeroExtend32(m_setloc.frame));
|
ZeroExtend32(m_param_fifo.Peek(1)), ZeroExtend32(m_param_fifo.Peek(2)));
|
||||||
m_response_fifo.Push(m_secondary_status.bits);
|
m_response_fifo.Push(m_secondary_status.bits);
|
||||||
SetInterrupt(Interrupt::ACK);
|
SetInterrupt(Interrupt::ACK);
|
||||||
EndCommand();
|
EndCommand();
|
||||||
|
@ -697,14 +697,14 @@ void CDROM::ExecuteCommand()
|
||||||
{
|
{
|
||||||
// TODO: Subchannel Q support..
|
// TODO: Subchannel Q support..
|
||||||
Log_DebugPrintf("CDROM GetlocP command");
|
Log_DebugPrintf("CDROM GetlocP command");
|
||||||
m_response_fifo.Push(1); // track number
|
m_response_fifo.Push(1); // track number
|
||||||
m_response_fifo.Push(1); // index
|
m_response_fifo.Push(1); // index
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.minute)); // minute within track
|
m_response_fifo.Push(m_last_sector_header.minute); // minute within track
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.second)); // second within track
|
m_response_fifo.Push(m_last_sector_header.second); // second within track
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.frame)); // frame within track
|
m_response_fifo.Push(m_last_sector_header.frame); // frame within track
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.minute)); // minute on entire disc
|
m_response_fifo.Push(m_last_sector_header.minute); // minute on entire disc
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.second)); // second on entire disc
|
m_response_fifo.Push(m_last_sector_header.second); // second on entire disc
|
||||||
m_response_fifo.Push(DecimalToBCD(m_last_sector_header.frame)); // frame on entire disc
|
m_response_fifo.Push(m_last_sector_header.frame); // frame on entire disc
|
||||||
SetInterrupt(Interrupt::ACK);
|
SetInterrupt(Interrupt::ACK);
|
||||||
EndCommand();
|
EndCommand();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue