10 Replies Latest reply on Apr 25, 2017 1:00 AM by anks

    USBUART not always read from PC

    dzuy_1446756

      We have a PSoC5 MCU with USBUART (CDC) enabled.

         

      Tested that PSoC can talk to PC and vice versa.  We have a process on the PC that listens on its USB port and can receive everything the PSoC sends.  Problem is, the PSoC doesn't always get data from the PC.  We had to send multiple times and one of those times, it would get it.

         

      In our main.c, we start and init USBUART.  The code basically has 2 functions: poll for data from PC and do something else.  In the PC polling function, we have

         

       if (0u != USBUART_DataIsReady()){

         

          // process data

         

      }

         

      I assume when the PC sends the data, the USBUART_DataIsReady() API should return true, but in this case, not all the time.