added unlockDevice