I am trying to use the CIO console as a debug port. I can use printf to get messages to the console and I can read from the console, but any call to getchar() results in a block until a line is read from the CIO console. Is there a way to do a non-blocking read from stdin? Or is there a non-blocking way to tell if there is anything to be read (like kbhit for the old Borland compliers)?
I have not used the CIO console in CCS, but my first suggestion would be to try the "feof(stdin)" function to determine if the end of file has been reached. I suspect that for stdin, this may not work, but it might be worth a quick try.
Othewise, I would suggest reposting this question in the Development Tools forum, either in the CCS section, or in the Compiler section.
--Bobby