Java tutorial
//package com.java2s; //License from project: Apache License public class Main { public static String getCpuInfo() { try { String arc = System.getProperty("os.arch").toUpperCase(); if (arc.startsWith("ARM")) { arc = "ARM"; } else if (arc.startsWith("MIPS")) { arc = "MIPS"; } else if (arc.startsWith("X86") || arc.endsWith("86")) { arc = "X86"; } else { arc = "ARM"; } return arc; } catch (Exception e) { return "ARM"; } } }