Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • Get Android device Model programatically

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 148
    Comment on it

    The following method can help you to find device manufacturer name and model name. To get these details Android provides Build class to get system properties like Build.MANUFACTURER returns the device build name.

    Build.MODEL returns the model name of current device. then you can print both accordingly, in my case i am printing both name together like this :

    public String checkDeviceModel() {
    String deviceManufacturerName = Build.MANUFACTURER;
    String deviceModelName = Build.MODEL;
    if (deviceModelName.startsWith(deviceManufacturerName)) {
        return capitalize(deviceModelName);
    } else {
        return capitalize(deviceManufacturerName) + " " + deviceModelName;
    }}
    

    output : Motorola MB860

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: