2.2 sysinfo --
Access to system information
Availability: S60.
The sysinfo module offers an API for checking the system
information of a S60 mobile device.
Note:
The method ring_type is not available for S60 1st Edition.
The sysinfo module has the following functions:
-
Returns the current active profile as a string, which can be one of the
following:
'general', 'silent', 'meeting',
'outdoor', 'pager', 'offline', , 'drive',
or 'user <profile value>'.
-
Returns the current battery level. On devices based on S60 2nd Edition
Feature Pack 1 (S60 2.1) or earlier the value ranges from 0 (empty) to
7 (full). On newer devices the value ranges from 0 (empty) to 100
(full). On the emulator the value is always 0.
Note:
The returned value may be incorrect while the device is being charged.
-
Returns the width and height of the display in twips. For a definition of a
twip, see Chapter 6, Terms and Abbreviations.
-
Returns the width and height of the display in pixels.
-
Returns the amount of free space left on the drives in bytes, for example
{u'C:' 100}. The keys in the dictionary are the drive letters
followed by a colon (:).
-
Returns the IMEI code of the device as a Unicode string or, if running
on the emulator, the hardcoded string
u'000000000000000'.
-
Returns the maximum size of the RAM drive on the device.
-
Returns the amount of RAM memory on the device.
-
Returns the amount of free RAM memory available on the device.
-
Returns the amount of read-only ROM memory on the device.
- Not supported in 1st Edition!
Returns the current ringing type as a string, which can be one of the
following:
'normal', 'ascending',
'ring_once', 'beep', or 'silent'.
-
Returns the operating system version number of the device as a three element tuple (major version, minor version, build number). The
elements are as follows2.1:
- The major version number, ranging from 0 to 127 inclusive
- The minor version number, ranging from 0 to 99 inclusive
- The build number, ranging from 0 to 32767 inclusive.
-
Returns the current network signal strength ranging from 0 to 7, with 0
meaning no signal and 7 meaning a strong signal. If using an emulator, value
0 is always returned.
-
Returns the current network signal strength in dBm. This is available SDK 2.8
onwards. If using an emulator value 0 is always returned.
-
Returns the software version as a Unicode string. On the emulator,
returns the hardcoded string u'emulator'. For example, a
software version can be returned as
u'V 4.09.1 26-02-04 NHL-10 (c) NMP'.
Footnotes
- ... follows2.1
-
Descriptions for these values are based on information found in S60 SDK
documentation [4].
Release 1.9.1 final , documentation updated on 24 Jan 2009.
See About this document... for information on suggesting changes.