RCS Integration Guide 80 NV182 1

User Manual: Pdf

Open the PDF directly: View PDF PDF.
Page Count: 17

DownloadRCS Integration Guide 80 NV182 1
Open PDF In BrowserView PDF
Qualcomm Technologies, Inc.

RCS Integration Guide
80-NV182-1 C
August 4, 2016

Confidential and Proprietary – Qualcomm Technologies, Inc.
NO PUBLIC DISCLOSURE PERMITTED: Please report postings of this document on public servers or websites to:
DocCtrlAgent@qualcomm.com.
Restricted Distribution: Not to be distributed to anyone who is not an employee of either Qualcomm Technologies, Inc. or its
affiliated companies without the express approval of Qualcomm Configuration Management.
Not to be used, copied, reproduced, or modified in whole or in part, nor its contents revealed in any manner to others without the
express written permission of Qualcomm Technologies, Inc.
Qualcomm is a trademark of Qualcomm Incorporated, registered in the United States and other countries. Other product and brand
names may be trademarks or registered trademarks of their respective owners.
This technical data may be subject to U.S. and international export, re-export, or transfer (“export”) laws. Diversion contrary to U.S.
and international law is strictly prohibited.
Qualcomm Technologies, Inc.
5775 Morehouse Drive
San Diego, CA 92121
U.S.A.
© 2015-2016 Qualcomm Technologies, Inc. All rights reserved.

Revision history
Revision

Date

A

January 2015

DRAFT release

B

February 2015

Initial release

C

Aug 2016

80-NV182-1 C

Description

Numerous changes were made in this revision. It should be read in its
entirety.

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

2

Contents

1 Introduction...................................................................................................... 5
1.1 Purpose.......................................................................................................................... 5
1.2 Conventions .................................................................................................................. 5
1.3 Technical assistance ...................................................................................................... 5

2 RCS architecture ............................................................................................. 6
2.1 RCS component list ...................................................................................................... 7
2.2 Changes to the RCS UI module .................................................................................... 8
2.3 Changes to the RCS DB.............................................................................................. 10

3 Integration steps............................................................................................ 12
3.1 Download the latest version ........................................................................................ 12
3.2 Verify that the configurations are correct ................................................................... 12
3.3 Verify the newly added RCS components .................................................................. 13
3.3.1 Libraries ........................................................................................................... 13
3.3.2 Permission files ................................................................................................ 13
3.3.3 Framework jars ................................................................................................ 13
3.3.4 APKs ................................................................................................................ 13
3.4 Install the RCS plugin ................................................................................................. 14

4 Validate the RCS function ............................................................................. 15
4.1 Procedure to use the RCS function ............................................................................. 15
4.2 Procedure to provision the RCS function ................................................................... 16

A References..................................................................................................... 17
A.1 Acronyms and terms .................................................................................................. 17

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

3

RCS Integration Guide

Contents

Figures
Figure 2-1 RCS system architecture ............................................................................................................ 6
Figure 2-2 Jump from Mms.apk to NativeUI.apk ........................................................................................ 9

Tables
Table 2-1
Table 2-2
Table 2-3
Table 2-4
Table 2-5
Table 4-1

RCS component list ..................................................................................................................... 7
UI changes based on the QTI Android platform ......................................................................... 8
Newly-added UI APKs ................................................................................................................ 9
Newly added fields in the SMS table ........................................................................................ 10
Newly added fields in the thread table ...................................................................................... 11
Parameter descriptions for rcs_service.properties ..................................................................... 15

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

4

1 Introduction

NOTE:

Numerous changes were made to this document revision; it should be read in its entirety.

1.1 Purpose
This document provides integration guidelines for OEMs using the Qualcomm Technologies, Inc.
(QTI) RCS solution to meet China Mobile (CMCC) requirements.

1.2 Conventions
Function declarations, function names, type declarations, attributes, and code samples appear in a
different font, for example, #include.
Code variables appear in angle brackets, for example, .
Shading indicates content that has been added or changed in this revision of the document.

1.3 Technical assistance
For assistance or clarification on information in this document, submit a case to Qualcomm
Technologies, Inc. (QTI) at https://createpoint.qti.qualcomm.com/.
If you do not have access to the CDMATech Support website, register for access or send email to
support.cdmatech@qti.qualcomm.com.

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

5

2 RCS architecture

The RCS system architecture can be divided into five layers. The main functions of each layer
are:


UI – Responsible for UI render/presentation to interact with the user



Device API – Responsible for interacting with the RCS service by way of AIDL



Service and Plug-in – Responsible for handling the most basic RCS service logic and
encapsulating the plug-in of CMCC



Stack API – Responsible for the interaction of the RCS adaptation layer and RCS protocol
layer by way of JNI



RCS framework – Responsible for the RCS transport protocol

The RCS system architecture is shown in Figure 2-1.

Figure 2-1 RCS system architecture

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

6

RCS Integration Guide

RCS architecture

2.1 RCS component list
Table 2-1 lists the modules (components) of the RCS system.
Table 2-1 RCS component list
Usage

Owner

Release to
OEMs

system/framework/rcs_service_aidl.jar

Definition of the common AIDL of
rcs_service_api and rcs_service

PCI

Source code

system/etc/permissions/rcs_service_
aidl.xml

Used to dynamically load
rcs_service_aidl.jar

PCI

Source code

system/framework/rcs_service_api.jar

Used for all RCS interfaces of
the UI

PCI

Source code

system/etc/permissions/rcs_service_
api.xml

Used to dynamically load
rcs_service_api.jar

PCI

Source code

system/framework/device_api.jar

Device API interface

PCI

binary

system/etc/permissions/device_api.xml

Used to dynamically load
device_api.jar

PCI

binary

system/framework/rcs_plugin_aidl.jar

Definition of the common AIDL of
rcs_service and rcs_plugin

PCI

binary

system/etc/permissions/rcs_plugin_aidl.x
ml

Used to dynamically load
rcs_plugin_aidl.jar

PCI

binary

system/vendor/ChinaMobile/system/app/D
eviceApiService/DeviceApiService.apk

Device API serivce

PCI

binary

system/vendor/ChinaMobile/system/app/R
csGbaProxy/RcsGbaProxy.apk

GBA authentication middleware

PCI

binary

system/vendor/ChinaMobile/system/app/R
csService/RcsService.apk

RCS service logic
implementation, which acts as a
bridge to connect the protocol
stack and the UI

PCI

binary

system/vendor/lib/librcs_jni.so

RCS protocol stack

PCI

binary

system/vendor/ChinaMobile/system/privapp/BiaoQingStore4Rcs_APK
/BiaoQingStore4Rcs_APK.apk

Emoticon store plug-in

CMCC

binary

system/vendor/ChinaMobile/system/app/
OnlineBusinessHall/OnlineBusinessHall.a
pk

Online Business Hall plug-in

CMCC

binary

system/vendor/ChinaMobile/system/app/R
csMap/RcsMap.apk

Map plug-in

PCI

binary

system/vendor/ChinaMobile/system/app/C
aiYinRCS/CaiYinRCS.apk

Enhanced screen plug-in

CMCC

binary

data/app/cmccsso/cmccsso.apk

SSO authentication service

CMCC

binary

data/app/RcsPlugin/RcsPlugin.apk

Integrate plug-in function to
provide service to the UI

PCI

binary

system/vendor/ChinaMobile/system/app/R
csSystemService/RcsSystemService.apk

Set RCS enable/disable

PCI

binary

Product location

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

7

RCS Integration Guide

RCS architecture

2.2 Changes to the RCS UI module
The RCS UI is divided into two parts – one part is anAndroid open source-based UI, such as
Contacts, Dialer, MMS, etc., which is integrated with the features of RCS.
Table 2-2 lists the UI modules in which RCS has changed the open source code.
Table 2-2 UI changes based on the QTI Android platform
Module

Main changes

frameworks/opt/telephony

The permission for rcs_service to write
SMS is added

packages/apps/Contacts

Profile, RCS capability discovery, QR
code scan, and Enhanced screen

packages/providers/ContactsProvider

Newly added field that supports RCS data
storage

packages/apps/ContactsCommon

UI change of the contacts

packages/apps/Mms

Text message, file transfer, 1-1 chat, 1-n
chat, group chat

packages/providers/TelephonyProvider

Newly added field that supports RCS data
storage

packages/apps/Dialer

The entry of Blacklist and Send Message
are added

packages/apps/InCallUI

Enhanced screen

vendor\qcom\proprietary\qrdplus\ChinaMobile\apps\Firewall

RCS message intercept

vendor\qcom\proprietary\qrdplus\ChinaMobile\res\Mms

