×
Namespaces

Variants
Actions

使用Power State API无法启动蓝牙的问题

From Nokia Developer Wiki
Jump to: navigation, search
Article Metadata

文章
huwell 在 13 Aug 2007 创建
最后由 hamishwillee 在 15 Dec 2011 编辑
  • 开发伙伴平台:

S60 3rd Edition,

S60 3rd Edition, FP1


  • 详细描述

头文件“btserversdkcrkeys.h”中包含了Central Repository keys,可用来控制蓝牙的启动。不过即使将开关状态设置为EBTPowerOn,但仍无法启动蓝牙(虽然可能已有图标标识它被激活)


  • 如何重现:
  CRepository* cenRep = CRepository::NewLC( KCRUidBluetoothPowerState );
 
TInt state, err = KErrNone;
 
cenRep->Get( KBTPowerState, state );
 
if( state == EBTPowerOff )
 
{
 
err = cenRep->Set( KBTPowerState, EBTPowerOn );
 
}
 
CleanupStack::PopAndDestroy(); // cenRep


  • 解决方案:

使用Bluetooth Notifier API来启动蓝牙

This page was last modified on 15 December 2011, at 13:23.
101 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.

×