source:
soft/tp20/correction/main0.c
@
72
Last change on this file since 72 was 57, checked in by , 13 years ago | |
---|---|
File size: 457 bytes |
Rev | Line | |
---|---|---|
[57] | 1 | |
2 | #include "stdio.h" | |
3 | ||
4 | int main() | |
5 | { | |
6 | int i; | |
7 | char byte; | |
8 | ||
9 | for( i=0 ; i<1000 ; i++ ) | |
10 | { | |
11 | if( tty_printf( " hello from processor %d\n", procid() ) ) | |
12 | { | |
13 | tty_puts("echec tty_printf\n"); | |
14 | exit(); | |
15 | } | |
16 | if( tty_getc_irq((void*)&byte) ) | |
17 | { | |
18 | tty_puts("echec tty_getc_irq\n"); | |
19 | exit(); | |
20 | } | |
21 | if(byte == 'q') exit(); | |
22 | } | |
23 | ||
24 | exit(); | |
25 | ||
26 | return 0; | |
27 | } // end main | |
28 |
Note: See TracBrowser
for help on using the repository browser.