mirror of
https://github.com/gbowne1/ClassicOS.git
synced 2025-10-18 07:05:07 -07:00
fixed the CMakeLists.txt so that it includes all the files in source as variables
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "io.h"
|
||||
|
||||
/*
|
||||
Common Ports
|
||||
Common Ports
|
||||
COM1: 0x3F8
|
||||
COM2: 0x2F8
|
||||
COM3: 0x3E8
|
||||
@@ -24,6 +24,12 @@ char io_read_com()
|
||||
// TODO: Read from the COM port
|
||||
// Use the appropriate memory or I/O address to read from the port
|
||||
// Return the read data
|
||||
|
||||
char data = 0; // Initialize the variable to store the read data
|
||||
|
||||
// Read from the COM port and assign the read value to the 'data' variable
|
||||
|
||||
return data; // Return the read data
|
||||
}
|
||||
|
||||
// Function to write to the COM port
|
||||
@@ -40,6 +46,12 @@ char io_read_lpt()
|
||||
// TODO: Read from the LPT port
|
||||
// Use the appropriate memory or I/O address to read from the port
|
||||
// Return the read data
|
||||
|
||||
char data = 0; // Initialize the variable to store the read data
|
||||
|
||||
// Read from the LPT port and assign the read value to the 'data' variable
|
||||
|
||||
return data; // Return the read data
|
||||
}
|
||||
|
||||
// Function to write to the LPT port
|
||||
|
@@ -1,6 +1,8 @@
|
||||
#ifndef IO_H
|
||||
#define IO_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
// Function to initialize the COM and LPT ports
|
||||
void io_init();
|
||||
|
||||
@@ -16,4 +18,9 @@ char io_read_lpt();
|
||||
// Function to write to the LPT port
|
||||
void io_write_lpt(char data);
|
||||
|
||||
// Function declarations for keyboard.c
|
||||
uint8_t inb(uint16_t port);
|
||||
void outb(uint16_t port, uint8_t data);
|
||||
void install_interrupt_handler(uint8_t interrupt, void (*handler)(void));
|
||||
|
||||
#endif /* IO_H */
|
Reference in New Issue
Block a user