Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

Check Bluetooth power on/off in Symbian 2nd edition phones

From Wiki
Jump to: navigation, search
Article Metadata
Created: giridharn (21 May 2007)
Last edited: hamishwillee (20 Jul 2012)

To Check Bluetooth Power On or Off

Headers required:

#include <SettingInfo.h>  // CSettingInfo

Library required:

LIBRARY PlatformEnv.lib  //CSettingInfo

Source file:

// Using class should derive MSettingInfoObserver. 
// and declare void HandleNotificationL(
// SettingInfo::TSettingID aID, const TDesC &aNewValue);
//iSettingInfo is of type CSettingInfo*
iSettingInfo = CSettingInfo::NewL( this );
TInt btMode = -1;
TInt err = iSettingInfo->Get( SettingInfo::EBluetoothPowerMode, btMode );
TBuf<30> errBuf;
// EBluetoothPowerMode : Current bluetooth power mode.
// Integer value. Possible values
// 0 (unpowered/sleeping)
// 1 (powered up and fully functional)
//Order notifications when bluetooth power mode is changed
err = iSettingInfo.NotifyChanges( SettingInfo::EBluetoothPowerMode );
//Changed states can be get from HandleNotificationL();

Related Links

This page was last modified on 20 July 2012, at 07:48.
36 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.