Whether MMS supports to set the toggle
(enable/disable) of RCS message storage
under CMCC mode

vendor\qcom\proprietary\qrdplus\ChinaMobile\res\Telephony
Provider

Whether telephonyProvider supports
RCS field under CMCC mode

The other part is the newly-added RCS UI. To reduce the coupling with the Android original
system UI, these UI changes are placed in a separate APK to be installed in the handset.The
interaction between UIs is done by the Intent mechanism.
For example, in the group chat UI of MMS, clicking the Group Chat Detail jumps to the group
management UI of the original UI, as shown in Figure 2-2.

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

8

RCS Integration Guide

RCS architecture

Figure 2-2 Jump from Mms.apk to NativeUI.apk
The newly-added UI APKs are listed in Table 2-3.
Table 2-3 Newly-added UI APKs
Module

Main changes

vendor/qcom/proprietary/qrdplus/ChinaMobile/apps/Rcs/rcs_native_ui

Newly added RCS UI

vendor/qcom/proprietary/qrdplus/ChinaMobile/apps/Rcs/rcs_public_account

Public account message

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

9

RCS Integration Guide

RCS architecture

2.3 Changes to the RCS DB
The SMS table is extended in the SmsProvider of TelephonyProvider to store the fields related to
new RCS messages. The changes are listed in Table 2-4.
Table 2-4 Newly added fields in the SMS table
Field

Data type

Field name

favorite

INTEGER

rcs_message_id

TEXT

Message ID

Added to favorite or not

Description
0: Not added; 1: Added

rcs_file_name

TEXT

Attachment name

rcs_mime_type

TEXT

Attachment type

rcs_msg_type

INTEGER

Message type

rcs_msg_state

INTEGER

Message state

Sender: Sending, Sent,
Delivered, Sent Fail,
Read, Burnt
Receiver: Unread, Read,
Burnt

rcs_chat_type

INTEGER

Conversation type

1-1, 1-n, n-n

rcs_conversation_id

TEXT

RCS conversation ID

rcs_contribution_id

TEXT

RCS contribution ID

rcs_file_selector

TEXT

File description

rcs_file_transfered

TEXT

How many bytes have
been transferred

rcs_file_transfer_id

TEXT

File transfer ID

rcs_file_icon

TEXT

File thumbnail

rcs_burn

INTEGER

Burn after reading

Text, image, audio, video

-1: Do not burn after
reading
Other: Burn the

message N seconds
after it is read

80-NV182-1 C

rcs_header

TEXT

From, To date in received
message

rcs_file_path

TEXT

File path

rcs_is_download

INTEGER

Download or not

rcs_file_size

INTEGER

rcs_thumb_path

TEXT

Attachment thumbnail
path

Attachment size

rcs_burn_body

TEXT

Burn message body

rcs_ext_contact

TEXT

Extend contact
information

rcs_file_record

INTEGER

Recorded file or not

Used to determine
whether the file being
transferred is a recorded
file or not
1: Recorded file
2: Not a recorded file

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

10

RCS Integration Guide

RCS architecture

Table 2-5 lists the changes to the thread table to store information related to group chat and top.
Table 2-5 Newly added fields in the thread table
Field

Data type

rcs_top

INTEGER

rcs_top_time

INTEGER

rcs_number

TEXT

last_msg_id

Field name

Description

Top conversation or not
Top time
The other party’s number

For 1-1, it is the other
party’s number;
For 1-n, it is a list of
numbers

INTEGER

ID of the last message

Used to update the
snippet display

msg_chat_type

INTEGER

Conversation type

Group chat or 1-1

last_msg_type

INTEGER

Type of the last message

Used to updat the snippet
display

rcs_unread_count

INTEGER

Unread message count

In the raw_contacts table of ContactsProvider, local_photo_setted is used to determine whether a
local photo is set.

80-NV182-1 C

Field

Data type

Field name

Description

local_photo_setted

INTEGER

Whether a local photo is
set

In the code, it is used to
determine photo updates
in different situations

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

11

3 Integration steps

3.1 Download the latest version
Get the latest version from the Qualcomm ChipCode website.

3.2 Verify that the configurations are correct
device/qcom/{$TARGET}/BoardConfig.mk
TARGET_USES_PCI_RCS := true;

device/qcom/common/base.mk
#RCS
RCS := rcs_service_aidl
RCS += rcs_service_aidl.xml
RCS := rcs_service_aidl_static
RCS += rcs_service_api
RCS += rcs_service_api.xml
PRODUCT_PACKAGES += $(RCS)

vendor/qcom/proprietary/qrdplus/ChinaMobile/product.mk
ifneq ($(TARGET_USES_PCI_RCS),true)
#RCS in ChinaMobile folder
RCS := NativeUI
RCS += PublicAccount
#RCS in other folders
RCS += librcs_jni
RCS += rcs_plugin_aidl_libs_gson_static.jar
RCS += rcs_plugin_aidl
RCS += rcs_plugin_aidl.xml
RCS += RcsService
RCS += RcsSystemService
RCS += device_api
RCS += device_api.xml
RCS += DeviceApiService
#RCS no ship
RCS_NO_SHIP += libbinaryByFounder
RCS_NO_SHIP += libqrcodedecoder
RCS_NO_SHIP += RcsPlugin
RCS_NO_SHIP += RcsGbaProxy

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

12

RCS Integration Guide Error! No text of specified style in document.

RCS_NO_SHIP
RCS_NO_SHIP
RCS_NO_SHIP
RCS_NO_SHIP

+=
+=
+=
+=

Integration steps

cmccsso
OnlineBusinessHall
CaiYinRCS
BiaoQingStore4Rcs_APK

PRODUCT_PACKAGES += RCS
PRODUCT_PACKAGES += RCS_NO_SHIP
endif

Continue the compilation after all the configurations are verified to be correct.

3.3 Verify the newly added RCS components
3.3.1 Libraries
system/vendor/lib/librcs_jni.so

3.3.2 Permission files
system/etc/permissions/rcs_service_aidl.xml
system/etc/permissions/rcs_service_api.xml
system/etc/permissions/rcs_plugin_aidl.xml
system/etc/permissions/device_api.xml

3.3.3 Framework jars
system/framework/rcs_service_aidl.jar
system/framework/rcs_service_api.jar
system/framework/device_api.jar
system/framework/rcs_plugin_aidl.jar

3.3.4 APKs
system/vendor/ChinaMobile/system/app/RcsService/RcsService.apk
system/vendor/ChinaMobile/system/app/DeviceApiService/DeviceApiService.apk
system/vendor/ChinaMobile/system/app/RcsSystemService/RcsSystemService.apk
system/vendor/ChinaMobile/system/app/NativeUI/NativeUI.apk
* system/vendor/ChinaMobile/system/app/RcsGbaProxy/RcsGbaProxy.apk
* system/vendor/ChinaMobile/system/priv-app\BiaoQingStore4Rcs_APK
* system/vendor/ChinaMobile/system/app/OnlineBusinessHall/OnlineBusinessHall.apk
*data/app/RcsPlugin/RcsPlugin.apk
*data/app/RcsMap/RcsMap.apk
80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

13

RCS Integration Guide Error! No text of specified style in document.

Integration steps

* data/app/cmccsso/cmccsso.apk
* data/app/CaiYinRCS/CaiYinRCS.apk
The components that are marked with * are plug-in functions. Refer to Chapter 4 if they are
needed.

3.4 Install the RCS plugin
Install the following plugins.
adb push OnlineBusinessHall.apk /system/app/OnlineBusinessHall/
adb push BiaoQingStore4Rcs_APK.apk /system/priv-app/BiaoQingStore4Rcs_APK/
adb install -r RcsPlugin.apk
adb install -r cmccsso.apk
adb install -r CaiYinRCS.apk
adb install -r RcsMap.apk

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

14

4 Validate the RCS function

Precondition
A CMCC USIM card that has the RCS service enabled.

4.1 Procedure to use the RCS function
Follow these steps to use the RCS function.
1. Turn on RCS toggle
adb shell setproppersist.sys.rcs.enabled1

2. Push the rcs_service.properties configuration file.
adb push rcs_service.properties/sdcard/Android/data/
com.suntek.mway.rcs.app.service/rcs_service.properties

The followings are examples of rcs_service.properties with descriptions of the parameters:
isTest=true
isForcedTest=true
testImsi0=460078132911067
dms_server_http=http://14.23.86.58:9080/dmsinterface/authen.do
dms_server_https=https://14.23.86.58:8443/dmsinterface/authen.do
network_type=0
sms_port=37273
sbc_conntype=tcp
add_dms_header=true
testMsisdn=+8618816832860
conf_uri=sip:1252000199@bfas1axm.gc.rcs2.chinamobile.com

