WO2020001112A1 - 一种支持多类型设备的平台的应用方法、移动终端 - Google Patents

一种支持多类型设备的平台的应用方法、移动终端 Download PDF

Info

Publication number
WO2020001112A1
WO2020001112A1 PCT/CN2019/081045 CN2019081045W WO2020001112A1 WO 2020001112 A1 WO2020001112 A1 WO 2020001112A1 CN 2019081045 W CN2019081045 W CN 2019081045W WO 2020001112 A1 WO2020001112 A1 WO 2020001112A1
Authority
WO
WIPO (PCT)
Prior art keywords
image file
file
platform
device information
operating system
Prior art date
Application number
PCT/CN2019/081045
Other languages
English (en)
French (fr)
Inventor
赖哲锋
刘绍海
Original Assignee
百富计算机技术(深圳)有限公司
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 百富计算机技术(深圳)有限公司 filed Critical 百富计算机技术(深圳)有限公司
Publication of WO2020001112A1 publication Critical patent/WO2020001112A1/zh

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4406Loading of operating system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation

Definitions

  • the present application belongs to the technical field of operating systems, and particularly relates to an application method of a platform supporting multiple types of devices, a mobile terminal, and a computer-readable storage medium.
  • the Android platform is the name of a free and open source operating system based on the Linux platform.
  • the platform consists of an operating system, middleware, user interface, and application software.
  • the Android operating system is mainly used in mobile devices, such as smartphones and tablets.
  • Android system packages usually correspond to hardware devices one by one, that is, based on different types of devices, different Android system packages need to be set.
  • this setting method causes developers to modify the Android system package bugs and add commonly used functions, they need to modify each type of device corresponding to the Android system package, and later for different types of models, generate Different Android system packages lead to too many versions released later, which is not easy to manage.
  • the embodiments of the present application provide a method for applying a platform supporting multiple types of devices, a mobile terminal, and a computer-readable storage medium, so as to solve the cumbersome and low-efficiency modification of the current android system package, and the android system package is not Convenient management issues.
  • a first aspect of the embodiments of the present application provides a method for applying a platform supporting multiple types of devices, including:
  • the platform-based device loads the image file of the platform, and the image file of the platform is a file that is compiled based on the platform's code warehouse and supports multiple types of devices;
  • a second aspect of the embodiments of the present application provides a mobile terminal based on a platform supporting multiple types of devices.
  • the mobile terminal includes:
  • a loading module configured to load an image file of the platform, and the image file of the platform is a file supporting multiple types of devices obtained by compiling based on a code warehouse of the platform;
  • An initialization module configured to obtain device information of the mobile terminal when the operating system corresponding to the image file in the mobile terminal is initialized, and execute an initialization script file corresponding to the device information in the image file;
  • An operating module is configured to perform an operation corresponding to the device information based on the device information of the device when an operating system corresponding to the image file in the mobile terminal is running.
  • a third aspect of the embodiments of the present application provides a mobile terminal including a memory, a processor, and a computer program stored in the memory and executable on the processor.
  • the processor executes the computer program, Implement the steps of the method provided by the first aspect of the embodiments of the present application.
  • a fourth aspect of the embodiments of the present application provides a computer-readable storage medium.
  • the computer-readable storage medium stores a computer program, and the computer program is implemented by one or more processors to implement the first embodiment of the present application. Steps of the method provided by aspects.
  • a fifth aspect of the embodiments of the present application provides a computer program product, where the computer program product includes a computer program, and the computer program is implemented by one or more processors to implement the described in the first aspect of the embodiments of the present application. Method steps.
  • the embodiment of the present application loads a platform image file through a platform-based device.
  • the platform image file is a file that is compiled based on the platform's code warehouse and supports multiple types of devices.
  • the image file in the device corresponds to When the operating system of the device is initialized, the device information of the device is acquired, and an initialization script file corresponding to the device information in the image file is executed.
  • the operating system corresponding to the image file in the device is running, based on the The device information of the device performs an operation corresponding to the device information.
  • the device information can determine the type of the device.
  • the operating system corresponding to the image file is initialized based on the device information of the device, and an initialization script corresponding to the device information of the device is executed.
  • the file after initialization, is also run based on the device information of the device, and performs operations corresponding to the device information.
  • the image file of the platform can be set to a file common to multiple types of devices and
  • the sum of the unique files of each type of device the platform's image file can be loaded into multiple types of devices based on the platform, and when initialized and run, it performs the same operations based on the device information of the current device.
  • the operations related to the device information can be described.
  • FIG. 1 is a schematic flowchart of an implementation method of an application method for a platform supporting multiple types of devices according to an embodiment of the present application
  • FIG. 2 is a schematic flowchart of an implementation method of another application method of a platform supporting multiple types of devices according to an embodiment of the present application;
  • FIG. 3 is a schematic block diagram of a mobile terminal according to an embodiment of the present application.
  • FIG. 4 is a schematic block diagram of another mobile terminal according to an embodiment of the present application.
  • the term “if” can be construed as “when” or “once” or “in response to a determination” or “in response to a detection” depending on the context .
  • the phrase “if determined” or “if [the described condition or event] is detected” may be interpreted, depending on the context, to mean “once determined” or “in response to the determination” or “once [the condition or event described ] “Or” In response to [Description of condition or event] detected ".
  • FIG. 1 is a schematic flowchart of an application method of a platform supporting multiple types of devices according to an embodiment of the present application. As shown in the figure, the method may include the following steps:
  • step S101 a device based on the platform loads an image file of the platform, and the image file of the platform is a file that is compiled based on a code warehouse of the platform and supports multiple types of devices.
  • the platform may be the android platform.
  • the operating system of the corresponding device is the android system.
  • the image file generated by the developer during development includes the PCI version image file, Debug Version image file, Release version image file.
  • the image file of the platform is a file supporting multiple types of devices obtained by compiling based on a code warehouse of the platform.
  • this still cannot solve the problem of how different types of devices can adapt to image files that support multiple types of devices.
  • step S102 when the operating system corresponding to the image file in the device is initialized, device information of the device is acquired, and an initialization script file corresponding to the device information in the image file is executed.
  • the operating system corresponding to the image file in the device when the operating system corresponding to the image file in the device is initialized, it means that after the image file compiled and generated by the developer based on the android platform is loaded, the device needs to be initialized.
  • the image file includes not only files that are common to multiple types of devices, but also files that are unique to different types of devices. Therefore, in order to ensure the normal operation of the device in the future, it is necessary to obtain the device of the device during initialization.
  • the device information of the device can determine the type of the device, and execute an initialization script file corresponding to the device information in the image file.
  • the script file unique to the device information In addition to executing the script file of the common part, the script file unique to the device information must also be executed, that is, the file corresponding to each device information is two parts: a common part and a unique part.
  • Step S103 when the operating system corresponding to the image file in the device is running, based on the device information of the device, an operation corresponding to the device information is performed.
  • the device information of the device still needs to be obtained to perform related operations corresponding to the device information.
  • the embodiment of the present application describes the embodiment of the present application from the side of the device on which the image file based on supporting multiple types of devices is loaded. It should be noted that although the embodiment of the present application describes the embodiment of the present application from the side of the device loaded with the image file based on supporting multiple types of devices, the process of obtaining the image file in the embodiment of the present application is to develop Based on the code warehouse of the platform, the personnel passes the version information through condition variables, and compiles the three versions of the obtained files.
  • the three versions of the file contain information about supported devices and can be loaded into any supported type of device. In this way, a unified code warehouse and a unified image file are implemented. Undoubtedly, for developers, if they need to fix a bug, they need to modify a 3 version image file. If they add common functions, they can also modify a 3 version image file, which improves the developer ’s Work efficiency, and also facilitate the management of documents.
  • FIG. 2 is a schematic flowchart of another application method of a platform supporting multiple types of devices according to an embodiment of the present application, which may include the following steps:
  • a device based on the platform loads a version image file of the platform.
  • the image file is a code warehouse based on the platform, and passes version information through condition variables to compile a file that supports multiple types of devices.
  • step S101 This step is consistent with the content of step S101. For details, refer to the description of step S101, and details are not described herein again.
  • the image file obtained by compilation includes three versions. However, there is usually a version of the image file in the device. In the case where there is already a version of the image file in the device, if the image file is loaded again, the reloaded image file will overwrite the image file previously loaded by the device.
  • Step S202 When the operating system corresponding to the image file in the device is initialized, the first-type device information of the device is obtained from the configuration file of the device or the Secure Processor through the u-boot file in the image file.
  • FIG. 1 describes how developers compile and obtain different versions of image files. This embodiment of the present application focuses on the side of the device on which the image files are loaded, and describes how the image files can be based on the image files and different types. , Initialize the operating system corresponding to the image file.
  • the type information of the device may also be obtained from a configuration file, and may also be obtained from a Secure Processor. However, more than the type information obtained from the configuration file or the Secure Processor includes other information.
  • Device information We name the device information obtained from the configuration file or the Secure Processor as the first type of device information, and the first type of device information is used to indicate that the device information is obtained from the configuration file or the Secure Processor.
  • the first type of device information includes device type information. After the type information of the device is obtained, the device tree information of the device can be continuously obtained.
  • Step S203 Obtain a device tree file of the device based on the first-type device information of the device through the u-boot file in the image file, and the device tree file is all types supported by the image file. Collection of equipment.
  • the type information of the device When the type information of the device is obtained from the Secure Processor, it indicates that the configuration file is stored on the Secure Processor side.
  • the communication interface with the Secure Processor The processor sends a request to read the type information.
  • the device ID, the motherboard, and the interface board version in the type information can be used as keywords, or the name of the device tree can be directly used as the key when the name of the device tree of the device is known.
  • Word Secure The processor searches for a device tree file matching the keyword from the compressed package of the configuration file. If the device tree file is found, the device tree file can be decompressed and stored in the memory.
  • the type information of the device is determined through u-boot.
  • the u-boot file can obtain a device tree file (DTB) of the device according to the type information of the device, and the device tree file is all types supported by the image file.
  • the device tree file also stores the device information.
  • the second type of device information is used to indicate the use of the device tree file.
  • Device information obtained in By using the first type of device information and / or the second type of device information, it is possible to execute files or operations related to the device for different types of devices during the initialization and running phases of the operating system.
  • a configuration file of the device is downloaded to the device, and the configuration file can distinguish between different types of devices or devices with different hardware versions.
  • Step S204 Load the kernel of the operating system, and pass the device tree file of the device and the first type of device information to the kernel of the operating system, so that the kernel of the operating system is loaded based on the device tree file Hardware resources corresponding to the device.
  • the device tree file and the first type of device information need to be passed to a kernel of the operating system, for example, kernel.
  • the kernel of the operating system can be loaded, and the device tree file of the device and the first type of device information are passed to the kernel of the operating system.
  • the kernel of the operating system can be loaded based on the device tree file.
  • a hardware resource corresponding to the device for example, a hardware driver.
  • Step S205 The kernel of the operating system obtains the second-type device information from the device tree file, and passes the first-type device information and the second-type device information to the device as the device information of the device.
  • the property subsystem in the operating system of the device when the operating system of the device is running, the device information of the device is obtained from the property subsystem, and the operation of the device corresponding to the device information is performed.
  • the second-type device information it is also necessary to obtain the second-type device information from the device tree file, and then pass the second-type device information and the first-type device as the device information of the device to the operating system of the device.
  • Property is an important concept in the Android system. In the Android system, it is mainly used for system configuration and simple information sharing between different services. It also contains device information, such as device name, Bluetooth name, compilation information, network dns address, And some other device information. In this way, when the operating system is running, the device information can be obtained from the property subsystem, and operations of the device corresponding to the device information are performed.
  • step S206 when the operating system corresponding to the image file in the device is running, the device information is obtained from the property subsystem, and the operation of the device corresponding to the device information is performed.
  • Step S207 After receiving the instruction to reload the image file, receive the image file to be reloaded, and load the image file.
  • the image file to be reloaded is based on the original image file based on the platform's code warehouse. Modification obtained.
  • FIG. 3 is a schematic block diagram of a mobile terminal according to an embodiment of the present application. For ease of description, only parts related to the embodiment of the present application are shown.
  • the mobile terminal 3 may be a software unit, a hardware unit, or a combination of software and hardware in a mobile terminal such as a mobile phone, a tablet computer, and a notebook, or may be integrated as an independent pendant to the mobile terminal such as a mobile phone, tablet, notebook in.
  • the mobile terminal 3 is based on a platform supporting multiple types of devices, and the mobile terminal 3 includes:
  • a loading module 31 configured to load an image file of the platform, where the image file of the platform is a file that is compiled based on the platform's code warehouse and supports multiple types of devices;
  • An initialization module 32 is configured to obtain device information of the mobile terminal when the operating system corresponding to the image file in the mobile terminal is initialized, and execute an initialization script file corresponding to the device information in the image file;
  • An operating module 33 is configured to perform an operation corresponding to the device information based on the device information of the device when an operating system corresponding to the image file in the mobile terminal is running.
  • the loading module 31 is further configured to:
  • a device based on the platform loads a version image file of the platform, and the image file is a file based on the platform's code warehouse, which passes version information through condition variables, and compiles a file that supports multiple types of devices.
  • the platform is an android platform;
  • the operating system is an android system;
  • the condition variable is located in a boot0 file, a u-boot file, and an Android file of the image file;
  • the image file includes: a PCI version image file, a Debug version image file, and a Release version image file.
  • the initialization module 32 includes:
  • the device type obtaining unit 321 is configured to obtain the first-type device information of the device from a configuration file of the device or a Secure Processor through a u-boot file in the image file.
  • the initialization module 32 further includes:
  • the initialization module 32 further includes:
  • a first information transfer unit 323 is configured to load a kernel of the operating system, and transfer first-type device information of the device and the device tree file to a kernel of the operating system, so as to facilitate the operation of the operating system.
  • the kernel loads hardware resources corresponding to the device based on the first type of device information and the device tree file;
  • a second information transfer unit 324 configured to obtain a second type of device information from the device tree file by the kernel of the operating system, and use the first type of device information and the second type of device information as the device
  • the device information is passed to the property subsystem in the operating system of the device, so that when the operating system of the device is running, the device information of the device is obtained from the property subsystem, and The operation of the device corresponding to the device information.
  • the mobile terminal 3 further includes:
  • a reloading module 34 is configured to receive an image file to be reloaded after receiving an instruction to reload the image file, and load the image file.
  • the image file to be reloaded is an original image based on the platform code warehouse. Modified based on the files obtained.
  • FIG. 4 is a schematic block diagram of a mobile terminal according to another embodiment of the present application.
  • the mobile terminal 4 of this embodiment includes: one or more processors 40, a memory 41, and a computer program 42 stored in the memory 41 and executable on the processor 40.
  • the processor 40 executes the computer program 42, the steps in the application method embodiments of the foregoing multiple-device-supported platforms are implemented, for example, steps S101 to S103 shown in FIG.
  • the processor 40 executes the computer program 42, the functions of each module / unit in the above-mentioned embodiment of the mobile terminal, such as the functions of modules 31 to 33 shown in FIG. 3, are implemented.
  • the computer program 42 may be divided into one or more modules / units, and the one or more modules / units are stored in the memory 41 and executed by the processor 40 to complete This application.
  • the one or more modules / units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe an execution process of the computer program 42 in the mobile terminal 4.
  • the computer program 42 may be divided into a loading module, an initialization module, and a running module.
  • a loading module configured to load an image file of the platform, and the image file of the platform is a file supporting multiple types of devices obtained by compiling based on a code warehouse of the platform;
  • An initialization module configured to obtain device information of the mobile terminal when the operating system corresponding to the image file in the mobile terminal is initialized, and execute an initialization script file corresponding to the device information in the image file;
  • An operating module is configured to perform an operation corresponding to the device information based on the device information of the device when an operating system corresponding to the image file in the mobile terminal is running.
  • the mobile terminal includes, but is not limited to, a processor 40 and a memory 41.
  • FIG. 4 is only an example of the mobile terminal 4 and does not constitute a limitation on the mobile terminal 4. It may include more or fewer components than shown in the figure, or combine some components, or different Components, for example, the mobile terminal may further include an input device, an output device, a network access device, a bus, and the like.
  • the processor 40 may be a central processing unit (Central Processing Unit (CPU), or other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (Application Specific Integrated Circuits) Specific Integrated Circuit (ASIC), off-the-shelf Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • CPU Central Processing Unit
  • DSP Digital Signal Processor
  • ASIC Application Specific Integrated Circuits
  • FPGA off-the-shelf Programmable Gate Array
  • a general-purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
  • the memory 41 may be an internal storage unit of the mobile terminal 4, such as a hard disk or a memory of the mobile terminal 4.
  • the memory 41 may also be an external storage device of the mobile terminal 4, such as a plug-in hard disk, a smart media card (SMC), and a secure digital (SD) provided on the mobile terminal 4. Flash card Card) and so on.
  • the memory 41 may include both an internal storage unit of the mobile terminal 4 and an external storage device.
  • the memory 41 is configured to store the computer program and other programs and data required by the mobile terminal.
  • the memory 41 may also be used to temporarily store data that has been output or is to be output.
  • the disclosed mobile terminal and method may be implemented in other ways.
  • the mobile terminal embodiments described above are merely schematic.
  • the division of the modules or units is only a logical function division.
  • there may be another division manner, such as multiple units or components. Can be combined or integrated into another system, or some features can be ignored or not implemented.
  • the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, which may be electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the objective of the solution of this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each of the units may exist separately physically, or two or more units may be integrated into one unit.
  • the above integrated unit may be implemented in the form of hardware or in the form of software functional unit.
  • the integrated module / unit When the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the method of the above embodiment, and can also be completed by a computer program instructing related hardware.
  • the computer program can be stored in a computer-readable storage medium.
  • the computer When the program is executed by a processor, the steps of the foregoing method embodiments can be implemented.
  • the computer program includes computer program code, and the computer program code may be in a source code form, an object code form, an executable file, or some intermediate form.
  • the computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a mobile hard disk, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signals, telecommunication signals, and software distribution media.
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • electric carrier signals telecommunication signals
  • software distribution media any entity or device capable of carrying the computer program code
  • a recording medium a U disk, a mobile hard disk, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signals, telecommunication signals, and software distribution media.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

