Crate android_bluetooth_serial

Source
Expand description

Android API wrapper handling Bluetooth classic RFCOMM/SPP connection.

This crate is looking for maintainers!

TODO:

Structs§

BluetoothDevice
Corresponds to android.bluetooth.BluetoothDevice.
BluetoothSocket
Manages the Bluetooth socket and IO streams. It uses a read buffer and a background thread, because the timeout of the Java InputStream from the BluetoothSocket cannot be set. The read timeout defaults to 0 (it does not block).

Constants§

SPP_UUID
The UUID for the well-known SPP profile.

Functions§

get_bonded_devices
Gets a list of BluetoothDevice objects that are bonded (paired) to the adapter. is_enabled() is checked at first; returns an empty list if it is not enabled.
is_enabled
Return true if Bluetooth is currently enabled and ready for use. It may return an error of std::io::ErrorKind::PermissionDenied, or some other error.