When I request the Cell ID and LAC information, on some devices I cannot retreive them.
I use this code:
TelephonyManager tm =(TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
location = (GsmCellLocation) tm.getCellLocation();
cellID = location.getCid();
lac = location.getLac();
- Does anyone know why some GSM carriers do not provide them?
- Do I need permissions for that?
- What else is there to know about retreiving the CellID and LAC?
So you can try something like. I have got cell id and the location area code for GSM. But for UMTS, getCid () returns a big number for exple 33 166 248. So i add modulo operator (exple xXx.getCid() % 0xffff).