Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

General question: What devices were used for testing? #149

Open
amasuke55 opened this issue Aug 29, 2023 · 5 comments
Open

General question: What devices were used for testing? #149

amasuke55 opened this issue Aug 29, 2023 · 5 comments

Comments

@amasuke55
Copy link

Hello,

I am currently trying to use flutter_ble_peripheral with two devices: Samsung A72 and S20.
both can not seem to advertise data despite other apps like LightBlue stating that the phones should have that BLE feature.
No other app worked for testing, so I tried to use this but it also just does not advertise the data.
I have a feeling it might be the Samsung devices so it would be helpful to know what devices were used to test flutter_ble_peripheral.

@microgeniusz80
Copy link

microgeniusz80 commented Sep 3, 2023

I/BluetoothLeAdvertiser(15672): startAdvertising is called
I/BluetoothAdapter(15672): isLeEnabled(): ON
I/BluetoothLeAdvertiser(15672): startAdvertisingSet, calling package name = dev.steenbakker.flutter_ble_peripheral_example
I/BluetoothAdapter(15672): isLeEnabled(): ON
I/FlutterBlePeripheral(15672): onStartSuccess() mode: 2, txPOWER 1
I/BLE Peripheral state (15672): advertising
I/BluetoothLeAdvertiser(15672): stopAdvertising is called
I/BluetoothLeAdvertiser(15672): stopAdvertisingSet, calling package name = dev.steenbakker.flutter_ble_peripheral_example
V/AudioManager(15672): querySoundEffectsEnabled...
I/BluetoothLeAdvertiser(15672): stopAdvertising is called

does it appear like this in your debug console? as soon as advertising started, stop advertising is called.
tested on both Samsung A52, and Samsung S23 Ultra.... not working

feel free to contact me at [email protected] so that we can discuss this further. thank you.

@amasuke55
Copy link
Author

amasuke55 commented Sep 4, 2023

For me it looks similar - like this when I try to Start advertising with the example code:

4 I/BluetoothAdapter( 9136): STATE_ON

D/BluetoothLeAdvertiser( 9136): onAdvertisingSetStarted(0, -15, 0)

I/FlutterBlePeripheral( 9136): onStartSuccess() mode: 2, txPOWER 1

I/BLE Peripheral state ( 9136): advertising

2 I/BluetoothAdapter( 9136): STATE_ON

D/BluetoothLeAdvertiser( 9136): Stop AdvertingSet

D/BluetoothLeAdvertiser( 9136): onAdvertisingSetStopped(0)```

@microgeniusz80
Copy link

so obviously, something is stopping the advertisement, as soon as advertisement started...

For me it looks similar - like this when I try to Start advertising with the example code:

4 I/BluetoothAdapter( 9136): STATE_ON

D/BluetoothLeAdvertiser( 9136): onAdvertisingSetStarted(0, -15, 0)

I/FlutterBlePeripheral( 9136): onStartSuccess() mode: 2, txPOWER 1

I/BLE Peripheral state ( 9136): advertising

2 I/BluetoothAdapter( 9136): STATE_ON

D/BluetoothLeAdvertiser( 9136): Stop AdvertingSet

D/BluetoothLeAdvertiser( 9136): onAdvertisingSetStopped(0)```

@Secret29
Copy link

I have the same issue!

/BluetoothLeAdvertiser( 5681): Start AdvertisingSet
D/BluetoothLeAdvertiser( 5681): onAdvertisingSetStarted(1, -15, 0)
I/FlutterBlePeripheral( 5681): onStartSuccess() mode: 2, txPOWER 1
I/BLE Peripheral state ( 5681): advertising
I/BluetoothAdapter( 5681): STATE_ON
I/BluetoothAdapter( 5681): STATE_ON
D/BluetoothLeAdvertiser( 5681): Stop AdvertingSet
D/BluetoothLeAdvertiser( 5681): onAdvertisingSetStopped(1)

@Secret29
Copy link

I resolved the issue by setting the timeout to 0.
AdvertiseSettings({
this.connectable = false,
this.timeout = 0,
this.advertiseMode = AdvertiseMode.advertiseModeLowLatency,
this.txPowerLevel = AdvertiseTxPower.advertiseTxPowerLow,
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants