check_device_code
