From e17912c8bd5528c395325a165a0c46cf005d8577 Mon Sep 17 00:00:00 2001 From: Ethan Chen Date: Thu, 16 May 2013 15:03:59 -0700 Subject: HTCQualcommRIL: adaptable signal strength format HTC signal strength format has 14 fields, stock libril has 12 Change-Id: I8f42a9864dcd5f3071663d16535423e5cc12afbd --- src/java/com/android/internal/telephony/HTCQualcommRIL.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/java/com/android/internal/telephony/HTCQualcommRIL.java b/src/java/com/android/internal/telephony/HTCQualcommRIL.java index 0276a34..81f4d16 100644 --- a/src/java/com/android/internal/telephony/HTCQualcommRIL.java +++ b/src/java/com/android/internal/telephony/HTCQualcommRIL.java @@ -147,6 +147,8 @@ public class HTCQualcommRIL extends QualcommSharedRIL implements CommandsInterfa * 13: LTE_SignalStrength.cqi */ + int parcelSize = p.dataSize(); + int gsmSignalStrength = p.readInt(); int gsmBitErrorRate = p.readInt(); int cdmaDbm = p.readInt(); @@ -154,8 +156,11 @@ public class HTCQualcommRIL extends QualcommSharedRIL implements CommandsInterfa int evdoDbm = p.readInt(); int evdoEcio = p.readInt(); int evdoSnr = p.readInt(); - p.readInt(); // ATT_SignalStrength.dbm - p.readInt(); // ATT_SignalStrength.ecno + if (parcelSize == 14) { + /* Signal strength parcel contains HTC ATT signal strength */ + p.readInt(); // ATT_SignalStrength.dbm + p.readInt(); // ATT_SignalStrength.ecno + } int lteSignalStrength = p.readInt(); int lteRsrp = p.readInt(); int lteRsrq = p.readInt(); -- cgit v1.1