Ignore:
Timestamp:
Jul 6, 2017, 3:47:20 PM (5 years ago)
Author:
max@…
Message:

add a basic RS232 COM1 implementation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/hal/x86_64/core/hal_interrupt.c

    r142 r152  
    2727
    2828#include <hal_kentry.h>
     29#include <hal_apic.h>
    2930#include <hal_internal.h>
    3031
     
    3738{
    3839        x86_printf("-> got timer: rip=%Z\n", tf->tf_rip);
     40        hal_com_send('h');
     41        return;
     42}
     43
     44/* -------------------------------------------------------------------------- */
     45
     46/*
     47 * Serial Port (COM1) interrupt
     48 */
     49void hal_com1_intr(struct trapframe *tf)
     50{
     51        char c = hal_com_read();
     52
     53        x86_printf("-> got com '%c'\n", c);
    3954        return;
    4055}
Note: See TracChangeset for help on using the changeset viewer.