Rev | Line | |
---|
[191] | 1 | #include "stdio.h" |
---|
| 2 | |
---|
| 3 | __attribute__((constructor)) void main() |
---|
| 4 | { |
---|
| 5 | unsigned int i; |
---|
| 6 | char byte; |
---|
| 7 | unsigned int proc = giet_procid(); |
---|
| 8 | |
---|
| 9 | for( i=0 ; i<1000 ; i++ ) |
---|
| 10 | { |
---|
| 11 | if( giet_tty_printf(" hello from processor %d\n", proc) ) |
---|
| 12 | { |
---|
| 13 | giet_tty_puts("echec tty_printf\n"); |
---|
| 14 | giet_exit(); |
---|
| 15 | } |
---|
| 16 | if( giet_tty_getc((void*)&byte) ) |
---|
| 17 | { |
---|
| 18 | giet_tty_puts("echec tty_getc_irq\n"); |
---|
| 19 | giet_exit(); |
---|
| 20 | } |
---|
| 21 | if ( byte == 'q' ) giet_exit(); |
---|
| 22 | } |
---|
| 23 | giet_exit(); |
---|
| 24 | |
---|
| 25 | } // end main |
---|
| 26 | |
---|
Note: See
TracBrowser
for help on using the repository browser.