Power Management Bluetooth on Windows Mobile platform

Has two standard API can to turn on/off your bluetooth module on Pocket PC.But the API is OEM optional implement method. So more PPC device can’t to support/use it.

ref. http://www.eggheadcafe.com/software/aspnet/29846486/widcommbroadcom-onoff.aspx

API declare

  • HRESULT OEMGetBthPowerState(DWORD* pdwState); // to get bluetooth power state
  • HRESULT OEMSetBthPowerState(DWORD dwState); // to set bluetooth power state
set dwState equal 0 is turn off, equal 1 is turn on
When your device use the Broadcom stack then it should has "BTFlightModeCtl.dll" in windows
or can to read following registry get a correct setting.
[HKLMSystemCurrentControlSetControlPowerBluetoothRadioOffOverride]
                    DLLName = "BTFlightModeCtl.dll"
in Application side may be can to try BthGetMode()/BthSetMode() 
please to visit http://msdn2.microsoft.com/en-us/library/aa455170.aspx has a demo code
廣告

發表迴響

在下方填入你的資料或按右方圖示以社群網站登入:

WordPress.com Logo

您的留言將使用 WordPress.com 帳號。 登出 / 變更 )

Twitter picture

您的留言將使用 Twitter 帳號。 登出 / 變更 )

Facebook照片

您的留言將使用 Facebook 帳號。 登出 / 變更 )

Google+ photo

您的留言將使用 Google+ 帳號。 登出 / 變更 )

連結到 %s

%d 位部落客按了讚: