The APIs in the Windows.Phone.Media.Devices namespace require the ID_CAP_AUDIOROUTING and the ID_CAP_VOIP capability. (Add this to your manifest)
Also, it's only possible to change the audio routing while in a active VOIP call.
Additionally, you need to do the audio routing in your background VOIP process, and not in the foreground process.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…