How to detect missing connections?

I have an app that depends on the hardware-observe and raw-usb connections being made. But how can I detect if it’s connected in code?

Because right now my app just hangs, if the connection is missing.

Can I perhaps prevent the start of the app if not all connections are made?

Have a look at the documentation:

Thank you! How did I miss that…

1 Like