Hello:

I wanted to share an issue I noticed when I was using linux/bluez and 
associated tools with the mynewt blehci controller on the nordic dev boards. 
There is a command called LE Read Buffer Size. This command tells the host the 
size of the ACL data packets (HC_LE_ACL_Data_Packet_Length). By default, the 
Mynewt controller sets this to 255. It appears that this size is too large if 
you use the tty that comes up when you plug in the board using usb to the usb 
connector on the dev boards. I had to drop the ACL data packet length down to 
27 to make it work reliably. I did not try other values in between to determine 
the maximum size; I noticed that 27 worked fine with other controllers so just 
used that same value with the Mynewt controller.

To change this value you have to go to syscfg.yml in net/nimble/transport/uart. 
Here is the config variable you need to change. Of course, you can change this 
value using your target or app. 

    BLE_ACL_BUF_SIZE:
        description: >
            This is the maximum size of the data portion of HCI ACL data
            packets. It does not include the HCI data header (of 4 bytes).
        value: 255

NOTE: if you use a usb to serial cable and hook it up to the board using the 
‘pins’ on the dev board (attach all the flow control lines!) you can use larger 
ACL data packet sizes. While I did not test this specifically with l2test, a 
colleague said this seems to work fine; it is only when using the usb connector 
and the associated tty that things seem to hang.

Enjoy!

Reply via email to