next up previous contents index
Next: 13.13.3 base_cooked_termios: Default termios Up: (X86 PC) Base Environment: Previous: 13.13.1 base_console.h: definitions for

13.13.2 base_console_init: Initialize the base console

   

SYNOPSIS

#include <oskit/x86/base_console.h>

void base_console_init(int argc, char **argv);

DESCRIPTION

This function parses the multiboot command line and optionally initializes the serial lines.

Command line options recognized by the base_console code include:

-f
Enables ``fast'' serial ports. Sets the baud rate of the console and GDB serial ports to 115200.
-h
Enables a serial line console on cons_com_port.
-d
Enables remote GDB on gdb_com_port.

Environment variables recognized include:

CONS_COM
Serial port number (1, 2, 3 or 4) to use as the console. Sets cons_com_port to this value and sets serial_console non-zero.
GDB_COM
Serial port number (1, 2, 3 or 4) to use as the remote GDB interface. Sets gdb_com_port to this value and sets enable_gdb non-zero.
BAUD
Baud rate to use for both the console and GDB serial ports. Any of the standard values in termios.h (section 12.4.30) are valid.

PARAMETERS

argc
Count of command line arguments in argv.
argv
Vector of command line arguments.

DEPENDENCIES

getenv
12.4.17
atoi
12.4.17
base_cooked_termios
13.13.3
base_raw_termios
13.13.4
strcmp
12.4.18
printf
12.6
base_gdt_load
13.7.3
base_critical_enter
13.2.5
base_critical_leave
13.2.5
com_cons_init
13.13.8
com_cons_flush
13.13.11
com_cons_getchar
13.13.9
com_cons_putchar
13.13.10
gdb_pc_com_init
13.18.9
gdb_serial_getchar
13.18.4
gdb_serial_putchar
13.18.5
gdb_serial_puts
13.18.6
gdb_serial_exit
13.18.3
direct_cons_getchar
13.13.5
direct_cons_putchar
13.13.6



Utah Flux Research Group