wait for device