5 Replies Latest reply on Dec 11, 2015 2:35 AM by user_429452331

    Sending data through USBUART

    ammarshamim_1514511

      Hello,

         

      I'm trying to use USB to get the data from PC into this board. On the PC I'm using putty to send and receive data. The code works fine when the pc sends data and receives back the same data through an array. But when I try to send back my own data by adding a new value in the array it doesn't give me a received value on the putty (i.e. on PC). can someone help me out with this problem. 

         

      My aim is to receive a value from PC, do some arithmetic on it and then send it back to the PC. That is why I'm trying to alter the values in the array.

         

                          while(USBUART_1_CDCIsReady() == 0u);    /* Wait till component is ready to send more data to the PC */ 
                          buffer[0] = 0x01;
                          //buffer[1] = 0x00;
                          USBUART_1_PutData(buffer, count);