2

In the snippet below, I am trying to read call logs and print their call type

Cursor cursor = context.getContentResolver().query(Calls.CONTENT_URI, ...);
while (cursor.moveToNext()) {
    int callType = cursor.getInt(cursor.getColumnIndex(Calls.TYPE));
    Log.d("callType", callType);
}

In some cases, I get values not listed in the official docs. Does anyone know what these callTypes mean?


callType 10

COMIO:

  • COMIO S1

OPPO:

  • A37fw
  • CPH1609
  • CPH1701
  • CPH1801
  • CPH1803
  • CPH1823
  • CPH1853
  • CPH1859
  • CPH1881
  • CPH1893
  • CPH1909
  • CPH1911
  • CPH1945
  • CPH1969
  • CPH1989
  • RMX1801
  • RMX1807

Realme:

  • RMX1825
  • RMX1827
  • RMX1833
  • RMX1901
  • RMX1911
  • RMX1992

Xiaomi:

  • Redmi 3S

callType 20

OPPO:

  • CPH1609
  • CPH1701
  • CPH1803
  • CPH1853
  • CPH1859
  • CPH1901
  • CPH1909
  • RMX1801
  • RMX1807

Realme:

  • RMX1825
  • RMX1833
  • RMX1901

callType 100

Realme:

  • RMX1827
  • RMX1901

callType 1001

PANASONIC:

  • Panasonic P85 NXT

zhirzh
  • 3,273
  • 3
  • 25
  • 30
  • 1
    Hey, did you get any work around for this issue? i am also getting wrong type from realme device for outgoing 100, incoming 101 etc. strange is some time getting call log type same defined in the official document. – RaRa Apr 19 '20 at 12:59
  • no positive developments so far. instead, I now have a few more unknown call type IDs: 10, 100, -20. – zhirzh Apr 19 '20 at 16:58
  • @RaRa did you find solution for this? we are also getting 100,101 for Realme. but what about missed call type? – Aram May 14 '20 at 12:32
  • I am also facing same issue. I got 100 and 101 value. This happens last dialed call only – Yogesh Rathi Jul 25 '20 at 20:11
  • Did someone found any updates? Still getting it randomly for Vivo and Asus phones. But it reverted back to normal call type values after some time. Its not predictable. Anyone found the possible values for phones? – Aram Jul 28 '20 at 12:52
  • We get 100,101 in Vivo phones and 8,9 in Asus phones. And after some time values are back to usual constants 1,2,3. Why is this happening. is it possible to get original values from different columns of calllog table at these time? – Aram Jul 29 '20 at 02:37

2 Answers2

1

I am able to explain the following additional call type constants: 1000, 1001, 1002

In my case the call type constants above are used for IMS call statuses in the calllog table.

See here: https://gerrit.aicp-rom.com/c/AICP/frameworks_base/+/57943/1/core/java/android/provider/CallLog.java#210

If possible, check the android source for the firmware you see the extra codes coming from in core/java/android/provider/CallLog.java. Hope this helps! It's unfortunate that this is not well-documented

Harrison
  • 319
  • 2
  • 14
0

For my OnePlus device the following codes are for:

  • 100 - VoWiFi Outgoing call
  • 101 - VoWiFi Incomming call

So I can only assume that the other codes like 10/20 might be for the same purpose but for other manufacturers. To bad that the codes are not documented and implemented in the android libs.

mch.zawalski
  • 558
  • 4
  • 5