Hi Dialog,
我有一个问题U.
I want to send a file from mobile to DA14585.
If I set max_mtu of DA14585 to 255, and every time the app sends 240 bytes to DA14585 until the file has been transmitted.
The connection interval is 40ms, I am not sure how many packets (maybe 6?) per connection interval.
Each packet contains 20 bytes, right?
6 packets * 20 bytes = 120 bytes, so 240 bytes should be sent about 80 ms, is that true?
I use a debug pin to estimate, we find that DA14585 receives 240 bytes data just about every 40 ms, why?
Thanks.
Keywords:
Device:
嗨stanley_yeh,
If you increase the max mtu then the device will send 20 bytes of payload at the first packet and then all susequent packets to the same characteristic will have 27 bytes of payload. The number of packets send depends on the central, he is responsible if he will receive the packet from the peripheral and if the peripheral will send an additional packet. For example if the peripheral has more data to send that means that it will send a packet with MD bit set to 1, but the central might ignore this bit and wont transmit in order for the peripheral to send an additional packet. If you receive more data than you expect that most probably means that you are using the DLE feature which allows you to carry more data in each packet, since you use the 585.
Thanks MT_dialog
Thank you so much!