It looks like you're new here. If you want to get involved, click one of these buttons!
if application:getDeviceInfo() == "iOS" then require "system" -- Misc functions print("Name: " .. system.name()) print("Model: " .. system.model()) print("System name: " .. system.systemName()) print("System version: " .. system.systemVersion()) print("Has retina display: " .. tostring(system.hasRetinaDisplay())) print("Has FPU (Floating Point Unit): " .. tostring(system.hasFPU())) print("Is multitasking supported: " .. tostring(system.isMultitaskingSupported())) print("CPU byte order (endian): " .. system.byteOrder()) print("Number of CPUs: " .. system.numCPUs()) print("CPU frequency (Hz): " .. system.cpuFrequency()) print("Bus frequency (Hz): " .. system.busFrequency()) print("Physical memory (bytes): " .. system.physicalMemory()) print("User memory (bytes): " .. system.userMemory()) print("Free memory (bytes): " .. system.freeMemory()) print("Total disk space (bytes): " .. system.totalDiskSpace()) print("Free disk space (bytes): " .. system.freeDiskSpace()) -- Battery state and level print("Battery monitoring enabled: " .. tostring(system.isBatteryMonitoringEnabled())) system.enableBatteryMonitoring() print("Battery state (unplugged, charging, full or unknown): " .. system.batteryState()) print("Battery level (0 - 1): " .. system.batteryLevel()) system.disableBatteryMonitoring() -- Proximity sensor system.enableProximityMonitoring() if system.isProximityMonitoringEnabled() then print("Proximity sensor state (on, off): " .. tostring(system.proximityState())) else print("Proximity sensor not supported!") end system.disableProximityMonitoring() end |
Likes: vitalitymobile, plamen, hgvyas123, omer, atilim
Comments
#MakeABetterGame! "Never give up, Never NEVER give up!" - Winston Churchill
Thank you
Note: All functions are available from iOS 1.0 to 3.0 except hasRetinaDisplay() and isMultitaskingSupported() that are available in 4.0 and later (if you use them change "deployment target" in Xcode to 4.0).