title: Inconsistent Android Bluetooth prompt during file download
body: <p>We are writing an application where a digital pen is paired with an android device, then the pen uploads a file to the Android device. We have inconsistent behaviour between different devices and would like a consistent solution. <strong>Ideally we would intercept the incoming file and manage the binary data within the application.</strong></p>
  
  <ul>
  <li>On a Galaxy S (2.2) and Galaxy Tablet (2.2), when a file was received via Bluetooth it would prompt the user to accept the file, but at that stage it includes a checkbox so that the file is automatically accepted from then on.</li>
  <li>On a HTC Desire (2.2) the user is prompted when the file is sent from the digital pen, but the user must manually accept the file each time one is sent. If the user doesn't accept in time then the file is lost.</li>
  </ul>
  
  <p>What we would like is consistent behaviour where the user does not need to manually accept each file.</p>
  
  <p>We have also tried several solutions such as</p>
  
  <ul>
  <li>listening for incoming files Bluetooth connections,</li>
  <li>implementing our own <code>BroadcastReceiver</code>, </li>
  <li>and attempting to get the Android device to act as a Bluetooth server and then manually intercept the file. (similar to the <a href="http://developer.android.com/resources/samples/BluetoothChat/index.html" rel="nofollow">BluetoothChat</a> sample application)</li>
  </ul>
  
  <p>... but without any luck. We are able to trigger an Activity from a Bluetooth intent, but it appears that the OBEX file transfer occurs at a lower level within the workings of the Android device and not able to be intercepted.</p>
  
  <p>We also have the issue that the standard Bluetooth/OBEX implementation writes to a different location depending on the vendor</p>
  
  <ul>
  <li><code>/mnt/sdcard/bluetooth</code> for Samsung</li>
  <li><code>/mnt/sdcard/Downloads/bluetooth</code> for HTC.</li>
  </ul>
  
  <p>... but this is a lesser problem and able to be managed via preferences.</p>