I'm working on an Android Bluetooth project to send and receive data from a custom made hardware. I used Bluetooth Chat Sample in SDK as basis.
I realized that there is no way to change baud rate on Client (Android phone) and baud rate will depend on hardware. I tried setting different baud rates on hardware and none met our expectations;
Fastest i can get is 91Kbps (when baud rate is set to 2.7Mbps ~ 910Kbps). Using minimum baud rate (115Kbps) i get 43Kbps. I tried using different phones and it's the same. I need to transfer 170KB data per second to hardware.
Specifications
Protocol: Synchronized or generated data is sent to hardware using packages of maximum 520 bytes size. Hardware sends verify command after each package recieved and approved then phone sends next data package.
Client: Android 2.3.3, Samsung galaxy w i8150, Bluetooth v3.0, RFCOMM
Hardware: Custom, Bluetooth v2.1 BlueGiga WT11i
I'm totally confused.. Can it possibly be a problem caused by Android or Bluetooth device on the phone? I wonder what the maximum baud rate is? Is there a way to speed up the transmission (like increasing maximum package size, or sending all packages without waiting for hardware verify commands).
Edit
After changing the package size to 4160 Bytes, Throughput has
increased to 254Kbps. I'm trying to figure out the optimum package
size to reach 1.5Mbps. I appreciate any suggestions
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…