title: Device ID Giving null Value
body: <p>I am trying to get Unique ID<code>[I.E unique id of a device]</code> by using below code</p>
  
  <pre><code>TelephonyManager tManager;
  
  tManager = (TelephonyManager).getSystemService(Context.TELEPHONY_SERVICE);
  
  String deviceId = tManager.getDeviceId();
  </code></pre>
  
  <p>Where <code>deviceId</code> Gives me Unique ID for Android Device. I am not testing this on emulator because in emulator i am getting value <code>000000000000000</code></p>
  
  <p>Any way i am testing it on real devices,and this works fine for mostly all devices , but in some device i am getting value <code>null</code></p>
  
  <p>I have tested this on </p>
  
  <pre><code>Samsung Galaxy S3
  
  Samsung Galaxy Tab3
  
  Samsung Galaxy Star
  
  Google Nexus4
  
  Google Nexus5
  
  Google Nexus7
  </code></pre>
  
  <p>In all the devices listed above it gives me correct out put except one Device and that is <code>Google Nexus7</code>, in this i m getting value <code>null</code></p>
  
  <p>So, ultimately my goal is to get unique value for each particular device, In case if this code gives me null value than i can try some alternate way </p>
  
  <p>i heard that  <code>Device MAC Address</code> is a unique for all devices, But unfortunately it just works on wifi connection.</p>
  
  <p>So is there any other way to get unique value of each particular device?</p>
  
  <p>Thanks Any way</p>