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

Identify BLE device #171

Open
andresp opened this issue Dec 11, 2023 · 3 comments
Open

Identify BLE device #171

andresp opened this issue Dec 11, 2023 · 3 comments

Comments

@andresp
Copy link

andresp commented Dec 11, 2023

I've been flashing a bunch of b-parasites in bulk and was wondering if there is a quick way to read out the BLE MAC?

As a feature request I would suggest implementing an "identify" command that makes the led flash, if that's possible through BT-Home. This could be helpful when provisioning and locating sensors.

@rbaron
Copy link
Owner

rbaron commented Dec 12, 2023

Hey @andresp,

In the ble sample, the MAC address is printed via RTT logging on first boot. This is what I use to check the MAC address. You can also choose your own MAC address via compilation flags.

The identify service is a good idea. The only issue is that currently, to squeeze the battery life to the max, we only advertise for a bit and shut the radio off completely. For an identify service, we'd need to advertise more often and also advertise more non-sensor data, which also consumes extra battery. As most people additionally use a case, the LED is not usually visible for the most part of its operation. I would be fine leaving this behind a config flag, off by default, or having a timer for 10-30 minutes in which the service is active. If someone wants to take a stab at it, I'm happy to review it.

@Nerdboy2
Copy link

Nerdboy2 commented Mar 7, 2024

I do it with the nRF Connect phone app.
I just start a scan in the phone while the sensor is flashing and when it starts to operate the phone/app will pick it up and show the MAC.
Super simple. Altough the RTT works aswell

@fabian727
Copy link

there is a button on the device. I didn't go deep into the code. Couldn't it be used to wake up the board and send the MAC?

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

4 participants