Well, scanf now works fine. I can read signed int, hex and float. :-) But every received sign is echoed by scanf.
while(1) { printf("Enter your personal secret Hex-key!\n"); if (scanf("%X",&A)) break; scanf("%*"); //Clearing scanf input stream }
"But every received sign is echoed by scanf" No it isn't - it's echoed by getchar: http://www.keil.com/support/man/docs/c51/c51_getchar.htm As suggested in your previous post, you should really read the stuff into your own buffer, and then use sscanf on that! http://www.keil.com/forum/docs/thread7600.asp