To place the UART into interrupt mode I modify the user_config.h file to get UART1 into interrupt mode:
#define BSPCFG_ENABLE_ITTYB 1
Make sure to recompile the build_libs.mcp for you particular build.
The attached io_main9.c is an evolution of the mqx\examples\io\main.c code base.
The terminal/console is using UART0/ttya in polled mode and UART1/ittyb is setup for interrupt mode.
So hardware wise connect UART0 and UART1 to two terminals with 115200,8,1,N settings.
Set a breakpoint at one of these lines:
err = _io_ioctl(fh_ptr, IO_IOCTL_SERIAL_GET_BAUD, &Old_Baud_rate); //Get Baud Rate from default to "Baud_rate"
printf("\nCurrent Baud Rate for alternate UART port is %d\n", Old_Baud_rate); //print to uart0
err = _io_ioctl(fh_ptr, IO_IOCTL_SERIAL_SET_BAUD, &New_Baud_rate); //Change/set Baud Rate from default to "Baud_rate"
Once you break, then change the UART1 terminal to 9600 before continuing. This was an example for customer to see how to use the IOCTL capability.
Note that when placing the UART into interrupt mode, the BSP initialization code is setting up a 64 byte fifo so that as the UART receives a character it shoves it into the fifo. When code wants a character it can check to see if byte is available (my code doesn't do this yet) or just ask for it and if available from fifo it will get it.
Regards,
David