









技术领域technical field
本申请涉及通信技术领域,具体涉及一种智能终端的系统升级方法、智能终端及存储介质。The present application relates to the field of communication technologies, and in particular, to a system upgrade method for an intelligent terminal, an intelligent terminal and a storage medium.
背景技术Background technique
在智能终端的使用过程中,智能终端通常会响应于服务器推送的系统升级提醒,提示用户对智能终端的系统进行升级。During the use of the intelligent terminal, the intelligent terminal usually prompts the user to upgrade the system of the intelligent terminal in response to a system upgrade reminder pushed by the server.
现有技术中,智能终端通常会在用户手动点击升级后,向服务器请求并下载该系统的升级包。智能终端可以使用该升级包对原有系统的系统文件进行更新。智能终端可以通过在重启时加载更新后的系统文件实现系统的更新。In the prior art, the intelligent terminal usually requests and downloads the upgrade package of the system from the server after the user manually clicks the upgrade. The smart terminal can use the upgrade package to update the system files of the original system. The smart terminal can update the system by loading the updated system file when restarting.
然而,在构思及实现本申请过程中,发明人发现现有技术中,在该系统升级过程中,智能终端通常无法使用,存在系统升级过程中智能终端使用效率低的问题。However, in the process of conceiving and implementing the present application, the inventor found that in the prior art, in the system upgrade process, the intelligent terminal is usually unavailable, and there is a problem of low use efficiency of the intelligent terminal in the system upgrade process.
前面的叙述在于提供一般的背景信息,并不一定构成现有技术。The preceding statements are intended to provide general background information and may not constitute prior art.
发明内容SUMMARY OF THE INVENTION
针对上述技术问题,本申请提供一种智能终端的系统升级方法、智能终端及存储介质,使用户可以在系统升级过程中正常使用智能终端,提高系统升级过程中智能终端的使用效率。In view of the above technical problems, the present application provides a system upgrade method for an intelligent terminal, an intelligent terminal and a storage medium, so that users can use the intelligent terminal normally during the system upgrade process and improve the use efficiency of the intelligent terminal during the system upgrade process.
为解决上述技术问题,本申请提供一种智能终端的系统升级方法,应用于智能终端,包括:In order to solve the above technical problems, the present application provides a system upgrade method for an intelligent terminal, which is applied to the intelligent terminal, including:
在升级方式选择界面中显示所述智能终端的系统升级方式,所述系统升级方式包括备份升级;Display the system upgrade mode of the intelligent terminal in the upgrade mode selection interface, and the system upgrade mode includes backup upgrade;
响应于升级方式选择指令,确定目标升级方式;当所述目标升级方式为备份升级时,显示存储空间显示界面;In response to the upgrade mode selection instruction, determine a target upgrade mode; when the target upgrade mode is a backup upgrade, display a storage space display interface;
若存在外接存储空间,响应于升级指令,使所述智能终端利用所述外接存储空间进行系统升级。If there is an external storage space, in response to the upgrade instruction, the intelligent terminal is made to use the external storage space to perform system upgrade.
可选地,当所述目标升级方式为备份升级时,显示存储空间显示界面,具体包括:Optionally, when the target upgrade mode is backup upgrade, displaying a storage space display interface, specifically including:
若确定存在所述外接存储空间,在所述存储空间显示界面上显示所述外接存储空间的标识;If it is determined that the external storage space exists, displaying the identifier of the external storage space on the storage space display interface;
若确定没有所述外接存储空间,在所述存储空间显示界面上显示提示接入所述外接存储空间的提示信息。If it is determined that there is no external storage space, a prompt message prompting access to the external storage space is displayed on the storage space display interface.
可选地,当所述目标升级方式为备份升级时,显示存储空间显示界面,还包括:Optionally, when the target upgrade mode is backup upgrade, displaying a storage space display interface, further comprising:
当所述目标升级方式为备份升级时,向服务器发送存储空间信息,以使所述服务器根据所述存储空间信息判断所述智能终端中是否存在外接存储空间,并向所述智能终端发送判断结果。When the target upgrade mode is backup upgrade, send storage space information to the server, so that the server can determine whether there is an external storage space in the intelligent terminal according to the storage space information, and send the determination result to the intelligent terminal .
可选地,在若存在外接存储空间,响应于升级指令,使所述智能终端利用所述外接存储空间进行系统升级之前,所述方法还包括:Optionally, before enabling the intelligent terminal to use the external storage space to perform system upgrade in response to an upgrade instruction if there is an external storage space, the method further includes:
当存在所述外接存储空间时,获取服务器发送的系统升级文件;When the external storage space exists, obtain the system upgrade file sent by the server;
其中,所述系统升级文件和所述外接存储空间用于对所述智能终端进行系统升级。Wherein, the system upgrade file and the external storage space are used for system upgrade of the intelligent terminal.
可选地,所述系统升级文件中包括校验文件和升级文件;若存在外接存储空间,响应于升级指令,使所述智能终端利用所述外接存储空间进行系统升级,具体包括:Optionally, the system upgrade file includes a verification file and an upgrade file; if there is an external storage space, in response to an upgrade instruction, the intelligent terminal uses the external storage space to perform system upgrade, specifically including:
使用所述校验文件与智能终端中对应的信息进行校验,确定校验结果;Use the verification file and the corresponding information in the intelligent terminal to perform verification to determine the verification result;
当所述校验结果为校验通过时,使用所述升级文件对所述外接存储空间中的备份系统的系统文件进行更新;When the verification result is that the verification passes, use the upgrade file to update the system file of the backup system in the external storage space;
当确定所述备份系统的系统文件更新成功时,将所述外接存储空间中的备份系统拷贝到所述智能终端的主存储空间中。When it is determined that the system file of the backup system is successfully updated, the backup system in the external storage space is copied to the main storage space of the intelligent terminal.
可选地,所述校验文件中包括设备信息集合和签名信息;所述使用所述校验文件与智能终端中对应的信息进行校验,确定校验结果,具体包括:Optionally, the verification file includes a device information set and signature information; the verification using the verification file and the corresponding information in the intelligent terminal to determine the verification result specifically includes:
当所述智能终端的设备信息在所述设备信息集合中时,确定所述设备信息校验成功;When the device information of the smart terminal is in the device information set, determine that the device information verification is successful;
当所述签名信息与所述智能终端中的签名信息匹配时,确定所述签名信息校验成功;When the signature information matches the signature information in the smart terminal, it is determined that the signature information verification is successful;
当所述设备信息与所述签名信息均校验成功时,确定所述校验结果为校验通过。When both the device information and the signature information are successfully verified, it is determined that the verification result is a verification pass.
可选地,所述使用所述升级文件对所述外接存储空间中的备份系统的系统文件进行更新,具体包括:Optionally, using the upgrade file to update the system file of the backup system in the external storage space specifically includes:
解析所述升级文件,获得所述升级文件中的更新指令和待更新文件;Parse the upgrade file, and obtain the update instruction and the file to be updated in the upgrade file;
根据所述更新指令和所述待更新文件,更新所述备份系统中的系统文件。According to the update instruction and the to-be-updated file, the system file in the backup system is updated.
可选地,所述根据所述更新指令和所述待更新文件,更新所述备份系统中的系统文件,具体包括以下至少一种:Optionally, the updating of the system file in the backup system according to the update instruction and the to-be-updated file specifically includes at least one of the following:
当所述更新指令为拷贝指令时,将所述备份系统中的指定文件拷贝到指定位置;When the update instruction is a copy instruction, copy the specified file in the backup system to a specified location;
当所述更新指令为新增指令时,将所述升级文件中的待更新文件新增到指定位置;When the update instruction is a new instruction, adding the to-be-updated file in the upgrade file to a specified location;
当所述更新指令为填充指令时,使用预设符号填充所述备份系统中的指定文件;When the update instruction is a filling instruction, use a preset symbol to fill the specified file in the backup system;
当所述更新指令为补丁指令时,将所述升级文件中的待更新文件写入到所述备份系统的指定文件中。When the update instruction is a patch instruction, the to-be-updated file in the upgrade file is written into a specified file of the backup system.
可选地,所述升级文件中还包括目标哈希值;所述将所述外接存储空间中的备份系统拷贝到所述智能终端的主存储空间中之前,所述方法,还包括:Optionally, the upgrade file further includes a target hash value; before the backup system in the external storage space is copied to the main storage space of the smart terminal, the method further includes:
计算更新后的所述备份系统的当前哈希值,当所述目标哈希值和所述当前哈希值匹配时,确定所述备份系统的系统文件更新成功。The updated current hash value of the backup system is calculated, and when the target hash value matches the current hash value, it is determined that the system file of the backup system is successfully updated.
可选地,当所述备份系统中包括多个分区时,所述计算更新后的所述备份系统的当前哈希值,并根据所述目标哈希值和所述当前哈希值,确定所述备份系统的系统文件是否更新成功,具体包括:Optionally, when the backup system includes multiple partitions, calculating the updated current hash value of the backup system, and determining the target hash value and the current hash value according to the target hash value and the current hash value. Whether the system files of the backup system are successfully updated, including:
计算每一所述分区的所述当前哈希值;calculating the current hash value for each of the partitions;
匹配每一所述分区的所述当前哈希值和所述分区的所述目标哈希值,并确定匹配结果;matching the current hash value of each of the partitions with the target hash value of the partition, and determining a matching result;
当全部所述分区的匹配结果均为匹配成功时,确定所述备份系统的所述系统文件更新成功。When the matching results of all the partitions are successful, it is determined that the system file of the backup system is updated successfully.
可选地,所述将所述外接存储空间中的备份系统拷贝到所述智能终端的主存储空间中,具体包括:Optionally, the copying of the backup system in the external storage space to the main storage space of the intelligent terminal specifically includes:
重启所述智能终端,加载并运行所述外接存储空间中更新后的所述备份系统;Restarting the intelligent terminal, loading and running the updated backup system in the external storage space;
当所述备份系统运行正常时,拷贝所述备份系统到所述智能终端的主存储空间中,完成所述智能终端的主存储空间中的新系统的更新;When the backup system operates normally, copy the backup system to the main storage space of the smart terminal, and complete the update of the new system in the main storage space of the smart terminal;
重启所述智能终端,加载并运行拷贝到所述主存储空间中的所述新系统。Restart the intelligent terminal, load and run the new system copied to the main storage space.
可选地,所述重启所述智能终端,加载并运行所述外接存储空间中更新后的所述备份系统,具体包括:Optionally, the restarting of the intelligent terminal to load and run the updated backup system in the external storage space specifically includes:
当确定所述备份系统的系统文件更新成功时,将升级变量设置为第一指标;When it is determined that the system file of the backup system is successfully updated, setting the upgrade variable as the first indicator;
重启所述智能终端,并根据所述第一指标,加载所述外接存储空间中的所述备份系统;restarting the smart terminal, and loading the backup system in the external storage space according to the first indicator;
在重启后的所述智能终端中运行预设脚本;当所述预设脚本运行成功时,确定所述备份系统运行正常。A preset script is run in the restarted smart terminal; when the preset script runs successfully, it is determined that the backup system runs normally.
可选地,所述方法,还包括以下至少一种:Optionally, the method further includes at least one of the following:
当确定所述备份系统的系统文件更新失败时,将所述升级变量设置为第二指标;When it is determined that the system file update of the backup system fails, the upgrade variable is set as the second indicator;
当所述预设脚本运行失败时,将所述升级变量设置为第二指标。When the preset script fails to run, the upgrade variable is set as the second indicator.
可选地,当所述升级变量为第二指标时,所述方法,还包括以下至少一种:Optionally, when the upgrade variable is the second index, the method further includes at least one of the following:
释放所述外接存储空间;release the external storage space;
在所述外接存储空间中重新生成备份系统。Regenerate the backup system in the external storage space.
本申请还提供一种智能终端,包括:存储器、处理器,其中,所述存储器上存储有系统升级程序,所述系统升级程序被所述处理器执行时实现如上述方法的步骤。The present application also provides an intelligent terminal, including: a memory and a processor, wherein a system upgrade program is stored in the memory, and the system upgrade program is executed by the processor to implement the steps of the above method.
本申请还提供一种计算机存储介质,所述计算机存储介质存储有计算机程序,所述计算机程序被处理器执行时实现如上述方法的步骤。The present application also provides a computer storage medium, where the computer storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above method are implemented.
如上所述,本申请的智能终端的系统升级方法,应用于智能终端,包括步骤:在升级方式选择界面中显示智能终端的系统升级方式,该系统升级方式中可以包括备份升级;在用户点击该升级方式选择界面中的某一升级方式时,生成升级方式选择指令,并确定目标升级方式;当目标升级方式为备份升级时,显示存储空间显示界面,存储空间显示界面中显示有该智能终端中包括的存储设备;若存在外接存储空间,响应于服务器发送的升级指令,使智能终端利用外接存储空间进行系统升级。通过上述技术方案,可以实现提高系统升级过程中的智能终端的使用效率的功能,还可以实现避免系统升级失败导致智能终端无法启动的情况,还解决了小容量智能终端在剩余空间不足时无法升级的问题,提升了用户体验。As described above, the system upgrade method for an intelligent terminal of the present application, applied to an intelligent terminal, includes the steps of: displaying a system upgrade mode of the intelligent terminal in the upgrade mode selection interface, and the system upgrade mode may include backup upgrade; When the upgrade method selects an upgrade method in the interface, the upgrade method selection instruction is generated, and the target upgrade method is determined; when the target upgrade method is backup upgrade, the storage space display interface is displayed, and the storage space display interface displays the intelligent terminal. The included storage device; if there is an external storage space, in response to an upgrade instruction sent by the server, the intelligent terminal uses the external storage space to upgrade the system. Through the above technical solutions, the function of improving the use efficiency of the intelligent terminal during the system upgrade process can be realized, and the situation that the intelligent terminal cannot be started due to the failure of the system upgrade can also be avoided, and the small-capacity intelligent terminal cannot be upgraded when the remaining space is insufficient. problem and improve the user experience.
附图说明Description of drawings
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本申请的实施例,并与说明书一起用于解释本申请的原理。为了更清楚地说明本申请实施例的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,对于本领域普通技术人员而言,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description serve to explain the principles of the application. In order to illustrate the technical solutions of the embodiments of the present application more clearly, the accompanying drawings required for the description of the embodiments will be briefly introduced below. Obviously, for those of ordinary skill in the art, without creative efforts On the premise, other drawings can also be obtained according to these drawings.
图1为实现本申请各个实施例的一种智能终端的硬件结构示意图;1 is a schematic diagram of a hardware structure of an intelligent terminal implementing various embodiments of the present application;
图2为本申请实施例提供的一种通信网络系统架构图;FIG. 2 is an architecture diagram of a communication network system provided by an embodiment of the present application;
图3是根据第一实施例示出的一种智能终端的系统升级方法的流程图;3 is a flowchart of a system upgrade method for an intelligent terminal according to the first embodiment;
图4是根据第一实施例示出的一种升级方式选择界面示意图;4 is a schematic diagram of an upgrade mode selection interface shown according to the first embodiment;
图5是根据第一实施例示出的一种存储空间显示界面示意图;5 is a schematic diagram of a storage space display interface according to the first embodiment;
图6是根据第二实施例示出的一种智能终端的系统升级方法的流程图;6 is a flowchart of a system upgrade method for an intelligent terminal according to the second embodiment;
图7是根据第二实施例示出的一种备份系统的系统文件更新流程图;Fig. 7 is a system file update flow chart of a backup system shown according to the second embodiment;
图8是根据第三实施例示出的一种主存储空间的系统更新流程图;Fig. 8 is a system update flow chart of a main storage space shown according to the third embodiment;
图9是根据第三实施例示出的一种备份系统更新示意图;9 is a schematic diagram of updating a backup system according to a third embodiment;
图10是根据第三实施例示出的一种新系统拷贝示意图。FIG. 10 is a schematic diagram of a new system copy according to the third embodiment.
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。通过上述附图,已示出本申请明确的实施例,后文中将有更详细的描述。这些附图和文字描述并不是为了通过任何方式限制本申请构思的范围,而是通过参考特定实施例为本领域技术人员说明本申请的概念。The realization, functional characteristics and advantages of the purpose of the present application will be further described with reference to the accompanying drawings in conjunction with the embodiments. Specific embodiments of the present application have been shown by the above-mentioned drawings, and will be described in more detail hereinafter. These drawings and written descriptions are not intended to limit the scope of the concepts of the present application in any way, but to illustrate the concepts of the present application to those skilled in the art by referring to specific embodiments.
具体实施方式Detailed ways
这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本申请相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本申请的一些方面相一致的装置和方法的例子。Exemplary embodiments will be described in detail herein, examples of which are illustrated in the accompanying drawings. Where the following description refers to the drawings, the same numerals in different drawings refer to the same or similar elements unless otherwise indicated. The implementations described in the illustrative examples below are not intended to represent all implementations consistent with this application. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present application as recited in the appended claims.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素,此外,本申请不同实施例中具有同样命名的部件、特征、要素可能具有相同含义,也可能具有不同含义,其具体含义需以其在该具体实施例中的解释或者进一步结合该具体实施例中上下文进行确定。It should be noted that, herein, the terms "comprising", "comprising" or any other variation thereof are intended to encompass non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements, It also includes other elements not expressly listed or inherent to such a process, method, article or apparatus. Without further limitation, an element defined by the phrase "comprises a..." does not preclude the presence of additional identical elements in the process, method, article, or device that includes the element, and further, different implementations of the present application Components, features and elements with the same names in the examples may have the same meaning or may have different meanings, and their specific meanings need to be determined by their explanations in this specific embodiment or further combined with the context in this specific embodiment.
应当理解,尽管在本文可能采用术语第一、第二、第三等来描述各种信息,但这些信息不应限于这些术语。这些术语仅用来将同一类型的信息彼此区分开。例如,在不脱离本文范围的情况下,第一信息也可以被称为第二信息,类似地,第二信息也可以被称为第一信息。取决于语境,如在此所使用的词语“如果”可以被解释成为“在……时”或“当……时”或“响应于确定”。再者,如同在本文中所使用的,单数形式“一”、“一个”和“该”旨在也包括复数形式,除非上下文中有相反的指示。应当进一步理解,术语“包含”、“包括”表明存在的特征、步骤、操作、元件、组件、项目、种类、和/或组,但不排除一个或多个其他特征、步骤、操作、元件、组件、项目、种类、和/或组的存在、出现或添加。本申请使用的术语“或”、“和/或”、“包括以下至少一个”等可被解释为包括性的,或意味着任一个或任何组合。例如,“包括以下至少一个:A、B、C”意味着“以下任一个:A;B;C;A和B;A和C;B和C;A和B和C”,再如,“A、B或C”或者“A、B和/或C”意味着“以下任一个:A;B;C;A和B;A和C;B和C;A和B和C”。仅当元件、功能、步骤或操作的组合在某些方式下内在地互相排斥时,才会出现该定义的例外。It should be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited by these terms. These terms are only used to distinguish the same type of information from each other. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of this document. Depending on the context, the word "if" as used herein can be interpreted as "at the time of" or "when" or "in response to determining." Also, as used herein, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context dictates otherwise. It should be further understood that the terms "comprising" and "comprising" indicate the presence of features, steps, operations, elements, components, items, kinds, and/or groups, but do not exclude one or more other features, steps, operations, elements, The existence, appearance or addition of components, items, categories, and/or groups. As used herein, the terms "or", "and/or", "including at least one of the following" and the like may be construed to be inclusive or to mean any one or any combination. For example, "comprising at least one of the following: A, B, C" means "any of the following: A; B; C; A and B; A and C; B and C; A and B and C", for example, " A, B or C" or "A, B and/or C" means "any of the following: A; B; C; A and B; A and C; B and C; A and B and C". Exceptions to this definition arise only when combinations of elements, functions, steps, or operations are inherently mutually exclusive in some way.
应该理解的是,虽然本申请实施例中的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,其可以以其他的顺序执行。而且,图中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,其执行顺序也不必然是依次进行,而是可以与其他步骤或者其他步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the steps in the flowcharts in the embodiments of the present application are displayed in sequence according to the arrows, these steps are not necessarily executed in the sequence indicated by the arrows. Unless explicitly stated herein, the execution of these steps is not strictly limited to the order and may be performed in other orders. Moreover, at least a part of the steps in the figure may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but may be executed at different times, and the execution order is not necessarily sequential. Instead, it may be performed in turn or alternately with other steps or at least a portion of sub-steps or stages of other steps.
取决于语境,如在此所使用的词语“如果”、“若”可以被解释成为“在……时”或“当……时”或“响应于确定”或“响应于检测”。类似地,取决于语境,短语“如果确定”或“如果检测(陈述的条件或事件)”可以被解释成为“当确定时”或“响应于确定”或“当检测(陈述的条件或事件)时”或“响应于检测(陈述的条件或事件)”。Depending on the context, the words "if", "if" as used herein may be interpreted as "at" or "when" or "in response to determining" or "in response to detecting". Similarly, the phrases "if determined" or "if detected (the stated condition or event)" can be interpreted as "when determined" or "in response to determining" or "when detected (the stated condition or event)," depending on the context )" or "in response to detection (a stated condition or event)".
需要说明的是,在本文中,采用了诸如S101、S102等步骤代号,其目的是为了更清楚简要地表述相应内容,不构成顺序上的实质性限制,本领域技术人员在具体实施时,可能会先执行S102后执行S101等,但这些均应在本申请的保护范围之内。It should be noted that, in this article, step codes such as S101 and S102 are used, the purpose of which is to express the corresponding content more clearly and briefly, and does not constitute a substantial restriction on the order. Those skilled in the art may S102 will be executed first and then S101, etc., but these should all fall within the protection scope of this application.
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.
在后续的描述中,使用用于表示元件的诸如“模块”、“部件”或者“单元”的后缀仅为了有利于本申请的说明,其本身没有特定的意义。因此,“模块”、“部件”或者“单元”可以混合地使用。In the following description, suffixes such as "module", "component" or "unit" used to represent elements are used only to facilitate the description of the present application, and have no specific meaning per se. Thus, "module", "component" or "unit" may be used interchangeably.
智能终端可以以各种形式来实施。例如,本申请中描述的智能终端可以包括诸如手机、平板电脑、笔记本电脑、掌上电脑、PDA(Personal Digital Assistant,个人数字助理)、PMP(Portable Media Player,便捷式媒体播放器)、导航装置、可穿戴设备、智能手环、计步器等智能终端,以及诸如数字TV、台式计算机等固定终端。Smart terminals can be implemented in various forms. For example, the smart terminals described in this application may include mobile phones, tablet computers, notebook computers, PDAs, PDAs (Personal Digital Assistants), PMPs (Portable Media Players, portable media players), navigation devices, Wearable devices, smart bracelets, pedometers and other smart terminals, as well as fixed terminals such as digital TVs and desktop computers.
后续描述中将以智能终端为例进行说明,本领域技术人员将理解的是,除了特别用于移动目的的元件之外,根据本申请的实施方式的构造也能够应用于固定类型的终端。The following description will take a smart terminal as an example, and those skilled in the art will understand that the configuration according to the embodiments of the present application can also be applied to a stationary type of terminal, in addition to elements specially used for mobile purposes.
请参阅图1,其为实现本申请各个实施例的一种智能终端的硬件结构示意图,该智能终端100可以包括:RF(Radio Frequency,射频)单元101、WiFi模块102、音频输出单元103、A/V(音频/视频)输入单元104、传感器105、显示单元106、用户输入单元107、接口单元108、存储器109、处理器110、以及电源111等部件。本领域技术人员可以理解,图1中示出的智能终端结构并不构成对智能终端的限定,智能终端可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Please refer to FIG. 1, which is a schematic diagram of the hardware structure of an intelligent terminal implementing various embodiments of the present application. The
下面结合图1对智能终端的各个部件进行具体的介绍:Below in conjunction with Fig. 1, each component of the intelligent terminal is introduced in detail:
射频单元101可用于收发信息或通话过程中,信号的接收和发送,具体的,将基站的下行信息接收后,给处理器110处理;另外,将上行的数据发送给基站。通常,射频单元101包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器、双工器等。此外,射频单元101还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于GSM(Global System of Mobile communication,全球移动通讯系统)、GPRS(General Packet Radio Service,通用分组无线服务)、CDMA2000(CodeDivision Multiple Access 2000,码分多址2000)、WCDMA(Wideband Code DivisionMultiple Access,宽带码分多址)、TD-SCDMA(Time Division-Synchronous CodeDivision Multiple Access,时分同步码分多址)、FDD-LTE(Frequency DivisionDuplexing-Long Term Evolution,频分双工长期演进)、TDD-LTE(Time DivisionDuplexing-Long Term Evolution,分时双工长期演进)和5G等。The
WiFi属于短距离无线传输技术,智能终端通过WiFi模块102可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图1示出了WiFi模块102,但是可以理解的是,其并不属于智能终端的必须构成,完全可以根据需要在不改变发明的本质的范围内而省略。WiFi is a short-distance wireless transmission technology, and the smart terminal can help users to send and receive emails, browse web pages, access streaming media, etc. through the
音频输出单元103可以在智能终端100处于呼叫信号接收模式、通话模式、记录模式、语音识别模式、广播接收模式等等模式下时,将射频单元101或WiFi模块102接收的或者在存储器109中存储的音频数据转换成音频信号并且输出为声音。而且,音频输出单元103还可以提供与智能终端100执行的特定功能相关的音频输出(例如,呼叫信号接收声音、消息接收声音等等)。音频输出单元103可以包括扬声器、蜂鸣器等等。The
A/V输入单元104用于接收音频或视频信号。A/V输入单元104可以包括GPU(Graphics Processing Unit,图形处理器)1041和麦克风1042,图形处理器1041对在视频捕获模式或图像捕获模式中由图像捕获装置(如摄像头)获得的静态图片或视频的图像数据进行处理。处理后的图像帧可以显示在显示单元106上。经图形处理器1041处理后的图像帧可以存储在存储器109(或其它存储介质)中或者经由射频单元101或WiFi模块102进行发送。麦克风1042可以在电话通话模式、记录模式、语音识别模式等等运行模式中经由麦克风1042接收声音(音频数据),并且能够将这样的声音处理为音频数据。处理后的音频(语音)数据可以在电话通话模式的情况下转换为可经由射频单元101发送到移动通信基站的格式输出。麦克风1042可以实施各种类型的噪声消除(或抑制)算法以消除(或抑制)在接收和发送音频信号的过程中产生的噪声或者干扰。The A/
智能终端100还包括至少一种传感器105,比如光传感器、运动传感器以及其他传感器。可选地,光传感器包括环境光传感器及接近传感器,可选地,环境光传感器可根据环境光线的明暗来调节显示面板1061的亮度,接近传感器可在智能终端100移动到耳边时,关闭显示面板1061和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于手机还可配置的指纹传感器、压力传感器、虹膜传感器、分子传感器、陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The
显示单元106用于显示由用户输入的信息或提供给用户的信息。显示单元106可包括显示面板1061,可以采用LCD(Liquid Crystal Display,液晶显示器)、OLED(OrganicLight-Emitting Diode,有机发光二极管)等形式来配置显示面板1061。The
用户输入单元107可用于接收输入的数字或字符信息,以及产生与智能终端的用户设置以及功能控制有关的键信号输入。可选地,用户输入单元107可包括触控面板1071以及其他输入设备1072。触控面板1071,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板1071上或在触控面板1071附近的操作),并根据预先设定的程式驱动相应的连接装置。触控面板1071可包括触摸检测装置和触摸控制器两个部分。可选地,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器110,并能接收处理器110发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板1071。除了触控面板1071,用户输入单元107还可以包括其他输入设备1072。可选地,其他输入设备1072可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种,具体此处不做限定。The
可选地,触控面板1071可覆盖显示面板1061,当触控面板1071检测到在其上或附近的触摸操作后,传送给处理器110以确定触摸事件的类型,随后处理器110根据触摸事件的类型在显示面板1061上提供相应的视觉输出。虽然在图1中,触控面板1071与显示面板1061是作为两个独立的部件来实现智能终端的输入和输出功能,但是在某些实施例中,可以将触控面板1071与显示面板1061集成而实现智能终端的输入和输出功能,具体此处不做限定。Optionally, the
接口单元108用作至少一个外部装置与智能终端100连接可以通过的接口。例如,外部装置可以包括有线或无线头戴式耳机端口、外部电源(或电池充电器)端口、有线或无线数据端口、存储卡端口、用于连接具有识别模块的装置的端口、音频输入/输出(I/O)端口、视频I/O端口、耳机端口等等。接口单元108可以用于接收来自外部装置的输入(例如,数据信息、电力等等)并且将接收到的输入传输到智能终端100内的一个或多个元件或者可以用于在智能终端100和外部装置之间传输数据。The
存储器109可用于存储软件程序以及各种数据。存储器109可主要包括存储程序区和存储数据区,可选地,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器109可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The
处理器110是智能终端的控制中心,利用各种接口和线路连接整个智能终端的各个部分,通过运行或执行存储在存储器109内的软件程序和/或模块,以及调用存储在存储器109内的数据,执行智能终端的各种功能和处理数据,从而对智能终端进行整体监控。处理器110可包括一个或多个处理单元;优选的,处理器110可集成应用处理器和调制解调处理器,可选地,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器110中。The
智能终端100还可以包括给各个部件供电的电源111(比如电池),优选的,电源111可以通过电源管理系统与处理器110逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The
尽管图1未示出,智能终端100还可以包括蓝牙模块等,在此不再赘述。Although not shown in FIG. 1 , the
为了便于理解本申请实施例,下面对本申请的智能终端所基于的通信网络系统进行描述。To facilitate understanding of the embodiments of the present application, a communication network system on which the intelligent terminal of the present application is based is described below.
请参阅图2,图2为本申请实施例提供的一种通信网络系统架构图,该通信网络系统为通用移动通信技术的LTE系统,该LTE系统包括依次通讯连接的UE(User Equipment,用户设备)201,E-UTRAN(Evolved UMTS Terrestrial Radio Access Network,演进式UMTS陆地无线接入网)202,EPC(Evolved Packet Core,演进式分组核心网)203和运营商的IP业务204。Please refer to FIG. 2. FIG. 2 is an architecture diagram of a communication network system provided by an embodiment of the application. The communication network system is an LTE system of universal mobile communication technology. ) 201 , E-UTRAN (Evolved UMTS Terrestrial Radio Access Network, Evolved UMTS Terrestrial Radio Access Network) 202 , EPC (Evolved Packet Core, Evolved Packet Core) 203 and operator's
可选地,UE201可以是上述终端100,此处不再赘述。Optionally, the
E-UTRAN202包括eNodeB2021和其它eNodeB2022等。可选地,eNodeB2021可以通过回程(backhaul)(例如X2接口)与其它eNodeB2022连接,eNodeB2021连接到EPC203,eNodeB2021可以提供UE201到EPC203的接入。
EPC203可以包括MME(Mobility Management Entity,移动性管理实体)2031,HSS(Home Subscriber Server,归属用户服务器)2032,其它MME2033,SGW(Serving Gate Way,服务网关)2034,PGW(PDN Gate Way,分组数据网络网关)2035和PCRF(Policy andCharging Rules Function,政策和资费功能实体)2036等。可选地,MME2031是处理UE201和EPC203之间信令的控制节点,提供承载和连接管理。HSS2032用于提供一些寄存器来管理诸如归属位置寄存器(图中未示)之类的功能,并且保存有一些有关服务特征、数据速率等用户专用的信息。所有用户数据都可以通过SGW2034进行发送,PGW2035可以提供UE 201的IP地址分配以及其它功能,PCRF2036是业务数据流和IP承载资源的策略与计费控制策略决策点,它为策略与计费执行功能单元(图中未示)选择及提供可用的策略和计费控制决策。
IP业务204可以包括因特网、内联网、IMS(IP Multimedia Subsystem,IP多媒体子系统)或其它IP业务等。The
虽然上述以LTE系统为例进行了介绍,但本领域技术人员应当知晓,本申请不仅仅适用于LTE系统,也可以适用于其他无线通信系统,例如GSM、CDMA2000、WCDMA、TD-SCDMA以及未来新的网络系统(如5G)等,此处不做限定。Although the above takes the LTE system as an example, those skilled in the art should know that this application is not only applicable to the LTE system, but also applicable to other wireless communication systems, such as GSM, CDMA2000, WCDMA, TD-SCDMA and future new The network system (such as 5G), etc., is not limited here.
基于上述智能终端硬件结构以及通信网络系统,提出本申请各个实施例。Based on the above-mentioned intelligent terminal hardware structure and communication network system, various embodiments of the present application are proposed.
第一实施例first embodiment
图3示出了本申请一实施例提供的一种智能终端的系统升级方法的流程图。在图1和图2所示实施例的基础上,如图3所示,以智能终端为执行主体,本实施例的方法可以包括如下步骤:FIG. 3 shows a flowchart of a system upgrade method for an intelligent terminal provided by an embodiment of the present application. On the basis of the embodiments shown in FIG. 1 and FIG. 2 , as shown in FIG. 3 , with an intelligent terminal as the execution subject, the method of this embodiment may include the following steps:
S101、在升级方式选择界面中显示智能终端的系统升级方式,系统升级方式包括备份升级。S101. Display the system upgrade mode of the intelligent terminal in the upgrade mode selection interface, and the system upgrade mode includes backup upgrade.
本实施例中,为了配合用户需求增加新功能、修复当前系统中存在的一些问题、优化系统运行效率,在智能终端的使用过程中通常需要对智能终端的系统进行升级。智能终端的系统升级通常由服务器发起。当管理员在服务器中完成升级版本的上传后,服务器会将系统升级提醒推送到智能终端。智能终端可以根据预设的系统升级方式执行对应的操作。例如,当智能终端设置的系统升级方式为用户手动升级时,智能终端可以在接收到该系统升级提醒后将该系统升级提醒展示在显示界面中。用户可以在查看到该系统升级提醒后,进入对应的系统升级界面手动选择系统升级。又如,当智能终端设置的系统升级方式为自动升级时,智能终端可以根据预设的升级时间,自动完成智能终端的系统升级。其中,智能终端的系统升级方式可以在智能终端的升级方式选择界面中进行设置。例如,如图4所示为智能终端的一种升级方式选择界面。该升级方式选择界面为设置模块中页面。该页面用于显示升级方式的菜单。该升级方式选择界面中可以包括在线升级(ONLINE UPDATE)、本地升级(LOCAL UPDATE)、备份升级(EXTRA UPDATE)三种。该三种升级方式分别对应于一个按钮。其中,在线升级(ONLINE UPDATE)和本地升级(LOCAL UPDATE)为现有技术中常用的两种升级方式。本申请将使用外接存储空间的升级方式称为备份升级(EXTRA UPDATE)。该备份升级(EXTRA UPDATE)的按钮可以设置于菜单的最后一项。当用户点击其中某一按钮时,智能终端将生成升级方式选择指令。该升级方式选择指令中对应的目标升级方式即为用户点击的按钮对应的升级方式。例如,当用户点击备份升级时,该升级方式选择指令对应的目标升级方式为备份升级。In this embodiment, in order to add new functions according to user requirements, repair some problems existing in the current system, and optimize system operation efficiency, the system of the intelligent terminal usually needs to be upgraded during the use of the intelligent terminal. The system upgrade of the intelligent terminal is usually initiated by the server. After the administrator uploads the upgrade version on the server, the server will push the system upgrade reminder to the smart terminal. The intelligent terminal can perform corresponding operations according to the preset system upgrade method. For example, when the system upgrade mode set by the smart terminal is manual upgrade by the user, the smart terminal may display the system upgrade reminder on the display interface after receiving the system upgrade reminder. After viewing the system upgrade reminder, the user can enter the corresponding system upgrade interface to manually select the system upgrade. For another example, when the system upgrade mode set by the intelligent terminal is automatic upgrade, the intelligent terminal can automatically complete the system upgrade of the intelligent terminal according to the preset upgrade time. The system upgrade mode of the smart terminal can be set in the upgrade mode selection interface of the smart terminal. For example, as shown in FIG. 4, an upgrade mode selection interface of the intelligent terminal is shown. The upgrade mode selection interface is the page in the setting module. This page is used to display a menu of how to upgrade. The upgrade mode selection interface may include online upgrade (ONLINE UPDATE), local upgrade (LOCAL UPDATE), and backup upgrade (EXTRA UPDATE). The three upgrade methods correspond to a button respectively. Among them, online upgrade (ONLINE UPDATE) and local upgrade (LOCAL UPDATE) are two upgrade methods commonly used in the prior art. In this application, the upgrade method using the external storage space is called backup upgrade (EXTRA UPDATE). The backup upgrade (EXTRA UPDATE) button can be set in the last item of the menu. When the user clicks one of the buttons, the intelligent terminal will generate an upgrade mode selection instruction. The target upgrade mode corresponding to the upgrade mode selection instruction is the upgrade mode corresponding to the button clicked by the user. For example, when the user clicks backup upgrade, the target upgrade mode corresponding to the upgrade mode selection instruction is backup upgrade.
S102、响应于升级方式选择指令,确定目标升级方式。当目标升级方式为备份升级时,显示存储空间显示界面。S102. In response to the upgrade mode selection instruction, determine the target upgrade mode. When the target upgrade mode is backup upgrade, the storage space display interface is displayed.
本实施例中,智能终端可以获取该升级方式选择指令。智能终端可以根据该升级方式选择指令,确定目标升级方式。当用户选择的是在线升级或者本地升级时,该次升级方式选择设置结束。智能终端可以提示用户完成设置和/或跳转到其他界面。而当用户选择的是备份升级时,由于升级过程中需要使用到外接存储空间,因此,智能终端会跳转到存储空间显示界面。当该智能终端中包括外接存储空间时,该存储空间显示界面可以如图5所示,智能终端会显示内部共享存储和SD存储。其中,内部共享存储为该智能终端的主存储空间。其中,SD存储为用户在该智能终端中插入的外接存储空间。当智能终端中未设置有外接存储空间时,如图5中框1的虚线框中的内容将不显示。当智能终端中设置有两个外接存储空间时,如图5中框2的虚线框中将显示第二个外接存储空间的信息。备份升级过程中需要使用到一个外接存储空间。因此,当智能终端跳转到存储空间显示界面后,如果智能终端中包括外接存储空间,则如图5所示,该存储空间显示界面上将显示该外接存储空间的标识。In this embodiment, the intelligent terminal may acquire the upgrade mode selection instruction. The intelligent terminal can select an instruction according to the upgrade mode to determine the target upgrade mode. When the user selects the online upgrade or the local upgrade, the selection and setting of the upgrade mode ends. The smart terminal can prompt the user to complete the settings and/or jump to other interfaces. When the user selects backup and upgrade, since an external storage space needs to be used in the upgrade process, the smart terminal will jump to the storage space display interface. When the intelligent terminal includes an external storage space, the storage space display interface may be as shown in FIG. 5 , and the intelligent terminal will display the internal shared storage and SD storage. The internal shared storage is the main storage space of the intelligent terminal. The SD storage is an external storage space inserted by the user in the smart terminal. When no external storage space is set in the smart terminal, the content in the dotted box of box 1 in FIG. 5 will not be displayed. When two external storage spaces are set in the smart terminal, the information of the second external storage space will be displayed in the dashed box of box 2 in FIG. 5 . An external storage space is required during the backup and upgrade process. Therefore, after the smart terminal jumps to the storage space display interface, if the smart terminal includes an external storage space, as shown in FIG. 5 , the storage space display interface will display the logo of the external storage space.
可选地,当该智能终端中不存在外接存储空间时,该智能终端可以在该存储空间显示界面上显示提示接入外接存储空间的提示信息。例如,如图5中框1的虚线框中不显示该外接存储空间的标识,而显示该提示信息。又如,智能终端可以以弹窗的方式显示该提示信息。例如,该提示信息可以为“请插入SD卡”。Optionally, when there is no external storage space in the intelligent terminal, the intelligent terminal may display prompt information prompting access to the external storage space on the storage space display interface. For example, in the dashed box of box 1 in FIG. 5 , the identification of the external storage space is not displayed, but the prompt information is displayed. For another example, the smart terminal may display the prompt information in the form of a pop-up window. For example, the prompt information may be "Please insert an SD card".
可选地,当该智能终端中不存在外接存储空间时,智能终端可以在用户点击升级按钮时,以弹窗的方式显示提示接入外接存储空间的提示信息。该提示信息用于告知用户需要接入外接存储空间才可以完成该备份升级的方式的设置。Optionally, when there is no external storage space in the intelligent terminal, when the user clicks the upgrade button, the intelligent terminal may display prompt information prompting access to the external storage space in a pop-up window. The prompt information is used to inform the user that the user needs to access the external storage space to complete the setting of the backup upgrade mode.
用户可以点击如图5所示的确定按钮,完成在智能终端中该备份升级方式的设置。智能终端可以在用户点击确定按钮时,重新获取智能终端中的存储空间信息。当用户已经根据该存储空间显示界面中的提示信息插入外接存储后,该智能终端可以通过重新获取存储空间信息,实现该智能终端中包括外接存储空间的判断。否则,当智能终端中不存在外接存储空间时,智能终端将无法触发该确定按钮的确定操作。即,该智能终端将无法完成该备份升级的设置。The user can click the OK button as shown in FIG. 5 to complete the setting of the backup and upgrade mode in the smart terminal. When the user clicks the OK button, the smart terminal can re-acquire the storage space information in the smart terminal. After the user has inserted the external storage according to the prompt information in the storage space display interface, the intelligent terminal can realize the judgment that the external storage space is included in the intelligent terminal by re-acquiring storage space information. Otherwise, when there is no external storage space in the smart terminal, the smart terminal will not be able to trigger the confirmation operation of the confirmation button. That is, the smart terminal will not be able to complete the backup and upgrade settings.
S103、若存在外接存储空间,响应于升级指令,使智能终端利用外接存储空间进行系统升级。S103. If there is an external storage space, in response to the upgrade instruction, enable the intelligent terminal to use the external storage space to perform system upgrade.
本实施例中,当智能终端完成升级方式的设置,且该升级方式被设置为备份升级后,该智能终端可以在获取到升级指令时,使用该备份升级的方式完成系统升级。在该备份升级过程中,智能终端需要在获取该升级指令后,获取存储空间信息并将该存储空间信息发送到服务器。服务器可以根据该存储空间信息,判断该智能终端中是否存在外接存储空间。该判断过程的使用,可以保证在执行升级操作时,该智能终端中存在外接存储空间,避免在用户插入外接存储设备完成升级方式的设置后拔出该外接存储设备。当服务器确定该智能终端中存在外接存储空间时,服务器可以将系统升级文件发送到智能终端。智能终端可以使用该系统升级文件,在外接存储空间中完成备份系统的升级。智能终端还可以在备份系统完成升级后,将该备份系统拷贝到主存储空间中。智能终端还可以在完成备份系统的拷贝后,释放外接存储空间。In this embodiment, after the smart terminal completes the setting of the upgrade mode, and the upgrade mode is set to backup upgrade, the smart terminal can use the backup upgrade mode to complete the system upgrade when acquiring the upgrade instruction. In the backup and upgrade process, the intelligent terminal needs to obtain storage space information and send the storage space information to the server after obtaining the upgrade instruction. The server can determine whether there is an external storage space in the intelligent terminal according to the storage space information. The use of the judgment process can ensure that there is an external storage space in the intelligent terminal when performing the upgrade operation, and avoid pulling out the external storage device after the user inserts the external storage device to complete the setting of the upgrade mode. When the server determines that there is an external storage space in the intelligent terminal, the server may send the system upgrade file to the intelligent terminal. The intelligent terminal can use the system upgrade file to complete the upgrade of the backup system in the external storage space. The intelligent terminal can also copy the backup system to the main storage space after the backup system is upgraded. The smart terminal can also release the external storage space after completing the copy of the backup system.
本申请提供的智能终端的系统升级方法,智能终端中可以包括升级方式选择界面。该升级方式选择界面中显示有多种智能终端的系统升级方式。该系统升级方式中可以包括备份升级。智能终端可以在用户点击该升级方式选择界面中的某一升级方式时,生成升级方式选择指令,确定目标升级方式。当该目标升级方式为备份升级时,智能终端会跳转到存储空间显示界面。该存储空间显示界面中可以显示有该智能终端中包括的存储设备。该存储设备中可以包括主存储空间和外接存储空间。当智能终端中包括外接存储空间时,智能终端可以在获取服务器发送的系统升级文件后,利用外接存储空间进行系统升级。本申请中,通过设置备份升级的系统升级方式,实现智能终端利用外接存储空间进行系统升级,使智能终端在系统升级过程中可以正常使用,提高系统升级过程中的智能终端的使用效率。In the system upgrade method for an intelligent terminal provided by the present application, the intelligent terminal may include an upgrade mode selection interface. The upgrade mode selection interface displays a variety of system upgrade modes of the intelligent terminal. The system upgrade method may include backup upgrade. When the user clicks an upgrade mode in the upgrade mode selection interface, the intelligent terminal can generate an upgrade mode selection instruction to determine the target upgrade mode. When the target upgrade mode is backup upgrade, the smart terminal will jump to the storage space display interface. The storage space display interface may display the storage device included in the smart terminal. The storage device may include a main storage space and an external storage space. When the intelligent terminal includes an external storage space, the intelligent terminal can use the external storage space to upgrade the system after obtaining the system upgrade file sent by the server. In this application, by setting the system upgrade method of backup upgrade, the intelligent terminal can use the external storage space to upgrade the system, so that the intelligent terminal can be used normally during the system upgrade process, and the use efficiency of the intelligent terminal in the system upgrade process is improved.
第二实施例Second Embodiment
图6示出了本申请一实施例提供的一种智能终端的系统升级方法的流程图。在图1至图5所示实施例的基础上,如图6所示,在若存在外接存储空间,以智能终端为执行主体,本实施例的系统升级方法具体可以包括如下步骤:FIG. 6 shows a flowchart of a system upgrade method for an intelligent terminal provided by an embodiment of the present application. On the basis of the embodiments shown in FIG. 1 to FIG. 5, as shown in FIG. 6, if there is an external storage space and the intelligent terminal is used as the execution subject, the system upgrade method of this embodiment may specifically include the following steps:
S201、当存在外接存储空间时,获取服务器发送的系统升级文件。其中,系统升级文件和外接存储空间用于对智能终端进行系统升级。S201. When there is an external storage space, obtain a system upgrade file sent by the server. Among them, the system upgrade file and the external storage space are used for system upgrade of the intelligent terminal.
本实施例中,当管理员在服务器中上传系统升级文件后,服务器会向已经关联的智能终端发送升级指令。如图7所示,服务器向智能终端发送升级指令。智能终端获取远程的服务器发送的升级指令。该升级指令用于提醒该智能终端进行系统升级。该关联的智能终端可以包括某品牌的已经卖出并进行开机注册的智能终端。或者,该关联的智能终端可以包括某品牌的某型号的已经卖出并进行开机注册的智能终端。In this embodiment, after the administrator uploads the system upgrade file in the server, the server will send an upgrade instruction to the associated intelligent terminal. As shown in Figure 7, the server sends an upgrade instruction to the intelligent terminal. The intelligent terminal obtains the upgrade instruction sent by the remote server. The upgrade instruction is used to remind the intelligent terminal to perform system upgrade. The associated smart terminals may include smart terminals of a certain brand that have been sold and registered. Alternatively, the associated smart terminal may include a certain model of a certain brand of smart terminals that have been sold and have been powered on and registered.
智能终端在获取服务器发送的升级指令后,可以检测器配置的系统升级方式,并根据该系统升级方式反馈信息。例如,当该系统升级方式为备份升级时,如图7所示,智能终端向服务器反馈存储空间信息。服务器可以在获取智能终端发送的存储空间信息后,判断该智能终端中是否存在外接存储空间。该外接存储空间为SD卡。该服务器可以通过反馈的存储空间信息的/dev/block/xx等智能终端中存储空间的地址进行确认。由于在该阶段,智能终端处于被动接受系统升级阶段,因此,在该阶段,智能终端仅需要根据升级指令反馈对应信息即可。即,该升级指令中可以包括服务器向该智能终端发送的存储空间信息请求指令。After acquiring the upgrade instruction sent by the server, the intelligent terminal can detect the system upgrade mode configured by the detector, and feed back information according to the system upgrade mode. For example, when the system upgrade method is backup upgrade, as shown in FIG. 7 , the intelligent terminal feeds back storage space information to the server. The server may determine whether there is an external storage space in the intelligent terminal after acquiring the storage space information sent by the intelligent terminal. The external storage space is an SD card. The server can be confirmed by the address of the storage space in the smart terminal such as /dev/block/xx of the feedback storage space information. Since at this stage, the smart terminal is in the stage of passively accepting the system upgrade, at this stage, the smart terminal only needs to feed back corresponding information according to the upgrade instruction. That is, the upgrade instruction may include a storage space information request instruction sent by the server to the intelligent terminal.
当该智能终端中不存在外接存储空间时,否则,服务器向智能终端反馈异常提醒。该异常提醒用于提示用户插入外置存储。智能终端可以在获取该异常提醒后在显示界面中显示该异常提醒。由于该在该阶段,智能终端处于被动状态,因此,服务器可以周期性的向智能终端发送升级指令,以使智能终端周期性的提醒用户插入外接存储,并周期性的向服务器反馈智能终端的存储空间信息。When there is no external storage space in the intelligent terminal, otherwise, the server feeds back an abnormality reminder to the intelligent terminal. The exception reminder is used to prompt the user to insert the external storage. The intelligent terminal may display the abnormality reminder on the display interface after acquiring the abnormality reminder. Since the smart terminal is in a passive state at this stage, the server can periodically send upgrade instructions to the smart terminal, so that the smart terminal periodically reminds the user to insert the external storage, and periodically feeds back the storage of the smart terminal to the server. spatial information.
当该智能终端中存在外接存储空间时,服务器可以通过传输数据的方式向智能终端发送系统升级文件。当智能终端接收到该系统升级文件后,该智能终端可以在后台开启系统升级进程。由于该系统升级进程在执行过程中主要使用了外接存储空间,因此,该系统升级进程的执行不会影响智能终端中主存储空间的正常使用。即,当该系统升级进程执行过程中,用户可以正常使用智能终端。为了更好的实现该效果,该系统升级进程可以为守护进程,并在后台执行。为了避免该系统升级进程可能对智能终端正常使用产生干扰,可以将该系统升级进程对主存储空间的权限设置为只读。这样,该系统升级进程将无法在主存储空间中进行写入,进一步避免了用户正常使用过程中对主存储空间读写操作的干扰。When there is an external storage space in the intelligent terminal, the server can send the system upgrade file to the intelligent terminal by means of data transmission. After the intelligent terminal receives the system upgrade file, the intelligent terminal can start the system upgrade process in the background. Since the system upgrade process mainly uses the external storage space during the execution process, the execution of the system upgrade process will not affect the normal use of the main storage space in the smart terminal. That is, during the execution of the system upgrade process, the user can use the smart terminal normally. In order to better achieve this effect, the system upgrade process can be a daemon process and be executed in the background. In order to avoid that the system upgrade process may interfere with the normal use of the smart terminal, the permission of the system upgrade process to the main storage space can be set to read-only. In this way, the system upgrade process will not be able to write in the main storage space, which further avoids the user's interference with the read and write operations of the main storage space during normal use.
S202、系统升级文件中包括校验文件,使用校验文件与智能终端中对应的信息进行校验,确定校验结果。S202. The system upgrade file includes a verification file, and the verification file is used to perform verification with the corresponding information in the smart terminal to determine the verification result.
本实施例中,当智能终端获取系统升级文件后,首先需要对系统升级文件进行校验,以确定该系统升级文件与该智能终端匹配。该校验过程可以通过系统升级进程执行。该系统升级文件中的校验文件可以为该系统升级文件的元数据。该元数据可以为服务器发送到智能终端的包含系统升级文件的报文的报文头。该校验文件中可以包括设备信息集合和签名信息。其中,设备信息集合中可以包括至少一个智能终端的设备信息。该设备信息可以为智能终端的型号、智能终端的系统的版本号等信息。由于系统升级通常对应于某些型号或者版本号的智能终端。因此,该设备信息集合中包括的至少一个智能终端的设备信息为该系统升级文件适用的智能终端的设备信息。例如,当升级文件中包括补丁文件时,该补丁文件通常用于修改某些版本号的系统中的bug。又如,当升级文件中包括新增文件时,该新增文件的新增功能的实现可能依赖于某些信号的智能终端中的硬件设备实现。In this embodiment, after the intelligent terminal obtains the system upgrade file, it first needs to verify the system upgrade file to determine that the system upgrade file matches the intelligent terminal. The verification process may be performed through a system upgrade process. The verification file in the system upgrade file may be metadata of the system upgrade file. The metadata may be the message header of the message containing the system upgrade file sent by the server to the intelligent terminal. The verification file may include a device information set and signature information. The device information set may include device information of at least one smart terminal. The device information may be information such as the model of the smart terminal, the version number of the system of the smart terminal, and the like. Because the system upgrade usually corresponds to certain models or versions of smart terminals. Therefore, the device information of at least one smart terminal included in the device information set is the device information of the smart terminal to which the system upgrade file is applicable. For example, when a patch file is included in the upgrade file, the patch file is often used to fix bugs in certain version numbers of the system. For another example, when the upgrade file includes a new file, the realization of the new function of the new file may depend on the realization of the hardware device in the smart terminal of some signals.
智能终端可以在获取到校验文件时,对校验文件中的内容进行解析,获取其中的设备信息集合和签名信息。可选地,智能终端使用校验文件与智能终端中对应的信息进行校验的校验内容可以包括如下步骤:When acquiring the verification file, the intelligent terminal can parse the content in the verification file, and obtain the device information set and signature information therein. Optionally, the verification content that is verified by the intelligent terminal using the verification file and the corresponding information in the intelligent terminal may include the following steps:
步骤1、智能终端可以获取校验文件中的设备信息集合。智能终端可以获取本身的设备信息。当本身的设备信息在设备信息集合中时,智能终端可以确定设备信息校验成功。Step 1. The intelligent terminal can obtain the device information set in the verification file. Smart terminals can obtain their own device information. When its own device information is in the device information set, the smart terminal can determine that the device information verification is successful.
总部2、智能终端可以获取校验文件中的签名信息。智能终端可以获取本身的签名信息。当本身的签名信息与校验文件中的签名信息匹配时,智能终端可以确定签名信息校验成功。Headquarters 2. The smart terminal can obtain the signature information in the verification file. The smart terminal can obtain its own signature information. When the signature information of itself matches the signature information in the verification file, the smart terminal can determine that the verification of the signature information is successful.
步骤3、智能终端可以在确定设备信息校验成功,且签名信息校验成功时,确定该次校验结果为校验通过。Step 3: The smart terminal may determine that the verification result of the current verification is passed when it is determined that the verification of the device information is successful and the verification of the signature information is successful.
可选地,为了提高服务器与智能终端之间的交互效率,智能终端可以在接收到该校验文件时,先执行校验。当校验通过后,该智能终端将继续获取服务器发送的系统升级文件中的升级文件。由于校验文件的内容较少,通常只有kb级数据。而升级文件通常数据量较大。该方式可以有效避免当验证不通过时,升级文件的获取,从而有效提高服务器与智能终端之间的交互效率,提高网络的利用率。Optionally, in order to improve the interaction efficiency between the server and the intelligent terminal, the intelligent terminal may perform the verification first when receiving the verification file. After the verification is passed, the intelligent terminal will continue to obtain the upgrade file in the system upgrade file sent by the server. Since the content of the checksum file is small, it usually only has KB-level data. The upgrade file usually has a large amount of data. This method can effectively avoid the acquisition of the upgrade file when the verification fails, thereby effectively improving the interaction efficiency between the server and the intelligent terminal, and improving the utilization rate of the network.
S203、当校验结果为校验通过时,使用升级文件对外接存储空间中的备份系统的系统文件进行更新。S203. When the verification result is that the verification passes, use the upgrade file to update the system file of the backup system in the external storage space.
本实施例中,当校验结果为校验通过时,智能终端可以继续使用升级文件进行升级。外接存储空间中可以设置有主存储空间中系统文件的备份。智能终端可以使用该升级文件对该外接存储空间中的该备份系统的系统文件进行更新。可选地,当该升级文件中包括全部系统文件时,该更新可以包括使用该升级文件替换该备份系统的系统文件。可选地,当该升级文件中包括系统文件的更新指令和待更新文件时,终端设置使用升级文件对外接存储空间中的备份系统的系统文件进行更新的具体步骤可以包括:In this embodiment, when the verification result is that the verification passes, the smart terminal can continue to use the upgrade file to upgrade. A backup of system files in the main storage space can be set in the external storage space. The intelligent terminal can use the upgrade file to update the system file of the backup system in the external storage space. Optionally, when the upgrade file includes all system files, the update may include replacing the system files of the backup system with the upgrade file. Optionally, when the upgrade file includes the update instruction of the system file and the file to be updated, the specific steps of the terminal setting and using the upgrade file to update the system file of the backup system in the external storage space may include:
步骤1、智能终端解析升级文件,获得该升级文件中的更新指令和待更新文件。如图7所示,该更新指令具体可以包括拷贝指令、新增指令、填充指令、补丁指令等。这些更新指令用于实现对外接存储空间中备份系统的系统文件的操作。其中,待更新文件为需要写入到备份系统中的文件。Step 1. The intelligent terminal parses the upgrade file, and obtains the update instruction and the file to be updated in the upgrade file. As shown in FIG. 7 , the update instruction may specifically include a copy instruction, an add instruction, a fill instruction, a patch instruction, and the like. These update instructions are used to implement operations on the system files of the backup system in the external storage space. The file to be updated is a file that needs to be written into the backup system.
步骤2、智能终端根据更新指令和待更新文件,更新备份系统中的系统文件。该过程中,针对不同的更新指令可以具有不同的操作。其具体包括:Step 2: The intelligent terminal updates the system files in the backup system according to the update instruction and the files to be updated. In this process, different update instructions may have different operations. It specifically includes:
当更新指令为拷贝指令时,智能终端可以直接拷贝目标内容到外接存储空间的指定位置上。该目标内容可以为升级文件中的待更新文件。或者,该目标内容可以为主存储空间的系统文件中的目标内容。或者,该目标内容可以为主存储空间中存储的目标内容。该更新操作具体可以通过Linux系统中的copy指令实现。该拷贝后的文件在备份系统中的位置发生改变,文件名不发生变化。When the update instruction is a copy instruction, the smart terminal can directly copy the target content to a specified location in the external storage space. The target content may be a to-be-updated file in the upgrade file. Alternatively, the target content may be the target content in the system file of the main storage space. Alternatively, the target content may be the target content stored in the main storage space. The update operation can be specifically implemented through the copy instruction in the Linux system. The location of the copied file in the backup system changes, but the file name does not change.
当更新指令为新增指令时,智能终端可以在获取系统文件中的待更新文件后,将该待更新文件写入外接存储空间的指定位置。该新增的文件为备份系统中原来不存在的文件。When the update instruction is a newly added instruction, the intelligent terminal can write the to-be-updated file to a specified location in the external storage space after acquiring the to-be-updated file in the system file. The newly added file is the original file that does not exist in the backup system.
当更新指令为填充指令时,智能终端可以直接对外接存储空间的指定位置的文档进行填充。该填充可以包括使用预设符号填对该充备份系统中指定位置的系统文件进行填充。该填充指令用于对已经不需要的文件内容进行覆盖,使其从有效的旧代码转变为无效字符串。When the update instruction is a filling instruction, the smart terminal can directly fill the document in the specified location of the external storage space. The padding may include padding a system file at a specified location in the padding backup system with a preset symbol padding. The padding directive is used to overwrite the content of a file that is no longer needed, turning it from valid old code to invalid strings.
当更新指令为补丁指令时,智能终端可以将升级文件中的待更新文件写入到备份系统的指定文件中。或者,智能终端还可以在读取主存储空间中对应位置内容到缓存后,将该主存储空间中对应位置内容与升级文件中的待更新文件进行补丁(patch)操作,并将合成的新内容写入到外接存储空间的指定位置。其中,patch操作为Linux中的patch命令。使用补丁指令更新后的文件其位置和文件名均不会发生变化。When the update instruction is a patch instruction, the intelligent terminal can write the to-be-updated file in the upgrade file into a specified file in the backup system. Alternatively, after reading the content of the corresponding location in the main storage space to the cache, the intelligent terminal may perform a patch operation on the content of the corresponding location in the main storage space and the to-be-updated file in the upgrade file, and synthesize the new content. Write to the specified location in the external storage space. Among them, the patch operation is the patch command in Linux. The location and filename of the file updated with the patch instruction will not change.
可选地,该备份系统的更新过程还可以包括步骤3。该步骤3用于对已经完成更新的备份系统进行校验,确定该备份系统更新是否成功。该备份系统的当前哈希值的验证,可以更加有效的确定备份系统是否更新成功,从而有效避免在备份系统没有更新成功时被加载。当包括步骤3时,该升级文件中还可以包括目标哈希值。Optionally, the update process of the backup system may further include step 3. Step 3 is used for verifying the updated backup system to determine whether the update of the backup system is successful. The verification of the current hash value of the backup system can more effectively determine whether the backup system is successfully updated, thereby effectively avoiding being loaded when the backup system is not successfully updated. When step 3 is included, the upgrade file may also include the target hash value.
步骤3、智能终端计算更新后的备份系统的系统文件的当前哈希值。智能终端可以在升级文件中的目标哈希值和当前哈希值匹配时,确定备份系统的系统文件是否更新成功。Step 3: The intelligent terminal calculates the current hash value of the updated system file of the backup system. The intelligent terminal can determine whether the system file of the backup system is successfully updated when the target hash value in the upgrade file matches the current hash value.
该步骤的执行可以如图8所示。当智能终端的系统升级进程完成备份系统的系统文件的更新时,智能终端可以执行校验操作。智能终端可以计算外接存储空间的目标哈希值。智能终端可以通过判断当前哈希值与目标哈希值是否匹配,确定后续执行步骤。The execution of this step may be as shown in FIG. 8 . When the system upgrade process of the intelligent terminal completes the update of the system files of the backup system, the intelligent terminal may perform a verification operation. The smart terminal can calculate the target hash value of the external storage space. The intelligent terminal can determine the subsequent execution steps by judging whether the current hash value matches the target hash value.
可选地,如图9所示,主存储空间中可以包括多个分区。这些分区可以分别为加载引导程序分区(bootloader)、系统引导文件分区(boot)、系统分区、数据分区(data)等。其中,系统分区中可以包括System、Vendor、Product、System_ext、odm等系统文件。其中,不同的分区是指存放不同内容的存储空间。例如,应用程序的apk等安装包可以存放在系统分区。又如,照片、视频、通讯录等用户数据存放在数据分区。如图9所示,外接存储空间的分区与主存储空计件类似。只是外接存储空间仅用于系统升级,因此,该外接存储空间中可以不包括数据分区。如图9所示,外接存储空间中完成更新后的备份系统中的各个分区显示为灰色。此时,主存储空间中使用的仍旧是旧的未更新的系统文件。该备份系统在更新过程中,智能终端可以从主存储空间中获取系统文件,并通过拷贝、补丁等操作添加到外接存储空间中。该过程中,只对外接存储空间中的备份系统进行更新,只对主存储空间进行读取操作,不会占用用户分区,使用户可以正常使用智能终端。Optionally, as shown in FIG. 9 , the main storage space may include multiple partitions. These partitions may be a bootloader partition (bootloader), a system boot file partition (boot), a system partition, a data partition (data), and the like. The system partition may include system files such as System, Vendor, Product, System_ext, and odm. The different partitions refer to storage spaces storing different contents. For example, installation packages such as application apks can be stored in the system partition. For another example, user data such as photos, videos, and contacts are stored in the data partition. As shown in Figure 9, the partition of the external storage space is similar to that of the main storage space. It's just that the external storage space is only used for system upgrade, therefore, the data partition may not be included in the external storage space. As shown in Figure 9, each partition in the updated backup system in the external storage space is grayed out. At this point, the old, unupdated system files are still used in the main storage space. During the update process of the backup system, the intelligent terminal can obtain system files from the main storage space and add them to the external storage space through operations such as copying and patching. In this process, only the backup system in the external storage space is updated, only the main storage space is read, and the user partition is not occupied, so that the user can use the smart terminal normally.
可选地,智能终端可以在完成备份系统的更新后,单独计算每一个分区的当前哈希值并进行验证。该单独分区的当前哈希值的计算可以更好的对分区内数据的更新情况进行检测,可以更好的定位更新错误,提高更新异常的纠正效率。例如,当系统引导文件分区出现异常时,智能终端只需要重新更新该系统引导分区即可,而不用整个升级文件重新更新。其具体过程可以被分为如下步骤:Optionally, the smart terminal may calculate and verify the current hash value of each partition separately after completing the update of the backup system. The calculation of the current hash value of the individual partition can better detect the update situation of the data in the partition, can better locate the update error, and improve the correction efficiency of the update abnormality. For example, when an abnormality occurs in the system boot file partition, the intelligent terminal only needs to re-update the system boot partition, instead of re-updating the entire upgrade file. The specific process can be divided into the following steps:
步骤31、智能终端计算每一分区的当前哈希值。Step 31: The smart terminal calculates the current hash value of each partition.
步骤32、智能终端匹配每一分区的当前哈希值和该分区的目标哈希值,并确定匹配结果。Step 32: The smart terminal matches the current hash value of each partition with the target hash value of the partition, and determines the matching result.
步骤33、当全部分区的匹配结果均为匹配成功时,确定备份系统的系统文件更新成功。Step 33: When the matching results of all partitions are successful, it is determined that the system files of the backup system are updated successfully.
步骤34、当存在至少一个分区的匹配结果为匹配失败时,重新更新该分区。Step 34: When the matching result of at least one partition is that the matching fails, re-update the partition.
可选地,智能终端可以在确定备份系统文件更新成功时,将升级变量设置为第一指标。其中,该升级变量可以为该引导程序中的一个全局变量。该第一指标可以为active。该第一指标用于指示该备份系统的系统文件更新成功。当该升级变量为设置为第一指标后,当该智能终端重启时,引导程序将加载备份系统。Optionally, the smart terminal may set the upgrade variable as the first indicator when determining that the backup system file is successfully updated. The upgrade variable may be a global variable in the bootstrap program. The first indicator can be active. The first indicator is used to indicate that the system file of the backup system is successfully updated. After the upgrade variable is set as the first indicator, when the intelligent terminal is restarted, the bootstrap program will load the backup system.
可选地,智能终端可以在确定备份系统的系统文件更新失败时,将升级变量设置为第二指标。该第二指标可以为fail。该第二指标用于指示该次系统升级失败。当该升级变量为第二指标时,该次智能终端的升级结束。智能终端将等待下次获取到服务器发送的升级指令时,再次执行升级操作。Optionally, the smart terminal may set the upgrade variable as the second indicator when it is determined that the system file update of the backup system fails. The second indicator can be fail. The second indicator is used to indicate that the current system upgrade fails. When the upgrade variable is the second indicator, the upgrade of the intelligent terminal is ended. The smart terminal will wait for the next time it obtains the upgrade instruction sent by the server, and execute the upgrade operation again.
S204、当确定备份系统的系统文件更新成功时,将外接存储空间中的备份系统拷贝到智能终端的主存储空间中。S204. When it is determined that the system files of the backup system are successfully updated, copy the backup system in the external storage space to the main storage space of the intelligent terminal.
本实施例中,当智能终端确定备份系统的系统文件更新成功时,智能终端可以将该备份系统拷贝到主存储空间中。智能终端可以在完成拷贝后重启并运行该拷贝后的系统,从而实现该智能终端的系统的升级。In this embodiment, when the intelligent terminal determines that the system file of the backup system is successfully updated, the intelligent terminal may copy the backup system to the main storage space. The intelligent terminal can restart and run the copied system after the copy is completed, so as to realize the system upgrade of the intelligent terminal.
可选地,为了确保拷贝到主存储空间中的备份系统可以正常运行,在拷贝该备份系统之前,智能终端可以先试运行该备份系统,提高系统升级的安全性。Optionally, in order to ensure that the backup system copied to the main storage space can run normally, before copying the backup system, the intelligent terminal may first try to run the backup system to improve the security of system upgrade.
该具体步骤可以包括:The specific steps may include:
步骤1、智能终端可以在确定备份系统的系统文件更新成功后,提醒用户重启智能终端。智能终端可以响应于用户的重启指令,执行重启操作。或者,智能终端还可以根据用户的使用习惯,在用户使用手机频率最低的时段重启智能终端。当智能终端被重启后,智能终端可以加载并运行外接存储空间中更新后的备份系统。Step 1. After determining that the system files of the backup system are successfully updated, the smart terminal may remind the user to restart the smart terminal. The smart terminal may perform a restart operation in response to the user's restart instruction. Alternatively, the smart terminal can also restart the smart terminal according to the user's usage habits during the period when the frequency of the user using the mobile phone is the lowest. When the smart terminal is restarted, the smart terminal can load and run the updated backup system in the external storage space.
可选地,当确定备份系统的系统文件更新成功时,智能终端可以将升级变量设置为第一指标。当智能终端重启后,引导程序可以在加载系统文件前读取该升级变量。当智能终端确定该升级变量为第一指标时,智能终端可以初始化外接存储空间,并加载该外接存储空间中的备份系统。当智能终端成功加载并运行该备份系统后,该智能终端可以运行预设脚本。该预设脚本用于判断该智能终端的系统是否可以正常运行。当该预设脚本运行成功时,智能终端可以确定该备份系统运行正常。Optionally, when it is determined that the system file of the backup system is successfully updated, the intelligent terminal may set the upgrade variable as the first indicator. When the smart terminal restarts, the bootloader can read the upgrade variable before loading system files. When the intelligent terminal determines that the upgrade variable is the first index, the intelligent terminal may initialize the external storage space and load the backup system in the external storage space. After the intelligent terminal successfully loads and runs the backup system, the intelligent terminal can run the preset script. The preset script is used to judge whether the system of the intelligent terminal can run normally. When the preset script runs successfully, the intelligent terminal can determine that the backup system runs normally.
可选地,当该预设脚本运行失败时,该智能终端可以将该升级变量设置为第二指标。该第二指标可以为fail。该第二指标用于指示该次系统升级失败。当该升级变量为第二指标时,该次智能终端的升级结束。智能终端将等待下次获取到服务器发送的升级指令时,再次执行升级操作。Optionally, when the preset script fails to run, the intelligent terminal may set the upgrade variable as the second indicator. The second indicator can be fail. The second indicator is used to indicate that the current system upgrade fails. When the upgrade variable is the second indicator, the upgrade of the intelligent terminal is ended. The smart terminal will wait for the next time it obtains the upgrade instruction sent by the server, and execute the upgrade operation again.
步骤2、智能终端可以在确定备份系统运行正常时,拷贝备份系统到智能终端的主存储空间中。如图10所示,其中的主存储空间中加载引导程序分区(bootloader)、系统引导文件分区(boot)和系统分区的内容为备份系统拷贝的内容。该拷贝的备份系统将覆盖该主存储空间中原有的系统文件。Step 2. When it is determined that the backup system is running normally, the smart terminal can copy the backup system to the main storage space of the smart terminal. As shown in FIG. 10 , the contents of the bootloader partition (bootloader), the system boot file partition (boot) and the system partition in the main storage space are the contents copied by the backup system. The copied backup system will overwrite the original system files in the primary storage space.
可选地,当确定预设脚本运行成功时,智能终端可以设置升级变量为第三指标。该第三指标用于指示该备份系统完成到主存储空间的拷贝。Optionally, when it is determined that the preset script runs successfully, the intelligent terminal may set the upgrade variable as the third indicator. The third indicator is used to instruct the backup system to complete the copy to the main storage space.
步骤3、智能终端可以在确定备份系统的系统文件更新成功后,提醒用户重启智能终端。智能终端可以响应于用户的重启指令,执行重启操作。或者,智能终端还可以根据用户的使用习惯,在用户使用手机频率最低的时段重启智能终端。当智能终端被重启后,智能终端可以加载并运行拷贝到主存储空间中的新系统。Step 3, the smart terminal may remind the user to restart the smart terminal after determining that the system files of the backup system are successfully updated. The smart terminal may perform a restart operation in response to the user's restart instruction. Alternatively, the smart terminal can also restart the smart terminal according to the user's usage habits during the period when the frequency of the user using the mobile phone is the lowest. When the smart terminal is restarted, the smart terminal can load and run the new system copied to the main storage space.
可选地,当智能终端重启后,引导程序可以在加载系统文件前读取该升级变量。当智能终端确定该升级变量为第三指标时,智能终端可以加载该主存储空间中的新系统。Optionally, when the smart terminal is restarted, the bootstrap program can read the upgrade variable before loading the system file. When the intelligent terminal determines that the upgrade variable is the third index, the intelligent terminal can load the new system in the main storage space.
可选地,等到该智能终端完成开机后,智能终端可以释放外接存储空间中的空间占用。如图10所示,该外接存储空间被释放。Optionally, after the intelligent terminal is turned on, the intelligent terminal can release the space occupied in the external storage space. As shown in Figure 10, the external storage space is released.
可选地,当智能终端因为升级变量为第二指标而结束升级时,智能终端还可以释放外接存储空间。该释放后的外接存储空间将在智能终端下一次接收到升级指令时被使用。Optionally, when the smart terminal ends the upgrade because the upgrade variable is the second indicator, the smart terminal may also release external storage space. The released external storage space will be used when the smart terminal receives an upgrade instruction next time.
可选地,当智能终端因为升级变量为第二指标而结束升级时,智能终端还可以在外接存储空间被释放后,重新拷贝主存储空间中系统文件的备份,得到备份系统。智能终端还可以在完成备份系统的拷贝后,向服务器请求升级文件,并重新执行升级操作。Optionally, when the smart terminal finishes the upgrade because the upgrade variable is the second indicator, the smart terminal can also re-copy the backup of the system files in the main storage space after the external storage space is released to obtain the backup system. The intelligent terminal can also request an upgrade file from the server after completing the copy of the backup system, and perform the upgrade operation again.
本申请提供的智能终端的系统升级方法中,智能终端可以在存在外接存储空间时获取服务器发送的系统升级文件。该系统升级文件中包括校验文件和升级文件。智能终端可以使用该校验文件与智能终端中对应的信息进行校验,确定校验结果。当校验结果为校验通过时,智能终端可以使用升级文件对外接存储空间中的备份系统的系统文件进行更新。当确定备份系统的系统文件更新成功时,智能终端可以将外接存储空间中的备份系统拷贝到智能终端的主存储空间中,从而实现系统升级。本申请中,通过使用外接存储空间对备份系统进行升级,实现了在更新期间后台执行更新操作,且不会对主存储空间中原系统的执行产生影响的效果,使用户在系统更新期间可以正常使用智能终端,提高在系统更新期间智能终端的使用效率。同时,本申请在备份系统进行系统升级的方式可以使系统在更新失败时,可以正常运行原系统,避免智能终端因为系统更新失败导致无法使用的情况出现。此外,本申请的系统更新在外接存储空间中执行,对智能终端的主存储空间需求小,即便是用户空间不足的小容量智能终端也可以正常完成系统升级,极大提升了用户体验。In the system upgrade method for an intelligent terminal provided by the present application, the intelligent terminal can obtain the system upgrade file sent by the server when there is an external storage space. The system upgrade file includes a check file and an upgrade file. The intelligent terminal can use the verification file to verify the corresponding information in the intelligent terminal to determine the verification result. When the verification result is that the verification passes, the smart terminal can use the upgrade file to update the system file of the backup system in the external storage space. When it is determined that the system files of the backup system are successfully updated, the intelligent terminal can copy the backup system in the external storage space to the main storage space of the intelligent terminal, thereby realizing system upgrade. In the present application, by using the external storage space to upgrade the backup system, the update operation is performed in the background during the update period without affecting the execution of the original system in the main storage space, so that the user can use the system normally during the system update period. Intelligent terminal, improve the use efficiency of intelligent terminal during system update. At the same time, the method of the present application for system upgrade in the backup system can enable the system to run the original system normally when the system update fails, and avoid the situation that the intelligent terminal cannot be used due to the failure of the system update. In addition, the system update of the present application is performed in an external storage space, which requires little main storage space of the smart terminal. Even a small-capacity smart terminal with insufficient user space can normally complete the system upgrade, which greatly improves the user experience.
本申请还提供一种智能终端,智能终端包括存储器、处理器,存储器上存储有系统升级程序,系统升级程序被处理器执行时实现上述任一实施例中的智能终端的系统升级方法的步骤。The present application also provides an intelligent terminal. The intelligent terminal includes a memory and a processor. The memory stores a system upgrade program. When the system upgrade program is executed by the processor, the steps of the system upgrade method for an intelligent terminal in any of the above embodiments are implemented.
本申请还提供一种计算机可读存储介质,计算机可读存储介质上存储有系统升级程序,系统升级程序被处理器执行时实现上述任一实施例中的智能终端的系统升级方法的步骤。The present application further provides a computer-readable storage medium, where a system upgrade program is stored on the computer-readable storage medium, and when the system upgrade program is executed by a processor, the steps of the system upgrade method for an intelligent terminal in any of the foregoing embodiments are implemented.
在本申请提供的智能终端和计算机可读存储介质的实施例中,可以包含任一上述智能终端的系统升级方法实施例的全部技术特征,说明书拓展和解释内容与上述方法的各实施例基本相同,在此不再做赘述。The embodiments of the intelligent terminal and the computer-readable storage medium provided in this application may include all the technical features of any of the above-mentioned embodiments of the system upgrading method for an intelligent terminal, and the expansion and explanation contents of the description are basically the same as the embodiments of the above-mentioned methods. , and will not be repeated here.
本申请实施例还提供一种计算机程序产品,计算机程序产品包括计算机程序代码,当计算机程序代码在计算机上运行时,使得计算机执行如上各种可能的实施方式中的方法。Embodiments of the present application also provide a computer program product, where the computer program product includes computer program code, when the computer program code runs on a computer, the computer can execute the methods in the various possible implementation manners above.
本申请实施例还提供一种芯片,包括存储器和处理器,存储器用于存储计算机程序,处理器用于从存储器中调用并运行计算机程序,使得安装有芯片的设备执行如上各种可能的实施方式中的方法。An embodiment of the present application further provides a chip, including a memory and a processor, where the memory is used to store a computer program, and the processor is used to call and run the computer program from the memory, so that the device with the chip installed executes the various possible implementation manners described above. Methods.
可以理解,上述场景仅是作为示例,并不构成对于本申请实施例提供的技术方案的应用场景的限定,本申请的技术方案还可应用于其他场景。例如,本领域普通技术人员可知,随着系统架构的演变和新业务场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。It can be understood that the above scenario is only an example, and does not constitute a limitation on the application scenarios of the technical solutions provided in the embodiments of the present application, and the technical solutions of the present application can also be applied to other scenarios. For example, those of ordinary skill in the art know that with the evolution of the system architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。The above-mentioned serial numbers of the embodiments of the present application are only for description, and do not represent the advantages or disadvantages of the embodiments.
本申请实施例方法中的步骤可以根据实际需要进行顺序调整、合并和删减。The steps in the method of the embodiment of the present application may be adjusted, combined and deleted in sequence according to actual needs.
本申请实施例设备中的单元可以根据实际需要进行合并、划分和删减。Units in the device of this embodiment of the present application may be combined, divided, and deleted according to actual needs.
在本申请中,对于相同或相似的术语概念、技术方案和/或应用场景描述,一般只在第一次出现时进行详细描述,后面再重复出现时,为了简洁,一般未再重复阐述,在理解本申请技术方案等内容时,对于在后未详细描述的相同或相似的术语概念、技术方案和/或应用场景描述等,可以参考其之前的相关详细描述。In this application, descriptions of the same or similar term concepts, technical solutions and/or application scenarios are generally only described in detail when they appear for the first time. When understanding the technical solutions and other contents of the present application, for the same or similar term concepts, technical solutions and/or application scenario descriptions, etc. that are not described in detail later, reference may be made to the related detailed descriptions before them.
在本申请中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In this application, the description of each embodiment has its own emphasis. For parts that are not described or described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
本申请技术方案的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本申请记载的范围。The technical features of the technical solutions of the present application can be combined arbitrarily. In order to simplify the description, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction in the combination of these technical features, all It should be considered as the scope described in this application.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在如上的一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台智能终端(可以是手机,计算机,服务器,被控终端,或者网络设备等)执行本申请每个实施例的方法。From the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is better implementation. Based on such understanding, the technical solutions of the present application can be embodied in the form of software products in essence or the parts that make contributions to the prior art, and the computer software products are stored in the above storage medium (such as ROM/RAM, magnetic CD, CD), including several instructions to make an intelligent terminal (which may be a mobile phone, a computer, a server, a controlled terminal, or a network device, etc.) to execute the method of each embodiment of the present application.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行计算机程序指令时,全部或部分地产生按照本申请实施例的流程或功能。计算机可以是通用计算机、专用计算机、计算机网络,或者其他可编程装置。计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线)或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。可用介质可以是磁性介质,(例如,软盘、存储盘、磁带)、光介质(例如,DVD),或者半导体介质(例如固态存储盘Solid State Disk(SSD))等。In the above-mentioned embodiments, it may be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented in software, it can be implemented in whole or in part in the form of a computer program product. A computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the procedures or functions according to the embodiments of the present application are generated in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable device. Computer instructions may be stored on or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server, or data center over a wire (e.g. coaxial cable, optical fiber, digital subscriber line) or wireless (eg infrared, wireless, microwave, etc.) means to another website site, computer, server or data center. A computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, a data center, or the like that includes an integration of one or more available media. Useful media may be magnetic media (eg, floppy disks, storage disks, magnetic tapes), optical media (eg, DVD), or semiconductor media (eg, Solid State Disk (SSD)), among others.
以上仅为本申请的优选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。The above are only the preferred embodiments of the present application, and are not intended to limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made by using the contents of the description and drawings of the present application, or directly or indirectly applied in other related technical fields , are similarly included within the scope of patent protection of this application.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202210569705.XACN114880003A (en) | 2022-05-24 | 2022-05-24 | System upgrade method of intelligent terminal, intelligent terminal and storage medium |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202210569705.XACN114880003A (en) | 2022-05-24 | 2022-05-24 | System upgrade method of intelligent terminal, intelligent terminal and storage medium |
| Publication Number | Publication Date |
|---|---|
| CN114880003Atrue CN114880003A (en) | 2022-08-09 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202210569705.XAPendingCN114880003A (en) | 2022-05-24 | 2022-05-24 | System upgrade method of intelligent terminal, intelligent terminal and storage medium |
| Country | Link |
|---|---|
| CN (1) | CN114880003A (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116506449A (en)* | 2023-06-26 | 2023-07-28 | 新亿成科技(江苏)有限公司 | Communication network node information synchronization method, system, equipment and storage medium |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116506449A (en)* | 2023-06-26 | 2023-07-28 | 新亿成科技(江苏)有限公司 | Communication network node information synchronization method, system, equipment and storage medium |
| CN116506449B (en)* | 2023-06-26 | 2023-09-26 | 新亿成科技(江苏)有限公司 | Communication network node information synchronization method, system, equipment and storage medium |
| Publication | Publication Date | Title |
|---|---|---|
| CN107276789B (en) | Log uploading method and device and computer readable storage medium | |
| US20120102477A1 (en) | Firmware update method and apparatus for a mobile device | |
| CN110147237B (en) | A method and device for removing redundant resources | |
| CN107273160A (en) | A kind of method and device of edition upgrading | |
| US9367403B2 (en) | Terminal and application restoring method | |
| US12099700B2 (en) | Method for browsing application folder and electronic device | |
| CN107766747B (en) | Method for verifying integrity of application program installation package, mobile terminal and server | |
| CN106293507A (en) | There is electronic equipment and the method for operation electronic equipment of external memory storage | |
| CN108595113A (en) | A kind of method and terminal of subregion adjustment | |
| CN107861730B (en) | Application processing method and mobile terminal | |
| CN108090345B (en) | Linux system external command execution method and device | |
| WO2014194865A1 (en) | Firmware upgrade method and apparatus, and communication device | |
| CN102982052A (en) | Method and apparatus for splitting media files | |
| CN115328563B (en) | System startup method and electronic device | |
| WO2021098360A1 (en) | Application control method, electronic device, and server | |
| CN108733797B (en) | File processing method and related device | |
| US20170078269A1 (en) | Method for managing application and electronic device supporting the same | |
| WO2022042233A1 (en) | Application interface migration system, method, and related device | |
| CN107015828A (en) | Audio software upgrade method, application program upgrade method, device and system | |
| CN112463199A (en) | System upgrading method and terminal | |
| CN111522575B (en) | Application program upgrading method and electronic equipment | |
| CN107844318B (en) | An operating system upgrade method, mobile terminal and server | |
| CN109408080A (en) | A kind of method and terminal of application upgrade | |
| CN109828770B (en) | A software upgrade method, terminal device and server | |
| US9928134B2 (en) | Method and apparatus for repairing dynamic link library file |
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination |