Skip to content

Jira 870, Change sensortag_button.ino to use localName #465

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

Merged
merged 1 commit into from
Mar 7, 2017
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -43,23 +43,12 @@ void loop() {
Serial.print(peripheral.advertisedServiceUuid());
Serial.println();

/*see if peripheral is a SensorTag
The localName SensorTag is in the Scan Response data packet
In this release we do not have the feature that gets the scan response data and hence
the local name in the scan is blank
We have to explicitly find the BLE mac address
Please use another deviice like nrfConnect app to discover the Bluetooth Address
*/
//if (peripheral.localName() == "SensorTag") {


/******************************************************
* ATTENTION:
* Change to the mac address according to your device!
* Use a central app that can display the BT MAC address
* ******************************************************
*/
if (peripheral.address() == "68:C9:0B:06:BC:81") {
/* see if peripheral is a SensorTag
* The localName, CC2650 SensorTag, is in the Scan Response Data packet.
* If this is not the expected name, please change the following
* if-statement accordingly.
*/
if (peripheral.localName() == "CC2650 SensorTag") {
// stop scanning
BLE.stopScan();

Expand Down