cancel
Showing results for 
Search instead for 
Did you mean: 

Code Examples

Employee

This example was not working for me. I was not able to set the time.

I'm not sure this was due to some setting of my Teraterm.

Anyway, to make it work I had to do this change:

        rslt = cyhal_uart_getc(&cy_retarget_io_uart_obj, &ch, UART_TIMEOUT_MS);

        if(rslt != CY_RSLT_ERR_CSP_UART_GETC_TIMEOUT)

        { 

        if(ch == '\r')  /// changed, it was  if(ch == '\n')

            {

                break;

            }

//////////////////////////////

I also don't see printed on screen what I type while setting the time: for this, I had to add:

printf("%c",ch); fflush(stdout);

0 Likes
Reply
0 Replies
Top labels