Table 4-1 provides the rcs_service.properties parameter descriptions.
Table 4-1 Parameter descriptions for rcs_service.properties

80-NV182-1 C

Configuration
name

Mandatory
or not

isTest

Optional

Whether to use the configured IMSI.
The value is TRUE if no SIM card is installed, in which case
testImsi(x) is used

isForcedTest

Optional

Whether to use the configured IMSI mandatorily.
testImsi(x) is used no matter if a SIM card is installed or not

Function

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

15

RCS Integration Guide Error! No text of specified style in document.

NOTE:

Validate the RCS function

Configuration
name

Mandatory
or not

testImsi0

Optional

dms_server_http

Mandatory

The requested DMS HTTP address

dms_server_https

Mandatory

The requested DMS HTTPS address

Function
If this IMSI is used, 0 indicates the slot number; more than 1
can be configured, such as testImsi1, testImsi2, etc.

network_type

Optional

Set the current network type – 1: Wi-Fi mode; 0: PS mode

sms_port

Optional

The port to monitor OTP and configuration messages

sbc_conntype

Optional

Define the registered transmission mode (tcpudptls)

add_dms_header

Optional

DMS HTTP request header is added, in which the x-up-callingline-id must use the testMsisdn configuration (used for
accessing ZTE DMS)

testMsisdn

Optional

Phone number (used for accessing ZTE DMS)

conf_uri

Optional

ZTE north nodes group (used for testing Fetionfusion)

When it comes to the commercial stage, rcs_service.properties is not mandatory. Currently,
due to the consideration of the specification, by default, the RCS service accesses the
standard DMS address by domain name. Because there is no account available for the
commercial domain name, this parameter must be configured to test the RCS function before
the commercial stage.

3. Reboot the handset
adb reboot

4.2 Procedure to provision the RCS function
Follow these steps to provision the RCS function.
1. Set the RCS log level and turn on the RCS log toggle.
adb shell setproppersist.sys.rcs.log.level 1
adb shell am broadcast -a
com.suntek.mway.rcs.app.service.framework.ReloadLog
adb reboot

2. Export the RCS-related log and analyze the log.
adb pull /sdcard/Android/data/com.suntek.mway.rcs.app.service \desktop

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

16

A References

A.1 Acronyms and terms
Acronym or term

Definition

AIDL

Android™ interface description language

APK

Android application package

GBA

Generic Bootstrapping Architecture

JNI

Java® Native Interface

MMS

Multimedia Messaging System

QR code

Quick response

RCS

Rich communication services (also, rich communication suite)

SDK

Software development kit

SSO

Single sign-on

80-NV182-1 C

Confidential and Proprietary – Qualcomm Technologies, Inc.
MAY CONTAIN U.S. AND INTERNATIONAL EXPORT CONTROLLED INFORMATION

17



Source Exif Data:
File Type                       : PDF
File Type Extension             : pdf
MIME Type                       : application/pdf
PDF Version                     : 1.5
Linearized                      : No
Encryption                      : Standard V2.3 (128-bit)
User Access                     : Print, Modify, Copy, Annotate, Fill forms, Print high-res
Keywords                        : August, 2016
Content Type Id                 : 0x01010090E864F62AFB2F4F8D23EC53E3BA280D
Modify Date                     : 2017:07:18 20:16:21-07:00
Dlc Doc Id Item Guid            : 6fbe1131-3aa5-41fd-9817-f25eaeb7561f
Create Date                     : 2016:08:04 06:28:25-07:00
Company                         : 
Source Modified                 : D:20160804132529
Author                          : 
Page Mode                       : UseOutlines
Format                          : application/pdf
Description                     : 80-NV182-1_C_RCS_Integration_Guide.pdf
Subject                         : 80-NV182-1_C_RCS_Integration_Guide.pdf
Title                           : RCS Integration Guide
Creator                         : 
Producer                        : Adobe PDF Library 11.0; modified using iText 2.1.7 by 1T3XT; modified using iText® 5.4.0 ©2000-2012 1T3XT BVBA (AGPL-version)
Creator Tool                    : Acrobat PDFMaker 11 for Word
Language                        : EN-US
Tagged PDF                      : Yes
Page Count                      : 17
EXIF Metadata provided by EXIF.tools

Navigation menu