当前位置: 首页 > news >正文

【笔记】Android U RILJ 中与运营商名称SPN显示相关的日志分析

源码阅读:AOSPXRef

常用日志关键字

Note:">"下发MD,"<"MD上报,[]中的id有请求和返回的对应关系

KEYComment
> OPERATOR下发MD,请求运营商信息
< OPERATORMD上报运营商注册信息
> DATA_REGISTRATION_STATE下发MD请求驻网状态信息
< DATA_REGISTRATION_STATEMD上报驻网状态
Poll ServiceState doneSST 更新网络状态完成
updateSpnDisplayCdnr网络状态变化触发SPN更新

实网Log分析

// radio关闭时不会更新SPN

03-27 14:23:59.808824  2120  2120 D MTKSST  : [GsmSST1] updateSpnDisplay: radio is off w/ showPlmn=true plmn=null

03-27 14:23:59.808919  2120  2120 D MTKSST  : [GsmSST1] updateSpnDisplay: rawSpn = 

// 还没获取到运营商信息。(请求运营商信息的过程很快,耗时短,都不需要半秒的)

03-27 14:23:29.955064  2120  2120 D RILJ    : [1938]> OPERATOR [PHONE0]

03-27 14:23:29.967462  2120  2455 D RILJ    : [1938]< OPERATOR {, , } [PHONE0]

// 还没驻网成功,搜网或处于飞行模式

03-27 14:23:59.737880  2120  2585 D RILJ    : [1984]> DATA_REGISTRATION_STATE [PHONE0]
03-27 14:23:59.747966  2120  2455 D RILJ    : [1984]< DATA_REGISTRATION_STATE {.regState = NOT_REG_MT_SEARCHING_OP, .rat = UNKNOWN, .reasonForDenial = NONE, .cellIdentity = {.noinit = {}}, .registeredPlmn = , .accessTechnologySpecificInfo = {.noinit = {}}} [PHONE0]

// 驻网在本地LTE网络,从mccmnc和registeredPlmn可以确认。

疑问:根据什么确认显示alphaLong还是alphaShort?

03-27 14:23:59.969940  2120  2585 D RILJ    : [1988]> DATA_REGISTRATION_STATE [PHONE0]

03-27 14:24:00.049672  2120  2455 D RILJ    : [1988]< DATA_REGISTRATION_STATE {.regState = REG_HOME, .rat = LTE, .reasonForDenial = NONE, .cellIdentity = {.lte = {.base = {.base = {.mcc = 722, .mnc = 07, .ci = 256, .pci = 0, .tac = 1, .earfcn = 2525}, .operatorNames = {.alphaLong = AR - Movistar, .alphaShort = Movistar}, .bandwidth = 10000}, .additionalPlmns = [], .optionalCsgInfo = {.noinit = {}}, .bands = [5]}}, .registeredPlmn = 72207, .accessTechnologySpecificInfo = {.eutranInfo = {.lteVopsInfo = {.isVopsSupported = true, .isEmcBearerSupported = true}, .nrIndicators = {.isEndcAvailable = false, .isDcNrRestricted = false, .isNrAvailable = false}}}} [PHONE0]

03-27 14:23:59.960990  2120  2120 D RILJ    : [1986]> OPERATOR [PHONE0]

// 通知应用程序网络状态发生变化

03-27 14:23:59.986333  2120  2455 D RILJ    : Unsol response received; Sending ack to ril.cpp [PHONE0]
03-27 14:23:59.986511  2120  2455 D RILJ    : [UNSL]< UNSOL_RESPONSE_NETWORK_STATE_CHANGED [PHONE0]

// 驻网信息,由Modem根据当时注册网络的信息上报的,和Telephony的SST信息一致。

03-27 14:23:59.987577  2120  2455 D RILJ    : [1986]< OPERATOR {AR - Movistar, Movistar, 72207} [PHONE0]

// CS在无线局域网,注册在HOME LTE(在CS域中,语音和短信数据通过电路交换方式传输),可用服务:[VOICE, SMS, VIDEO]

