Changes between Version 3 and Version 4 of library_stdio
- Timestamp:
- Aug 6, 2014, 3:52:26 PM (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
library_stdio
v3 v4 3 3 The [source:soft/giet_vm/giet_libs/stdio.c stdio.c] and [source:soft/giet_vm/giet_libs/stdio.h stdio.h] files contains all system calls provided to user applications by the GIET-VM. They are generally prefixed by ''giet_''. 4 4 5 == Processor protected register==5 == __1) Access to processor protected register__ == 6 6 7 7 * '''int giet_procid()''' … … 16 16 cycle count and the processor index. This value is comprised between 0 & 65535. 17 17 18 == Informations stored in the running task context==18 == __2) Informations stored in the running task context__ == 19 19 20 20 * '''int giet_proc_task_id()'''; … … 28 28 This functions returns the thread index, identiying the task in a given vspace. 29 29 30 == TTY terminal access==30 == __3) Access to TTY terminal__ == 31 31 32 32 * '''void giet_tty_printf( char* format, ... )''' 33 This function print formated text on a private terminal that must have been allocated to the calling task in the mapping (''use_tty'' argument). Therefore, it does not take the TTY lock. 33 This function print formated text on a private terminal that must have been allocated to the calling task in the mapping (''use_tty'' argument). Therefore, it does not take the TTY lock. In case or error, it makes a giet_exit(). 34 34 35 Only a limited number of formats are supported: 35 36 * %d : signed decimal … … 39 40 * %c : char 40 41 * %s : string 41 In case or error, it makes a giet_exit().42 42 43 43 * '''void giet_shr_printf( char* format, ... )''' 44 44 This function print formated text on the shared terminal arbitrarily allocated by the kernel, taking the TTY lock 45 for exclusive access. It supports the same formats as the giet_tty_printf() function. 46 In case or error, it makes a giet_exit(). 45 for exclusive access. It supports the same formats as the giet_tty_printf() function. In case or error, it makes a giet_exit(). 47 46 48 47 * '''void giet_tty_getc( char* byte ) 49 This blocking function fetches a single character from the private terminal that must have been allocated to the calling task in the application mapping. It uses the TTY_RX_IRQ interrupt, and the associated kernel buffer. 50 In case or error, it makes a giet_exit(). 48 This blocking function fetches a single character from the private terminal that must have been allocated to the calling task in the application mapping. It uses the TTY_RX_IRQ interrupt, and the associated kernel buffer. In case or error, it makes a giet_exit(). 51 49 52 50 * '''void giet_tty_getw( unsigned int* val )'''