Movatterモバイル変換


[0]ホーム

URL:


CN117348894A - A software upgrade method, terminal equipment and system - Google Patents

A software upgrade method, terminal equipment and system
Download PDF

Info

Publication number
CN117348894A
CN117348894ACN202210743776.7ACN202210743776ACN117348894ACN 117348894 ACN117348894 ACN 117348894ACN 202210743776 ACN202210743776 ACN 202210743776ACN 117348894 ACN117348894 ACN 117348894A
Authority
CN
China
Prior art keywords
server
data packet
software
upgrade
terminal device
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210743776.7A
Other languages
Chinese (zh)
Inventor
王剑
顾文彬
谢俗
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co LtdfiledCriticalHuawei Technologies Co Ltd
Priority to CN202210743776.7ApriorityCriticalpatent/CN117348894A/en
Publication of CN117348894ApublicationCriticalpatent/CN117348894A/en
Pendinglegal-statusCriticalCurrent

Links

Classifications

Landscapes

Abstract

Translated fromChinese

一种软件升级方法、系统及终端设备,涉及移动通信技术领域。所述方法包括:终端设备向第一服务端发送第一消息,第一信息用于请求第一服务端给终端设备发送第一升级数据包;终端设备接收来自第一服务端的第一升级数据包;终端设备向第二服务端发送第二消息,第二信息用于请求第二服务端给终端设备发送第二升级数据包;终端设备接收来自第二服务端的第二升级数据包;终端设备根据第一升级数据包和第二升级数据包更新目标软件。所述方法应用于终端设备中,使得终端设备可以同时从多个服务端接收软件升级包,以提升接收升级包的传输吞吐量和升级速度,提高了升级的可靠性,从而提升了用户体验。

A software upgrade method, system and terminal equipment relate to the field of mobile communication technology. The method includes: the terminal device sends a first message to the first server, the first information is used to request the first server to send a first upgrade data packet to the terminal device; the terminal device receives the first upgrade data packet from the first server ; The terminal device sends a second message to the second server, and the second information is used to request the second server to send a second upgrade data packet to the terminal device; the terminal device receives the second upgrade data packet from the second server; the terminal device according to The first upgrade data package and the second upgrade data package update the target software. The method is applied to terminal equipment, so that the terminal equipment can receive software upgrade packages from multiple servers at the same time, thereby improving the transmission throughput and upgrade speed of receiving upgrade packages, improving the reliability of upgrades, and thereby improving user experience.

Description

Translated fromChinese
一种软件升级方法、终端设备及系统A software upgrade method, terminal equipment and system

技术领域Technical field

本申请涉及移动通信技术领域,尤其涉及一种软件升级方法、终端设备及系统。The present application relates to the field of mobile communication technology, and in particular, to a software upgrade method, terminal equipment and system.

背景技术Background technique

随着移动通信技术的发展,运行在终端设备内部的软件的版本也在不断更新换代,为了保证终端设备内部的软件版本是新版本,需要对终端设备中的软件进行升级维护。With the development of mobile communication technology, the version of the software running inside the terminal device is also constantly updated. In order to ensure that the software version inside the terminal device is a new version, the software in the terminal device needs to be upgraded and maintained.

手机、平板电脑等终端设备的软件版本的升级通常应用空中下载(Over the Air,OTA)技术。OTA是一种通过无线网络进行数据下载的技术,目前主要采用的是单包升级策略,具体为,终端设备发起一次软件版本检测,服务器(也称服务端)向该终端设备返回一个下载路径,以便终端设备根据该下载路径获得一个OTA升级包,进而根据该OTA升级包进行版本升级。并且,为了节省服务器的存储资源和终端设备下载OTA升级包的时间,且降低开发成本,所述的OTA升级包通常为相邻两个版本之间的差分文件。这样,当终端设备安装的软件的当前版本与服务器上发布的该软件的最新版本相差不止一个版本时,终端设备需要下载多个OTA升级包才能将软件从当前版本升级到最新版本。Upgrading software versions of terminal devices such as mobile phones and tablets usually uses Over the Air (OTA) technology. OTA is a technology for downloading data through wireless networks. Currently, the single-package upgrade strategy is mainly used. Specifically, the terminal device initiates a software version detection, and the server (also called the server) returns a download path to the terminal device. So that the terminal device obtains an OTA upgrade package according to the download path, and then performs version upgrade according to the OTA upgrade package. Moreover, in order to save storage resources of the server and time for terminal devices to download the OTA upgrade package, and reduce development costs, the OTA upgrade package is usually a differential file between two adjacent versions. In this way, when the current version of the software installed on the terminal device differs by more than one version from the latest version of the software released on the server, the terminal device needs to download multiple OTA upgrade packages to upgrade the software from the current version to the latest version.

然而,在上述多包连续升级的机制下,对于终端设备上安装的软件的当前版本较低,而服务器上发布的最新版本较高的情况,客户端检测到的OTA升级包的个数可能会非常多,客户端仅从一个服务器下载升级包的时间过长,影响用户体验。并且,若终端设备的存储空间不足和/或电量不足时,终端设备会出现升级失败的情况。However, under the above-mentioned multi-package continuous upgrade mechanism, if the current version of the software installed on the terminal device is lower and the latest version released on the server is higher, the number of OTA upgrade packages detected by the client may increase. Very often, it takes too long for the client to download the upgrade package from only one server, affecting the user experience. Moreover, if the terminal device has insufficient storage space and/or insufficient power, the terminal device may fail to upgrade.

发明内容Contents of the invention

本申请实施例提供一种软件升级方法,应用于终端设备,所述终端设备可以同时从多个服务端接收软件升级包,以提升接收升级包的传输吞吐量和升级速度,从而提高了升级过程的可靠性,提升了用户体验。Embodiments of the present application provide a software upgrade method, which is applied to terminal equipment. The terminal equipment can receive software upgrade packages from multiple servers at the same time to improve the transmission throughput and upgrade speed of receiving upgrade packages, thereby improving the upgrade process. reliability and improved user experience.

第一方面,本申请实施例提供一种软件升级方法,应用于终端设备,所述方法包括:In a first aspect, embodiments of the present application provide a software upgrade method, which is applied to terminal equipment. The method includes:

所述终端设备向第一服务端发送第一消息,所述第一信息用于请求第一服务端给所述终端设备发送第一升级数据包;The terminal device sends a first message to the first server, and the first information is used to request the first server to send a first upgrade data packet to the terminal device;

所述终端设备接收来自所述第一服务端的第一升级数据包;The terminal device receives the first upgrade data packet from the first server;

所述终端设备向第二服务端发送第二消息,所述第二信息用于请求第二服务端给所述终端设备发送第二升级数据包;The terminal device sends a second message to the second server, and the second information is used to request the second server to send a second upgrade data packet to the terminal device;

所述终端设备接收来自所述第二服务端的第二升级数据包;The terminal device receives a second upgrade data packet from the second server;

所述终端设备根据所述第一升级数据包和所述第二升级数据包更新目标软件。The terminal device updates the target software according to the first upgrade data package and the second upgrade data package.

通过从至少两个服务端接收软件升级包,可以有效提升接收升级包的传输吞吐量和升级速度,从而提高了升级过程的可靠性,也提升了用户体验。By receiving software upgrade packages from at least two servers, the transmission throughput and upgrade speed of receiving upgrade packages can be effectively improved, thereby improving the reliability of the upgrade process and improving user experience.

在一种可能的实现方式中,所述终端设备根据所述第一升级数据包和所述第二升级数据包更新目标软件,具体包括:In a possible implementation manner, the terminal device updates the target software according to the first upgrade data package and the second upgrade data package, specifically including:

响应于用户的输入操作,所述终端设备根据所述第一升级数据包和所述第二升级数据包更新目标软件。In response to the user's input operation, the terminal device updates the target software according to the first upgrade data package and the second upgrade data package.

这样,用户就可以在升级包下载完成后与终端设备交互,以在合适的时刻将升级包应用至目标软件的更新,有利于提升用户体验。In this way, the user can interact with the terminal device after the upgrade package is downloaded to apply the upgrade package to the target software update at the appropriate moment, which is beneficial to improving the user experience.

在一种可能的实现方式中,所述方法还包括:In a possible implementation, the method further includes:

所述终端设备显示第一提示信息,所述第一提示信息用于提示用户正在使用多个服务端进行加速下载和/或升级。The terminal device displays first prompt information, and the first prompt information is used to prompt the user that multiple servers are being used for accelerated downloading and/or upgrading.

这样,在第一和第二服务端都在为终端设备传送升级包时,用户能够从终端设备处获知升级包的下载情况,有利于提升用户体验。In this way, when both the first and second servers are transmitting the upgrade package to the terminal device, the user can learn the download status of the upgrade package from the terminal device, which is beneficial to improving the user experience.

在一种可能的实现方式中,所述方法还包括:In a possible implementation, the method further includes:

所述终端设备显示第二提示信息,所述第二提示信息用于提示用户升级速度的提升程度。The terminal device displays second prompt information, and the second prompt information is used to prompt the user to improve the upgrade speed.

这样,在第一和第二服务端都在为终端设备传送升级包时,用户能够从终端设备处获知升级速度的提升程度,有利于提升用户体验。In this way, when both the first and second servers are transmitting the upgrade package to the terminal device, the user can learn from the terminal device how much the upgrade speed has been improved, which is beneficial to improving the user experience.

在一种可能的实现方式中,所述第一升级数据包和所述第二升级数据包重叠或者不重叠。In a possible implementation manner, the first upgrade data packet and the second upgrade data packet overlap or do not overlap.

这样,由于不同服务端存储的软件升级数据包有可能是相同也有可能是不同的,故从第一和第二服务端分别下载的升级包可能重叠或不重叠,终端设备可以根据实际需要组合使用以提升升级的可靠性。In this way, since the software upgrade data packages stored by different servers may be the same or different, the upgrade packages downloaded from the first and second servers may or may not overlap, and the terminal devices can be combined and used according to actual needs. to improve the reliability of upgrades.

在一种可能的实现方式中,所述方法还包括:In a possible implementation, the method further includes:

所述终端设备获取所述第一服务端的负载情况和所述第二服务端的负载情况,并根据获取的负载情况增加或者减少所述第一服务端和/或所述第二服务端发送的数据包流量。The terminal device obtains the load situation of the first server and the load situation of the second server, and increases or decreases the data sent by the first server and/or the second server according to the obtained load situation. Packet traffic.

这样,终端设备可以增加负载较少的服务端的数据包流量,减少负载较多的服务端的数据包流量,以更加有效提升升级包的下载和升级速度。In this way, the terminal device can increase the data packet traffic of the server with less load and reduce the data packet traffic of the server with more load, so as to more effectively increase the download and upgrade speed of the upgrade package.

在一种可能的实现方式中,所述方法还包括:In a possible implementation, the method further includes:

所述终端设备获取所述第一服务端的传输链路情况和所述第二服务端的传输链路情况,并根据获取的传输链路情况增加或者减少所述第一服务端和/或所述第二服务端发送的数据包流量。The terminal device obtains the transmission link status of the first server and the transmission link status of the second server, and increases or decreases the first server and/or the third server according to the obtained transmission link status. 2. Data packet traffic sent by the server.

这样,终端设备可以增加传输链路情况较好的服务端的数据包流量,减少传输链路情况较差的服务端的数据包流量,以更加有效提升升级包的下载和升级速度。其中,传输链路情况包括但不限于信道质量、丢包率和重传次数。In this way, the terminal device can increase the data packet traffic of the server with good transmission link conditions and reduce the data packet traffic of the server with poor transmission link conditions, so as to more effectively increase the download and upgrade speed of the upgrade package. Among them, the transmission link conditions include but are not limited to channel quality, packet loss rate and number of retransmissions.

