Page 1 of 1

I've cleared the kickoff, now what?

Posted: Tue Jul 22, 2003 11:00 pm
by Kattmat
Okey, here's the deal:
I've gone through a couple of tutorials and have been able to make my own bootloader which jumps into protected mode and loads a C-written kernel. The kernel can only do 4 things: print to screen, clear the screen, input and output to memory. Print and clear uses the in-/output functions so maybe we could say there is only 2 real functions. Anyway, now I want to be able to read keys from the keyboard when the user presses them. How to do this? Do I set up a loop that gets a sertain value from a sertain memory position using a sertain index number?  Can someone please show me some code on how to do this?  Major thanks in advance!

Regards,
  Anton Kiland, Sweden.

ps.
Is it only I who gets a rush out of this? =)

RE:I've cleared the kickoff, now what?

Posted: Wed Jul 23, 2003 11:00 pm
by Kattmat
Keyboard input.. How to do that, for example?


Please. Any help is kindly accepted!

RE:I've cleared the kickoff, now what?

Posted: Wed Jul 23, 2003 11:00 pm
by CarbonBased
The best source of info here is to look at an already existing OS on this board for an overview of the whole process.

You must first remap the pic; move the IRQ's to at or above 0x20.  This will place the keyboard ISR at 0x21 (IIRC).  At this point, you'll have to install a basic interrupt vector here.  A simple keyboard ISR can simply input from port 0x60 and iret... for assurance that it's actually working, you might want to beep the PC internal, or output the letter.

Hope that helps,
Cheers

RE:I've cleared the kickoff, now what?

Posted: Wed Jul 23, 2003 11:00 pm
by Kattmat
Look.. I don't get anything of what you just said but it sounds great. Now, how to do it in the real world? I can't understand the sourcecode I've been looking at either.

RE:I've cleared the kickoff, now what?

Posted: Wed Jul 23, 2003 11:00 pm
by VE3MTM
The topic is well-explained in various tutorials out there, a few of which are linked to from this very site