public class BluetoothNatives extends Object
| Modifier and Type | Method and Description |
|---|---|
static boolean |
addService(byte[] service,
short[] handles) |
static boolean |
connect(byte[] deviceAddress) |
static void |
disable() |
static boolean |
disconnect(short connHandle) |
static boolean |
discoverServices(short connHandle,
byte[] uuid) |
static boolean |
enable() |
static boolean |
sendExecuteWriteResponse(short connHandle,
short attributeHandle,
byte status) |
static boolean |
sendNotification(short connHandle,
short attributeHandle,
byte[] value,
int valueSize,
boolean confirm) |
static boolean |
sendPairRequest(short connHandle) |
static boolean |
sendPairResponse(short connHandle,
boolean accept) |
static boolean |
sendPasskeyResponse(short connHandle,
boolean accept,
int passkey) |
static boolean |
sendPrepareWriteResponse(short connHandle,
short attributeHandle,
byte status,
byte[] value,
int valueSize,
int offset) |
static boolean |
sendReadRequest(short connHandle,
short attributeHandle) |
static boolean |
sendReadResponse(short connHandle,
short attributeHandle,
byte status,
byte[] value,
int valueSize) |
static boolean |
sendWriteRequest(short connHandle,
short attributeHandle,
byte[] value,
int valueSize,
boolean noResponse) |
static boolean |
sendWriteResponse(short connHandle,
short attributeHandle,
byte status) |
static boolean |
startAdvertising(byte[] advertisementData,
int advertisementDataSize) |
static boolean |
startScanning(byte filterAction,
byte filterType,
byte[] filterData,
int filterDataSize) |
static boolean |
stopAdvertising() |
static boolean |
stopScanning() |
static int |
waitEvent(byte[] buffer,
int bufferLength) |
public static boolean addService(byte[] service,
short[] handles)
public static boolean connect(byte[] deviceAddress)
public static void disable()
public static boolean disconnect(short connHandle)
public static boolean discoverServices(short connHandle,
@Nullable
byte[] uuid)
public static boolean enable()
public static boolean sendExecuteWriteResponse(short connHandle,
short attributeHandle,
byte status)
public static boolean sendNotification(short connHandle,
short attributeHandle,
byte[] value,
int valueSize,
boolean confirm)
public static boolean sendPairRequest(short connHandle)
public static boolean sendPairResponse(short connHandle,
boolean accept)
public static boolean sendPasskeyResponse(short connHandle,
boolean accept,
int passkey)
public static boolean sendPrepareWriteResponse(short connHandle,
short attributeHandle,
byte status,
byte[] value,
int valueSize,
int offset)
public static boolean sendReadRequest(short connHandle,
short attributeHandle)
public static boolean sendReadResponse(short connHandle,
short attributeHandle,
byte status,
byte[] value,
int valueSize)
public static boolean sendWriteRequest(short connHandle,
short attributeHandle,
byte[] value,
int valueSize,
boolean noResponse)
public static boolean sendWriteResponse(short connHandle,
short attributeHandle,
byte status)
public static boolean startAdvertising(byte[] advertisementData,
int advertisementDataSize)
public static boolean startScanning(byte filterAction,
byte filterType,
byte[] filterData,
int filterDataSize)
public static boolean stopAdvertising()
public static boolean stopScanning()
public static int waitEvent(byte[] buffer,
int bufferLength)