Android device Id



如何在设备中重置出厂设置或更新操作系统的情况下获得Android手机的硬件唯一Id。我想获得唯一id,它在未来的任何事件中都不会更改,比如工厂重置或Os更新。

我认为这应该很有帮助:

@SuppressLint("HardwareIds")
String android_id = Settings.Secure.getString(getContentResolver(), Settings.Secure.ANDROID_ID);

您需要使用设备的wifi mac地址或buetooth地址。。。。它们在出厂重置后不会改变。。。。

最新更新