[pkg-fso-commits] [SCM] FSO frameworkd Debian packaging branch, master, updated. milestone4-368-g700ab82
Michael 'Mickey' Lauer
mickey at vanille-media.de
Mon Feb 2 18:51:32 UTC 2009
The following commit has been merged in the master branch:
commit 7d69f3ceacf92a896d1eada126009937b9d5dec3
Author: Michael 'Mickey' Lauer <mickey at vanille-media.de>
Date: Sat Dec 6 21:16:19 2008 +0100
ogsmd: [FREESCALE NEPTUNE] Query our MNO database to show the provider's
alphanumerical name in addition to the numerical code (which is the only
thing we get on this modem...)
diff --git a/ChangeLog b/ChangeLog
index ce3a456..b432183 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,7 +4,8 @@
* [ogsmd] Implemented org.freesmartphone.GSM.SIM.GetIssuer()
NOTE: Clients can now show the Mobile Virtual Network Operator instead of the
actual service provider, if they want to. See e.g. FSO ticket #271.
- * [ogsmd] Added codeToOperator function and a mcc,mni database
+ * [ogsmd] Added codeToOperator function and a mobile network operator database
+ * [ogsmd] [FREESCALE NEPTUNE] Query our MNO database to show the alphanumeric operator name.
2008-12-05 Michael Lauer <mickey at openmoko.org>
diff --git a/framework/subsystems/ogsmd/modems/freescale_neptune/mediator.py b/framework/subsystems/ogsmd/modems/freescale_neptune/mediator.py
index 3798230..118e522 100644
--- a/framework/subsystems/ogsmd/modems/freescale_neptune/mediator.py
+++ b/framework/subsystems/ogsmd/modems/freescale_neptune/mediator.py
@@ -9,7 +9,7 @@ Package: ogsmd.modems.freescale_neptune
Module: mediator
"""
-__version__ = "0.5.0.0"
+__version__ = "0.5.1.0"
MODULE_NAME = "ogsmd.modems.freescale_neptune.mediator"
from ogsmd.modems.abstract.mediator import *
@@ -98,9 +98,10 @@ class NetworkGetStatus( NetworkMediator ):
Modem violating GSM 07.07 here. No matter which answering format you specify
with +COPS=..., +COPS? will always return the numerical ID of the provider
as a string. We might have +ESPN? to the rescue, but that always returns
- an empty string for me. So until this is cleared, we have to use PLNM matching.
+ an empty string for me. So until this is cleared, we have to use code matching
+ with our database (mobile_network_code).
- Oh, by the way, +CREG? is not implemented either.
+ Oh, by the way, +CREG? is not implemented either. *sigh*
"""
def trigger( self ):
request, response, error = yield( "+CSQ" )
@@ -128,7 +129,10 @@ class NetworkGetStatus( NetworkMediator ):
result["mode"] = const.REGISTER_MODE[int(values[0])]
roaming = self._object.modem.data( "roaming", False )
result["registration"] = "roaming" if roaming else "home"
- result[ "provider"] = values[2].strip( '"' )
+
+ mccmni = values[2].strip( '"' ).replace( '-', '' )
+ result["code"] = int( mccmni )
+ result["provider"] = const.codeToOperator( mccmni )
self._ok( result )
--
FSO frameworkd Debian packaging
More information about the pkg-fso-commits
mailing list