How it works
- Pick the device; it is found by its Windows id, or by its name when the routine came from another PC.
- Use it in an If to branch, or in a Wait until to pause until the device connects.
- Waiting doesn't keep checking over and over: KeyRoutines listens for Windows' device change messages and continues when the device appears.
Routines that use it
Pick the right output
In a gaming routine, if the headset is connected use Set default audio device on it, otherwise switch to the speakers.
Wait for a Bluetooth headset
After turning Bluetooth on with Wi-Fi or Bluetooth on/off, wait until the headset is connected before switching audio to it.
Skip a call setup
Only run the Discord: input device step when the USB microphone is connected, so the routine doesn't fail without it.
Questions
- Can a routine wait until my Bluetooth headphones connect?
- Yes. Put Audio device connected in a Wait until, optionally with a time limit. The routine continues as soon as Windows reports the headset.
- Will it find my headset on a different PC?
- It looks for the device by id first and then by name. A routine imported from another PC still matches a device with the same name.