How to get "IMEI" number in Java code | Telit Cinterion IoT Developer Community
November 17, 2015 - 6:49pm, 4380 views
Hi All,
Is it possiable to get the "IMEI" number in java code ?
I have tried the API "System.getProperty( )" , but it's not working.
thanks.
Tony
Hi Tony,
I don't think that you can get IMEI with java API, but you can use AT commands with java code to get it. I get it like this:
sharedData.IMEI = ATCommand.send("AT+CGSN");
sharedData.IMEI = sharedData.IMEI.substring(10, 25);
SharedData is just one of my objects which stores information about the module and Midlet.
Hi Jure,
Thanks for your answer and example code.
I can get the IMEI number now.
Tony