Index: soft/giet_vm/giet_libs/stdio.c
===================================================================
--- soft/giet_vm/giet_libs/stdio.c	(revision 646)
+++ soft/giet_vm/giet_libs/stdio.c	(revision 647)
@@ -49,5 +49,5 @@
 
 //////////////////////////////////////////////////////////////////////////////
-///////////////////// Task context  system calls /////////////////////////////
+///////////////////// Task related  system calls /////////////////////////////
 //////////////////////////////////////////////////////////////////////////////
 
@@ -73,4 +73,45 @@
 }
 
+//////////////////////////////
+void giet_exit( char* string ) 
+{
+    sys_call( SYSCALL_EXIT,
+              (unsigned int)string,
+              0, 0, 0 );
+}
+
+/////////////////////////////////////////
+void giet_assert( unsigned int condition,
+                  char*        string )
+{
+    if ( condition == 0 ) giet_exit( string );
+}
+
+//////////////////////////
+void giet_context_switch() 
+{
+    sys_call( SYSCALL_CTX_SWITCH,
+              0, 0, 0, 0 );
+}
+
+//////////////////////////////////////////////////////////////////////////////
+///////////////////// Applications  system calls /////////////////////////////
+//////////////////////////////////////////////////////////////////////////////
+
+///////////////////////////////////////
+int giet_kill_application( char* name ) 
+{
+    return ( sys_call( SYSCALL_KILL_APP,
+                       (unsigned int)name,
+                       0, 0, 0 ) );
+}
+
+///////////////////////////////////////
+int giet_exec_application( char* name ) 
+{
+    return ( sys_call( SYSCALL_EXEC_APP,
+                       (unsigned int)name,
+                       0, 0, 0 ) );
+}
 
 //////////////////////////////////////////////////////////////////////////////
@@ -515,10 +556,12 @@
                     unsigned int bufsize ) 
 {
-    int           ret;
+    int           ret;                           // return value from syscalls
     unsigned char byte;
     unsigned int  index = 0;
+    unsigned int  string_cancel = 0x00082008;    // string containing BS/SPACE/BS
  
     while (index < (bufsize - 1)) 
     {
+        // get one character
         do 
         { 
@@ -526,5 +569,5 @@
                            (unsigned int)(&byte),
                            1,
-                           0xFFFFFFFF,
+                           0xFFFFFFFF,        // channel index from task context
                            0);
             if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
@@ -532,20 +575,46 @@
         while (ret != 1);
 
-        if (byte == 0x0A)  /* LF */
+        // analyse character
+        if (byte == 0x0A)                          // LF  special character
         {
             break; 
         }
-        else if ((byte == 0x7F) && (index > 0))  /* DEL */
-        {
-            index--; 
-        }
-        else 
+        else if ( (byte == 0x7F) ||                // DEL special character
+                  (byte == 0x08) )                 // BS  special character
+        {
+            if ( index > 0 )     
+            {
+                index--; 
+
+                // cancel character
+                ret = sys_call( SYSCALL_TTY_WRITE,
+                                (unsigned int)(&string_cancel),
+                                3,
+                                0XFFFFFFFF,        // channel index from task context
+                                0 );
+                if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
+            }
+        }
+        else if ( (byte < 0x20) || (byte > 0x7F) )  // non printable characters
+        {
+        }
+        else                                       // take all other characters
         {
             buf[index] = byte;
             index++;
+
+            // echo
+            ret = sys_call( SYSCALL_TTY_WRITE,
+                            (unsigned int)(&byte),
+                            1,
+                            0XFFFFFFFF,        // channel index from task context
+                            0 );
+            if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
+     
         }
     }
     buf[index] = 0;
-}
+
+}   // end giet_tty_gets()
 
 ///////////////////////////////////////
@@ -561,5 +630,4 @@
     unsigned int  length = 0;
     unsigned int  i;
-    unsigned int  channel = 0xFFFFFFFF;
     int           ret;      // return value from syscalls
  
@@ -573,5 +641,5 @@
                             (unsigned int)(&string_byte),
                             1,
