reset the device, need to incorporate auto-detection