Skip to content
This repository has been archived by the owner on Jan 27, 2021. It is now read-only.

Updated code snippet for checking whether bt is connected or not #63

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ if(!bt.isBluetoothAvailable()) {
```java
public void onStart() {
super.onStart();
if(!bt.isBluetoothEnable()) {
if(!bt.isBluetoothEnabled()) {
// Do somthing if bluetooth is disable
} else {
// Do something if bluetooth is already enable
Expand Down Expand Up @@ -121,7 +121,7 @@ startActivityForResult(intent, BluetoothState.REQUEST_CONNECT_DEVICE);

don't forget declare library activty like this
```java
<activity android:name="app.akexorcist.bluetoothspp.DeviceList" />
<activity android:name="app.akexorcist.bluetotohspp.library.DeviceList" />
```

• After intent to choose device activity and finish that activity. You need to check result data on onActivityResult
Expand Down