cancel
Showing results for 
Search instead for 
Did you mean: 

Bluetooth SDK

ErVe_4649071
New Contributor II

Hello

How do I find the static MAC address of a bluetooth device?

I am using the CYBT-213043-MESH-02 kit but every time I upload a code it changes my MAC address.

Can anybody help me?

Thank you!

0 Likes
1 Solution
DheerajPK_41
Moderator
Moderator

Hi,

It is according to the spec.

"To decrease the complexity of deploying nodes, a unique Bluetooth BD_ADDR is not required for mesh operations. Instead, each node shall be assigned a 128-bit UUID known as the Device UUID. Device manufacturers shall follow the standard UUID format as defined in [8] and generation procedure to ensure the uniqueness of each Device UUID."

For executing PTS or similar testing, you can enable PTS macro in the makefile of each application.

If PTS is defined, then the device takes the UUID as local bda with 0x0f in the remaining bytes.

You can configure BT_DEVICE_ADDRESS also in the makefile. But please do not try to use BT_DEVICE_ADDRESS unless testing with PTS=1.

Thanks,

-Dheeraj

View solution in original post

0 Likes
3 Replies
DheerajPK_41
Moderator
Moderator

Hi,

It takes random address. All Mesh applications prints the UUID in the puart trace. You can use any mesh helper applications such as MeshClient, android/ios app, etc... to scan and find this address.

Please check the void mesh_application_init(void) in mesh_applicaion.c. (search for "UUID").

Thanks,

-Dheeraj

ErVe_4649071
New Contributor II

Thank you very much for your help Dheeraj.

I have some questions.

Why does it need to be a random address?

Could you get any address that is not random but can be detected by Android, IOS or Mesh Client applications?

Could you give me an example of how to save UUID in a variable?

I am a beginner in this environment and I still have doubts.

I hope you can help me.

Thank you

0 Likes
DheerajPK_41
Moderator
Moderator

Hi,

It is according to the spec.

"To decrease the complexity of deploying nodes, a unique Bluetooth BD_ADDR is not required for mesh operations. Instead, each node shall be assigned a 128-bit UUID known as the Device UUID. Device manufacturers shall follow the standard UUID format as defined in [8] and generation procedure to ensure the uniqueness of each Device UUID."

For executing PTS or similar testing, you can enable PTS macro in the makefile of each application.

If PTS is defined, then the device takes the UUID as local bda with 0x0f in the remaining bytes.

You can configure BT_DEVICE_ADDRESS also in the makefile. But please do not try to use BT_DEVICE_ADDRESS unless testing with PTS=1.

Thanks,

-Dheeraj

View solution in original post

0 Likes