Fix the PIT square wave generator.
svn path=/branches/ntvdm/; revision=61151
}
else
{
- /* Clear the count */
- Count = 0;
-
/* Decrease the value */
PitChannels[i].CurrentValue -= Count * 2;
+ /* Clear the count */
+ Count = 0;
+
/* Did it fall to zero? */
if (PitChannels[i].CurrentValue == 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 */
PicInterruptRequest(0);