在一种可能的实现方式中,所述第一服务端或所述第二服务端是服务器、移动应用、云服务或其他终端设备。In a possible implementation, the first server or the second server is a server, mobile application, cloud service or other terminal device.

这样,由于不局限于常规的服务器作为升级软件的服务端,可以进一步拓宽下载渠道,提升软件升级速度。In this way, since it is not limited to conventional servers as the server for upgrading software, download channels can be further broadened and the speed of software upgrades can be improved.

第二方面,本申请实施例提供一种终端设备,包括:一个或多个处理器;以及存储器,所述存储器中存储有代码;当所述代码被终端设备执行时,使得所述终端设备执行第一方面的方法。In a second aspect, embodiments of the present application provide a terminal device, including: one or more processors; and a memory, where code is stored in the memory; when the code is executed by the terminal device, the terminal device is caused to execute The first approach.

第三方面,本申请实施例提供一种计算机存储介质,包括计算机指令,当所述计算机指令在终端设备上运行时,使得所述终端设备执行第一方面的方法。In a third aspect, embodiments of the present application provide a computer storage medium that includes computer instructions. When the computer instructions are run on a terminal device, the terminal device executes the method of the first aspect.

第四方面,本申请实施例提供一种计算机程序产品,当所述计算机程序产品在计算机上运行时,使得所述计算机执行第一方面的方法。In a fourth aspect, embodiments of the present application provide a computer program product, which when the computer program product is run on a computer, causes the computer to execute the method of the first aspect.

第五方面,本申请实施例提供一种软件升级系统,包括:终端设备、第一服务端和第二服务端,软件升级系统包括:一个或多个处理器;以及存储器,存储器中存储有代码;当代码被软件升级系统执行时,使得软件升级系统执行第一方面的方法。In a fifth aspect, embodiments of the present application provide a software upgrade system, including: a terminal device, a first server and a second server. The software upgrade system includes: one or more processors; and a memory, with codes stored in the memory. ; When the code is executed by the software upgrade system, the software upgrade system is caused to execute the method of the first aspect.

本申请第二至五方面的技术方案所达到的技术效果可参见第一方面的内容。The technical effects achieved by the technical solutions of the second to fifth aspects of this application can be found in the content of the first aspect.

附图说明Description of drawings

图1为本申请实施例提供的一种软件升级系统的架构示意图;Figure 1 is a schematic architectural diagram of a software upgrade system provided by an embodiment of the present application;

图2为本申请实施例提供的一种手机的结构示意图;Figure 2 is a schematic structural diagram of a mobile phone provided by an embodiment of the present application;

图3为本申请实施例提供的一种手机的软件结构框图;Figure 3 is a software structure block diagram of a mobile phone provided by an embodiment of the present application;

图4为本申请实施例提供的一种软件升级方法的流程图;Figure 4 is a flow chart of a software upgrade method provided by an embodiment of the present application;

图5为本申请实施例提供的一种手机的界面示意图;Figure 5 is a schematic interface diagram of a mobile phone provided by an embodiment of the present application;

图6为本申请实施例提供的另一种手机的界面示意图;Figure 6 is a schematic interface diagram of another mobile phone provided by an embodiment of the present application;

图7为本申请实施例提供的另两种软件升级系统的架构示意图;Figure 7 is a schematic architectural diagram of two other software upgrade systems provided by embodiments of the present application;

图8为本申请实施例提供的一种终端设备的结构示意图。Figure 8 is a schematic structural diagram of a terminal device provided by an embodiment of the present application.

具体实施方式Detailed ways

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行描述。其中,在本申请实施例的描述中,除非另有说明,“/”表示或的意思,例如,A/B可以表示A或B;本文中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,在本申请实施例的描述中,“多个”是指两个或多于两个。The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application. Among them, in the description of the embodiments of this application, unless otherwise stated, "/" means or, for example, A/B can mean A or B; "and/or" in this article is only a way to describe related objects. The association relationship means that there can be three relationships. For example, A and/or B can mean: A alone exists, A and B exist simultaneously, and B alone exists. In addition, in the description of the embodiments of this application, "plurality" refers to two or more than two.

以下,术语“第一”、“第二”仅用于描述目的,而不能理解为暗示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括一个或者更多个该特征,在本申请实施例的描述中,除非另有说明,“多个”的含义是两个或两个以上。Hereinafter, the terms “first” and “second” are used for descriptive purposes only and shall not be understood as implying or implying relative importance or implicitly specifying the quantity of indicated technical features. Therefore, the features defined as “first” and “second” may explicitly or implicitly include one or more of the features. In the description of the embodiments of this application, unless otherwise specified, “plurality” The meaning is two or more.