03-27 14:24:00.057818  2120  2585 D NRM-C-0 : onRequestNetworkRegistrationInfoComplete result: 0, info: NetworkRegistrationInfo{ domain=CS transportType=WWAN registrationState=HOME networkRegistrationState=HOME roamingType=NOT_ROAMING accessNetworkTechnology=LTE rejectCause=0 emergencyEnabled=false availableServices=[VOICE,SMS,VIDEO] cellIdentity=CellIdentityLte:{ mCi=256 mPci=0 mTac=1 mEarfcn=2525 mBands=[5] mBandwidth=10000 mMcc=722 mMnc=07 mAlphaLong=AR - Movistar mAlphaShort=Movistar mAdditionalPlmns={} mCsgInfo=null} voiceSpecificInfo=VoiceSpecificRegistrationInfo { mCssSupported=false mRoamingIndicator=0 mSystemIsInPrl=0 mDefaultRoamingIndicator=0} dataSpecificInfo=null nrState=**** rRplmn=72207 isUsingCarrierAggregation=false}

// PS状态变化,从搜网到注册完成,驻网在HOME LTE,具备DATA能力,

03-27 14:24:00.074533  2120  2601 D NRM-I-0 : onRequestNetworkRegistrationInfoComplete result: 0, info: NetworkRegistrationInfo{ domain=PS transportType=WLAN registrationState=NOT_REG_OR_SEARCHING networkRegistrationState=NOT_REG_OR_SEARCHING roamingType=NOT_ROAMING accessNetworkTechnology=UNKNOWN rejectCause=0 emergencyEnabled=false availableServices=[] cellIdentity=null voiceSpecificInfo=null dataSpecificInfo=android.telephony.DataSpecificRegistrationInfo :{ maxDataCalls = 0 isDcNrRestricted = false isNrAvailable = false isEnDcAvailable = false mLteAttachResultType = 0 mLteAttachExtraInfo = 0 LteVopsSupportInfo :  mVopsSupport = 1 mEmcBearerSupport = 1 } nrState=**** rRplmn=null isUsingCarrierAggregation=false}

03-27 14:24:00.103294  2120  2585 D NRM-C-0 : onRequestNetworkRegistrationInfoComplete result: 0, info: NetworkRegistrationInfo{ domain=PS transportType=WWAN registrationState=HOME networkRegistrationState=HOME roamingType=NOT_ROAMING accessNetworkTechnology=LTE rejectCause=0 emergencyEnabled=false availableServices=[DATA] cellIdentity=CellIdentityLte:{ mCi=256 mPci=0 mTac=1 mEarfcn=2525 mBands=[5] mBandwidth=10000 mMcc=722 mMnc=07 mAlphaLong=AR - Movistar mAlphaShort=Movistar mAdditionalPlmns={} mCsgInfo=null} voiceSpecificInfo=null dataSpecificInfo=android.telephony.DataSpecificRegistrationInfo :{ maxDataCalls = 16 isDcNrRestricted = false isNrAvailable = false isEnDcAvailable = false mLteAttachResultType = 0 mLteAttachExtraInfo = 0 LteVopsSupportInfo :  mVopsSupport = 2 mEmcBearerSupport = 2 } nrState=**** rRplmn=72207 isUsingCarrierAggregation=false}

// TS.25是MD配,但是来源TS.25的SPN显示优先级很低

03-27 14:24:00.208931  2120  2120 D MtkRILJ : lookupOperatorNameMVNO plmn name update to TS.25/MVNO: AR - Movistar

// ServiceState 更新网络状态完成,切换到LTE,alphatag更新到AR - Movistar