-                            channel, 
+                            0xFFFFFFFF,    // channel index from task context
                             0); 
             if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
@@ -580,5 +648,5 @@
 
         // analyse character
-        if ((string_byte > 0x2F) && (string_byte < 0x3A))  /* decimal character */
+        if ((string_byte > 0x2F) && (string_byte < 0x3A))  // decimal character 
         {
             buf[length] = (unsigned char)string_byte;
@@ -589,14 +657,14 @@
                             (unsigned int)(&string_byte),
                             1, 
-                            channel, 
+                            0xFFFFFFFF,    // channel index from task context
                             0 );
-            if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
-        }
-        else if (string_byte == 0x0A)                     /* LF character */
+            if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
+        }
+        else if (string_byte == 0x0A)                     // LF character 
         {
             done = 1;
         }
-        else if ( (string_byte == 0x7F) ||                /* DEL character */
-                  (string_byte == 0x08) )                 /* BS  character */
+        else if ( (string_byte == 0x7F) ||                // DEL character
+                  (string_byte == 0x08) )                 // BS  character 
         {
             if ( length > 0 ) 
@@ -607,5 +675,5 @@
                                 (unsigned int)(&string_cancel),
                                 3, 
-                                channel, 
+                                0xFFFFFFFF,    // channel index from task context
                                 0 );
                 if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
@@ -646,5 +714,5 @@
                             (unsigned int)(&string_cancel),
                             3, 
-                            channel, 
+                            0xFFFFFFFF,    // channel index from task context
                             0 );
             if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
@@ -655,5 +723,5 @@
                         (unsigned int)(&string_byte),
                         1, 
-                        channel, 
+                        0xFFFFFFFF,    // channel index from task context
                         0 );
         if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
@@ -662,5 +730,5 @@
         *val = 0;
     }
-}
+}   // end giet_tty_getw()
 
 
@@ -999,42 +1067,4 @@
 ///////////////////// Miscellaneous system calls /////////////////////////////////
 //////////////////////////////////////////////////////////////////////////////////
-
-//////////////////////////////
-void giet_exit( char* string ) 
-{
-    sys_call( SYSCALL_EXIT,
-              (unsigned int)string,
-              0, 0, 0 );
-}
-
-//////////////////////////////
-void giet_kill( char* name ) 
-{
-    sys_call( SYSCALL_KILL_APP,
-              (unsigned int)name,
-              0, 0, 0 );
-}
-
-//////////////////////////////
-void giet_exec( char* name ) 
-{
-    sys_call( SYSCALL_EXIT,
-              (unsigned int)name,
-              0, 0, 0 );
-}
-
-/////////////////////////////////////////
-void giet_assert( unsigned int condition,
-                  char*        string )
-{
-    if ( condition == 0 ) giet_exit( string );
-}
-
-//////////////////////////
-void giet_context_switch() 
-{
-    sys_call( SYSCALL_CTX_SWITCH,
-              0, 0, 0, 0 );
-}
 
 /////////////////////////////////////////////////
Index: soft/giet_vm/giet_libs/stdio.h
===================================================================
--- soft/giet_vm/giet_libs/stdio.h	(revision 646)
+++ soft/giet_vm/giet_libs/stdio.h	(revision 647)
@@ -170,5 +170,5 @@
 
 //////////////////////////////////////////////////////////////////////////
-//                    Task context system calls
+//              Task related system calls
 //////////////////////////////////////////////////////////////////////////
 
@@ -178,4 +178,19 @@
 
 extern unsigned int giet_thread_id(); 
+
+extern void giet_exit( char* string );
+
+extern void giet_assert( unsigned int condition, 
+                         char*        string );
+
+extern void giet_context_switch();
+
+//////////////////////////////////////////////////////////////////////////
+//               Application related system calls
+//////////////////////////////////////////////////////////////////////////
+
+extern int giet_kill_application( char* name );
+
+extern int giet_exec_application( char* name );
 
 //////////////////////////////////////////////////////////////////////////
@@ -323,15 +338,4 @@
 //////////////////////////////////////////////////////////////////////////
 
