0

I was wondering if it was possible to write an input loop in C where I do not need to hit ENTER key to send input for processing : as soon as input is entered, the system catches the keyboard entry. Please how can I achieve this?

The reasoning behind this is I am trying to code a finite state machine that receives a sequence of integer inputs and validates these inputs in an order and if a wrong input is entered, it cries out that an error has occurred, and these input are validated till the last expected digit is entered. Please help

i_use_the_internet
  • 604
  • 1
  • 9
  • 28
  • 1
    You can use what a keylogger uses. Reading from the device itself directly. But that's a little to complicated for normal projects. – Haris Apr 05 '16 at 17:24
  • The comp.lang.c FAQ has also something to say about this. – Jens Apr 05 '16 at 17:28

0 Answers0