03-27 14:24:00.223138  2120  2120 D MTKSST  : [GsmSST0] Poll ServiceState done: newSS={mVoiceRegState=0(IN_SERVICE), mDataRegState=0(IN_SERVICE), mChannelNumber=2525, duplexMode()=1, mCellBandwidths=[10000], mOperatorAlphaLong=AR - Movistar, mOperatorAlphaShort=AR - Movistar, isManualNetworkSelection=false(automatic), getRilVoiceRadioTechnology=14(LTE), getRilDataRadioTechnology=14(LTE), mCssIndicator=unsupported, mNetworkId=-1, mSystemId=-1, mCdmaRoamingIndicator=-1, mCdmaDefaultRoamingIndicator=-1, mIsEmergencyOnly=false, isUsingCarrierAggregation=false, mArfcnRsrpBoost=0, mNetworkRegistrationInfos=[NetworkRegistrationInfo{ domain=PS transportType=WLAN registrationState=NOT_REG_OR_SEARCHING networkRegistrationState=NOT_REG_OR_SEARCHING roamingType=NOT_ROAMING accessNetworkTechnology=UNKNOWN rejectCause=0 emergencyEnabled=false availableServices=[] cellIdentity=null voiceSpecificInfo=null dataSpecificInfo=android.telephony.DataSpecificRegistrationInfo :{ maxDataCalls = 0 isDcNrRestricted = false isNrAvailable = false isEnDcAvailable = false mLteAttachResultType = 0 mLteAttachExtraInfo = 0 LteVopsSupportInfo :  mVopsSupport = 1 mEmcBearerSupport = 1 } nrState=**** rRplmn=null isUsingCarrierAggregation=false}, NetworkRegistrationInfo{ domain=CS transportType=WWAN registrationState=HOME networkRegistrationState=HOME roamingType=NOT_ROAMING accessNetworkTechnology=LTE rejectCause=0 emergencyEnabled=false availableServices=[VOICE,SMS,VIDEO] cellIdentity=CellIdentityLte:{ mCi=256 mPci=0 mTac=1 mEarfcn=2525 mBands=[5] mBandwidth=10000 mMcc=722 mMnc=07 mAlphaLong=AR - Movistar mAlphaShort=AR - Movistar mAdditionalPlmns={} mCsgInfo=null} voiceSpecificInfo=VoiceSpecificRegistrationInfo { mCssSupported=false mRoamingIndicator=0 mSystemIsInPrl=0 mDefaultRoamingIndicator=0} dataSpecificInfo=null nrState=**** rRplmn=72207 isUsingCarrierAggregation=false}, NetworkRegistrationInfo{ domain=PS transportType=WWAN registrationState=HOME networkRegistrationState=HOME roamingType=NOT_ROAMING accessNetworkTechnology=LTE rejectCause=0 emergencyEnabled=false availableServices=[DATA] cellIdentity=CellIdentityLte:{ mCi=256 mPci=0 mTac=1 mEarfcn=2525 mBands=[5] mBandwidth=10000 mMcc=722 mMnc=07 mAlphaLong=AR - Movistar mAlphaShort=AR - Movistar mAdditionalPlmns={} mCsgInfo=null} voiceSpecificInfo=null dataSpecificInfo=android.telephony.DataSpecificRegistrationInfo :{ maxDataCalls = 16 isDcNrRestricted = false isNrAvailable = false isEnDcAvailable = false mLteAttachResultType = 0 mLteAttachExtraInfo = 0 LteVopsSupportInfo :  mVopsSupport = 2 mEmcBearerSupport = 2 } nrState=**** rRplmn=72207 isUsingCarrierAggregation=false}], mNrFrequencyRange=0, mOperatorAlphaLongRaw=AR - Movistar, mOperatorAlphaShortRaw=Movistar, mIsDataRoamingFromRegistration=false, mIsIwlanPreferred=false}

03-27 14:24:00.224207  2120  2120 D MTKSST  : [GsmSST0] RAT switched Unknown -> LTE at cell 256

// 非漫游,根据EF中displayRule显示SPN值,但是实际界面显示了PLMN

03-27 14:24:00.252327  2120  2120 D MTKSST  : [GsmSST0] carrierName=, overrideName=

03-27 14:24:00.252465  2120  2120 D ServiceStateTracker: [0] updateSpnDisplayCdnr: curSpn = ; curPlmn = AR - Movistar; curDisplayRule = 2

03-27 14:24:00.258072  2120  2120 I CDNR : getCarrierDisplayNameFromEf withoutRoaming = false

