MOS Source Code
Loading...
Searching...
No Matches
console.h File Reference
+ Include dependency graph for console.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  console_t
 
struct  console_ops_t
 

Enumerations

enum  console_caps {
  CONSOLE_CAP_COLOR = 1 << 0 , CONSOLE_CAP_CLEAR = 1 << 1 , CONSOLE_CAP_GET_SIZE = 1 << 2 , CONSOLE_CAP_CURSOR_HIDE = 1 << 3 ,
  CONSOLE_CAP_CURSOR_MOVE = 1 << 4 , CONSOLE_CAP_EXTRA_SETUP = 1 << 5 , CONSOLE_CAP_READ = 1 << 6
}
 

Functions

__BEGIN_DECLS void console_register (console_t *con)
 
console_tconsole_get (const char *name)
 
console_tconsole_get_by_prefix (const char *prefix)
 
size_t console_write (console_t *con, const char *data, size_t size)
 
size_t console_write_color (console_t *con, const char *data, size_t size, standard_color_t fg, standard_color_t bg)
 
void console_putc (console_t *con, u8 c)
 

Variables

list_head consoles
 

Enumeration Type Documentation

◆ console_caps

Enumerator
CONSOLE_CAP_COLOR 
CONSOLE_CAP_CLEAR 
CONSOLE_CAP_GET_SIZE 
CONSOLE_CAP_CURSOR_HIDE 
CONSOLE_CAP_CURSOR_MOVE 
CONSOLE_CAP_EXTRA_SETUP 

extra setup required

CONSOLE_CAP_READ 

console supports read

Definition at line 13 of file console.h.

Function Documentation

◆ console_register()

__BEGIN_DECLS void console_register ( console_t * con)

Definition at line 71 of file console.c.

Referenced by limine_entry(), and platform_startup_early().

+ Here is the call graph for this function:

◆ console_get()

console_t * console_get ( const char * name)

Definition at line 101 of file console.c.

Referenced by MOS_SETUP().

+ Here is the call graph for this function:

◆ console_get_by_prefix()

console_t * console_get_by_prefix ( const char * prefix)

Definition at line 114 of file console.c.

Referenced by MOS_SETUP().

+ Here is the call graph for this function:

◆ console_write()

size_t console_write ( console_t * con,
const char * data,
size_t size )

Definition at line 124 of file console.c.

◆ console_write_color()

size_t console_write_color ( console_t * con,
const char * data,
size_t size,
standard_color_t fg,
standard_color_t bg )

Definition at line 132 of file console.c.

Referenced by print_to_console().

◆ console_putc()

void console_putc ( console_t * con,
u8 c )

Definition at line 148 of file console.c.

Referenced by serial_console_irq_handler().

+ Here is the call graph for this function:

Variable Documentation

◆ consoles

list_head consoles
extern

Definition at line 16 of file console.c.

Referenced by console_get(), console_get_by_prefix(), console_register(), and lvprintk().