Author |
Message |
Michael
Joined: Sat Jul 25, 2009 6:10 am Posts: 112 Location: United Kingdom
|
The Keyboard
First of all, I would to apologise for my absence - I have been busy with other stuff (and still technically am). Anyway, down to business:
How do I recieve keyboard input using C? Please remember that I am not using any standard includes (I have to code these myself). I followed the examples in bkerndev, but it wouldn't compile.
From what I understand I need to setup the IDT, ISRs and IRQs before I can take input? Does anyone have any tutorials/help please?
_________________ Thanks, Michael Sammels
OS Developing is 10% luck, 20% skill, 15% concentrated power of will. 5% pleasure, 50% pain, and a 100% reason continue the game.
|
Sat Oct 17, 2009 6:06 pm |
|
|
ctimko
Joined: Wed Oct 14, 2009 9:39 am Posts: 198 Location: United States
|
Re: The Keyboard
You need to first setup the GDT, then the IDT, and in those you will setup your ISRs and IRQs. After that, you are going to have to attach the keyboard to an IRQ. I don't exactly remember what the suggested is, but for now I have attached mine to IRQ1. If you want, I can work up a tutorial for the keyboard stuff for everyone and post it. It will take me a few days since I have other things, but it would probably be better than me just posting code here and you don't learn. <(o.o)>
_________________ Charles Timko push %esp ;Musings of a computer addict
|
Sat Oct 17, 2009 8:05 pm |
|
|
Michael
Joined: Sat Jul 25, 2009 6:10 am Posts: 112 Location: United Kingdom
|
Re: The Keyboard
I have a GDT setup in ASM. A tutorial would be handy, Google is not being friendly.
_________________ Thanks, Michael Sammels
OS Developing is 10% luck, 20% skill, 15% concentrated power of will. 5% pleasure, 50% pain, and a 100% reason continue the game.
|
Sat Oct 17, 2009 9:18 pm |
|
|
Kieran
Site Admin
Joined: Sat Jul 25, 2009 7:44 am Posts: 274 Location: United Kingdom
|
Re: The Keyboard
Michael, start loking at OSDev.org, its a great site and until we have the information here, that will prob be your main resource for os devving.
_________________ Thank you for reading,
Kieran C G Foot
|
Sun Oct 18, 2009 10:58 am |
|
|
Michael
Joined: Sat Jul 25, 2009 6:10 am Posts: 112 Location: United Kingdom
|
Re: The Keyboard
OSDev.org is where I pulled together what I have so far
_________________ Thanks, Michael Sammels
OS Developing is 10% luck, 20% skill, 15% concentrated power of will. 5% pleasure, 50% pain, and a 100% reason continue the game.
|
Sun Oct 18, 2009 11:11 am |
|
|
Kieran
Site Admin
Joined: Sat Jul 25, 2009 7:44 am Posts: 274 Location: United Kingdom
|
Re: The Keyboard
ok mate, well Im sure you have all of the neede information already, keep trying mate and it will all come together
_________________ Thank you for reading,
Kieran C G Foot
|
Sun Oct 18, 2009 11:13 am |
|
|
Michael
Joined: Sat Jul 25, 2009 6:10 am Posts: 112 Location: United Kingdom
|
Re: The Keyboard
I think OSDev lacks IDT tutorials So does everywhere, tbh.
_________________ Thanks, Michael Sammels
OS Developing is 10% luck, 20% skill, 15% concentrated power of will. 5% pleasure, 50% pain, and a 100% reason continue the game.
|
Sun Oct 18, 2009 11:14 am |
|
|
ctimko
Joined: Wed Oct 14, 2009 9:39 am Posts: 198 Location: United States
|
Re: The Keyboard
Check out this tutorial. This will help you with the IDT, IRQ, and ISRs http://jamesmolloy.co.uk/tutorial_html/index.htmlThis is what I used to help me start my kernel out in C and then I converted it to C++. Charles
_________________ Charles Timko push %esp ;Musings of a computer addict
|
Sun Oct 18, 2009 12:26 pm |
|
|
Michael
Joined: Sat Jul 25, 2009 6:10 am Posts: 112 Location: United Kingdom
|
Re: The Keyboard
Thanks, I'll take a look.
_________________ Thanks, Michael Sammels
OS Developing is 10% luck, 20% skill, 15% concentrated power of will. 5% pleasure, 50% pain, and a 100% reason continue the game.
|
Sun Oct 18, 2009 12:27 pm |
|
|
Kieran
Site Admin
Joined: Sat Jul 25, 2009 7:44 am Posts: 274 Location: United Kingdom
|
Re: The Keyboard
Mike mate, ill be on msn later, give me a buzz if you get stuck with the IDT
_________________ Thank you for reading,
Kieran C G Foot
|
Mon Oct 19, 2009 7:33 am |
|
|