Sending data through USBUART | Cypress Semiconductor
Sending data through USBUART
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 = 0x01;
//buffer = 0x00;