Java 类android.bluetooth.BluetoothAssignedNumbers 实例源码

项目:Linphone4Android    文件:BluetoothManager.java   
public void initBluetooth() {
    if (!ensureInit()) {
        Log.w("[Bluetooth] Manager tried to init bluetooth but LinphoneService not ready yet...");
        return;
    }

    IntentFilter filter = new IntentFilter();
    filter.addCategory(BluetoothHeadset.VENDOR_SPECIFIC_HEADSET_EVENT_COMPANY_ID_CATEGORY + "." + BluetoothAssignedNumbers.PLANTRONICS);
    filter.addAction(AudioManager.ACTION_SCO_AUDIO_STATE_UPDATED);
    filter.addAction(BluetoothAdapter.ACTION_CONNECTION_STATE_CHANGED);
    filter.addAction(BluetoothHeadset.ACTION_VENDOR_SPECIFIC_HEADSET_EVENT);
    mContext.registerReceiver(this,  filter);
    Log.d("[Bluetooth] Receiver started");

    startBluetooth();
}