目前,通常在如图1所示的系统架构下实现终端设备中软件的在线升级:首先终端设备101通过通信网络(如经过基站102)访问存储有软件包的服务器103,检测服务器103上是否有新的升级软件版本,若确定服务器103上有新的升级软件版本,则从服务器上下载升级软件包,或者,服务器向该终端设备103返回一个下载路径,进行软件升级。示例性的,上述通信网络可以是无线网络。例如,上述通信网络可以是局域网(local area networks,LAN),也可以是广域网(wide area networks,WAN),例如互联网。上述通信网络可使用任何已知的网络通信协议来实现,上述网络通信协议可以是各种有线或无线通信协议,诸如以太网、通用串行总线(universal serial bus,USB)、火线(FIREWIRE)、全球移动通讯系统(global system for mobile communications,GSM)、通用分组无线服务(general packetradio service,GPRS)、码分多址接入(code division multiple access,CDMA)、宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-divisioncode division multiple access,TDSCDMA),长期演进(long term evolution,LTE)、蓝牙、无线保真(wireless fidelity,WiFi)、NFC、基于互联网协议的语音通话(voice overInternet protocol,VoIP)、支持网络切片架构的通信协议或任何其他合适的通信协议。At present, online upgrade of software in terminal equipment is usually implemented under the system architecture as shown in Figure 1: First, the terminal equipment 101 accesses the server 103 where the software package is stored through the communication network (such as through the base station 102), and detects whether there is any software package on the server 103. For a new upgrade software version, if it is determined that there is a new upgrade software version on the server 103, the upgrade software package will be downloaded from the server, or the server will return a download path to the terminal device 103 for software upgrade. For example, the above communication network may be a wireless network. For example, the above communication network may be a local area network (LAN) or a wide area network (WAN), such as the Internet. The above communication network can be implemented using any known network communication protocol. The above network communication protocol can be various wired or wireless communication protocols, such as Ethernet, universal serial bus (universal serial bus, USB), FireWire, Global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (wideband code division multiple access (WCDMA), time-division code division multiple access (TDSCDMA), long term evolution (LTE), Bluetooth, wireless fidelity (WiFi), NFC, Internet protocol-based Voice over Internet protocol (VoIP), communication protocol supporting network slicing architecture, or any other suitable communication protocol.

随着移动通信技术的发展,手机、平板电脑等终端设备的系统软件固定版本的升级通常应用空中下载(Over the Air,OTA)技术。OTA是一种通过无线网络进行数据下载的技术,目前OTA主要采用的是单包升级策略,具体为,终端设备发起一次软件版本检测,服务器(也称服务端)向该终端设备返回一个下载路径,以便终端设备根据该下载路径获得一个OTA升级包,进而根据该OTA升级包进行版本升级。然而,以上方案中主要使用的某一个服务端,属于单个数据源。单个数据源会受到单一链路可靠性、单一节点吞吐量的限制,从而影响OTA升级版的下载速度和下载成功率。With the development of mobile communication technology, over-the-air (OTA) technology is usually used to upgrade fixed versions of system software on terminal devices such as mobile phones and tablet computers. OTA is a technology for downloading data through wireless networks. Currently, OTA mainly adopts a single-package upgrade strategy. Specifically, the terminal device initiates a software version detection, and the server (also called the server) returns a download path to the terminal device. , so that the terminal device obtains an OTA upgrade package according to the download path, and then performs version upgrade according to the OTA upgrade package. However, a certain server mainly used in the above scheme belongs to a single data source. A single data source will be limited by the reliability of a single link and the throughput of a single node, thus affecting the download speed and download success rate of the OTA upgrade version.

并且,为了节省服务器的存储资源和终端设备下载OTA升级包的时间,以及降低开发成本,所述的OTA升级包通常为相邻两个版本之间的差分文件。这样,当终端设备安装的软件的当前版本与服务器上发布的该软件的最新版本相差不止一个版本时,终端设备需要下载多个OTA升级包才能将软件从当前版本升级到最新版本。在上述多个OTA升级包连续升级的情况下,如果终端设备上安装的软件的当前版本较低,而服务器上发布的最新版本较高,终端设备检测到的OTA升级包的个数可能会非常多,终端设备仅从一个服务器下载升级包的时间过长,影响用户体验。另外,若终端设备的存储空间不足和/或电量不足时,终端设备会出现升级失败的情况。Moreover, in order to save storage resources of the server and time for the terminal device to download the OTA upgrade package, and reduce development costs, the OTA upgrade package is usually a differential file between two adjacent versions. In this way, when the current version of the software installed on the terminal device differs by more than one version from the latest version of the software released on the server, the terminal device needs to download multiple OTA upgrade packages to upgrade the software from the current version to the latest version. In the above situation where multiple OTA upgrade packages are continuously upgraded, if the current version of the software installed on the terminal device is lower and the latest version released on the server is higher, the number of OTA upgrade packages detected by the terminal device may be very large. Many times, it takes too long for the terminal device to download the upgrade package from only one server, affecting the user experience. In addition, if the terminal device has insufficient storage space and/or insufficient power, the terminal device may fail to upgrade.

本申请实施例提供的一种软件升级方法,可应用于图1所示的终端设备101中。所述方法包括:终端设备101可以请求第一服务端、第二服务端等多个服务端分别发送相同或不同的升级数据包,终端设备101根据接收到的多个升级数据包来更新目标软件。由于终端设备可以同时从多个服务端接收软件升级包,因此可以提高升级包的下载速度,从而可以扩大传输吞吐量和提高升级速度,提升了用户体验。The software upgrade method provided by the embodiment of the present application can be applied to the terminal device 101 shown in Figure 1 . The method includes: the terminal device 101 can request multiple servers such as the first server and the second server to respectively send the same or different upgrade data packets, and the terminal device 101 updates the target software according to the multiple upgrade data packets received. . Since the terminal device can receive software upgrade packages from multiple servers at the same time, the download speed of the upgrade package can be increased, thereby expanding the transmission throughput and improving the upgrade speed, thereby improving the user experience.

示例性的,上述终端设备101具体可以为手机、可折叠电子设备、平板电脑、桌面型计算机、膝上型计算机、手持计算机、电视、可穿戴设备、车载设备、增强现实(augmentedreality,AR)/虚拟现实(virtual reality,VR)设备、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、个人数字助理(personal digitalassistant,PDA)、蜂窝电话、人工智能设备、智能家居设备、智慧城市设备等,本申请实施例对该终端设备的具体类型不作任何限制。For example, the terminal device 101 may be a mobile phone, a foldable electronic device, a tablet computer, a desktop computer, a laptop computer, a handheld computer, a television, a wearable device, a vehicle-mounted device, or an augmented reality (AR)/ Virtual reality (VR) devices, laptops, ultra-mobile personal computers (UMPC), netbooks, personal digital assistants (PDAs), cellular phones, artificial intelligence devices, smart home devices, Smart city equipment, etc., the embodiments of this application do not place any restrictions on the specific types of terminal equipment.

以手机作为上述终端设备101举例,图2示出了手机的结构示意图。Taking a mobile phone as the above-mentioned terminal device 101 as an example, FIG. 2 shows a schematic structural diagram of the mobile phone.

手机可以包括处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,气压传感器180C,磁传感器180D,加速度传感器180E,距离传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,骨传导传感器180M等。The mobile phone may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, and a mobile phone. Communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone interface 170D, sensor module 180, button 190, motor 191, indicator 192, camera 193, display screen 194, and user identification Module (subscriber identification module, SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyro sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.

可以理解的是,本申请实施例示意的结构并不构成对手机的具体限定。在本申请另一些实施例中,手机可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。It can be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the mobile phone. In other embodiments of the present application, the mobile phone may include more or less components than shown in the figures, or some components may be combined, some components may be separated, or some components may be arranged differently. The components illustrated may be implemented in hardware, software, or a combination of software and hardware.

处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processingunit,GPU),图像信号处理器(image signal processor,ISP),控制器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 110 may include one or more processing units. For example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processing unit (GPU), an image signal processor ( image signal processor (ISP), controller, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural network processing unit (NPU), etc. Among them, different processing units can be independent devices or integrated in one or more processors.

控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller can generate operation control signals based on the instruction operation code and timing signals to complete the control of fetching and executing instructions.

处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in processor 110 is cache memory. This memory may hold instructions or data that have been recently used or recycled by processor 110 . If the processor 110 needs to use the instructions or data again, it can be called directly from the memory. Repeated access is avoided and the waiting time of the processor 110 is reduced, thus improving the efficiency of the system.

在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuitsound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purposeinput/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In some embodiments, processor 110 may include one or more interfaces. The interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuitsound, I2S) interface, a pulse code modulation (PCM) interface, and a universal asynchronous receiver (universal asynchronous receiver) /transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (subscriber identity module, SIM) interface, and/or Universal serial bus (USB) interface, etc.

I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K,充电器,闪光灯,摄像头193等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现手机的触摸功能。The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (derail clock line, SCL). In some embodiments, processor 110 may include multiple sets of I2C buses. The processor 110 can separately couple the touch sensor 180K, charger, flash, camera 193, etc. through different I2C bus interfaces. For example, the processor 110 can be coupled to the touch sensor 180K through an I2C interface, so that the processor 110 and the touch sensor 180K communicate through the I2C bus interface to implement the touch function of the mobile phone.

I2S接口可以用于音频通信。在一些实施例中,处理器110可以包含多组I2S总线。处理器110可以通过I2S总线与音频模块170耦合,实现处理器110与音频模块170之间的通信。在一些实施例中,音频模块170可以通过I2S接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。The I2S interface can be used for audio communication. In some embodiments, processor 110 may include multiple sets of I2S buses. The processor 110 can be coupled with the audio module 170 through the I2S bus to implement communication between the processor 110 and the audio module 170 . In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface to implement the function of answering calls through a Bluetooth headset.

PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块170与无线通信模块160可以通过PCM总线接口耦合。在一些实施例中,音频模块170也可以通过PCM接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。所述I2S接口和所述PCM接口都可以用于音频通信。The PCM interface can also be used for audio communications to sample, quantize and encode analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface to implement the function of answering calls through a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.

UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。例如:处理器110通过UART接口与无线通信模块160中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块170可以通过UART接口向无线通信模块160传递音频信号,实现通过蓝牙耳机播放音乐的功能。The UART interface is a universal serial data bus used for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is generally used to connect the processor 110 and the wireless communication module 160 . For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface to implement the function of playing music through a Bluetooth headset.

MIPI接口可以被用于连接处理器110与显示屏194,摄像头193等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(displayserial interface,DSI)等。在一些实施例中,处理器110和摄像头193通过CSI接口通信,实现手机的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现手机的显示功能。The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 . MIPI interfaces include camera serial interface (CSI), display serial interface (displayserial interface, DSI), etc. In some embodiments, the processor 110 and the camera 193 communicate through the CSI interface to implement the shooting function of the mobile phone. The processor 110 and the display screen 194 communicate through the DSI interface to implement the display function of the mobile phone.

GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头193,显示屏194,无线通信模块160,音频模块170,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。The GPIO interface can be configured through software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, display screen 194, wireless communication module 160, audio module 170, sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, etc.

USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口130可以用于连接充电器为手机充电,也可以用于手机与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。The USB interface 130 is an interface that complies with USB standard specifications, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the mobile phone, and can also be used to transmit data between the mobile phone and peripheral devices. It can also be used to connect headphones to play audio through them. This interface can also be used to connect other electronic devices, such as AR devices, etc.

可以理解的是,本申请实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对手机的结构限定。在本申请另一些实施例中,手机也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。It can be understood that the interface connection relationships between the modules illustrated in the embodiments of the present application are only schematic illustrations and do not constitute structural limitations on the mobile phone. In other embodiments of the present application, the mobile phone may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。在一些有线充电的实施例中,充电管理模块140可以通过USB接口130接收有线充电器的充电输入。在一些无线充电的实施例中,充电管理模块140可以通过手机的无线充电线圈接收无线充电输入。充电管理模块140为电池142充电的同时,还可以通过电源管理模块141为终端设备供电。The charging management module 140 is used to receive charging input from the charger. Among them, the charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from the wired charger through the USB interface 130 . In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through the wireless charging coil of the mobile phone. While charging the battery 142, the charging management module 140 can also provide power to the terminal device through the power management module 141.

电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,显示屏194,摄像头193,和无线通信模块160等供电。电源管理模块141还可以用于监测电池容量,电池循环次数,电池健康状态(漏电,阻抗)等参数。在其他一些实施例中,电源管理模块141也可以设置于处理器110中。在另一些实施例中,电源管理模块141和充电管理模块140也可以设置于同一个器件中。The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the display screen 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 can also be used to monitor battery capacity, battery cycle times, battery health status (leakage, impedance) and other parameters. In some other embodiments, the power management module 141 may also be provided in the processor 110 . In other embodiments, the power management module 141 and the charging management module 140 may also be provided in the same device.

手机的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。The wireless communication function of the mobile phone can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.

天线1和天线2用于发射和接收电磁波信号。手机中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in a phone can be used to cover a single or multiple communication bands. Different antennas can also be reused to improve antenna utilization. For example: Antenna 1 can be reused as a diversity antenna for a wireless LAN. In other embodiments, antennas may be used in conjunction with tuning switches.

移动通信模块150可以提供应用在手机上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(lownoise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。The mobile communication module 150 can provide wireless communication solutions including 2G/3G/4G/5G applied to mobile phones. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves through the antenna 1, perform filtering, amplification and other processing on the received electromagnetic waves, and transmit them to the modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves through the antenna 1 for radiation. In some embodiments, at least part of the functional modules of the mobile communication module 150 may be disposed in the processor 110 . In some embodiments, at least part of the functional modules of the mobile communication module 150 and at least part of the modules of the processor 110 may be provided in the same device.

调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。A modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs sound signals through audio devices (not limited to speaker 170A, receiver 170B, etc.), or displays images or videos through display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be independent of the processor 110 and may be provided in the same device as the mobile communication module 150 or other functional modules.

无线通信模块160可以提供应用在手机上的包括无线局域网(wireless localarea networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequencymodulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。The wireless communication module 160 can provide applications on the mobile phone including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) network), Bluetooth (bluetooth, BT), global navigation satellite system (global navigation satellite system). navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared technology (infrared, IR) and other wireless communication solutions. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 . The wireless communication module 160 can also receive the signal to be sent from the processor 110, frequency modulate it, amplify it, and convert it into electromagnetic waves through the antenna 2 for radiation.

在一些实施例中,手机的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得手机可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括GSM,GPRS,CDMA,WCDMA,TD-SCDMA,LTE,BT,GNSS,WLAN,NFC,FM,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system,GLONASS),北斗卫星导航系统(beidounavigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellitesystem,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。在本申请的一些实施例中,手机通过无线通信模块150或无线通信模块160与图1所示的基站102建立通信连接。经由天线1或天线2,手机可以向图1所示的服务器103发送软件版本检测请求,检测系统软件或其他安装软件的版本是否已更新至最新版本。如果检测到有新版本可以更新,则可以通过无线通信模块150或无线通信模块160从服务器103或服务器103返回的下载路径下载软件的最新版本。In some embodiments, the antenna 1 of the mobile phone is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the mobile phone can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include GSM, GPRS, CDMA, WCDMA, TD-SCDMA, LTE, BT, GNSS, WLAN, NFC, FM, and/or IR technology, etc. The GNSS may include global positioning system (GPS), global navigation satellite system (GLONASS), Beidou satellite navigation system (beidounavigation satellite system, BDS), quasi-zenith satellite system (quasi- zenith satellitesystem (QZSS) and/or satellite based augmentation systems (SBAS). In some embodiments of the present application, the mobile phone establishes a communication connection with the base station 102 shown in Figure 1 through the wireless communication module 150 or the wireless communication module 160. Via antenna 1 or antenna 2, the mobile phone can send a software version detection request to the server 103 shown in Figure 1 to detect whether the version of the system software or other installed software has been updated to the latest version. If it is detected that a new version can be updated, the latest version of the software can be downloaded from the server 103 or the download path returned by the server 103 through the wireless communication module 150 or the wireless communication module 160 .

手机通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The mobile phone implements display functions through the GPU, display screen 194, and application processor. The GPU is an image processing microprocessor and is connected to the display screen 194 and the application processor. GPUs are used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.

显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emittingdiode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrixorganic light emitting diode的,AMOLED),柔性发光二极管(flex light-emittingdiode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot lightemitting diodes,QLED)等。在一些实施例中,手机可以包括1个或N个显示屏194,N为大于1的正整数。在本申请的一些实施例中,用户可以通过显示屏194查看手机的系统软件或其他安装软件的版本是否已更新至最新版本。例如,如图5(a)所示,在手机的设置界面501下点击“系统和更新”选项502,进入至如图5(b)所示的“系统和更新”界面503,选择“软件更新”选项504后,手机会自动检测系统软件(例如EMUI)是否是最新版本。如果检测到有新版本可以更新,如图5(c)所示,则可以通过点击新版本控件507以下载系统软件的最新版本。The display screen 194 is used to display images, videos, etc. Display 194 includes a display panel. The display panel can use a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active matrix organic light emitting diode or an active matrix organic light emitting diode (active-matrix organic light emitting diode). (AMOLED), flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diodes (QLED), etc. In some embodiments, the mobile phone may include 1 or N display screens 194, where N is a positive integer greater than 1. In some embodiments of the present application, the user can check whether the system software or other installed software versions of the mobile phone have been updated to the latest version through the display screen 194 . For example, as shown in Figure 5(a), click the "System and Update" option 502 under the settings interface 501 of the mobile phone to enter the "System and Update" interface 503 as shown in Figure 5(b), and select "Software Update" "After option 504, the phone will automatically detect whether the system software (such as EMUI) is the latest version. If it is detected that a new version can be updated, as shown in Figure 5(c), you can download the latest version of the system software by clicking the new version control 507.

手机可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。The mobile phone can realize the shooting function through the ISP, camera 193, video codec, GPU, display 194 and application processor.

ISP用于处理摄像头193反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头193中。The ISP is used to process the data fed back by the camera 193. For example, when taking a photo, the shutter is opened, the light is transmitted to the camera sensor through the lens, the optical signal is converted into an electrical signal, and the camera sensor passes the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on image noise, brightness, and skin color. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP may be provided in the camera 193.

摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,手机可以包括1个或N个摄像头193,N为大于1的正整数。Camera 193 is used to capture still images or video. The object passes through the lens to produce an optical image that is projected onto the photosensitive element. The photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then passes the electrical signal to the ISP to convert it into a digital image signal. ISP outputs digital image signals to DSP for processing. DSP converts digital image signals into standard RGB, YUV and other format image signals. In some embodiments, the mobile phone may include 1 or N cameras 193, where N is a positive integer greater than 1.

数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当手机在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。Digital signal processors are used to process digital signals. In addition to digital image signals, they can also process other digital signals. For example, when the mobile phone selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

视频编解码器用于对数字视频压缩或解压缩。手机可以支持一种或多种视频编解码器。这样,手机可以播放或录制多种编码格式的视频,例如:动态图像专家组(movingpicture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。Video codecs are used to compress or decompress digital video. A mobile phone can support one or more video codecs. In this way, the mobile phone can play or record videos in multiple encoding formats, such as: Moving Picture Experts Group (MPEG)1, MPEG2, MPEG3, MPEG4, etc.

NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现手机的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can continuously learn by itself. NPU can realize intelligent cognitive applications of mobile phones, such as image recognition, face recognition, speech recognition, text understanding, etc.

外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展手机的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the mobile phone. The external memory card communicates with the processor 110 through the external memory interface 120 to implement the data storage function. Such as saving music, videos, etc. files in external memory card.

内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储手机使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。处理器110通过运行存储在内部存储器121的指令,和/或存储在设置于处理器中的存储器的指令,执行手机的各种功能应用以及数据处理。Internal memory 121 may be used to store computer executable program code, which includes instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the stored program area can store an operating system, at least one application program required for a function (such as a sound playback function, an image playback function, etc.). The storage data area can store data created during the use of the mobile phone (such as audio data, phone book, etc.). In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), etc. The processor 110 executes instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor to execute various functional applications and data processing of the mobile phone.

手机可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。The mobile phone can implement audio functions through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone interface 170D, and the application processor. Such as music playback, recording, etc.

音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .

扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。手机可以通过扬声器170A收听音乐,或收听免提通话。Speaker 170A, also called "speaker", is used to convert audio electrical signals into sound signals. The mobile phone can listen to music through speaker 170A, or listen to hands-free calls.

受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当手机接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。Receiver 170B, also called "earpiece", is used to convert audio electrical signals into sound signals. When the mobile phone answers a call or voice message, the voice can be heard by bringing the receiver 170B close to the human ear.

麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。手机可以设置至少一个麦克风170C。在另一些实施例中,手机可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,手机还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak close to the microphone 170C with the human mouth and input the sound signal to the microphone 170C. The mobile phone can be set with at least one microphone 170C. In other embodiments, the mobile phone can be equipped with two microphones 170C, which in addition to collecting sound signals, can also implement noise reduction functions. In other embodiments, the mobile phone can also be equipped with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions, etc.

耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。The headphone interface 170D is used to connect wired headphones. The headphone interface 170D may be a USB interface 130, or may be a 3.5 mm open mobile terminal platform (OMTP) standard interface or a Cellular Telecommunications Industry Association of the USA (CTIA) standard interface.

压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。手机根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,手机根据压力传感器180A检测所述触摸操作强度。手机也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。The pressure sensor 180A is used to sense pressure signals and can convert the pressure signals into electrical signals. In some embodiments, pressure sensor 180A may be disposed on display screen 194 . There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. A capacitive pressure sensor may include at least two parallel plates of conductive material. When a force is applied to pressure sensor 180A, the capacitance between the electrodes changes. The phone determines the intensity of the pressure based on changes in capacitance. When a touch operation is performed on the display screen 194, the mobile phone detects the strength of the touch operation according to the pressure sensor 180A. The mobile phone can also calculate the touch position based on the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch location but with different touch operation intensities may correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold is applied to the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold is applied to the short message application icon, an instruction to create a new short message is executed.

陀螺仪传感器180B可以用于确定手机的运动姿态。在一些实施例中,可以通过陀螺仪传感器180B确定手机围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器180B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器180B检测手机抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消手机的抖动,实现防抖。陀螺仪传感器180B还可以用于导航,体感游戏场景。The gyro sensor 180B can be used to determine the movement posture of the mobile phone. In some embodiments, the angular velocity of the phone about three axes (ie, x, y, and z axes) may be determined by gyro sensor 180B. The gyro sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyro sensor 180B detects the angle at which the mobile phone shakes, and calculates the distance that the lens module needs to compensate based on the angle, so that the lens can counteract the shake of the mobile phone through reverse movement to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenes.

气压传感器180C用于测量气压。在一些实施例中,手机通过气压传感器180C测得的气压值计算海拔高度,辅助定位和导航。Air pressure sensor 180C is used to measure air pressure. In some embodiments, the mobile phone calculates the altitude based on the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.

磁传感器180D包括霍尔传感器。手机可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当手机是翻盖机时,手机可以根据磁传感器180D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。Magnetic sensor 180D includes a Hall sensor. The mobile phone can use the magnetic sensor 180D to detect the opening and closing of the flip leather case. In some embodiments, when the mobile phone is a flip phone, the mobile phone can detect the opening and closing of the flip cover based on the magnetic sensor 180D. Then, based on the detected opening and closing status of the leather case or the opening and closing status of the flip cover, features such as automatic unlocking of the flip cover are set.

加速度传感器180E可检测手机在各个方向上(一般为三轴)加速度的大小。当手机静止时可检测出重力的大小及方向。还可以用于识别终端设备姿态,应用于横竖屏切换,计步器等应用。The acceleration sensor 180E can detect the acceleration of the mobile phone in various directions (generally three axes). When the mobile phone is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of terminal devices and be used in applications such as horizontal and vertical screen switching, pedometers, etc.

距离传感器180F,用于测量距离。手机可以通过红外或激光测量距离。在一些实施例中,拍摄场景,手机可以利用距离传感器180F测距以实现快速对焦。Distance sensor 180F for measuring distance. Cell phones can measure distance using infrared or laser. In some embodiments, when shooting scenes, the mobile phone can use the distance sensor 180F to measure distance to achieve fast focusing.

接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。手机通过发光二极管向外发射红外光。手机使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定手机附近有物体。当检测到不充分的反射光时,手机可以确定手机附近没有物体。手机可以利用接近光传感器180G检测用户手持手机贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋模式自动解锁与锁屏。Proximity light sensor 180G may include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The mobile phone emits infrared light through light-emitting diodes. Cell phones use photodiodes to detect reflected infrared light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the phone. When insufficient reflected light is detected, the phone can determine that there are no objects near the phone. The mobile phone can use the proximity light sensor 180G to detect when the user is holding the mobile phone close to the ear to talk, so that the screen can be automatically turned off to save power. The proximity light sensor 180G can also be used in holster mode, and pocket mode automatically unlocks and locks the screen.

环境光传感器180L用于感知环境光亮度。手机可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环境光传感器180L还可以与接近光传感器180G配合,检测手机是否在口袋里,以防误触。The ambient light sensor 180L is used to sense ambient light brightness. The mobile phone can adaptively adjust the brightness of the display screen 194 based on the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the phone is in your pocket to prevent accidental touches.

指纹传感器180H用于采集指纹。手机可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。Fingerprint sensor 180H is used to collect fingerprints. The mobile phone can use the collected fingerprint characteristics to unlock the fingerprint, access the application lock, take pictures with the fingerprint, answer incoming calls with the fingerprint, etc.

温度传感器180J用于检测温度。在一些实施例中,手机利用温度传感器180J检测的温度,执行温度处理策略。例如,当温度传感器180J上报的温度超过阈值,手机执行降低位于温度传感器180J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,手机对电池142加热,以避免低温导致手机异常关机。在其他一些实施例中,当温度低于又一阈值时,手机对电池142的输出电压执行升压,以避免低温导致的异常关机。Temperature sensor 180J is used to detect temperature. In some embodiments, the mobile phone uses the temperature detected by the temperature sensor 180J to execute the temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the mobile phone reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the mobile phone heats the battery 142 to prevent the low temperature from causing the mobile phone to shut down abnormally. In some other embodiments, when the temperature is lower than another threshold, the mobile phone boosts the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.

触摸传感器180K,也称“触控器件”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于手机的表面,与显示屏194所处的位置不同。在本申请的一些实施例中,用户在通过显示屏194查看到手机的系统软件或其他安装软件的版本有新版本可以更新,如图5(c)所示,则可以通过点击新版本控件507以下载系统软件的最新版本。该新版本控件507对应的触摸传感器180K接收到作用于其上的触摸操作,可以将检测到的该触摸操作传递给应用处理器,从而触发处理器下载系统软件的最新版本。Touch sensor 180K, also known as "touch device". The touch sensor 180K can be disposed on the display screen 194. The touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen". The touch sensor 180K is used to detect a touch operation on or near the touch sensor 180K. The touch sensor can pass the detected touch operation to the application processor to determine the touch event type. Visual output related to the touch operation may be provided through display screen 194 . In other embodiments, the touch sensor 180K may also be disposed on the surface of the mobile phone in a position different from that of the display screen 194 . In some embodiments of the present application, when the user sees through the display screen 194 that the system software or other installed software of the mobile phone has a new version that can be updated, as shown in Figure 5(c), the user can click the new version control 507 to download the latest version of system software. The touch sensor 180K corresponding to the new version control 507 receives a touch operation acting on it and can pass the detected touch operation to the application processor, thereby triggering the processor to download the latest version of the system software.

骨传导传感器180M可以获取振动信号。在一些实施例中,骨传导传感器180M可以获取人体声部振动骨块的振动信号。骨传导传感器180M也可以接触人体脉搏,接收血压跳动信号。在一些实施例中,骨传导传感器180M也可以设置于耳机中,结合成骨传导耳机。音频模块170可以基于所述骨传导传感器180M获取的声部振动骨块的振动信号,解析出语音信号,实现语音功能。应用处理器可以基于所述骨传导传感器180M获取的血压跳动信号解析心率信息,实现心率检测功能。Bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human body's vocal part. The bone conduction sensor 180M can also contact the human body's pulse and receive blood pressure beating signals. In some embodiments, the bone conduction sensor 180M can also be provided in an earphone and combined into a bone conduction earphone. The audio module 170 can analyze the voice signal based on the vibration signal of the vocal vibrating bone obtained by the bone conduction sensor 180M to implement the voice function. The application processor can analyze the heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 180M to implement the heart rate detection function.

按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。手机可以接收按键输入,产生与手机的用户设置以及功能控制有关的键信号输入。The buttons 190 include a power button, a volume button, etc. Key 190 may be a mechanical key. It can also be a touch button. The mobile phone can receive key input and generate key signal input related to user settings and function control of the mobile phone.

马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏194不同区域的触摸操作,马达191也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。The motor 191 can generate vibration prompts. The motor 191 can be used for vibration prompts for incoming calls and can also be used for touch vibration feedback. For example, touch operations for different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. The motor 191 can also respond to different vibration feedback effects for touch operations in different areas of the display screen 194 . Different application scenarios (such as time reminders, receiving information, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.

指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。The indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, or may be used to indicate messages, missed calls, notifications, etc.

SIM卡接口195用于连接SIM卡。SIM卡可以通过插入SIM卡接口195,或从SIM卡接口195拔出,实现和手机的接触和分离。手机可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口195可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口195可以同时插入多张卡。所述多张卡的类型可以相同,也可以不同。SIM卡接口195也可以兼容不同类型的SIM卡。SIM卡接口195也可以兼容外部存储卡。手机通过SIM卡和网络交互,实现通话以及数据通信等功能。在一些实施例中,手机采用eSIM,即:嵌入式SIM卡。eSIM卡可以嵌在手机中,不能和手机分离。The SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into the SIM card interface 195 or pulled out from the SIM card interface 195 to achieve contact and separation from the mobile phone. The mobile phone can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card, etc. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different. The SIM card interface 195 is also compatible with different types of SIM cards. The SIM card interface 195 is also compatible with external memory cards. The mobile phone interacts with the network through the SIM card to realize functions such as calls and data communication. In some embodiments, the mobile phone uses an eSIM, that is, an embedded SIM card. The eSIM card can be embedded in the mobile phone and cannot be separated from the mobile phone.

上述手机的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的Android系统为例,示例性说明手机的软件结构。The software system of the above-mentioned mobile phones can adopt layered architecture, event-driven architecture, micro-core architecture, micro-service architecture, or cloud architecture. The embodiment of this application takes the Android system with a layered architecture as an example to illustrate the software structure of the mobile phone.

仍以手机为上述终端设备101举例,图3示出了本申请实施例的手机的软件结构框图。Still taking a mobile phone as the above-mentioned terminal device 101 as an example, FIG. 3 shows a software structure block diagram of the mobile phone according to the embodiment of the present application.

分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。The layered architecture divides the software into several layers, and each layer has clear roles and division of labor. The layers communicate through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: application layer, application framework layer, Android runtime (Android runtime) and system libraries, and kernel layer.

应用程序层可以包括一系列应用程序。The application layer can include a series of applications.

如图3所示,应用程序层中可以包括通话,备忘录,浏览器,联系人,相机,图库,日历,地图,音乐,视频,短信息等应用(application,APP),还可以包括系统软件应用,例如EMUI;或者,应用程序层中可以由用户到应用市场下载安装微信等第三方应用。As shown in Figure 3, the application layer can include applications (applications, APPs) such as calls, memos, browsers, contacts, cameras, galleries, calendars, maps, music, videos, and short messages, and can also include system software applications. , such as EMUI; or, in the application layer, users can go to the application market to download and install third-party applications such as WeChat.

在本申请实施例中,用户可以从手机桌面或下拉菜单上的设置功能等入口打开系统软件应用,在系统软件应用内可以通过打开“软件更新”选项以查看本机系统软件是否已更新至最新版本。示例性地,在打开系统软件应用的情况下,用户可以在系统软件应用内查看终端设备的系统软件名称及当前版本、当前版本是否为最新版本等。此外,用户还可以设置系统软件的自动下载和/或自动安装,包括在WLAN下自动下载升级包或更新应用,以及下载后在凌晨等空闲时间自动安装等。与此相似,用户自主安装的第三方应用的设置中也有检查新版本等。In the embodiment of this application, the user can open the system software application from the mobile phone desktop or the settings function on the drop-down menu. In the system software application, the user can check whether the local system software has been updated to the latest by opening the "Software Update" option. Version. For example, when the system software application is opened, the user can check the system software name and current version of the terminal device in the system software application, whether the current version is the latest version, etc. In addition, users can also set up automatic download and/or automatic installation of system software, including automatically downloading upgrade packages or updating applications under WLAN, and automatically installing them during free time such as early morning after downloading. Similarly, the settings of third-party applications installed by users also include checking for new versions, etc.

应用程序框架层为应用程序层的应用程序提供应用编程接口(applicationprogramming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。The application framework layer provides an application programming interface (API) and programming framework for applications in the application layer. The application framework layer includes some predefined functions.

如图3所示,应用程序框架层还可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,输入管理器,通知管理器等,本申请实施例对此不做任何限制。As shown in Figure 3, the application framework layer may also include a window manager, a content provider, a view system, a phone manager, a resource manager, an input manager, a notification manager, etc. This embodiment of the present application does not do anything about this. limit.

上述窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。The above-mentioned window manager is used to manage window programs. The window manager can obtain the display size, determine whether there is a status bar, lock the screen, capture the screen, etc.

上述内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。The above content providers are used to store and retrieve data and make this data accessible to applications. Said data can include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

上述视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。The above view system includes visual controls, such as controls for displaying text, controls for displaying pictures, etc. A view system can be used to build applications. The display interface can be composed of one or more views. For example, a display interface including a text message notification icon may include a view for displaying text and a view for displaying pictures.

上述电话管理器用于提供手机的通信功能。例如通话状态的管理(包括接通,挂断等)。上述资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。The above-mentioned phone manager is used to provide communication functions of the mobile phone. For example, call status management (including connected, hung up, etc.). The above resource manager provides various resources to applications, such as localized strings, icons, pictures, layout files, video files, etc.

上述通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,系统软件有新版本的消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,终端设备振动,指示灯闪烁等。The above notification manager allows the application to display notification information in the status bar, which can be used to convey notification type messages, and can automatically disappear after a short stay without user interaction. For example, the notification manager is used to notify that the download is complete, that the system software has a new version, etc. The notification manager can also be notifications that appear in the status bar at the top of the system in the form of charts or scroll bar text, such as notifications for applications running in the background, or notifications that appear on the screen in the form of conversation windows. For example, text information is prompted in the status bar, a prompt sound is emitted, the terminal device vibrates, and the indicator light flashes, etc.

上述输入管理器可以提供输入管理服务,用于管理系统的输入,例如触摸屏输入、按键输入、传感器输入等。输入管理器从输入设备节点取出事件,通过和窗口管理器的交互,将事件分配至合适的窗口。The above-mentioned input manager can provide input management services for managing system input, such as touch screen input, key input, sensor input, etc. The input manager fetches events from the input device node and distributes the events to appropriate windows through interaction with the window manager.

如图3所示,系统库可以包括多个功能模块。例如:表面管理器(surfacemanager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL)等。As shown in Figure 3, the system library can include multiple functional modules. For example: surface manager (surfacemanager), media libraries (Media Libraries), 3D graphics processing library (for example: OpenGL ES), 2D graphics engine (for example: SGL), etc.

表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。2D图形引擎是2D绘图的绘图引擎。The surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications. The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc. The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, composition, and layer processing. 2D Graphics Engine is a drawing engine for 2D drawing.

安卓运行时(Android Runtime)包括核心库和虚拟机。Android Runtime负责安卓系统的调度和管理。Android Runtime includes core libraries and virtual machines. Android Runtime is responsible for the scheduling and management of the Android system.

核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。The core library contains two parts: one is the functional functions that need to be called by the Java language, and the other is the core library of Android.

应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The application layer and application framework layer run in virtual machines. The virtual machine executes the java files of the application layer and application framework layer into binary files. The virtual machine is used to perform object life cycle management, stack management, thread management, security and exception management, and garbage collection and other functions.

内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动、蓝牙驱动等,本申请实施例对此不做任何限制。The kernel layer is the layer between hardware and software. The kernel layer at least includes a display driver, a camera driver, an audio driver, a sensor driver, a Bluetooth driver, etc. The embodiments of this application do not impose any restrictions on this.

以下将结合附图详细阐述本申请实施例提供的一种软件升级方法,可以应用于图1所示的终端设备101中,与图1所示不同的是,终端设备101可以从多个服务器接收升级包。A software upgrade method provided by the embodiment of the present application will be described in detail below with reference to the accompanying drawings. It can be applied to the terminal device 101 shown in Figure 1. The difference from that shown in Figure 1 is that the terminal device 101 can receive data from multiple servers. Upgrade package.

图4示意性的示出服务器1031和服务器1032,终端设备101通过服务器1031和服务器1032进行软件升级的方法可包括以下步骤:Figure 4 schematically shows the server 1031 and the server 1032. The method for the terminal device 101 to perform software upgrade through the server 1031 and the server 1032 may include the following steps:

S401、终端设备101向服务器1031发送请求升级数据包的第一消息。S401. The terminal device 101 sends a first message requesting an upgrade data package to the server 1031.

以终端设备101为手机,需要升级的系统软件应用为手机EMUI软件为例,如图5(a)所示,手机的显示屏显示设置界面501。设置界面501可以包括WLAN、蓝牙、移动网络、超级终端、更多连接、系统和更新、关于本机等选项,部分选项的功能是开启还是关闭也显示在设置界面501中。例如,手机当前的WLAN和蓝牙处于开启状态,移动网络处于关闭状态。Taking the terminal device 101 as a mobile phone and the system software application that needs to be upgraded as the EMUI software of the mobile phone as an example, as shown in Figure 5(a), the display screen of the mobile phone displays a setting interface 501. The setting interface 501 may include options such as WLAN, Bluetooth, mobile network, HyperTerminal, more connections, system and updates, about this machine, etc. Whether the functions of some options are turned on or off is also displayed in the setting interface 501. For example, the current WLAN and Bluetooth of the mobile phone are turned on, and the mobile network is turned off.

用户在手机设置界面501中选择“系统和更新”选项502,进入至如图5(b)所示的系统和更新界面503。系统和更新界面503可以包括软件更新、系统导航方式、语言和输入法、日期和时间、手机克隆、备份和回复、重置等选项,用户可以通过点击每个选项可以进入到选项对应的功能界面。The user selects the "system and update" option 502 in the mobile phone setting interface 501 and enters the system and update interface 503 as shown in Figure 5(b). The system and update interface 503 may include options such as software update, system navigation, language and input method, date and time, mobile phone cloning, backup and recovery, reset, etc. The user can enter the functional interface corresponding to the option by clicking on each option. .

用户点击“软件更新”选项504,进入至如图5(c)所示的软件更新界面505。软件更新界面505可以包括当前需要更新的软件名称和软件版本,例如软件名称为EMUI,软件版本为10.0.0.205。软件更新界面505还可以包括当前补丁包和当前版本,以供用户查看。软件更新界面505还可以包括检查更新控件506,用户可以通过点击控件506获取该软件是否有更新版本。参见新版本控件507,手机通过检查更新后发现存在新的软件版本10.1.0.126,新版本控件以不同颜色、不同字体或加粗字体、以及在新版本后增加“·”等方式提醒用户该软件存在更新版本。软件更新界面505还可以包括控件508,供用户对本机的软件更新进行下载和安装设置。The user clicks the "Software Update" option 504 to enter the software update interface 505 as shown in Figure 5(c). The software update interface 505 may include the name and software version of the software that currently needs to be updated. For example, the software name is EMUI and the software version is 10.0.0.205. The software update interface 505 may also include the current patch package and the current version for the user to view. The software update interface 505 may also include a check update control 506. The user can click the control 506 to obtain whether there is an updated version of the software. See new version control 507. After checking for updates, the mobile phone found that there is a new software version 10.1.0.126. The new version control reminds users of the software in different colors, different fonts or bold fonts, and by adding "·" after the new version. A newer version exists. The software update interface 505 may also include a control 508 for the user to download and install software updates for the local machine.

用户点击控件508,进入到如图5(d)所示的本机设置界面509。本机设置界面509可以包括WLAN下自动下载、夜间安装等选项及其对应的开关控件。参见图5(d),“WLAN下自动下载”选项510处于关闭状态,此时用户可以手动下载EMUI新版本。实际使用中,用户也可以点击“WLAN下自动下载”选项510,将该选项打开,从而可以自动下载EMUI新版本。用户还可以将“夜间安装”选项511打开,手机将在凌晨2:00至4:00时自动安装升级包,并重启手机。且“夜间安装”选项511下还提示用户升级电量需大于35%,如果电量不足,请提前插入充电器。The user clicks the control 508 to enter the local setting interface 509 as shown in Figure 5(d). The local setting interface 509 may include options such as automatic download under WLAN and night installation and their corresponding switch controls. Referring to Figure 5(d), the "automatic download under WLAN" option 510 is turned off. At this time, the user can manually download the new version of EMUI. In actual use, the user can also click the "Automatic download under WLAN" option 510 to turn on this option, so that the new version of EMUI can be automatically downloaded. Users can also turn on the "Night Installation" option 511, and the phone will automatically install the upgrade package and restart the phone between 2:00 and 4:00 am. And under the "Night Installation" option 511, the user is also prompted to upgrade the battery to more than 35%. If the battery is insufficient, please plug in the charger in advance.

如果手机为如图5(d)所示的“WLAN下自动下载”选项510处于关闭状态,用户在软件更新界面505内还可以点击如图5(c)中的新版本控件507,从而进入到如图5(e)所示的手动下载界面512。手动下载界面512可以包括下载页面513、更新日志514、取消控件515等。下载页面513显示出当前新版本软件正在下载,以圆环的方式示出下载进度为5%,新版本的版本号10.1.0.126以及新版本的大小1.04GB。更新日志514用于供用户查看最近或全部的软件更新记录。如果用户看到所要下载的软件较大,可能消耗较多流量,也可以选择点击取消控件515停止下载。If the "automatic download under WLAN" option 510 as shown in Figure 5(d) is turned off on the mobile phone, the user can also click the new version control 507 in Figure 5(c) in the software update interface 505 to enter Manual download interface 512 as shown in Figure 5(e). The manual download interface 512 may include a download page 513, an update log 514, a cancellation control 515, etc. The download page 513 shows that the new version of the software is currently being downloaded. The download progress is shown in a circle as 5%, the version number of the new version is 10.1.0.126, and the size of the new version is 1.04GB. The update log 514 is used for users to view recent or all software update records. If the user sees that the software to be downloaded is large and may consume more data, he or she can also choose to click the cancel control 515 to stop the download.

步骤S401中终端设备101发送请求升级数据包的消息可以是在用户点击如图5(c)中的新版本控件507之后,通过移动通信模块150或无线通信模块160发出的消息。该消息中可以包括需要升级的软件(也称目标软件)在终端设备101中当前的版本信息,这样服务器在接收到该消息后,可以确定向终端设备101发送哪些升级数据包。The message sent by the terminal device 101 to request an upgrade data package in step S401 may be a message sent through the mobile communication module 150 or the wireless communication module 160 after the user clicks on the new version control 507 in Figure 5(c). The message may include the current version information of the software that needs to be upgraded (also called target software) in the terminal device 101, so that after receiving the message, the server can determine which upgrade data packets to send to the terminal device 101.

S402、服务器1031向终端设备101发送升级数据包1。S402. The server 1031 sends the upgrade data package 1 to the terminal device 101.

服务器1031在接收到终端设备101发送的第一消息后,根据目标软件在终端设备101中当前的版本信息,以及服务器1031内所存储的目标软件的升级数据包文件,确定向终端设备101发送哪些升级数据包。服务器1031内所存储的目标软件的升级数据包文件可以包括目标软件的差分文件和/或目标软件对应版本的全量数据包。例如,目标软件在服务器1031内的最新版本为V6,服务器1031内包括差分文件V2-V1,差分文件V3-V2,全量数据包V4,差分文件V5-V4,差分文件V6-V5,终端设备101内的目标软件的当前版本为V2,则服务器1031可以确定向终端设备101发送的升级数据包可以包括全量数据包V4,差分文件V5-V4和差分文件V6-V5。After receiving the first message sent by the terminal device 101, the server 1031 determines which software to send to the terminal device 101 based on the current version information of the target software in the terminal device 101 and the upgrade data package file of the target software stored in the server 1031. Upgrade data package. The upgrade data package file of the target software stored in the server 1031 may include a differential file of the target software and/or a full data package of the corresponding version of the target software. For example, the latest version of the target software in server 1031 is V6. Server 1031 includes differential files V2-V1, differential files V3-V2, full data package V4, differential files V5-V4, differential files V6-V5, and terminal device 101 If the current version of the target software is V2, the server 1031 may determine that the upgrade data package sent to the terminal device 101 may include the full data package V4, the difference files V5-V4 and the difference files V6-V5.

服务器1031向终端设备101发送升级数据包1的过程中,终端设备101可以显示升级包的下载页面。示例性地,如图5(e)所示的手动下载界面512,此时服务器1031可以正在向手机发送升级数据包1。During the process of the server 1031 sending the upgrade data package 1 to the terminal device 101, the terminal device 101 may display the download page of the upgrade package. For example, in the manual download interface 512 shown in Figure 5(e), the server 1031 may be sending the upgrade data package 1 to the mobile phone at this time.

S403、终端设备101向服务器1032发送请求升级数据包的第二消息。S403. The terminal device 101 sends a second message requesting an upgrade data package to the server 1032.

该步骤403的触发,可以同步骤S401类似,可以是在用户点击如图5(c)中的新版本控件507之后,通过移动通信模块150或无线通信模块160发出的消息。与步骤S401不同的是,所述第二消息是终端设备101向服务器1032发出的,而非向服务器1031发出的。同样的,第二消息中也可以包括目标软件在终端设备101中当前的版本信息,这样服务器1032在接收到该消息后,可以确定向终端设备101发送哪些升级数据包。The trigger of step 403 may be similar to step S401, and may be a message sent through the mobile communication module 150 or the wireless communication module 160 after the user clicks on the new version control 507 in Figure 5(c). Different from step S401, the second message is sent by the terminal device 101 to the server 1032 instead of to the server 1031. Similarly, the second message may also include the current version information of the target software in the terminal device 101, so that the server 1032 can determine which upgrade data packets to send to the terminal device 101 after receiving the message.

S404、服务器1032向终端设备101发送升级数据包2。S404. The server 1032 sends the upgrade data package 2 to the terminal device 101.

服务器1032在接收到终端设备101发送的第二消息后,根据目标软件在终端设备101中当前的版本信息,以及服务器1032内所存储的目标软件的升级数据包文件,确定向终端设备101发送哪些升级数据包。服务器1032内所存储的目标软件的升级数据包文件可以包括目标软件的差分文件和/或目标软件对应版本的完整包,具体可以参见步骤S402的示例,此处不再赘述。After receiving the second message sent by the terminal device 101, the server 1032 determines which software to send to the terminal device 101 based on the current version information of the target software in the terminal device 101 and the upgrade data package file of the target software stored in the server 1032. Upgrade data package. The upgrade data package file of the target software stored in the server 1032 may include a differential file of the target software and/or a complete package of the corresponding version of the target software. For details, see the example of step S402, which will not be described again here.

服务器1032向终端设备101发送升级数据包2的过程中,终端设备101可以显示升级包的下载页面。示例性地,如图5(e)所示的手动下载界面512,此时服务器1032也可以正在向手机发送升级数据包2。在本申请的一些实施例中,终端设备101正在接收从服务器1031和服务器1032发来的升级数据包1和升级数据包2时,可以在终端设备101的显示屏上显示提示信息。示例性地,如图6(a)所示,在手机的下载页面601显示提示信息602“正在使用多个服务端为您加速升级”。During the process of the server 1032 sending the upgrade data package 2 to the terminal device 101, the terminal device 101 may display the download page of the upgrade package. For example, in the manual download interface 512 shown in Figure 5(e), the server 1032 may also be sending the upgrade data package 2 to the mobile phone at this time. In some embodiments of the present application, when the terminal device 101 is receiving the upgrade data package 1 and the upgrade data package 2 sent from the server 1031 and the server 1032, prompt information may be displayed on the display screen of the terminal device 101. For example, as shown in FIG. 6(a) , the prompt message 602 "Multiple servers are being used to accelerate your upgrade" is displayed on the download page 601 of the mobile phone.

其中,升级数据包1和升级数据包2可以重叠或者不重叠。例如,目标软件在服务器1031内的最新版本为V6,服务器1031内包括差分文件V2-V1,差分文件V3-V2,全量数据包V4,差分文件V5-V4,差分文件V6-V5,终端设备101内的目标软件的当前版本为V2,则服务器1031可以确定向终端设备101发送的升级数据包可以包括全量数据包V4,差分文件V5-V4和差分文件V6-V5。例如,目标软件在服务器1032内的最新版本为V8,服务器1032内包括差分文件V2-V1,全量数据包V3,差分文件V4-V3,差分文件V5-V4,差分文件V6-V5,全量数据包V7,差分文件V8-V7,则服务器1032可以确定向终端设备101发送的升级数据包可以包括全量数据包V3,差分文件V4-V3,差分文件V5-V4,差分文件V6-V5,全量数据包V7,差分文件V8-V7。如此,升级数据包1和升级数据包2可以是重叠的。Among them, upgrade data package 1 and upgrade data package 2 may overlap or not overlap. For example, the latest version of the target software in server 1031 is V6. Server 1031 includes differential files V2-V1, differential files V3-V2, full data package V4, differential files V5-V4, differential files V6-V5, and terminal device 101 If the current version of the target software is V2, the server 1031 may determine that the upgrade data package sent to the terminal device 101 may include the full data package V4, the difference files V5-V4 and the difference files V6-V5. For example, the latest version of the target software in server 1032 is V8, and server 1032 includes differential files V2-V1, full data package V3, differential files V4-V3, differential files V5-V4, differential files V6-V5, and full data packages. V7, differential files V8-V7, then the server 1032 can determine that the upgrade data packet sent to the terminal device 101 may include the full data packet V3, the differential files V4-V3, the differential files V5-V4, the differential files V6-V5, and the full data packet V7, differential files V8-V7. In this way, upgrade data package 1 and upgrade data package 2 may overlap.

终端设备可以根据实际需要对升级数据包1和升级数据包2组合使用以提升升级的可靠性。例如,目标软件在服务器1031内的最新版本为V6,终端设备101内的目标软件的当前版本为V2,服务器1031内包括差分文件V2-V1,差分文件V3-V2,全量数据包V4,差分文件V5-V4,全量数据包V6,则服务器1031可以确定向终端设备101发送的升级数据包1可以包括全量数据包V6。另外,目标软件在服务器1032内的最新版本为V8,服务器1032内包括差分文件V2-V1,全量数据包V3,差分文件V4-V3,差分文件V5-V4,差分文件V6-V5,差分文件V7-V6,差分文件V8-V7,则服务器1032可以确定向终端设备101发送的升级数据包2可以包括全量数据包V3,差分文件V4-V3,差分文件V5-V4,差分文件V6-V5,差分文件V7-V6,差分文件V8-V7。终端设备在收到升级数据包1和升级数据包2后确定要将目标软件更新至V8,那么,为了提升升级的可靠性,可以将升级数据包1中的全量数据包V6和升级数据包2中的差分文件V7-V6、差分文件V8-V7进行组合,以更快更稳定地将目标软件更新至最新版本。The terminal device can use the upgrade data package 1 and the upgrade data package 2 in combination according to actual needs to improve the reliability of the upgrade. For example, the latest version of the target software in the server 1031 is V6, and the current version of the target software in the terminal device 101 is V2. The server 1031 includes differential files V2-V1, differential files V3-V2, full data package V4, and differential files. V5-V4, full data packet V6, then the server 1031 can determine that the upgrade data packet 1 sent to the terminal device 101 can include the full data packet V6. In addition, the latest version of the target software in the server 1032 is V8. The server 1032 includes differential files V2-V1, full data package V3, differential files V4-V3, differential files V5-V4, differential files V6-V5, and differential files V7. -V6, differential files V8-V7, then the server 1032 can determine that the upgrade data packet 2 sent to the terminal device 101 may include the full data packet V3, differential files V4-V3, differential files V5-V4, differential files V6-V5, differential files Files V7-V6, differential files V8-V7. After receiving upgrade data package 1 and upgrade data package 2, the terminal device determines to update the target software to V8. Then, in order to improve the reliability of the upgrade, the full data package V6 in upgrade data package 1 and upgrade data package 2 can be The differential files V7-V6 and differential files V8-V7 are combined to update the target software to the latest version faster and more stably.

在本申请的一些实施例中,终端设备101还可以分别获取服务器1031的负载情况和服务器1032的负载情况,根据负载情况增加或者减少单个服务器所发送的数据包流量。示例性的,终端设备101可以在步骤S401发送请求发送升级数据包的第一消息中增加负载反馈请求,服务器1031在步骤402向终端设备101发送升级数据包1时、或者在步骤402之前将其负载情况反馈给终端设备101,例如服务器1031当前负载过多和/或当前负载设备数量;终端设备101可以在步骤S403发送请求发送升级数据包的第二消息中增加负载反馈请求,服务器1032在步骤404向终端设备101发送升级数据包2时、或者在步骤404之前将其负载情况反馈给终端设备101,例如服务器1032当前负载一般和/或当前负载设备数量。终端设备101接收到服务器1031和服务器1032的负载情况后,可以确定由服务器1031继续发送升级数据包1,而中断服务器1032发送升级数据包2。In some embodiments of the present application, the terminal device 101 can also obtain the load status of the server 1031 and the load status of the server 1032 respectively, and increase or decrease the data packet traffic sent by a single server according to the load status. For example, the terminal device 101 may add a load feedback request to the first message requesting the sending of the upgrade data packet in step S401. The server 1031 may send the upgrade data packet 1 to the terminal device 101 in step S402 or before step 402. The load situation is fed back to the terminal device 101, for example, the current load of the server 1031 is too much and/or the current number of loaded devices; the terminal device 101 can add a load feedback request in the second message requesting to send an upgrade data package in step S403, and the server 1032 in step S403 404 when sending the upgrade data package 2 to the terminal device 101, or before step 404, the load status of the server 1032 is fed back to the terminal device 101, for example, the current load of the server 1032 is general and/or the current number of loaded devices. After receiving the load conditions of the server 1031 and the server 1032, the terminal device 101 can determine that the server 1031 continues to send the upgrade data packet 1 and interrupts the server 1032 to send the upgrade data packet 2.

在本申请的另一些实施例中,终端设备101还可以分别获取终端设备101与服务器1031之间的传输链路情况,以及终端设备101与服务器1032之间的传输链路情况,根据传输链路情况增加或者减少单个服务器所发送的数据包流量。其中,所述传输链路情况可以包括信道质量、丢包率,重传次数等。示例性的,终端设备101可以在步骤S401发送请求发送升级数据包的第一消息中增加信道质量测量信号,且在步骤S402的服务器1031向终端设备101发送升级数据包1的时候增加信道质量测量信号的反馈信号。终端设备101可以根据该反馈信号确定终端设备101与服务器1031之间的信道质量,当信道质量大于第一阈值时,确定终端设备101与服务器1031之间的传输链路情况良好。同样地,终端设备101可以在步骤S403和404增加信道质量测量信号及其反馈信号,由此终端设备101也可以确定终端设备101与服务器1032之间的信道质量,当信道质量小于等于第一阈值时,确定终端设备101与服务器1032之间的传输链路情况较差。终端设备101接收到上述传输链路情况后,可以确定由服务器1031继续发送升级数据包1,而中断服务器1032发送升级数据包2。In other embodiments of the present application, the terminal device 101 can also obtain the transmission link status between the terminal device 101 and the server 1031, and the transmission link status between the terminal device 101 and the server 1032. According to the transmission link Situations increase or decrease the amount of packet traffic sent by a single server. The transmission link conditions may include channel quality, packet loss rate, number of retransmissions, etc. For example, the terminal device 101 may add a channel quality measurement signal to the first message sending a request to send an upgrade data packet in step S401, and add the channel quality measurement signal when the server 1031 sends the upgrade data packet 1 to the terminal device 101 in step S402. signal feedback signal. The terminal device 101 can determine the channel quality between the terminal device 101 and the server 1031 based on the feedback signal. When the channel quality is greater than the first threshold, it is determined that the transmission link between the terminal device 101 and the server 1031 is in good condition. Similarly, the terminal device 101 can add the channel quality measurement signal and its feedback signal in steps S403 and 404, whereby the terminal device 101 can also determine the channel quality between the terminal device 101 and the server 1032. When the channel quality is less than or equal to the first threshold When, it is determined that the transmission link between the terminal device 101 and the server 1032 is in poor condition. After receiving the above transmission link situation, the terminal device 101 can determine that the server 1031 will continue to send the upgrade data packet 1 and interrupt the server 1032 to send the upgrade data packet 2.

在本申请的又一些实施例中,终端设备101还可以根据服务器1031和服务器1032的负载情况、终端设备101与服务器1031之间的传输链路情况、以及终端设备101与服务器1032之间的传输链路情况,综合判断是否增加或者减少单个服务器所发送的数据包流量。具体的,终端设备101可以和服务器1031、1032协商包传输窗口的大小,从而来限制或者加速单个数据通道的传输数据量。例如,终端设备101根据当前服务器1031和服务器1032的负载情况、终端设备101与服务器1031、1032之间的传输链路情况,确定出由服务器1031继续发送升级数据包1,且由服务器1032发送升级数据包2,此时可以在手动下载界面提示用户,如图6(a)所示,在下载页面601显示提示信息602“正在使用多个服务端为您加速升级”。又如,终端设备101开始根据当前服务器1031和服务器1032的负载情况、终端设备101与服务器1031、1032之间的传输链路情况,确定出由服务器1031继续发送升级数据包1,而中断由服务器1032发送升级数据包2;终端设备101在下载新版本时仍然在检测服务器1032的负载情况、终端设备101与服务器1032之间的传输链路情况,假设在下载至5%时,终端设备检测到服务器1032的负载减少且终端设备101与服务器1032之间的传输链路情况较好的情况下,此时服务器1032可以重新发送升级数据包2,并估算两个服务器同时下载升级数据包相对于1个服务器下载升级包所提升的速度。同时,终端设备101可以在手动下载界面提示用户,如图6(b)所示,在下载页面603显示提示信息604“可以为您加速升级,预计升级速度提升50%”。In some embodiments of the present application, the terminal device 101 can also determine the load status of the server 1031 and the server 1032, the transmission link status between the terminal device 101 and the server 1031, and the transmission between the terminal device 101 and the server 1032. Link conditions, comprehensively determine whether to increase or decrease the data packet traffic sent by a single server. Specifically, the terminal device 101 can negotiate the size of the packet transmission window with the servers 1031 and 1032, thereby limiting or accelerating the amount of transmission data of a single data channel. For example, the terminal device 101 determines that the server 1031 will continue to send the upgrade data packet 1 and the server 1032 will send the upgrade according to the current load conditions of the server 1031 and the server 1032 and the transmission link conditions between the terminal device 101 and the servers 1031 and 1032. For data package 2, the user can be prompted on the manual download interface. As shown in Figure 6(a), the prompt message 602 "Multiple servers are being used to accelerate your upgrade" is displayed on the download page 601. For another example, the terminal device 101 begins to determine based on the current load conditions of the server 1031 and the server 1032 and the transmission link conditions between the terminal device 101 and the servers 1031 and 1032 that the server 1031 will continue to send the upgrade data packet 1, and the interruption will be caused by the server. 1032 sends upgrade data packet 2; when downloading the new version, the terminal device 101 is still detecting the load of the server 1032 and the transmission link between the terminal device 101 and the server 1032. It is assumed that when the download reaches 5%, the terminal device detects When the load on the server 1032 is reduced and the transmission link between the terminal device 101 and the server 1032 is in good condition, the server 1032 can resend the upgrade data packet 2 and estimate that the two servers download the upgrade data packet at the same time relative to 1 The speed increased by each server downloading the upgrade package. At the same time, the terminal device 101 can prompt the user on the manual download interface, as shown in Figure 6(b), and display the prompt message 604 on the download page 603 that "the upgrade can be accelerated for you, and the upgrade speed is expected to be increased by 50%."

S405、终端设备101根据升级数据包1和升级数据包2更新目标软件。S405. The terminal device 101 updates the target software according to the upgrade data package 1 and the upgrade data package 2.

终端设备101在下载完升级数据包1和升级数据包2之后,可以根据用户的选择更新目标软件。示例性地,用户在图5(e)或图6所示的界面查看到升级数据包下载完毕后,可以根据情况选择立即更新目标软件或随后更新目标软件;例如下载完成界面上有“安装”按钮,用户点击“安装”按钮进行目标软件的更新。如果用户点击如图5(d)所示的“WLAN下自动下载”选项510,将该选项从关闭状态变为打开状态,且“夜间安装”选项511仍处于打开状态,那么用户可以不用等待升级数据包的下载和选择更新目标软件,而是在后台识别到终端设备101处于WLAN连接态下自动下载升级数据包1和升级数据包2,并根据时钟指示的时间在凌晨时间再进行安装。如此,终端设备101可以在用户无感知的情况下自动完成软件下载和更新,无需用户在每次版本更新后手动下载和更新,提升了用户体验。After downloading the upgrade data package 1 and the upgrade data package 2, the terminal device 101 can update the target software according to the user's selection. For example, after the user sees that the upgrade data package is downloaded on the interface shown in Figure 5(e) or Figure 6, he can choose to update the target software immediately or update the target software later according to the situation; for example, there is "Install" on the download completion interface. button, the user clicks the "Install" button to update the target software. If the user clicks the "Automatic download under WLAN" option 510 as shown in Figure 5(d) to change the option from closed to open, and the "night installation" option 511 is still open, then the user does not need to wait for the upgrade Instead of downloading the data package and selecting the update target software, it is recognized in the background that the terminal device 101 is in the WLAN connection state and automatically downloads the upgrade data package 1 and the upgrade data package 2, and then installs it in the early morning according to the time indicated by the clock. In this way, the terminal device 101 can automatically download and update software without the user being aware of it, eliminating the need for the user to manually download and update after each version update, which improves the user experience.

在本申请的一些实施例中,终端设备的软件升级系统不仅限于如图4所示的终端设备101、服务器1031、服务器1032。如图7(a)所示,终端设备的软件升级系统除了包括服务器1031、服务器1032,还包括多个服务器103N。上述服务器1031、1032以及多个服务器103N均与终端设备101建立无线通信连接,以通过OTA技术向终端设备101发送升级数据包。In some embodiments of the present application, the software upgrade system of the terminal device is not limited to the terminal device 101, server 1031, and server 1032 as shown in Figure 4. As shown in Figure 7(a), the software upgrade system of the terminal device includes not only servers 1031 and 1032, but also multiple servers 103N. The above-mentioned servers 1031, 1032 and multiple servers 103N all establish wireless communication connections with the terminal device 101 to send upgrade data packages to the terminal device 101 through OTA technology.

在本申请的一些实施例中,为终端设备提供软件升级的服务端还可以是移动APP,手机,云服务或同级设备。如果是手机等终端设备,则终端设备之间也可以互为数据源,从而形成一个星形的网络结构。如图7(b)所示,终端设备101的软件升级系统除了包括服务器1031、服务器1032,还包括终端设备108,即终端设备101可以通过服务器1031、服务器1032和终端设备108这三个服务端进行OTA升级;终端设备106的软件升级系统包括终端设备108、服务器1032和服务器103N,即终端设备106可以通过终端设备108、服务器1032和服务器103N这三个服务端进行OTA升级;终端设备108的软件升级系统包括服务器1031、服务器1032、服务器103N、终端设备101和终端设备106,即终端设备108可以通过上述五个服务端进行OTA升级,上述服务器1031、1032、服务器103N、终端设备101和终端设备106均与终端设备108建立无线通信连接,以通过OTA技术向终端设备108发送升级数据包。In some embodiments of the present application, the server that provides software upgrades for terminal devices may also be a mobile APP, a mobile phone, a cloud service, or a device of the same level. If it is a terminal device such as a mobile phone, the terminal devices can also serve as data sources for each other, thus forming a star-shaped network structure. As shown in Figure 7(b), the software upgrade system of the terminal device 101 includes not only the server 1031 and the server 1032, but also the terminal device 108. That is, the terminal device 101 can use the three servers of the server 1031, the server 1032 and the terminal device 108. Perform OTA upgrade; the software upgrade system of terminal device 106 includes terminal device 108, server 1032 and server 103N, that is, terminal device 106 can perform OTA upgrade through three servers: terminal device 108, server 1032 and server 103N; the software upgrade system of terminal device 108 The software upgrade system includes server 1031, server 1032, server 103N, terminal device 101 and terminal device 106. That is, the terminal device 108 can be upgraded OTA through the above five servers. The above servers 1031, 1032, server 103N, terminal device 101 and terminal Each device 106 establishes a wireless communication connection with the terminal device 108 to send an upgrade data package to the terminal device 108 through OTA technology.

需要说明的是,本申请实施例中,上述步骤的序号并不代表执行顺序的先后,可以适当变更顺序执行,例如,终端设备可以先向第二服务端请求发送升级数据包,然后再向第一服务端请求发送升级数据包;也可在其中增加步骤,例如,如图7(a)和7(b)所示的多个服务端,还可以增加终端设备向第三服务端请求发送升级数据包及从第三服务端接收升级数据包的过程,本申请对此不予限制。本申请提供的软件升级方法,通过多数据流链路完成OTA升级,终端设备可以同时从多个数据源接收软件升级包,以提升接收升级包的传输吞吐量和升级速度。It should be noted that in the embodiment of the present application, the sequence numbers of the above steps do not represent the order of execution, and the order of execution can be appropriately changed. For example, the terminal device can first request the second server to send an upgrade data packet, and then send the upgrade data packet to the second server. A server requests to send an upgrade data packet; steps can also be added, for example, multiple servers as shown in Figures 7(a) and 7(b), and a terminal device can also be added to request a third server to send an upgrade. The data packet and the process of receiving the upgrade data packet from the third server are not limited by this application. The software upgrade method provided by this application completes OTA upgrade through multi-data stream links. The terminal device can receive software upgrade packages from multiple data sources at the same time to improve the transmission throughput and upgrade speed of receiving upgrade packages.

可以理解的是,为了实现上述功能,终端设备包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。It can be understood that, in order to implement the above functions, the terminal device includes hardware structures and/or software modules corresponding to each function. Those skilled in the art should readily appreciate that the algorithm steps of each example described in conjunction with the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is performed by hardware or by computer software driving the hardware depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each specific application, but such implementations should not be considered beyond the scope of this application.

本申请实施例可以根据上述方法示例对终端设备进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。Embodiments of the present application can divide the terminal device into functional modules according to the above method examples. For example, each functional module can be divided corresponding to each function, or two or more functions can be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or software function modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. In actual implementation, there may be other division methods.

本申请实施例公开了一种终端设备,包括处理器,以及与处理器相连的存储器、输入设备和输出设备。其中,输入设备和输出设备可集成为一个设备,例如,可将触摸传感器作为输入设备,将显示屏作为输出设备,并将触摸传感器和显示屏集成为触摸屏。An embodiment of the present application discloses a terminal device, which includes a processor, a memory, an input device, and an output device connected to the processor. Among them, the input device and the output device can be integrated into one device. For example, the touch sensor can be used as the input device, the display screen can be used as the output device, and the touch sensor and the display screen can be integrated into a touch screen.

此时,如图8所示,上述终端设备可以包括:触摸屏801,所述触摸屏801包括触摸传感器806和显示屏807;一个或多个处理器802;一个或多个摄像头808;存储器803;一个或多个应用程序(未示出);以及一个或多个计算机程序804,上述各器件可以通过一个或多个通信总线805连接。其中该一个或多个计算机程序804被存储在上述存储器803中并被配置为被该一个或多个处理器802执行,该一个或多个计算机程序804包括指令,上述指令可以用于执行上述实施例中的各个步骤。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应实体器件的功能描述,在此不再赘述。At this time, as shown in Figure 8, the above-mentioned terminal device may include: a touch screen 801 including a touch sensor 806 and a display screen 807; one or more processors 802; one or more cameras 808; a memory 803; or multiple application programs (not shown); and one or more computer programs 804, each of the above devices may be connected through one or more communication buses 805. Where the one or more computer programs 804 are stored in the above-mentioned memory 803 and configured to be executed by the one or more processors 802, the one or more computer programs 804 include instructions, the above-mentioned instructions may be used to perform the above-mentioned implementations. steps in the example. All relevant content of each step involved in the above method embodiments can be quoted from the functional description of the corresponding physical device, and will not be described again here.

示例性的,上述处理器802具体可以为图2所示的处理器110,上述存储器803具体可以为图2所示的内部存储器116和/或外部存储器120,上述摄像头808具体可以为图2所示的摄像头193,上述显示屏807具体可以为图2所示的显示屏194,上述触摸传感器806具体可以为图2所示的传感器模块180中的触摸传感器180K,本申请实施例对此不做任何限制。For example, the processor 802 may be the processor 110 shown in FIG. 2 , the memory 803 may be the internal memory 116 and/or the external memory 120 shown in FIG. 2 , and the camera 808 may be the one shown in FIG. 2 . The camera 193 shown in the figure, the above-mentioned display screen 807 can be specifically the display screen 194 shown in Figure 2, the above-mentioned touch sensor 806 can be specifically the touch sensor 180K in the sensor module 180 shown in Figure 2, the embodiment of the present application does not do this Any restrictions.

本申请实施例还提供一种计算机存储介质,该计算机存储介质中存储有计算机指令,当该计算机指令在终端设备上运行时,该终端设备执行上述相关方法步骤实现上述实施例中的方法。Embodiments of the present application also provide a computer storage medium that stores computer instructions. When the computer instructions are run on a terminal device, the terminal device executes the above related method steps to implement the method in the above embodiment.

本申请实施例还提供了一种计算机程序产品,当该计算机程序产品在计算机上运行时,使得计算机执行上述相关方法步骤,以实现上述实施例中的方法。An embodiment of the present application also provides a computer program product. When the computer program product is run on a computer, it causes the computer to execute the above related method steps to implement the method in the above embodiment.

另外,本申请的实施例还提供一种装置,这个装置具体可以是芯片,组件或模块,该装置可包括相连的处理器和存储器;其中,存储器用于存储计算机执行指令,当装置运行时,处理器可执行存储器存储的计算机执行指令,以使芯片执行上述各方法实施例中的方法。In addition, embodiments of the present application also provide a device. This device may be a chip, a component or a module. The device may include a connected processor and a memory. The memory is used to store computer execution instructions. When the device is running, The processor can execute computer execution instructions stored in the memory, so that the chip executes the methods in each of the above method embodiments.

其中,本申请实施例提供的终端设备、计算机存储介质、计算机程序产品或芯片均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。Among them, the terminal equipment, computer storage media, computer program products or chips provided by the embodiments of the present application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the corresponding methods provided above. The beneficial effects of this method will not be repeated here.

通过以上实施方式的描述,所属领域的技术人员可以了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。Through the description of the above embodiments, those skilled in the art can understand that for the convenience and simplicity of description, only the division of the above functional modules is used as an example. In practical applications, the above functions can be allocated to different modules according to needs. The functional module is completed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.

在本申请所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个装置,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods, for example, multiple units or components may be combined or can be integrated into another device, or some features can be ignored, or not implemented. On the other hand, the coupling or direct coupling or communication connection between each other shown or discussed may be through some interfaces, and the indirect coupling or communication connection of the devices or units may be in electrical, mechanical or other forms.

作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是一个物理单元或多个物理单元,即可以位于一个地方,或者也可以分布到多个不同地方。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。A unit described as a separate component may or may not be physically separate. A component shown as a unit may be one physical unit or multiple physical units, that is, it may be located in one place, or it may be distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application can be integrated into one processing unit, each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated units can be implemented in the form of hardware or software functional units.

集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该软件产品存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(read only memory,ROM)、随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。Integrated units may be stored in a readable storage medium if they are implemented in the form of software functional units and sold or used as independent products. Based on this understanding, the technical solutions of the embodiments of the present application are essentially or contribute to the existing technology, or all or part of the technical solution can be embodied in the form of a software product, and the software product is stored in a storage medium , including several instructions to cause a device (which can be a microcontroller, a chip, etc.) or a processor to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage media include: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), magnetic disk or optical disk and other media that can store program codes.

以上内容,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以权利要求的保护范围为准。The above contents are only specific embodiments of the present application, but the protection scope of the present application is not limited thereto. Any person familiar with the technical field can easily think of changes or replacements within the technical scope disclosed in the present application, and should are covered by the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claims.

Claims (19)

CN202210743776.7A2022-06-272022-06-27 A software upgrade method, terminal equipment and systemPendingCN117348894A (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202210743776.7ACN117348894A (en)2022-06-272022-06-27 A software upgrade method, terminal equipment and system

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202210743776.7ACN117348894A (en)2022-06-272022-06-27 A software upgrade method, terminal equipment and system

Publications (1)

Publication NumberPublication Date
CN117348894Atrue CN117348894A (en)2024-01-05

Family

ID=89354458

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202210743776.7APendingCN117348894A (en)2022-06-272022-06-27 A software upgrade method, terminal equipment and system

Country Status (1)

CountryLink
CN (1)CN117348894A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN117834649A (en)*2024-03-012024-04-05荣耀终端有限公司 Data transmission method and related device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN117834649A (en)*2024-03-012024-04-05荣耀终端有限公司 Data transmission method and related device

Similar Documents

PublicationPublication DateTitle
CN113542839B (en) Screen projection method of electronic device and electronic device
CN113885759B (en)Notification message processing method, device, system and computer readable storage medium
CN111416794B (en)Data transmission method and electronic equipment
CN116360725B (en)Display interaction system, display method and device
CN110489215A (en)The treating method and apparatus of scene is waited in a kind of application program
CN111372329B (en)Connection establishing method and terminal equipment
CN113254409B (en)File sharing method, system and related equipment
WO2022042637A1 (en)Bluetooth-based data transmission method and related apparatus
CN114579389A (en)Application management method, device, equipment and storage medium
CN113887264B (en) Code scanning method, system and related device
CN116723384B (en) Process control method, electronic device and readable storage medium
CN115460445B (en) Screen projection method of electronic equipment and electronic equipment
WO2022135157A1 (en)Page display method and apparatus, and electronic device and readable storage medium
CN112817634B (en) COTA package download method and device
CN116048831B (en) Target signal processing method and electronic device
WO2024260185A1 (en)Data transmission method, terminal, and system
CN117348894A (en) A software upgrade method, terminal equipment and system
CN117251223A (en)Cloud function plug-in configuration and scheduling method, system and electronic equipment
WO2022242412A1 (en)Method for killing application, and related device
CN117331471A (en)Interaction method and related equipment
CN115017227A (en) Data synchronization method and related equipment
CN114489469A (en) A data reading method, electronic device and storage medium
CN116382728B (en) Propagation name display method and terminal equipment
CN115495716B (en) A local authentication method and electronic device
CN117707562A (en)Parameter updating method and terminal equipment

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination

[8]ページ先頭

©2009-2025 Movatter.jp