本申请适用于操作系统技术领域,提供了一种支持多类型设备的平台的应用方法、移动终端及计算机可读存储介质,所述方法包括:基于所述平台的设备加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件,在所述设备中的镜像文件对应的操作系统初始化时,获取所述设备的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件,在所述设备中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作,通过本申请可以提高android系统包修改时的效率、便于android系统包的管理。

Description

一种支持多类型设备的平台的应用方法、移动终端 技术领域
本申请属于操作系统技术领域,尤其涉及一种支持多类型设备的平台的应用方法、移动终端及计算机可读存储介质。
背景技术
Android平台是基于Linux平台的自由及开放源代码的操作系统的名称,该平台由操作系统、中间件、用户界面和应用软件组成。目前Android操作系统主要使用于移动设备,如智能手机和平板电脑等。
目前,Android的系统包通常是与硬件设备一一对应的,即基于不同类型的设备,需要设置有不同的Android的系统包。然而,这种设置方式导致开发人员在修改Android系统包中的bug和新增常用功能时,就需要将每个类型的设备对应Android系统包均修改一遍,并且后期针对不同类型的机型,生成不同的Android系统包,导致后期发布的版本太多,不方便管理。
技术问题
有鉴于此,本申请实施例提供了一种支持多类型设备的平台的应用方法、移动终端及计算机可读存储介质,以解决目前对android系统包的修改繁琐、效率低、且android系统包不方便管理的问题。
技术解决方案
本申请实施例的第一方面提供了一种支持多类型设备的平台的应用方法,包括:
基于所述平台的设备加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
在所述设备中的镜像文件对应的操作系统初始化时,获取所述设备的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
在所述设备中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
本申请实施例的第二方面提供了一种移动终端,基于支持多类型设备的平台,所述移动终端包括:
加载模块,用于加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
初始化模块,用于在所述移动终端中的镜像文件对应的操作系统初始化时,获取所述移动终端的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
运行模块,用于在所述移动终端中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
本申请实施例的第三方面提供了一种移动终端,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现本申请实施例第一方面提供的所述方法的步骤。
本申请实施例的第四方面提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被一个或多个处理器执行时实现本申请实施例第一方面提供的所述方法的步骤。
本申请实施例的第五方面提供了一种计算机程序产品,所述计算机程序产品包括计算机程序,所述计算机程序被一个或多个处理器执行时实现本申请实施例第一方面提供的所述方法的步骤。
有益效果
本申请实施例通过基于平台的设备加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件,在所述设备中的镜像文件对应的操作系统初始化时,获取所述设备的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件,在所述设备中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。所述设备信息能够确定设备的类型,在所述设备中,所述镜像文件对应的操作系统初始化时,是基于所述设备的设备信息,执行的是与所述设备的设备信息对应的初始化脚本文件,在初始化后,运行时,也是基于所述设备的设备信息,执行与所述设备信息对应的操作,这样,所述平台的镜像文件就可以设置为:多种类型的设备通用的文件和每个类型的设备独有文件的之和,所述平台的镜像文件就可以加载到基于所述平台的多个类型的设备中,初始化和运行时,就根据当前的设备的设备信息执行与所述设备信息相关的操作即可。在修改通用bug和新增通用功能时,只需要修改一套镜像文件即可,同时由于多类型的设备共有一套镜像文件,也使得方便文件管理。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例提供的一种支持多类型设备的平台的应用方法的实现流程示意图;
图2是本申请实施例提供的另一种支持多类型设备的平台的应用方法的实现流程示意图;
图3是本申请实施例提供的一种移动终端的示意框图;
图4是本申请实施例提供的另一种移动终端的示意框图。
本发明的实施方式
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。
应当理解,当在本说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。
还应当理解,在此本申请说明书中所使用的术语仅仅是出于描述特定实施例的目的而并不意在限制本申请。如在本申请说明书和所附权利要求书中所使用的那样,除非上下文清楚地指明其它情况,否则单数形式的“一”、“一个”及“该”意在包括复数形式。
还应当进一步理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。
如在本说明书和所附权利要求书中所使用的那样,术语“如果”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。类似地,短语“如果确定”或“如果检测到[所描述条件或事件]”可以依据上下文被解释为意指“一旦确定”或“响应于确定”或“一旦检测到[所描述条件或事件]”或“响应于检测到[所描述条件或事件]”。
为了说明本申请所述的技术方案,下面通过具体实施例来进行说明。
图1是本申请实施例提供的一种支持多类型设备的平台的应用方法的实现流程示意图,如图所示该方法可以包括以下步骤:
步骤S101,基于所述平台的设备加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件。
在本申请实施例中,所述平台可以是android平台,同样,对应的设备的操作系统就是android系统,对于android系统而言,开发人员开发时生成的镜像文件包括:PCI版本的镜像文件、Debug版本的镜像文件、Release版本的镜像文件。
在支持多类型设备的平台的应用中,开发人员在开发的过程中,首先需要创建代码仓库,然后基于所述平台的代码仓库编译获得镜像文件,由于所述镜像文件实际上是三个版本的文件,分别为PCI版本、Debug版本和Release版本,所以,为了最终能够获得三个版本的镜像文件,需要通过编译系统传递不同的条件变量控制,将条件变量传递到boot0,u-boot,Android中,而kernel中因为没有与版本有关的内容,因此不使用此变量。通过条件变量编译区分不同版本的镜像文件,也就是说不同版本的镜像文件并不是二进制兼容的,他们属于编译时识别,后续根据不同的版本打包输出不同版本的镜像文件。这样,不同版本的镜像文件就获得了。虽然,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件。然而,这样依然无法解决不同类型的设备如何与支持多类型设备的镜像文件适配的问题。
步骤S102,在所述设备中的镜像文件对应的操作系统初始化时,获取所述设备的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件。
在本申请实施例中,在所述设备中的镜像文件对应的操作系统初始化时,表示加载了开发人员基于所述android平台编译生成的镜像文件之后,还需要对所述设备进行初始化,由于目前镜像文件中不仅包括了多种类型的设备通用的文件,还包括不同类型的设备独有的文件,所以,为了保证所述设备以后能够正常运行,在进行初始化时,需要获取所述设备的设备信息,所述设备的设备信息能够确定设备的类型,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件。除了执行通用的部分的脚本文件,还要执行所述设备信息独有的脚本文件,即每个设备信息对应的文件是两部分:通用部分和独有部分。
步骤S103,在所述设备中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
在本申请实施例中,在所述设备中的镜像文件对应的操作系统运行时,仍然需要获取所述设备的设备信息,以执行与所述设备信息对应的相关的操作。
本申请实施例从加载了基于支持多类型设备的镜像文件的设备一侧对本申请实施例进行说明。需要说明的一点是,虽然本申请实施例是从加载了基于支持多类型设备的镜像文件的设备一侧对本申请实施例进行说明,然而,本申请实施例中的镜像文件的获得过程是,开发人员基于所述平台的代码仓库,通过条件变量传递版本信息,编译获得的三个版本的文件。这三个版本的文件中包含了支持的设备的信息,可以加载到任意支持的类型的设备中。这样就是实现了统一代码仓库,统一镜像文件。无疑,对于开发人员而言,如果需要修复bug,就需要修改一份3个版本的镜像文件即可,若增加通用功能,也是修改一份3个版本的镜像文件即可,提高了开发人员的工作效率,并且,还有利于文件的管理。
图2是本申请实施例提供的另一种支持多类型设备的平台的应用方法的流程示意图,可以包括以下步骤:
步骤S201,基于所述平台的设备加载所述平台的一个版本的镜像文件,所述镜像文件是基于所述平台的代码仓库,通过条件变量传递版本信息,编译获得的支持多类型设备的文件。
该步骤与步骤S101的内容一致,具体可参照步骤S101的描述,在此不再赘述。
需要说明的一点是,虽然编译获得的镜像文件包括三个版本的。然而,设备中通常存在一个版本的镜像文件,在设备中已经存在一个版本的镜像文件的情况下,如果再次加载镜像文件,那么再次加载的镜像文件会覆盖所述设备之前加载的镜像文件。
步骤S202,在所述设备中的镜像文件对应的操作系统初始化时,通过镜像文件中的u-boot文件,从所述设备的配置文件或Secure Processor中获取所述设备的第一类设备信息。
图1所示实施例中,描述了开发人员如何编译获得不同版本的镜像文件,本申请实施例重点从加载了所述镜像文件的设备一侧,描述如何可以基于所述镜像文件,根据不同类型的设备,初始化运行所述镜像文件对应的操作系统。
实际应用中,所述设备的类型信息也可以从配置文件中获得,还可以从Secure Processor中获得,然而,从所述配置文件中或所述Secure Processor中获得的不止类型信息,还包括了其它设备信息,我们将从配置文件或Secure Processor中获取的设备信息命名为第一类设备信息,所述第一类设备信息用来表示从配置文件中或所述Secure Processor中获得设备信息。所述第一类设备信息包括设备的类型信息。在获得了设备的类型信息之后,就可以继续获得所述设备的设备树信息。
步骤S203,通过所述镜像文件中的u-boot文件,基于所述设备的第一类设备信息,获取所述设备的设备树文件,所述设备树文件为所述镜像文件支持的所有类型的设备的集合。
我们以从Secure Processor中获得为例,说明如何通过所述镜像文件中的u-boot文件获取所述设备的设备树文件。所述设备的类型信息从Secure Processor中获取时,表示所述配置文件存放在Secure Processor端。通过与Secure Processor端的通信接口向Secure Processor发出读取类型信息的请求,可以通过类型信息中的设备ID、主板和接口板版本作为关键字,也可以在知道所述设备的设备树的名称的前提下直接将设备树的名称作为关键字,Secure Processor端从配置文件的压缩包中查找与所述关键字匹配的设备树文件,如果查找到,就可以解压缩设备树文件并放到内存中。
所述设备的类型信息通过u-boot确定,u-boot文件可以根据所述设备的类型信息获取所述设备的设备树文件(DTB),所述设备树文件为所述镜像文件支持的所有类型的设备的集合,所述设备树文件也保存了设备信息,我们可以将从设备树文件中获得的设备信息命名为第二类设备信息,所述第二类设备信息用来表示用设备树文件中获得的设备信息。通过所述第一类设备信息和/或第二类设备信息,就可以在所述操作系统的初始化和运行阶段,针对不同类型的设备,执行与所述设备相关的文件或操作。
在设备的生产阶段,设备的配置文件就会下载到所述设备中,所述配置文件可以区分不同类型的设备或者不同硬件版本的设备。
步骤S204,加载所述操作系统的内核,并将所述设备的设备树文件和第一类设备信息传递给所述操作系统的内核,以便于所述操作系统的内核基于所述设备树文件加载与所述设备对应的硬件资源。
在本申请实施例中,在获得了第一类设备信息和设备树文件之后,还需要将所述设备树文件和第一类设备信息传递到所述操作系统的内核中,例如,kernel。这时可以加载所述操作系统的内核,并将所述设备的设备树文件和第一类设备信息传递给所述操作系统的内核,所述操作系统的内核基于所述设备树文件就可以加载与所述设备对应的硬件资源,例如,硬件驱动。
步骤S205,所述操作系统的内核从所述设备树文件中获取第二类设备信息,并将所述第一类设备信息和所述第二类设备信息作为所述设备的设备信息传递到所述设备的操作系统中的property子系统中,以便于所述设备的操作系统运行时,从所述property子系统中获取所述设备的设备信息,执行与所述设备信息对应的设备的操作。
在本申请实施例中,还需要从所述设备树文件中获取第二类设备信息,然后将第二类设备信息和第一类设备作为所述设备的设备信息传递到所述设备的操作系统中的property子系统中。Property是Android系统中一个重要的概念,在Android系统内,主要用于系统配置,以及不同服务间的简单信息分享,还包含了设备信息,例如设备名字,蓝牙名字,编译信息,网络dns地址,以及其他的一些设备信息。这样,所述操作系统在运行时就可以从所述property子系统中获取所述设备信息,执行与所述设备信息对应的设备的操作。
步骤S206,在所述设备中的镜像文件对应的操作系统运行时,从所述property子系统中获取所述设备信息,执行与所述设备信息对应的设备的操作。
步骤S207,在接收到重新加载镜像文件的指令后,接收待重新加载的镜像文件,并加载该镜像文件,所述待重新加载的镜像文件为基于所述平台的代码仓库在原镜像文件的基础上修改获得的。
在本申请实施例中,操作系统中难免存在一些bug,或者增加一些新的功能,这是就需要对系统进行升级。对于开发人员而言,只需要修改针对支持多类型设备的操作系统的3个版本文件即可,无需向以往那样针对每个类型的设备的操作系统分别进行修改。无疑大大节省了时间,提高了工作效率。假设上一次加载的操作系统的版本为android 2.4,那么修改后的版本就为android 2.5,重新加载的镜像文件android 2.5就是基于所述平台的代码仓库在原镜像文件android 2.4的基础上修改获得的,设备一侧接收到重新加载镜像文件android 2.5的指令后,接收待重新加载的镜像文件android 2.5,并加载该镜像文件android 2.5,加载后,按照上述初始化方法和运行方法继续操作即可。
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
图3是本申请一实施例提供的移动终端的示意框图,为了便于说明,仅示出与本申请实施例相关的部分。
该移动终端3可以是内置于手机、平板电脑、笔记本等移动终端内的软件单元、硬件单元或者软硬结合的单元,也可以作为独立的挂件集成到所述手机、平板电脑、笔记本等移动终端中。
所述移动终端3,基于支持多类型的设备的平台,所述移动终端3包括:
加载模块31,用于加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
初始化模块32,用于在所述移动终端中的镜像文件对应的操作系统初始化时,获取所述移动终端的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
运行模块33,用于在所述移动终端中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
可选的,所述加载模块31还用于:
基于所述平台的设备加载所述平台的一个版本的镜像文件,所述镜像文件是基于所述平台的代码仓库,通过条件变量传递版本信息,编译获得的支持多类型设备的文件。
可选的,所述平台为android平台;所述操作系统为android系统;
所述条件变量位于所述镜像文件的boot0文件、u-boot文件、Android文件中;
所述镜像文件包括:PCI版本的镜像文件、Debug版本的镜像文件、Release版本的镜像文件。
可选的,所述初始化模块32包括:
设备类型获取单元321,用于通过镜像文件中的u-boot文件,从所述设备的配置文件或Secure Processor中获取所述设备的第一类设备信息。
可选的,所述初始化模块32还包括:
设备树获取单元322,用于在获取所述设备的第一类设备信息之后,通过所述镜像文件中的u-boot文件,基于所述设备的第一类设备信息,获取所述设备的设备树文件,所述设备树文件为所述镜像文件支持的所有类型的设备的集合。
可选的,所述初始化模块32还包括:
第一信息传递单元323,用于加载所述操作系统的内核,并将所述设备的第一类设备信息和所述设备树文件传递给所述操作系统的内核,以便于所述操作系统的内核基于所述第一类设备信息和所述设备树文件加载与所述设备对应的硬件资源;
第二信息传递单元324,用于所述操作系统的内核从所述设备树文件中获取第二类设备信息,并将所述第一类设备信息和所述第二类设备信息作为所述设备的设备信息传递到所述设备的操作系统中的property子系统中,以便于所述设备的操作系统运行时,从所述property子系统中获取所述设备的设备信息,执行与所述设备的设备信息对应的设备的操作。
可选的,所述移动终端3还包括:
重新加载模块34,用于在接收到重新加载镜像文件的指令后,接收待重新加载的镜像文件,并加载该镜像文件,所述待重新加载的镜像文件为基于所述平台的代码仓库在原镜像文件的基础上修改获得的。
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述移动终端的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述装置中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
图4是本申请又一实施例提供的移动终端的示意框图。如图4所示,该实施例的移动终端4包括:一个或多个处理器40、存储器41以及存储在所述存储器41中并可在所述处理器40上运行的计算机程序42。所述处理器40执行所述计算机程序42时实现上述各个支持多设备的平台的应用方法实施例中的步骤,例如图1所示的步骤S101至S103。或者,所述处理器40执行所述计算机程序42时实现上述移动终端实施例中各模块/单元的功能,例如图3所示模块31至33的功能。
示例性的,所述计算机程序42可以被分割成一个或多个模块/单元,所述一个或者多个模块/单元被存储在所述存储器41中,并由所述处理器40执行,以完成本申请。所述一个或多个模块/单元可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序42在所述移动终端4中的执行过程。例如,所述计算机程序42可以被分割成加载模块、初始化模块、运行模块。
加载模块,用于加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
初始化模块,用于在所述移动终端中的镜像文件对应的操作系统初始化时,获取所述移动终端的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
运行模块,用于在所述移动终端中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
其它模块或者单元可参照图3所示的实施例中的描述,在此不再赘述。
所述移动终端包括但不仅限于处理器40、存储器41。本领域技术人员可以理解,图4仅仅是移动终端4的一个示例,并不构成对移动终端4的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述移动终端还可以包括输入设备、输出设备、网络接入设备、总线等。
所述处理器40可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器 (Digital Signal Processor,DSP)、专用集成电路 (Application Specific Integrated Circuit,ASIC)、现成可编程门阵列 (Field-Programmable Gate Array,FPGA) 或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。
所述存储器41可以是所述移动终端4的内部存储单元,例如移动终端4的硬盘或内存。所述存储器41也可以是所述移动终端4的外部存储设备,例如所述移动终端4上配备的插接式硬盘,智能存储卡(Smart Media Card, SMC),安全数字(Secure Digital, SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器41还可以既包括所述移动终端4的内部存储单元也包括外部存储设备。所述存储器41用于存储所述计算机程序以及所述移动终端所需的其他程序和数据。所述存储器41还可以用于暂时地存储已经输出或者将要输出的数据。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
在本申请所提供的实施例中,应该理解到,所揭露的移动终端和方法,可以通过其它的方式实现。例如,以上所描述的移动终端实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括是电载波信号和电信信号。
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。

Claims (10)

  1. 一种支持多类型设备的平台的应用方法,其特征在于,包括:
    基于所述平台的设备加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
    在所述设备中的镜像文件对应的操作系统初始化时,获取所述设备的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
    在所述设备中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
  2. 如权利要求1所述的支持多类型设备的平台的应用方法,其特征在于,所述基于所述平台的设备加载所述平台的镜像文件包括:
    基于所述平台的设备加载所述平台的一个版本的镜像文件,所述镜像文件是基于所述平台的代码仓库,通过条件变量传递版本信息,编译获得的支持多类型设备的文件。
  3. 如权利要求2所述的支持多类型设备的平台的应用方法,其特征在于,所述平台为android平台;所述操作系统为android系统;
    所述条件变量位于所述镜像文件的boot0文件、u-boot文件、Android文件中;
    所述镜像文件包括:PCI版本的镜像文件、Debug版本的镜像文件、Release版本的镜像文件。
  4. 如权利要求3所述的支持多类型设备的平台的应用方法,其特征在于,所述获取所述设备的设备信息包括:
    通过镜像文件中的u-boot文件,从所述设备的配置文件或Secure Processor中获取所述设备的第一类设备信息。
  5. 如权利要求4所述的支持多类型设备的平台的应用方法,其特征在于,在获取所述设备的第一类设备信息之后,还包括:
    通过所述镜像文件中的u-boot文件,基于所述设备的第一类设备信息,获取所述设备的设备树文件,所述设备树文件为所述镜像文件支持的所有类型的设备的集合。
  6. 如权利要求5所述的支持多设备的平台的应用方法,其特征在于,在获取所述设备的设备树文件之后,还包括:
    加载所述操作系统的内核,并将所述设备的第一类设备信息和所述设备树文件传递给所述操作系统的内核,以便于所述操作系统的内核基于所述设备树文件加载与所述设备对应的硬件资源;
    所述操作系统的内核从所述设备树文件中获取第二类设备信息,并将所述第一类设备信息和所述第二类设备信息作为所述设备的设备信息传递到所述设备的操作系统中的property子系统中,以便于所述设备的操作系统运行时,从所述property子系统中获取所述设备的设备信息,执行与所述设备信息对应的设备的操作。
  7. 如权利要求1所述的支持多设备的平台的应用方法,其特征在于,还包括:
    在接收到重新加载镜像文件的指令后,接收待重新加载的镜像文件,并加载该镜像文件,所述待重新加载的镜像文件为基于所述平台的代码仓库在原镜像文件的基础上修改获得的。
  8. 一种移动终端,其特征在于,基于支持多类型设备的平台,所述移动终端包括:
    加载模块,用于加载所述平台的镜像文件,所述平台的镜像文件是基于所述平台的代码仓库编译获得的支持多类型设备的文件;
    初始化模块,用于在所述移动终端中的镜像文件对应的操作系统初始化时,获取所述移动终端的设备信息,并执行所述镜像文件中与所述设备信息对应的初始化脚本文件;
    运行模块,用于在所述移动终端中的镜像文件对应的操作系统运行时,基于所述设备的设备信息,执行与所述设备信息对应的操作。
  9. 一种移动终端,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至7任一项所述方法的步骤。
  10. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机程序,所述计算机程序被一个或多个处理器执行时实现如权利要求1至7任一项所述方法的步骤。
PCT/CN2019/081045 2018-06-26 2019-04-02 一种支持多类型设备的平台的应用方法、移动终端 WO2020001112A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810671900.7 2018-06-26
CN201810671900.7A CN109062617B (zh) 2018-06-26 2018-06-26 一种支持多类型设备的平台的应用方法、移动终端

Publications (1)

Publication Number Publication Date
WO2020001112A1 true WO2020001112A1 (zh) 2020-01-02

Family

ID=64821646

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/081045 WO2020001112A1 (zh) 2018-06-26 2019-04-02 一种支持多类型设备的平台的应用方法、移动终端

Country Status (2)

Country Link
CN (1) CN109062617B (zh)
WO (1) WO2020001112A1 (zh)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109062617B (zh) * 2018-06-26 2020-07-28 百富计算机技术(深圳)有限公司 一种支持多类型设备的平台的应用方法、移动终端
CN109976751B (zh) * 2019-03-28 2022-12-27 中科寒武纪科技股份有限公司 模型操作方法、相关装置及计算机可读存储介质
WO2021120074A1 (zh) * 2019-12-18 2021-06-24 深圳市大疆创新科技有限公司 软件扩展方法、终端设备、可移动平台、负载和存储介质
CN111240752B (zh) * 2019-12-31 2021-08-17 北京元心科技有限公司 操作系统自适配方法及系统
CN114168168A (zh) * 2020-09-10 2022-03-11 华为技术有限公司 设备树修复方法、系统及计算机可读存储介质
CN112286568A (zh) * 2020-09-22 2021-01-29 福建升腾资讯有限公司 一种Android系统多版本兼容方法
CN112463244B (zh) * 2020-10-29 2022-12-27 苏州浪潮智能科技有限公司 一种cpu启动方法、装置、电子设备及计算机可读存储介质
CN112631671A (zh) * 2020-12-31 2021-04-09 东软睿驰汽车技术(沈阳)有限公司 一种操作系统初始化的方法和装置
CN112783516B (zh) * 2021-01-07 2024-06-04 广东天波信息技术股份有限公司 硬件适配的方法、电子设备和计算机可读存储介质
CN113286090B (zh) * 2021-06-07 2023-07-18 经纬恒润(天津)研究开发有限公司 摄像头多驱动动态配置方法、加载方法及相关装置
CN113282280A (zh) * 2021-06-18 2021-08-20 卡斯柯信号有限公司 面向功能可扩充的通用信号设备交互方法、设备及介质
CN114661330B (zh) * 2022-05-25 2022-09-09 武汉海微科技有限公司 车辆硬件程序更新方法、装置、设备及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170242664A1 (en) * 2016-02-18 2017-08-24 Line Corporation Method, apparatus, system, and non-transitory computer readable medium for extending at least one function of a package file
CN107577477A (zh) * 2017-09-06 2018-01-12 武汉虹信通信技术有限责任公司 一种基于dtb文件的多平台软件版本自适应方法及系统
CN107632828A (zh) * 2016-07-18 2018-01-26 迈普通信技术股份有限公司 多dts文件支持方法、编译装置及嵌入式设备
CN109062617A (zh) * 2018-06-26 2018-12-21 百富计算机技术(深圳)有限公司 一种支持多类型设备的平台的应用方法、移动终端

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140379925A1 (en) * 2013-06-21 2014-12-25 Electronics And Telecommunications Research Institute Apparatus and method for interworking between app store servers to share application information
CN104484211B (zh) * 2014-12-29 2017-07-28 广东欧珀移动通信有限公司 共享镜像文件的方法及装置
CN104767635B (zh) * 2015-01-12 2019-01-04 武汉烽火网络有限责任公司 一种基于命令行动态替换用于多设备共镜像的方法
CN105138389B (zh) * 2015-07-30 2019-01-11 北京京东尚科信息技术有限公司 一种集群中虚拟设备的管理方法及系统
CN105260205B (zh) * 2015-09-30 2018-11-06 中山市天启智能科技有限公司 一种嵌入式板上实现双操作系统启动的方法
CN105607921B (zh) * 2015-10-29 2019-11-12 Tcl集团股份有限公司 一种基于Android系统的系统服务启动方法及系统
CN105607941A (zh) * 2015-11-25 2016-05-25 上海斐讯数据通信技术有限公司 一种安卓项目中配置编译的装置和方法
CN107463427A (zh) * 2017-06-29 2017-12-12 北京北信源软件股份有限公司 一种虚拟机操作系统类型与版本的获取方法与装置
CN107526587A (zh) * 2017-08-02 2017-12-29 中国航空无线电电子研究所 一种综合模块化航空电子系统的构建方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170242664A1 (en) * 2016-02-18 2017-08-24 Line Corporation Method, apparatus, system, and non-transitory computer readable medium for extending at least one function of a package file
CN107632828A (zh) * 2016-07-18 2018-01-26 迈普通信技术股份有限公司 多dts文件支持方法、编译装置及嵌入式设备
CN107577477A (zh) * 2017-09-06 2018-01-12 武汉虹信通信技术有限责任公司 一种基于dtb文件的多平台软件版本自适应方法及系统
CN109062617A (zh) * 2018-06-26 2018-12-21 百富计算机技术(深圳)有限公司 一种支持多类型设备的平台的应用方法、移动终端

Also Published As

Publication number Publication date
CN109062617A (zh) 2018-12-21
CN109062617B (zh) 2020-07-28

Similar Documents

Publication Publication Date Title
WO2020001112A1 (zh) 一种支持多类型设备的平台的应用方法、移动终端
US9811360B2 (en) Dynamic determination of application server runtime classloading
US9558016B2 (en) Platform system, method for changing support hardware configuration of universal extensible firmware interface basic input output system and computer program product
US10055218B2 (en) System and method for adding and storing groups of firmware default settings
US10810017B2 (en) Systems and methods for handling firmware driver dependencies in host operating systems while applying updates from bootable image file
WO2017166447A1 (zh) 内核模块加载方法和装置
US10747526B2 (en) Apparatus and method to execute prerequisite code before delivering UEFI firmware capsule
US10860307B2 (en) Fragmented firmware storage system and method therefor
EP3207453B1 (en) Api versioning independent of product releases
WO2018032653A1 (zh) 一种Java卡应用的功能实现方法及装置
US20060230397A1 (en) Method for third-party registration of software components
CN111767056A (zh) 一种源码编译方法、可执行文件运行方法及终端设备
US6961848B2 (en) System and method for supporting legacy operating system booting in a legacy-free system
US9250917B2 (en) Auto-cloudifying applications via runtime modifications
US8516455B2 (en) Dynamic loading of kernel extensions
CN110515671B (zh) 初始化方法、初始化装置、终端设备及可读存储介质
US11340882B2 (en) Systems and methods for enforcing update policies while applying updates from bootable image file
WO2023060893A1 (zh) 存储空间管理方法、装置、设备及存储介质
US20160239285A1 (en) Systems and methods for download and installation of drivers for unmanaged information handling resources
US9003364B2 (en) Overriding system attributes and function returns in a software subsystem
CN115237458A (zh) 一种调用推理硬件执行ai应用的方法及相关产品
CN108804221B (zh) 基于xip方式的嵌入式系统及其资源优化方法
CN116302150B (zh) hypervisor自启动程序生成方法和操作系统启动方法
US11669618B2 (en) Systems and methods for securing and loading bios drivers and dependencies in a predefined and measured load order
US11334342B1 (en) Updating firmware of unsupported devices

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19826179

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19826179

Country of ref document: EP

Kind code of ref document: A1