13 lines
347 B
C
13 lines
347 B
C
#include "../includes/interrupt_handler.h"
|
|
#include "../includes/serial.h"
|
|
#include "../includes/screen.h"
|
|
|
|
void interrupt_handler(struct isr_state stack)
|
|
{
|
|
write_to_com(COM1_PORT, int_to_string(stack.int_no, 10));
|
|
write_to_com(COM1_PORT, "Divide by zero detected!\n");
|
|
write_to_com(COM1_PORT, "Halting system!\n");
|
|
asm("cli");
|
|
asm("hlt");
|
|
}
|