Skip to content

Commit 0e36522

Browse files
committed
Set name during pairing (without nick)
1 parent 16b9cfd commit 0e36522

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Firmware/BlueSMiRF-v2/Bluetooth.ino

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -703,6 +703,12 @@ void becomeDiscoverable()
703703

704704
bluetoothSerial->end();
705705

706+
char broadcastNamePairing[50] = "";
707+
708+
// During discovery, broadcast as 'BlueSMiRF-BC61-Pairing', regardless of nickname setting
709+
snprintf(broadcastNamePairing, sizeof(broadcastNamePairing), "BlueSMiRF-%02X%02X-Pairing", btMACAddress[4],
710+
btMACAddress[5]);
711+
706712
// Move to passive mode with buffers
707713
bluetoothSetBroadcastName(broadcastNamePairing);
708714

0 commit comments

Comments
 (0)