From: Natanael Adityasatria Date: Mon, 5 Oct 2015 16:30:27 +0000 (+0200) Subject: Update byte for D0 X-Git-Url: https://git.martlubbers.net/?a=commitdiff_plain;h=b98b580848fcb1c5c77928f36542566e1a15fb88;p=des2015.git Update byte for D0 --- diff --git a/natanael/ex10/ex10d1.c b/natanael/ex10/ex10d1.c index 0b699ba..5167f28 100644 --- a/natanael/ex10/ex10d1.c +++ b/natanael/ex10/ex10d1.c @@ -27,7 +27,7 @@ void enable_interupt() // enable port D0 ioperm(0x378, 1, 1); byte = inb(0x378); - byte = byte | 0x10; /* hex 10 = 00010000 */ + byte = byte | 0x01; /* hex 10 = 00010000 */ outb(byte, 0x378); } @@ -53,8 +53,8 @@ void write_RTIMES(char * filename, unsigned int number_of_values, void send_parallel_port_intrp() { - outb(inb(0x378) & 0xEF, 0x378); - outb(inb(0x378) | 0x10, 0x378); /* enable interrupt */ + outb(inb(0x378) & 0xFE, 0x378); + outb(inb(0x378) | 0x01, 0x378); /* enable interrupt */ } void do_task(void *arg) diff --git a/natanael/ex10/ex10d2.c b/natanael/ex10/ex10d2.c index c24cde4..c4f472b 100644 --- a/natanael/ex10/ex10d2.c +++ b/natanael/ex10/ex10d2.c @@ -26,7 +26,7 @@ void enable_interupt() // enable port D0 ioperm(0x378, 1, 1); byte = inb(0x378); - byte = byte | 0x10; /* hex 10 = 00010000 */ + byte = byte | 0x01; /* hex 10 = 00010000 */ outb(byte, 0x378); } @@ -39,8 +39,8 @@ void disable_interupt() void send_parallel_port_intrp() { - outb(inb(0x378) & 0xEF, 0x378); - outb(inb(0x378) | 0x10, 0x378); /* enable interrupt */ + outb(inb(0x378) & 0xFE, 0x378); + outb(inb(0x378) | 0x01, 0x378); /* enable interrupt */ } void do_task(void *arg)