Exemplo n.º 1
0
        public void Reset()
        {
            // If the driver is enabled
            if (enabled)
            {
                // Wait for the Input Buffer Full flag to clear
                byte StatusRegValue = 0x02;
                while ((StatusRegValue & 0x02) != 0)
                {
                    StatusRegValue = CommandPort.Read_Byte();
                }

                // Send the command | options
                //          (0xF0   | 0x0E    - pulse only line 0 - CPU reset line)
                CommandPort.Write_Byte(0xFE);
            }
        }
Exemplo n.º 2
0
        /// <summary>
        /// The internal interrupt handler.
        /// </summary>
        public void InterruptHandler()
        {
            byte scancode = DataPort.Read_Byte();

            HandleScancode(scancode);
        }
Exemplo n.º 3
0
 /// <summary>
 /// Enables the PC speaker sound.
 /// </summary>
 public void EnableSound()
 {
     //OR with 0x03 to enable sound
     SpeakerPort.Write_Byte((byte)(SpeakerPort.Read_Byte() | 0x03));
 }