Page 1 of 1

How to Enable the Clock or the PIT on Qemu i386 Emulator

Posted: Mon Dec 07, 2015 7:31 am
by aswinmohanme
I have recently been following James M Kernel Dev. I use Qemu instead of Boschs for emulating the i386 architecture.

But Iam Stuck how do I enable the clock or the Programmable Interval Timer in qemu ?

Re: How to Enable the Clock or the PIT on Qemu i386 Emulator

Posted: Mon Dec 07, 2015 2:15 pm
by SpyderTL
I'm not sure what you are asking. Can you explain what you are trying to do?

The PIT should be set up and running by the time your OS code starts executing, so you shouldn't need to do anything with it. You can change the frequency and make it interrupt the CPU faster or slower, if you want, but I would just leave it at its default value, for now.

Re: How to Enable the Clock or the PIT on Qemu i386 Emulator

Posted: Mon Dec 07, 2015 2:42 pm
by iansjack
The same way that you would on real hardware.

Re: How to Enable the Clock or the PIT on Qemu i386 Emulator

Posted: Mon Dec 07, 2015 9:32 pm
by aswinmohanme
The Problem is with my code I think . Trying to Fix it , the Output is not displayed on the screen

Re: How to Enable the Clock or the PIT on Qemu i386 Emulator

Posted: Tue Dec 08, 2015 4:29 am
by kenod
Do you have working code for the keyboard? I had a problem with PIT code as well, but it turned out I had some trouble with my interrupts. Also, can you post your PIT code? That would help us with finding the problem.