4.104.115
Last change
on this file since fe32208 was
fe32208,
checked in by Joel Sherrill <joel.sherrill@…>, on 04/05/10 at 17:06:57
|
2010-04-05 Thomas Znidar <t.znidar@…>
- ChangeLog?, Makefile.am, README, bsp_specs, configure.ac, gdb-init,
preinstall.am, clock/clock.c, console/console.c, console/debugio.c,
include/bsp.h, include/tm27.h, make/custom/mcf5225x.cfg,
start/start.S, startup/bspclean.c, startup/bspstart.c,
startup/init5225x.c, startup/linkcmds, timer/timer.c: New files.
|
-
Property mode set to
100644
|
File size:
917 bytes
|
Line | |
---|
1 | /* |
---|
2 | * Multi UART console serial I/O. |
---|
3 | * |
---|
4 | * TO DO: Add DMA input/output |
---|
5 | * |
---|
6 | * The license and distribution terms for this file may be |
---|
7 | * found in the file LICENSE in this distribution or at |
---|
8 | * http://www.rtems.com/license/LICENSE. |
---|
9 | * |
---|
10 | * $Id$ |
---|
11 | */ |
---|
12 | |
---|
13 | #include <stdio.h> |
---|
14 | #include <fcntl.h> |
---|
15 | #include <rtems/libio.h> |
---|
16 | #include <rtems/termiostypes.h> |
---|
17 | #include <termios.h> |
---|
18 | #include <bsp.h> |
---|
19 | #include <malloc.h> |
---|
20 | #include <rtems/mw_uid.h> |
---|
21 | |
---|
22 | #include <rtems/bspIo.h> |
---|
23 | |
---|
24 | static void _BSP_null_char(char c) |
---|
25 | { |
---|
26 | rtems_interrupt_level level=UART0_IRQ_LEVEL; |
---|
27 | |
---|
28 | if (c == '\n') |
---|
29 | _BSP_null_char('\r'); |
---|
30 | |
---|
31 | rtems_interrupt_disable(level); |
---|
32 | while ((MCF_UART_USR(CONSOLE_PORT) & MCF_UART_USR_TXRDY) == 0) |
---|
33 | continue; |
---|
34 | MCF_UART_UTB(CONSOLE_PORT) = c; |
---|
35 | while ((MCF_UART_USR(CONSOLE_PORT) & MCF_UART_USR_TXRDY) == 0) |
---|
36 | continue; |
---|
37 | rtems_interrupt_enable(level); |
---|
38 | } |
---|
39 | |
---|
40 | BSP_output_char_function_type BSP_output_char = _BSP_null_char; |
---|
Note: See
TracBrowser
for help on using the repository browser.