Detect multiple devices

Allows the detection of multiple devices. Still uses the first found if
only deploying, waits for a USB-connected device if trying to start a
debug session. Commands with a “static” device ID will ignore the
previous logic.