This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

BLE4.2 and iPhone 7 throughput, PDU, packets per event and conn interval

Hi, I can see that Apple states that iPhone 7 supports LE Data Packet Length Extension forums.developer.apple.com/.../73168. Anyone know if the packets per event and the connection interval is different on the iPhone7 ? I am trying to calculate the potential througput i can get from this iPhone model.

/donnib

  • Yes, it is different. And the behavior might change depending on the iOS version as well. This also depend on whether the peer support DLE or not.

    iPhone 7 iOS 10.0.3, peer Without DLE:
    ATT MTU size = 185 bytes.
    Didn't test max number of packets but it depends on the connection interval as well. The connection event has to be ended before the next connection evnt.

    iPhone 7 iOS 10 with DLE: PDU size: 251bytes, (2.12ms) ATT MTU size requested by iPhone:749 The maximum number of packets dependes on the connection interval and the capabilities of the peer.

    I did a quick test with the experimental ble_app_att_mtu_throughput example in the SDK and I could send three packets with 244byte of actual data, ATT MTU size:247bytes pdu size 251byte, 30ms connection interval. But I don't think this is optimized for iOS as it is a nRF52 to 52 example.

  • Hi, Thank you for your reply, if i connect with an nRF52 to an iPhone 7 then what can i theoretically expect, i am not sure i follow your data given above. Let's assume that i enable DLE on the nRF52 and i use the iPhone 7 with iOS10. I use 6 events per interval of 30ms (but this is where i don't know if i could go lower like 7,5ms, does iPhone7 support that do you know ?) and a payload size of 251bytes so theoretically the speed should be 6 * 251 * 1/0.030=50,2kB per second or 401kbps, is this correct ?

  • Connection interval depends on the master (= GAP Central) so are you concerned about iPhone being Central or Peripheral? You can try to change connection interval from Slave (GAP Peripheral) side but that has other limitations/delays... In general default connection interval when iPhone connects to BLE GAP Peripheral is 30ms.

  • iPhone is the master and the peripheral is my device which i develop.

  • You can actually keep the connection event open until just before the next event starts. So using a faster connection interval isn't necessarily better in this case. I think you should try to use longer interval when using DLE. Connection intervals of 7.5ms isn't supported by iOS, but it doesn't matter as you wouldn't be able to fit 6 * 251 byte in that short amount of time. Theoretically you should be able to get 600-700+ kbs, But I haven't tried to optimize that for iOS.

    Best thing would be to test it properly, but for calculations you need to consider the "RX time" + T_IFS + "tx time" + T_IFS, then repeat until you reach the connection interval.

Related