-extern void giet_exit( char* string );
-
-extern void giet_kill( char* name );
-
-extern void giet_exec( char* name );
-
-extern void giet_assert( unsigned int condition, 
-                         char*        string );
-
-extern void giet_context_switch();
-
 extern void giet_procs_number( unsigned int* x_size,
                                unsigned int* y_size,
Index: soft/giet_vm/giet_libs/stdlib.c
===================================================================
--- soft/giet_vm/giet_libs/stdlib.c	(revision 646)
+++ soft/giet_vm/giet_libs/stdlib.c	(revision 647)
@@ -8,7 +8,6 @@
 #include <stdlib.h>
 
-///////////////////////////////////////////////////////////////////////////////////
+/////////////////////////
 int atoi(const char *str)
-///////////////////////////////////////////////////////////////////////////////////
 {
     int res  = 0; // Initialize result
@@ -31,7 +30,6 @@
 }
 
-///////////////////////////////////////////////////////////////////////////////////
+////////////////////////////
 double atof(const char *str)
-///////////////////////////////////////////////////////////////////////////////////
 {
     const char *pstr = str;
@@ -77,7 +75,6 @@
 }
 
-////////////////////////////////////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////////
 void * memcpy(void *_dst, const void * _src, unsigned int size) 
-////////////////////////////////////////////////////////////////////////////////////////
 {
     unsigned int * dst = _dst;
@@ -102,7 +99,6 @@
 }
 
-////////////////////////////////////////////////////////////////////////////////////////
+//////////////////////////////////////////////////////////
 inline void * memset(void * dst, int s, unsigned int size) 
-////////////////////////////////////////////////////////////////////////////////////////
 {
     char * a = (char *) dst;
@@ -114,4 +110,41 @@
 }
 
+///////////////////////////////////
+unsigned int strlen( char* string )
+{
+    unsigned int i = 0;
+    while ( string[i] != 0 ) i++;
+    return i;
+}
+
+///////////////////////////////
+unsigned int strcmp( char * s1,
+                     char * s2 )
+{
+    while (1)
+    {
+        if (*s1 != *s2) return 1;
+        if (*s1 == 0)   break;
+        s1++, s2++;
+    }
+    return 0;
+}
+
+/////////////////////////
+char* strcpy( char* dest, 
+              char* source )
+{
+    if (!dest || !source) return dest;
+
+    while (*source)
+    {
+        *(dest) = *(source);
+        dest++;
+        source++;
+    }
+    *dest = 0;
+    return dest;
+}
+
 // Local Variables:
 // tab-width: 4
Index: soft/giet_vm/giet_libs/stdlib.h
===================================================================
--- soft/giet_vm/giet_libs/stdlib.h	(revision 646)
+++ soft/giet_vm/giet_libs/stdlib.h	(revision 647)
@@ -10,5 +10,5 @@
 
 ////////////////////////////////////////////////////////////////////////////////////////
-// This function translate a character string to a signed integer.  
+// This function translates a character string to a signed integer.  
 // For a negative value, the first character must be a '-' (minus) character.
 ////////////////////////////////////////////////////////////////////////////////////////
@@ -39,4 +39,25 @@
                      unsigned int size );
 
+////////////////////////////////////////////////////////////////////////////////////////
+// This function returns the number of characters in a string.
+// The terminating NUL character is not taken into account.
+////////////////////////////////////////////////////////////////////////////////////////
+unsigned int strlen( char* string );
+
+////////////////////////////////////////////////////////////////////////////////////////
+// This function compare the two s1 & s2 strings.
+// It returns 0 if strings are identical (including the terminating NUL character).
+// It returns 1 if they are not. 
+////////////////////////////////////////////////////////////////////////////////////////
+unsigned int strcmp( char* s1,
+                     char* s2 );
+
+////////////////////////////////////////////////////////////////////////////////////////
+// This function copies the source string to the dest string.
+// It returns a pointer on the dest string.
+////////////////////////////////////////////////////////////////////////////////////////
+char* strcpy( char* dest,
+              char* source );
+
 #endif
 
