detect failure while calling setupDevice()