Reading Bluetooth device address returns zero (Known Issue)

From Nokia Developer Wiki
Jump to: navigation, search
Article Metadata
Tested with
Devices(s): All devices based on Symbian
Platform(s): Symbian, all
Platform Security
Capabilities: LocalServices
Keywords: KPropertyKeyBluetoothGetLocalDeviceAddress, TBTDevAddr
Created: User:Kbwiki (03 Jun 2010)
Last edited: hamishwillee (12 Mar 2012)


Trying to retrieve a Bluetooth Device Address returns zero (or NULL) if Bluetooth has never been used. This is apparent when using the *#2820# code, which will result in Bluetooth device address: without any value at all.

Also, the following code:

TBuf<20> bluetoothAddress;
TPckgBuf<TBTDevAddr> aDevAddrPckg;
KPropertyKeyBluetoothGetLocalDeviceAddress, aDevAddrPckg);
aDevAddrPckg().GetReadable(bluetoothAddress, KNullDesC, KNullDesC, KNullDesC);

will return 000000000000 as bluetoothAddress.

This can be problematic if using Bluetooth address for identifying a device.


If the returned value is zero, Bluetooth needs to be turned on at least once. After this, the value can be received, and it also persists when phone is turned off.

This page was last modified on 12 March 2012, at 08:45.
40 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.


Thank you!

We appreciate your feedback.