Part Number: CC2640R2F
Other Parts Discussed in Thread: CC1310, CC2640
Tool/software: TI-RTOS
Hello,
I'm working on two CC2640 Launchpad and following the simple_serial_socket_server and simple_serial_socket_client code. I tested the demo mentioned in Git and could use a CC1310 to send data packet to the client through UART. The data packet is 204 bytes long with a packet label number in the head. The data rate is about 6.4k Bytes/s and Baud rate is set to be 115200. Due to large data stream, I set the ringbuffer size to be 204 which is my packet length. The first half of the data is increasing numbers and the second half of data is decreasing numbers which shows below:
I have tested the CC1310 directly connected to PC and there is no packet loss. However, when I connected to my CC2640 client, there will be packet loss on my PC which is connected to the server:
The third column is packet number.
I tried to change the ringbuffer size which didn't help. And if change ring buffer size to be very large (2040 and 1020), I would get nothing on my server end. During experiment, red and green LED are always on which indicated noitying was enabled.
1. Could you please tell me, what would be the possible reason of this packet loss? Is it due to high UART data rate or notifying?
2. In your git readme, you mentioned that"If the amount of data sent over UART to the device exceeds UART_MAX_READ_SIZE plus the size of the ring buffer, data loss is probable. This is due to the internal UART ring buffer wrapping before the application has the chance to process the previous UART buffer. To be able to handle larger chunks of data, the size of the ring buffer can be increased inside the board file."
Why I could not get any data if I set it to a large number?
Thank you so much!