10 posts / 0 new
Last post
Clonimus74
Offline
Last seen:3 years 5 months ago
加入:2015-04-13 10:35
DSPS Dropped packets

Hi,

I use the following setup with DSPS:

M3 MCU >> UART + HW Flow control >> DA14580-01 DSPS Device >> BLE >> DA14580-01 DSPS Host (ZY daughter board with P2ML3078 eval board) >> FTDI (of the eval board) >> PC -win7

I send 901bytes every 128msec, which is close to the defined max throughput of the DSPS, from the M3 and expect to get them in the PC, but I get about 1-2 lost packets per minute.

What can I do in order to overcome this?

Thank you

Keywords:
Device:
Clonimus74
Offline
Last seen:3 years 5 months ago
加入:2015-04-13 10:35
No one has any ideas?

No one has any ideas?

MT_dialog
Offline
Last seen:6 days 12 hours ago
Staff
加入:2015-06-08 11:34
Hi Clonimus,

Hi Clonimus,

Do you use a sniffer in order to track the lost packets?

Do you have a capture from an analyser in order to track and compare the activity in the uart and the air activity of the ble ?

Thanks MT_dialog

Clonimus74
Offline
Last seen:3 years 5 months ago
加入:2015-04-13 10:35
No,

No,
My application can send the data via UART or USB-FS.
I send static data and verify the correct data is received.
Using USB I have no problems, my M3 application executes exactly the same up to the point of choosing USB or BLE.
I can see the data transmit correctly if I connect the UART from M3 to FTDI instead of BLE.
So I'm positive that the problem is that every now and then there's a loss of data (I wasn't accurate before, it's not a full packet that gets lost it's a few bytes once or twice every second, so the packet is invalid and the parser drops it) at the BLE side.
I'm not sure if the problem is in the transmitting BLE or receiving BLE.
I tried changing the TX_BUFFER_ITEM_COUNT & RX_BUFFER_ITEM_COUNT sizes but when I do the devices either not connect, or the initial short command (5 bytes) is not sent.

MT_dialog
Offline
Last seen:6 days 12 hours ago
Staff
加入:2015-06-08 11:34
Hi Clonimus74,

Hi Clonimus74,

The only suggestion i cant give you is to try and reduce the data rate and see what happens.速度的限制DSPS application, but if we dont have some data in order to examine we can't imagine where the probelm could be. The application should send the data without any modifications.

Thanks MT_dialog

Clonimus74
Offline
Last seen:3 years 5 months ago
加入:2015-04-13 10:35
Sorry, I don't understand.

Sorry, I don't understand.
sending data is slower rates is not a problem (as when I send my command data from the PC to the dvice ~5-6 bytes).
I need to be able to send the raw data fro the device to the PC.
What do you mean by "The application should send the data without any modifications"?, The problem exists when I use the device and host DSPS as is without modifications.

MT_dialog
Offline
Last seen:6 days 12 hours ago
Staff
加入:2015-06-08 11:34
Hi Clonimus74,

Hi Clonimus74,

What i meant is that the DSPS application should be able to send data with the rate you are trying to send, so in order to have a better look at the problem we must have an inner site to the UART and to the BLE connection in order to see why there are missing data, otherwise we cant guess why this is happening.

Thanks MT_dialog

MT_dialog
Offline
Last seen:6 days 12 hours ago
Staff
加入:2015-06-08 11:34
Hi Clonimus74,

Hi Clonimus74,

Can you please remove the sleep and check again for missing data?

Thanks MT_dialog

liyang
Offline
Last seen:3 months 3 weeks ago
Expert
加入:2014-09-24 11:51
How far between the master

How far between the master device and the slave device? The same plan like u,but the distance only less than 1m,oh my god ,that makes me in trouble

klim9531
Offline
Last seen:4 years 3 months ago
加入:2015-01-28 23:52
Hi Liyang,

Hi Clonimus,

Is there any chance that you have defined CFG_UART_SW_FLOW_CTRL in the da14580_config.h file? If so then a data value of 0x11 would be interpreted as 'XON' and the effect would be to remove that byte from the data stream. However, this is probably not the cause of your problem because if it were, then a data value of 0x13 would cause data transfer to stop completely, for a LONG time (until a value of 0x11 was received).

But maybe it would help if you can somehow look at the exact value of the data that is getting lost and see if there is any consistency to the value, or if it is just random byte values.

Hope this helps, klim