search for: serial_on

Displaying 2 results from an estimated 2 matches for "serial_on".

2013 Jul 12
0
[PATCH 001/001] core/serial: Add support for serial output functions.
...< 7) + +/* If DLAB is set 0 in COM_LINE_CTRL_REG */ +#define COM_RX 0 /* Receiver */ +#define COM_TX 0 /* Transmitter */ + +/* If DLAB is set 1 in COM_LINE_CTRL_REG */ +#define COM_DIVREG_LOW 0 +#define COM_DIVREG_HIGH 1 + +typedef enum { + SERIAL_OFF, + SERIAL_ON, + SERIAL_DONT_EXIST, +} serial_state; + +extern int serial_puts(const char *); +extern int serial_print(const char *, ...); + +#endif \ No newline at end of file diff --git a/core/serial.c b/core/serial.c new file mode 100644 index 0000000..0fcbf31 --- /dev/null +++ b/core/serial.c @@ -0,0 +1,1...
2013 Jul 12
2
[PATCH 001/001] core/serial: Add support for serial output functions.
...#define COM_DLAB_BIT (1 << 7) + +/* If DLAB is set 0 in COM_LINE_CTRL_REG */ +#define COM_RX 0 /* Receiver */ +#define COM_TX 0 /* Transmitter */ + +/* If DLAB is set 1 in COM_LINE_CTRL_REG */ +#define COM_DIVREG_LOW 0 +#define COM_DIVREG_HIGH 1 + +typedef enum { + SERIAL_OFF, + SERIAL_ON, + SERIAL_DONT_EXIST, +} serial_state; + +extern int serial_puts(const char *); +extern int serial_print(const char *, ...); + +#endif \ No newline at end of file diff --git a/core/serial.c b/core/serial.c new file mode 100644 index 0000000..e2e5366 --- /dev/null +++ b/core/serial.c @@ -0,0 +1,1...