Pregunta

I'd like to know, whether Android-based phones with API level > 14 support Bluetooth Version 2.0 ? I am trying to print to a mobile printer named Fujitsu FTP-628WSL from a Sony XPeria S Phone with Android version 4.0.4. We're already successfully printing with a Samsung Galaxy SII (Android 2.3.x) to that printer. The Sony XPeria S prints successfully to a Bixolon SPP-R200 (which I think has BT Version 2.1 but I am not 100% sure... it's definitely newer than the Fujitsu by a couple of years) - could it be, that the Fujitsu's Bluetooth Version is simply not supported?

I already went through:

We're using secure RFComm connections for both printers. It is possible to pair the Fujitsu and connect to it, but it seems rather unstable to me and printing wont work with the following error message:

11-19 14:42:13.647: E/BluetoothService.cpp(329): stopDiscoveryNative: D-Bus error in StopDiscovery: org.bluez.Error.Failed (**Invalid discovery session**)
11-19 14:42:19.677: E/app.BluetoothConnection(14736): Failed to connect to rfcomm socket.Service discovery failed

I tried to find something about that "Invalid discovery session" - without success.

¿Fue útil?

Solución

Android added Bluetooth 2 support in API 5, and Bluetooth 4 LE in API ~14.

The version of Bluetooth supported by Android phones also depends phone model - different phones have different Bluetooth hardware and different Bluetooth stacks.

(Things got really weird with the Galaxy Nexus with 4.0.4. which had an API and hardware support for Bluetooth 4, but was missing the support in the stack - fortunately, that has been rectified with Android 4.2.)

In your case, your phone/stack/api will have no problem supporting Bluetooth 2, but what about the Bluetooth profile? Perhaps you are trying to use Bluetooth Printing Profile and maybe your device doesn't support that? Maybe you could connect to your phone with a PC and enumerate the supported profiles to see whether it has BPP (basic printing profile).

You should also verify whether which profile your printer supports - I'm just guessing with BPP.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top