mirror of
https://github.com/reactos/reactos.git
synced 2024-08-05 19:11:16 +00:00
[NTVDM]
Fix the PIT square wave generator. svn path=/branches/ntvdm/; revision=61151
This commit is contained in:
parent
9c6b9c9bab
commit
d49a1c16b2
|
@ -277,12 +277,12 @@ VOID PitDecrementCount(DWORD Count)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
/* Clear the count */
|
|
||||||
Count = 0;
|
|
||||||
|
|
||||||
/* Decrease the value */
|
/* Decrease the value */
|
||||||
PitChannels[i].CurrentValue -= Count * 2;
|
PitChannels[i].CurrentValue -= Count * 2;
|
||||||
|
|
||||||
|
/* Clear the count */
|
||||||
|
Count = 0;
|
||||||
|
|
||||||
/* Did it fall to zero? */
|
/* Did it fall to zero? */
|
||||||
if (PitChannels[i].CurrentValue == 0)
|
if (PitChannels[i].CurrentValue == 0)
|
||||||
{
|
{
|
||||||
|
@ -304,7 +304,9 @@ VOID PitDecrementCount(DWORD Count)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Was there any rising edge on channel 0 ? */
|
/* Was there any rising edge on channel 0 ? */
|
||||||
if ((PitChannels[i].OutputFlipFlop || ReloadCount) && (i == 0))
|
if (((PitChannels[i].OutputFlipFlop && (ReloadCount == 1))
|
||||||
|
|| (ReloadCount > 1))
|
||||||
|
&& (i == 0))
|
||||||
{
|
{
|
||||||
/* Yes, IRQ 0 */
|
/* Yes, IRQ 0 */
|
||||||
PicInterruptRequest(0);
|
PicInterruptRequest(0);
|
||||||
|
|
Loading…
Reference in a new issue