IRQ Stuff
git-svn-id: https://spexeah.com:8443/svn/Asuro@66 6dbc8c32-bb84-406f-8558-d1cf31a0ab0c
This commit is contained in:
parent
3959607fc1
commit
1c2102f023
@ -28,11 +28,12 @@ implementation
|
||||
|
||||
procedure Main; interrupt; //IRQ0, called every 55ms
|
||||
begin
|
||||
CLI;
|
||||
//CLI;
|
||||
console.writestringln('helo1');
|
||||
if(procedure_ptr <> nil) then begin
|
||||
procedure_ptr();
|
||||
end;
|
||||
outb($0020, $20);
|
||||
outb($20, $20);
|
||||
end;
|
||||
|
||||
procedure register();
|
||||
|
@ -28,12 +28,12 @@ implementation
|
||||
|
||||
procedure Main; interrupt; //IRQ1, Keyboard Interrupt
|
||||
begin
|
||||
CLI;
|
||||
//CLI;
|
||||
console.writestringln('helo2');
|
||||
if(procedure_ptr <> nil) then begin
|
||||
procedure_ptr(inb($60));
|
||||
end;
|
||||
console.writestringln('helo');
|
||||
outb($0020, $20);
|
||||
outb($20, $20);
|
||||
end;
|
||||
|
||||
procedure register();
|
||||
|
@ -1,13 +1,13 @@
|
||||
{ ************************************************
|
||||
* Asuro
|
||||
* Unit: Drivers/isr32
|
||||
* Unit: Drivers/isr40
|
||||
* Description: 1024/s Timer interrupt
|
||||
************************************************
|
||||
* Author: Aaron Hance
|
||||
* Contributors:
|
||||
************************************************ }
|
||||
|
||||
unit isr49;
|
||||
unit isr40;
|
||||
|
||||
interface
|
||||
|
||||
@ -28,11 +28,12 @@ implementation
|
||||
|
||||
procedure Main; interrupt; //IRQ0, called every 55ms
|
||||
begin
|
||||
CLI;
|
||||
//CLI;
|
||||
console.writestringln('helo3');
|
||||
if(procedure_ptr <> nil) then begin
|
||||
procedure_ptr();
|
||||
end;
|
||||
outb($0020, $20);
|
||||
outb($20, $20);
|
||||
end;
|
||||
|
||||
procedure register();
|
19
src/irq.pas
19
src/irq.pas
@ -10,6 +10,7 @@
|
||||
unit irq;
|
||||
|
||||
interface
|
||||
|
||||
uses util;
|
||||
|
||||
procedure init();
|
||||
@ -18,14 +19,16 @@ implementation
|
||||
|
||||
procedure init();
|
||||
begin
|
||||
outb($0020, $11);
|
||||
outb($00A0, $11);
|
||||
outb($0021, $20);
|
||||
outb($00A1, $28);
|
||||
outb($0021, $04);
|
||||
outb($00A1, $02);
|
||||
outb($0021, $01);
|
||||
outb($00A1, $01);
|
||||
outb($20, $11);
|
||||
outb($A0, $11);
|
||||
outb($21, $20);
|
||||
outb($A1, $28);
|
||||
outb($21, $04);
|
||||
outb($A1, $02);
|
||||
outb($21, $01);
|
||||
outb($A1, $01);
|
||||
outb($21, $00);
|
||||
outb($A1, $00);
|
||||
end;
|
||||
|
||||
end.
|
@ -15,7 +15,7 @@ uses
|
||||
ISR0, ISR1, ISR2, ISR3, ISR4, ISR5, ISR6, ISR7, ISR8, ISR9,
|
||||
ISR10, ISR11, ISR12, ISR13, ISR14, ISR15, ISR16, ISR17, ISR18,
|
||||
ISR32, ISR33,
|
||||
ISR49;
|
||||
ISR40;
|
||||
|
||||
procedure init();
|
||||
|
||||
@ -45,7 +45,7 @@ begin
|
||||
|
||||
ISR32.register(); // 55ms Timer
|
||||
ISR33.register(); // Keyboard
|
||||
ISR49.register(); // 1024/s Timer
|
||||
ISR40.register(); // 1024/s Timer
|
||||
end;
|
||||
|
||||
end.
|
Loading…
x
Reference in New Issue
Block a user