Probe input device type
Check if screencap command exists on device

If not, wait 3 seconds and try again.

This change avoid try to parse FB info from error
message of screencap command not found, and retry
immediately.