03-27 14:24:00.258204  2120  2120 I CDNR : getCarrierDisplayNameFromEf registeredPlmnNumeric = 72207; isRoaming = false; showSpn = true; showPlmn = false; spn = 

// 根据EF内容,更新了SPN为AR - Movistar,同PLMN,所以会显示AR - Movistar

03-27 14:24:00.258433  2120  2120 D CDNR : getCarrierDisplayNameFromEf displayRule = { SPN_bit = 2, PLMN_bit = 0 }; spn = AR - Movistar; plmn = AR - MovistarshowSpn = true; showPlmn = false

03-27 14:24:00.258617  2120  2120 D CDNR : CarrierName from EF: { spn = AR - Movistar, dataSpn = null, showSpn = true, plmn = AR - Movistar, showPlmn = false

03-27 14:24:00.267668  2120  2120 D ServiceStateTracker: [0] updateTctSpnDisplay: updateSpnDisplay: changed sending intent, rule=2, showPlmn='false', plmn='AR - Movistar', showSpn='true', spn='AR - Movistar', dataSpn='null', subId='2'

03-27 14:24:00.303102  2120  2120 D ServiceStateTracker: [0] setCarrierText simNumeric:72207, operatorNumeric:72207, gid1:FFFFFFFF, carrierText:AR - Movistar

相关说明

1、不同平台的Modem配置TS.25或许会存在差异,比如6835芯片的配置路径在modem_t_6835 / mcu/custom/service/plmn/TS25。

2、TS25文件用于显示运营商名称,较新的平台机制(带MIPC的平台)才移到Modem维护的。没有TS.25时,会在Telephony AP侧配置,spn-conf.xml中。

定制方案

无法修改网络上报的信息,客制化只能在Telphony FW中配置运营商名称期望值。

针对平台定义的运营商名称,修改在spn-conf.xml,具体看mk编译生效文件的路径,可能用:

  • /device/mediatek/system/common/
  • /device/mediatek/common/
<spnOverride numeric="72207" spn="Movistar"/>
<spnOverride numeric="722070" spn="Movistar"/>

http://www.lryc.cn/news/328716.html

相关文章:

  • 蓝桥杯【奇怪的捐赠】c语言
  • 【3月比赛合集】5场可报名的「创新应用」、「数据分析」和「程序设计」大奖赛,任君挑选!
  • vue3 视频播放功能整体复盘梳理
  • vue-ueditor-wrap上传图片报错:后端配置项没有正常加载,上传插件不能正常使用
  • 数据仓库的发展历程
  • MySQL开窗函数
  • Java学习笔记(23)
  • nodejs下载安装以及npm、yarn安装及配置教程
  • Playwright库page.evaluate()方法执行JavaScript 表达式
  • 【微服务】OpenFeign+Sentinel集中处理远程调用异常
  • 集合嵌套,Collections,斗地主案例,日志框架
  • maven pom relativePath属性的作用
  • 【STM32 HAL库SPI/QSPI协议学习,基于外部Flash读取。】
  • Nginx入门--初识Nginx的架构
  • 网络性能提升10%,ZStack Edge 云原生超融合基于第四代英特尔®至强®可扩展处理器解决方案发布
  • 双非计算机考研目标211,选11408还是22408更稳?
  • 简单了解策略模式
  • 算法——运动模型
  • 基于R语言lavaan结构方程模型(SEM)技术应用
  • 本地虚拟机服务器修改站点根目录并使用域名访问的简单示例
  • 生信数据分析——GO+KEGG富集分析
  • 微服务(基础篇-007-RabbitMQ)
  • 汇总:五个开源的Three.js项目
  • JavaScript(一)---【js的两种导入方式、全局作用域、函数作用域、块作用域】
  • 部署云原生边缘计算平台kubeedge
  • Java设计模式:单例模式详解
  • Qt5.14.2 定时器黑魔法,一键唤醒延时任务
  • C++项目——集群聊天服务器项目(九)客户端异常退出业务
  • STM32CubeIDE基础学习-HC05蓝牙模块和手机通信
  • npm mongoose包下载冲突解决之道