ensure a deviceID exists