wait for device before doing backup/restore
fix #242
Merge pull request #246 from askeing/add_wait_before_backup_restore

wait for device before doing backup/restore