background image
Original Author Paul Laughton, 2011
Page 143
De Re BASIC!
If the PhoneType is CDMA and the phone is registered to a network, the Phone.info command also
returns the following items in the Bundle:
Key
Type
Values
Meaning
BaseID
N
A positive number
or -1 if BaseID is unknown
CDMA base station identification number
NetworkID
N
A positive number
or -1 if NetworkID is unknown
CDMA network identification number
SystemID
N
A positive number
or -1 if SystemID is unknown
CDMA system identification number
If your program has executed Phone.rcv.init, then Phone.info may be able to report the strength of the
signal connecting your phone to the cell tower. If the signal strength is available, Phone.info will try to
report it in one or two of the following bundle keys (the first three are mutually exclusive):
Key
Type
Values
Meaning
SignalLevel
N
A positive number 0 - 4
General measure of signal quality as shown in
status bar. Higher is better.
GsmSignal
N
A positive number, 0 - 31
or 99 if unknown
"SignalLevel" unavailable, phone type is GSM,
get GSM level instead.
CdmaDbm
N
A negative number, typically
-90 (strong) to -105 (weak)
"SignalLevel" unavailable, phone type is CDMA,
get raw power level in dBm instead.
SignalASU
N
0 - 31, 99 (most)
0 - 97, 99 (LTE)
"Arbitrary Strength Units",
range depends on network type.
This information is not available on some Android devices, depending on the device manufacturer and
your wireless carrier.
Screen rotation, size[], realsize[], density
Returns information about your screen.
Provide numeric variables to get the rotation and density of the screen.
Provide numeric array variables to get the "application size" and "real size" of the screen.
A size is returned as two values, width first and height second, in a two-element array. If the array
exists, it is overwritten. Otherwise a new array is created.
All parameters are optional. Use commas to indicate omitted parameters (see Optional Parameters).
rotation: The current orientation of your screen relative to the "natural" orientation of your device. The
natural orientation may be portrait or landscape, as defined by the manufacturer. The return value is a
number from 0 to 3. Multiply by 90 to get the rotation in degrees clockwise.
size[]: The size of the screen in pixels available for applications. This excludes system decorations. The
width and height values reflect the current screen orientation.