interrupt template for gnu assembler

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
Whatever

interrupt template for gnu assembler

Post by Whatever »

Can somebody give me a working template of an interrupt in gnu assembler?

thanx in advance
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re:interrupt template for gnu assembler

Post by Solar »

Every good solution is obvious once you've found it.
Whatever

Re:interrupt template for gnu assembler

Post by Whatever »

srry, but not really.. how do i tell my pc that the function is an isr and has to call that specific function when e.g. a key on my keyboard is pressed?
distantvoices
Member
Member
Posts: 1600
Joined: Wed Oct 18, 2006 11:59 am
Location: Vienna/Austria
Contact:

Re:interrupt template for gnu assembler

Post by distantvoices »

you as th kernel developer tell this the cpu:

*here* is the interrupt descriptor table and *here* are the functions you have to call in case an interrupt occurs.

basically, the cpu does nothing else but receiving an event (roughly spoken) looking up the corresponding function and jumping to it. Thats kinda automation you have to provide it with.

How? Solars link should provide this information, hm?
... the osdever formerly known as beyond infinity ...
BlueillusionOS iso image
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:interrupt template for gnu assembler

Post by Pype.Clicker »

Whatever wrote: srry, but not really.. how do i tell my pc that the function is an isr and has to call that specific function when e.g. a key on my keyboard is pressed?
or, stated otherwise, it is an ISR *because* you write its address in some slot of the IDT .. And it will be called for keypress *because* you select the slot corresponding to IRQ1 :)
Post Reply