AnsweredAssumed Answered

Example of using scanf() in an MQX task?

Question asked by David Pfaltzgraff on Aug 4, 2015
Latest reply on Aug 10, 2015 by David Pfaltzgraff

I would like to set up a task running under MQX that would "listen" for user input via the virtual COM port. Until the user inputs something, this task is to remain in the idle state.

 

Since scanf() likes to work on a string, I may need to use a variation of getc() and do my own character handling. But, I'd be OK with that as long as the task remains idle until input is available.

 

Is there a good example of this?

 

Thanks

Outcomes