A method, system, and electronic device for implementing software development

By generating a system software tool development kit and using configuration files and module configuration files, the problem of existing SDKs being unable to extend the system layer is solved, thereby enabling the expansion of system layer capabilities and improving user experience.

CN115543276BActive Publication Date: 2026-11-20HUAWEI TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202110743630.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-06-30
Publication Date
2026-11-20
Estimated Expiration
2041-06-30

AI Technical Summary

Technical Problem

The existing SDK cannot support the extension of capabilities below the system layer of the operating system, making it difficult for developers to enrich system-level capabilities and improve user experience.

Method used

It provides a system software tool development kit that generates extended components by obtaining system-level files from the operating system, supporting the expansion of system-level capabilities. This includes the use of configuration files and module configuration files to automatically copy and compile files, ensuring API and ABI compatibility.

Benefits of technology

It enriches the capabilities of the system layer, reduces the difficulty of development, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115543276B_ABST
    Figure CN115543276B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a method, system and electronic device for implementing software development. The method is applied to an electronic device. The electronic device can publish a system software tool development package based on n files in a system layer of a first software. The system software tool development package can be used to expand the capability of the system layer, and the capability of the system layer can be enriched. The user experience is improved and the development difficulty is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of software, and more specifically, to a method, system, and electronic device for implementing software development. Background Technology

[0002] Currently, various operating systems provide SDKs to facilitate the development of various applications. The SDKs currently provided only contain interfaces for the application framework layer. Developers can use the SDK to support the compilation and development of applications and extend the application layer of the operating system. However, it is not currently possible to extend the capabilities of the system layer below the application layer through the SDK. Summary of the Invention

[0003] This application provides a method, system, and electronic device for software development. The method can provide a system software tool development kit at the system layer, which can support the expansion of system layer capabilities, enrich system layer capabilities, improve user experience, and reduce development difficulty.

[0004] Firstly, a system is provided, comprising a source-side device and a target-side device, wherein... The source-side device is used to acquire n files of the first software to generate a system software tool development kit and to release the system software tool development kit. The n files are system-level files of the first software. The system software tool development kit includes the n files, where n≥1 and n is a positive integer. The target-side device is used to acquire the first software and the system software tool development kit, use the system software tool development kit to compile the source code of the extension component to generate the extension component, and merge the first software and the extension component to generate the second software.

[0005] In this embodiment, the source device obtains n files of the first software to generate a system software tool development kit and publishes the system software tool development kit. The n files are system layer files of the first software. Thus, the target device can extend the capabilities of the first software system layer through the system software tool development kit, enriching the capabilities of the system layer, improving the user experience and reducing the development difficulty.

[0006] In conjunction with the first aspect, in some implementations of the first aspect, the source-side device also publishes the first software.

[0007] In conjunction with the first aspect, in some implementations of the first aspect, the first software includes a configuration file that indicates a first path of the n files in the system layer and a second path in the system software tool development kit; The source-side device is specifically used to execute the configuration file, copy the n files to the second path in the system software tool development kit to generate the system software tool development kit, and release the system software tool development kit.

[0008] Specifically, the configuration file includes the first path of the n files in the first software and the second path in the system software tool development kit. When the source device executes the configuration file, it can automatically copy the n files from the first path to the second path.

[0009] In this embodiment of the application, the first software includes a configuration file, so that the source-side device can execute the configuration file to automatically copy n files in the system layer to the set path.

[0010] In conjunction with the first aspect, in some implementations of the first aspect, the configuration file is also used to indicate the format of the n files in the system software tool development kit; The source-side device is specifically used to execute the configuration file, determine the format of the n files in the system software tool development kit to generate the system software tool development kit, and release the system software tool development kit.

[0011] In conjunction with the first aspect, in some implementations of the first aspect, the system software tool development kit further includes: a module configuration file, which indicates the functions of the n files; and the target-side device, specifically used to compile the system software tool development kit and the source code of the extension component according to the module configuration file, and generate the extension component.

[0012] Specifically, since the module configuration file can indicate the functions of the n files, the target device can write the source code of the extension component according to the module configuration file. After completing the source code writing of the extension component, it can compile the system software tool development kit and the source code of the system extension component to generate the extension component.

[0013] In conjunction with the first aspect, in some implementations of the first aspect, the source-side device is further used to compile the software source code of the first software to generate m files, where m ≥ n and m is a positive integer; the m files include the n files.

[0014] In this embodiment of the application, n system-layer files can be selected from the m compiled files to release a system software tool development kit. These n files are the system-layer files of the first software. Thus, the target device can extend the capabilities of the first software system layer through the system software tool development kit, enriching the capabilities of the system layer, improving the user experience, and reducing the development difficulty.

[0015] In conjunction with the first aspect, in some implementations of the first aspect, the n files are interface files corresponding to the functions not implemented by the first software.

[0016] Specifically, the unimplemented function of the first software may correspond to one or more interfaces at the system layer, and the n files can be the files corresponding to these one or more interfaces. For example, if the unimplemented function of the first software is 5G communication, and this 5G communication function corresponds to a communication interface at the system layer, then the n files can be the files corresponding to the communication interface. The source code supporting the 5G communication function can then be compiled using these n files, thereby generating an extended component that supports the 5G communication function.

[0017] In conjunction with the first aspect, in some implementations of the first aspect, the system layer includes an application framework layer and / or a system library and / or a hardware adaptation layer and / or a kernel layer.

[0018] In conjunction with the first aspect, in some implementations of the first aspect, before merging the first software and the extended component to generate the second software, the target-side device is further configured to detect the compatibility of the first software and the extended component; merging the first software and the extended component to generate the second software includes: when the first software and the extended component are compatible, the target-side device merges the first software and the extended component to generate the second software.

[0019] In conjunction with the first aspect, in some implementations of the first aspect, the target-side device is further configured to detect the compatibility between the first software and the extended component, including: the target-side device detecting the version of the first system software tool development kit released by the first software and the version of the second system software tool development kit used by the extended component; when the first software and the extended component are compatible, it includes: when the version of the first system software tool development kit is the same as the version of the second system software tool development kit used by the extended component, the first software and the extended component are compatible.

[0020] Specifically, in order to ensure the merging of the first software and the extended components, it is necessary to detect the merging of the first software and the extended components. Since it involves the expansion of system-level capabilities, it is necessary to ensure API compatibility and ABI compatibility. Therefore, it is necessary to compile the version of the system software development kit used by the extended components to be consistent with the version of the system software development kit released based on the first software.

[0021] Secondly, a method for software development is provided, which involves obtaining n files of a first software to generate a system software tool development package and releasing the system software tool development package. The n files are system layer files of the first software, and the system software tool development package includes the n files, where n ≥ 1 and n is a positive integer.

[0022] In this embodiment of the application, n files of the first software are obtained to generate a system software tool development kit, and the system software tool development kit is released. Since the n files are system layer files of the first software, system layer capabilities can be extended based on the system software tool development kit.

[0023] In conjunction with the second aspect, in some implementations of the second aspect, the first software further includes a configuration file indicating a first path of the n files in the system layer and a second path in the system software tool development package; the process of obtaining the n files of the first software to generate the system software tool development package and publishing the system software tool development package includes: executing the configuration file, copying the n files to the second path in the system software tool development package to generate the system software tool development package, and publishing the system software tool development package.

[0024] Specifically, the configuration file includes the first path of the n files in the first software and the second path in the system software tool development kit. When the configuration file is executed, the n files can be automatically copied from the first path to the second path.

[0025] In this embodiment of the application, the first software includes a configuration file, so that when the configuration file is executed, n files in the system layer can be automatically copied to the set path.

[0026] In conjunction with the second aspect, in some implementations of the second aspect, the configuration file is also used to indicate the format of the n files in the system software tool development kit; The process of obtaining n files from the first software to generate a system software tool development kit and releasing the system software tool development kit includes executing the configuration file, determining the format of the n files in the system software tool development kit to generate the system software tool development kit, and releasing the system software tool development kit.

[0027] In conjunction with the second aspect, in some implementations of the second aspect, the system software tool development kit also includes: a module configuration file; the module configuration file is used to indicate the functions of the n files.

[0028] In conjunction with the second aspect, in some implementations of the second aspect, the method further includes: compiling the software source code of the first software to generate m files, where m ≥ n and m is a positive integer; the m files include the n files.

[0029] In this embodiment of the application, n system-layer files can be selected from the m compiled files to release a system software tool development kit. These n files are the system-layer files of the first software. Thus, the target device can extend the capabilities of the first software system layer through the system software tool development kit, enriching the capabilities of the system layer, improving the user experience, and reducing the development difficulty.

[0030] In conjunction with the second aspect, in some implementations of the second aspect, the n files are interface files corresponding to the functions not implemented by the first software.

[0031] Specifically, the unimplemented function of the first software may correspond to one or more interfaces at the system layer, and the n files can be the files corresponding to these one or more interfaces. For example, if the unimplemented function of the first software is 5G communication, and this 5G communication function corresponds to a communication interface at the system layer, then the n files can be the files corresponding to the communication interface. The source code supporting the 5G communication function can then be compiled using these n files, thereby generating an extended component that supports the 5G communication function.

[0032] In conjunction with the second aspect, in some implementations of the second aspect, the system layer includes an application framework layer and / or a system library and / or a hardware adaptation layer and / or a kernel layer.

[0033] Thirdly, a method for implementing software development is provided, the method comprising: obtaining a first software and a system software tool development kit, the system software tool development kit comprising n files, the n files being system layer files of the first software; compiling the source code of an extension component using the system software tool development kit to generate an extension component; and merging the extension component and the first software to generate a second software.

[0034] In this embodiment of the application, by obtaining the system software tool development kit, since the system software tool development kit includes n files of the first software system layer, the system layer capabilities can be extended based on the system software tool development kit, thereby enriching the system layer capabilities, improving the user experience and reducing the development difficulty.

[0035] In conjunction with the third aspect, in some implementations of the third aspect, the first software includes a configuration file that indicates a first path for the n files at the system layer and a second path in the system software tool development kit.

[0036] In conjunction with the third aspect, in some implementations of the third aspect, the configuration file is also used to indicate the format of the n files in the system software tool development kit.

[0037] In conjunction with the third aspect, in some implementations of the third aspect, the system software tool development kit further includes: a module configuration file, which indicates the functions of the n files; the compilation of the extension component source code using the system software tool development kit to generate the extension component includes: compiling the extension component source code using the system software tool development kit according to the module configuration file to generate the extension component.

[0038] Specifically, since the module configuration file can indicate the functions of the n files, the source code of the extension component can be written according to the module configuration file. After the source code of the extension component is written, the system software tool development kit and the source code of the system extension component can be compiled to generate the extension component.

[0039] In conjunction with the third aspect, in some implementations of the third aspect, the system layer includes an application framework layer and / or a system library layer and / or a hardware adaptation layer and / or a kernel layer.

[0040] In conjunction with the third aspect, in some implementations of the third aspect, before merging the extended component and the first software to generate the second software, the method further includes: detecting the compatibility between the first software and the extended component; merging the extended component and the first software to generate the second software includes: merging the extended component and the first software to generate the second software when the first software and the extended component are compatible.

[0041] In conjunction with the third aspect, in some implementations of the third aspect, the detection of compatibility between the first software and the extended component includes: detecting the version of the first system software tool development kit released by the first software and the version of the second system software tool development kit used by the extended component; when the first software and the extended component are compatible, it includes: when the version of the first system software tool development kit is the same as the version of the second system software tool development kit used by the extended component, the first software and the extended component are compatible.

[0042] Specifically, in order to ensure the merging of the first software and the extended components, it is necessary to detect the merging of the first software and the extended components. Since it involves the expansion of system-level capabilities, it is necessary to ensure API compatibility and ABI compatibility. Therefore, it is necessary to compile the version of the system software development kit used by the extended components to be consistent with the version of the system software development kit released based on the first software.

[0043] Fourthly, an electronic device according to an embodiment of this application includes modules / units for performing the above aspects or any possible design of the above aspects; these modules / units can be implemented in hardware or by hardware executing corresponding software.

[0044] Fifthly, a chip according to an embodiment of this application is coupled to a memory in an electronic device and is used to call a computer program stored in the memory and execute the above-mentioned aspects of the embodiments of this application and any possible design of the above-mentioned aspects; in the embodiments of this application, "coupling" means that two components are directly or indirectly combined with each other.

[0045] Sixthly, a computer-readable storage medium according to an embodiment of this application includes a computer program that, when run on an electronic device, causes the electronic device to perform the technical solutions described above and any possible design thereof.

[0046] A seventh aspect is a computer program according to an embodiment of this application, the computer program including instructions that, when executed on a computer, cause the computer to perform the technical solutions described above and any possible design of the above aspects.

[0047] Eighthly, a chip according to an embodiment of this application is provided. The chip includes a processor and a data interface. The processor reads instructions stored in a memory through the data interface to execute the above aspects and any possible design of the above aspects.

[0048] For the beneficial effects in aspects four through eight, please refer to the beneficial effects in aspects one through three, which will not be repeated here. Attached Figure Description

[0049] Figure 1 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.

[0050] Figure 2 This is a software structure block diagram of an electronic device provided in an embodiment of this application.

[0051] Figure 3 This is a software structure block diagram of another electronic device provided in the embodiments of this application.

[0052] Figure 4 This is an exemplary flowchart of a method for implementing software development provided in an embodiment of this application.

[0053] Figure 5 This is an exemplary block diagram of the compatibility check provided in the embodiments of this application.

[0054] Figure 6 This is a structural block diagram of the source-side device according to an embodiment of this application.

[0055] Figure 7 This is a structural block diagram of the target-side device according to an embodiment of this application. Detailed Implementation

[0056] The terminology used in the following embodiments is for the purpose of describing particular embodiments only and is not intended to be limiting of this application. As used in the specification and appended claims of this application, the singular expressions “a,” “an,” “the,” “the,” “the,” and “this” are intended to also include expressions such as “one or more,” unless the context clearly indicates otherwise. It should also be understood that in the following embodiments of this application, “at least one” and “one or more” refer to one, two, or more than two. The term “and / or” is used to describe the relationship between related objects, indicating that three relationships may exist; for example, A and / or B can indicate: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character “ / ” generally indicates that the preceding and following related objects are in an “or” relationship.

[0057] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.

[0058] The following describes an electronic device, a user interface for such an electronic device, and embodiments for using such an electronic device. In some embodiments, the electronic device may be a portable electronic device that also includes other functions such as a personal digital assistant and / or music player, such as a mobile phone, tablet computer, wearable electronic device with wireless communication capabilities (such as a smartwatch), etc. Exemplary embodiments of the portable electronic device include, but are not limited to, portable electronic devices running iOS®, Android®, Microsoft®, Harmony OS, or other operating systems. The aforementioned portable electronic device may also be other portable electronic devices, such as a laptop computer, etc. It should also be understood that in some other embodiments, the aforementioned electronic device may not be a portable electronic device, but a desktop computer.

[0059] For example, Figure 1A schematic diagram of the structure of electronic device 100 is shown. Electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, a compass 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.

[0060] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0061] Processor 110 may include one or more processing units, such as application processors (APs), modem processors, graphics processing units (GPUs), image signal processors (ISPs), controllers, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). Different processing units may be independent components or integrated into one or more processors. In some embodiments, electronic device 101 may also include one or more processors 110. The controller can generate operation control signals based on instruction opcodes and timing signals to control instruction fetching and execution. In other embodiments, processor 110 may also include a memory for storing instructions and data. For example, the memory in processor 110 may be a cache memory. This memory can store instructions or data that processor 110 has just used or is reusing. If processor 110 needs to reuse the instruction or data, it can directly retrieve it from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the electronic device 101 in processing data or executing instructions.

[0062] In some embodiments, the processor 110 may include one or more interfaces. These interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a SIM card interface, and / or a USB interface, etc. The USB interface 130 is a USB standard-compliant interface, specifically a Mini USB interface, a Micro USB interface, a USB Type-C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 101, and can also be used for data transfer between the electronic device 101 and peripheral devices. The USB interface 130 can also be used to connect headphones for audio playback.

[0063] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a structural limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0064] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.

[0065] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, external memory, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.

[0066] The wireless communication function of electronic device 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.

[0067] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with tuning switches.

[0068] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 may be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 may be housed in the same device.

[0069] The wireless communication module 160 can provide solutions for wireless communication applications on the electronic device 100, including wireless local area networks (WLANs) (such as wireless fidelity (WiFi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signals, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.

[0070] Electronic device 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0071] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel may be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a MiniLED, a MicroLED, a Micro-OLED, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include one or more display screens 194.

[0072] In some embodiments of this application, when the display panel uses materials such as OLED, AMOLED, and FLED, the above-mentioned Figure 1The display screen 194 can be bent. Here, "the display screen 194 can be bent" means that the display screen can be bent to any angle at any part and can maintain that angle. For example, the display screen 194 can be folded from the middle left to right. It can also be folded from the middle up to down.

[0073] The display screen 194 of electronic device 100 can be a flexible screen. Currently, flexible screens are attracting much attention due to their unique characteristics and enormous potential. Compared to traditional screens, flexible screens are highly flexible and bendable, providing users with new interaction methods based on their bendability and meeting more user needs for electronic devices. For electronic devices equipped with foldable displays, the foldable display can switch between a small screen in a folded state and a large screen in an unfolded state at any time. Therefore, users are increasingly using split-screen functionality on electronic devices equipped with foldable displays.

[0074] Electronic device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0075] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization of image noise, brightness, and skin tone. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.

[0076] Camera 193 is used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats. In some embodiments, electronic device 100 may include one or more cameras 193.

[0077] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when electronic device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.

[0078] Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. Thus, electronic device 100 can play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0079] NPU stands for Neural Network (NN) Computing Processor. By borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it can rapidly process input information and continuously learn on its own. NPUs enable intelligent cognitive applications in electronic devices, such as image recognition, facial recognition, speech recognition, and text understanding.

[0080] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.

[0081] Internal memory 121 can be used to store one or more computer programs, which include instructions. Processor 110 can execute the instructions stored in internal memory 121, thereby causing electronic device 101 to perform the methods provided in some embodiments of this application, as well as various applications and data processing. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system; the program storage area may also store one or more applications (such as a gallery, contacts, etc.). The data storage area may store data created during the use of electronic device 101 (such as photos, contacts, etc.). In addition, internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as one or more disk storage components, flash memory components, universal flash storage (UFS), etc. In some embodiments, processor 110 can execute instructions stored in internal memory 121 and / or instructions stored in memory disposed in processor 110 to cause electronic device 101 to perform the methods provided in embodiments of this application, as well as other applications and data processing. Electronic device 100 can implement audio functions such as music playback and recording through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.

[0082] The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0083] The pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, the pressure sensor 180A can be disposed on the display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors. A capacitive pressure sensor may include at least two parallel plates with conductive materials. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the pressure intensity based on the change in capacitance. When a touch operation is applied to the display screen 194, the electronic device 100 detects the intensity of the touch operation based on the pressure sensor 180A. The electronic device 100 can also calculate the touch position based on the detection signal from the pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different touch operation intensities can correspond to different operation commands. For example, when a touch operation with an intensity less than a first pressure threshold is applied to the SMS application icon, a command to view an SMS message is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to the SMS application icon, a command to create a new SMS message is executed.

[0084] The gyroscope sensor 180B can be used to determine the motion attitude of the electronic device 100. In some embodiments, the gyroscope sensor 180B can determine the angular velocity of the electronic device 100 around three axes (i.e., the X, Y, and Z axes). The gyroscope sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyroscope sensor 180B detects the angle of the electronic device 100's shake, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to counteract the shake of the electronic device 100 through reverse movement, thus achieving image stabilization. The gyroscope sensor 180B can also be used in navigation and motion-sensing game scenarios.

[0085] The 180E accelerometer can detect the magnitude of acceleration of electronic device 100 in various directions (typically three axes). When electronic device 100 is stationary, it can detect the magnitude and direction of gravity. It can also be used to identify the posture of electronic devices and applied to applications such as screen orientation switching and pedometers.

[0086] The ambient light sensor 180L is used to sense the brightness of ambient light. The electronic device 100 can adaptively adjust the brightness of the display screen 194 based on the sensed ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also work with the proximity sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.

[0087] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can utilize the characteristics of the collected fingerprints to achieve fingerprint unlocking, accessing application locks, taking photos with fingerprints, answering calls with fingerprints, etc.

[0088] Temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 uses the temperature detected by temperature sensor 180J to execute a temperature handling strategy. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, electronic device 100 performs thermal protection by reducing the performance of a processor located near temperature sensor 180J to reduce power consumption. In other embodiments, when the temperature is below another threshold, electronic device 100 heats battery 142 to prevent abnormal shutdown of electronic device 100 due to low temperature. In still other embodiments, when the temperature is below yet another threshold, electronic device 100 boosts the output voltage of battery 142 to prevent abnormal shutdown due to low temperature.

[0089] Touch sensor 180K, also known as a "touch panel," can be located on display screen 194. The touch sensor 180K and display screen 194 together form a touchscreen, also known as a "touch screen." Touch sensor 180K detects touch operations applied to or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180K may also be located on the surface of electronic device 100, in a different position than display screen 194.

[0090] Figure 2 This is a software architecture block diagram of an electronic device 100 in the prior art. The layered architecture divides the software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the system library layer, and the kernel layer. The application layer may include a series of application packages.

[0091] like Figure 2 As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and SMS.

[0092] The application framework layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The application framework layer includes some predefined functions.

[0093] like Figure 2 As shown, the application framework layer may include a window manager, content provider, view system, phone manager, resource manager, notification manager, etc.

[0094] The window manager is used to manage window programs. The window manager can obtain the screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.

[0095] Content providers store and retrieve data, making that data accessible to applications. This data may include videos, images, audio, made and received phone calls, browsing history and bookmarks, phone books, etc.

[0096] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build applications. A display interface can consist of one or more views. For example, a display interface including a text notification icon could include views for displaying text and views for displaying images.

[0097] The phone manager is used to provide communication functions for electronic device 100. For example, it manages call status (including connection and disconnection).

[0098] The file explorer provides applications with various resources, such as localized strings, icons, images, layout files, video files, and so on.

[0099] The notification manager allows applications to display notifications in the status bar. These notifications can be used to convey informational messages and can disappear automatically after a short pause, requiring no user interaction. For example, the notification manager can be used to notify users of download completion or message alerts. The notification manager can also display notifications as icons or scrolling text in the top status bar, such as notifications from background applications, or as dialog boxes on the screen. Examples include displaying text messages in the status bar, emitting sounds, vibrating electronic devices, and flashing indicator lights.

[0100] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.

[0101] The Surface Manager is used to manage the display subsystem and provides the blending of 2D and 3D layers for multiple applications.

[0102] The media library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG.

[0103] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0104] A 2D graphics engine is a graphics engine for 2D drawing.

[0105] The kernel layer is the layer between hardware and software. The kernel layer includes at least display drivers, camera drivers, audio drivers, and sensor drivers.

[0106] Before introducing the embodiments of this application, let's first introduce a few concepts related to the embodiments of this application.

[0107] Software Development Kit (SDK): An SDK can be considered a collection of related documents, examples, and tools that assist in the development of a certain type of software. It is equivalent to a development integration environment, such as Android development tools. There are also SDKs for specific software functions, such as image recognition technology and speech recognition and analysis technology.

[0108] Application Programming Interface (API): An API can be considered as a set of predefined interfaces (such as functions or HTTP interfaces) that provide applications and developers with the ability to access a set of routines based on software or hardware without needing to access the source code or understand the details of the internal workings.

[0109] Understandably, an SDK can be considered a collection of multiple APIs and other files. For example, to develop a video doorbell with features such as video intercom, visitor screenshotting, and facial recognition, you first need to generate APIs for these three functions. These three APIs can then be combined into an SDK. An application is then created based on the SDK, and firmware is written into the doorbell. When the video doorbell needs to add a new function like iris recognition, an iris recognition API needs to be generated, forming a new SDK. New firmware is then generated and updated into the doorbell to enable it to have all four functions.

[0110] Application Binary Interface (ABI): The ABI contains the programming conventions that an application must adhere to during system runtime. The ABI includes a set of system calls and methods for using these system calls, as well as rules regarding memory addresses and machine register usage. From an application's perspective, the ABI is both part of the system architecture and a key aspect of the hardware architecture.

[0111] Currently, various operating systems provide SDKs to developers to facilitate the development of various applications, thereby supporting application compilation and development. Simultaneously, they combine... Figure 2 As can be seen, when an application runs, it interacts with the system layer through the interface of the application framework layer. Therefore, the application layer and the system layer are connected through the interface of the application framework layer. However, in the prior art, due to the strong coupling between the kernel layer, system library, and application framework layer, changes are propagated. This propagation means that when one layer changes, other layers will also change. For example, when a functional module in the system library changes, some content in the kernel layer and application framework layer will change accordingly. Therefore, it is difficult to provide stable and open interfaces to the outside world for the kernel layer, system library, and application framework layer. That is, it is impossible to provide developers with an SDK with system layer interfaces. The system layer can be understood as other layers besides the application layer (such as the kernel layer, system library, and application framework layer). In another embodiment of this application, the system layer may include the application framework layer, system library, hardware adaptation layer, and kernel layer. Since the prior art cannot provide an SDK with system layer interfaces, it cannot meet the needs of developers or users. For example, in one scenario, a first electronic device has a 4G chip and an operating system that supports 4G communication. The first electronic device can then perform 4G communication. However, when this operating system is installed on a second electronic device with a 5G chip, the second electronic device cannot perform 5G communication because the operating system does not support 5G communication. To enable 5G communication in the second electronic device, it is necessary to extend the system-level capabilities of the operating system. However, in existing technologies, extending the system-level capabilities of an operating system requires manipulating the operating system's source code, rather than extending the system-level capabilities through an SDK.

[0112] For example, in another scenario, the operating system of the first electronic device has the function of performing 720P video decoding, but not 1080P video decoding. The expansion of video decoding capability also needs to be based on the expansion of system-level capabilities. For similar reasons, the system-level capabilities cannot be expanded through SDK.

[0113] For example, in another scenario, the first electronic device could be a smart POS device with an operating system. This smart POS device initially does not have a display. When it is desired to add a display to the smart POS device to enable the display of the amount received after each transaction, for reasons similar to those mentioned above, adding hardware involves extending the capabilities of the operating system's system layer. However, in the prior art, the capabilities of the system layer cannot be extended through an SDK.

[0114] In summary, existing SDKs can only support the compilation and development of applications, and cannot support the compilation and development of system-level extension capabilities. Therefore, this application provides a method for calling a software interface, which can provide an SDK with system-level interfaces, thereby supporting the compilation and development of system-level extension capabilities.

[0115] For ease of description, the operating system will be referred to as software.

[0116] As shown in Figure 3, this is a software structure block diagram of an electronic device 100 in one embodiment, and... Figure 2 Similarly, from bottom to top, they are kernel layer, system library, application framework layer, and application layer.

[0117] In another embodiment, the software architecture diagram of the electronic device 100 can be arranged from bottom to top as follows: kernel layer, hardware adaptation layer, system library, application framework layer, and application layer.

[0118] The kernel layer includes the kernel subsystem and the driver subsystem.

[0119] The use of a multi-kernel design allows for the selection of a suitable kernel for different resource-constrained devices.

[0120] For example, the kernel subsystem may include the Linxu Kernel and / or Lite OS and / or HarmonyOS kernel.

[0121] The driver subsystem can provide unified peripheral access capabilities and driver development and management framework.

[0122] The system layer is a collection of core software capabilities that provides services to applications through the application framework layer. The system layer may include the following components: The system's basic capability subsystem set provides the foundational capabilities for distributed applications to run, schedule, and migrate across multiple electronic devices. It consists of subsystems such as distributed soft bus, distributed task scheduling, multi-mode input, and common basic library.

[0123] Basic service software subsystem set: To provide public and general software services, it consists of subsystems such as time notification, telephone, and multimedia.

[0124] Enhanced Software Service Subsystem Set: This set of subsystems consists of wearable-specific services, Internet of Things (IoT)-specific services, and other subsystems designed to provide differentiated, enhanced software services for different electronic devices.

[0125] Hardware service subsystem set: To provide hardware services, it consists of subsystems such as location services, biometric features, and wearable proprietary hardware services.

[0126] It should be noted that the software in this application embodiment can select subsystems from the basic service software subsystem set, the enhanced software service subsystem set, and the hardware service subsystem set according to the deployment environment of different electronic devices, and each subsystem can be selected according to its function.

[0127] Application framework layer: This layer provides multi-language (e.g., Java / C / C++) user program frameworks and Ability frameworks for applications, as well as multi-language framework APIs exposed to various software and hardware services. Different electronic devices may support different APIs, which depends on the subsystems of the software's system layer within the electronic device.

[0128] Application layer, with Figure 2 The application layer is similar and will not be described in detail here.

[0129] The following is combined Figure 4 A schematic flowchart illustrating the method for calling the interface provided in the embodiments of this application is shown.

[0130] Figure 4 An exemplary flowchart of a software compilation and building method provided in an embodiment of this application is shown, the process including: S401 compiles the software source code, generating m files.

[0131] Compilation is the process of translating software source code (usually in a high-level language) into object code (usually in machine language) that can be directly executed by electronic devices or virtual machines. For example, source code in Java can be compiled into one or more binary files.

[0132] In this embodiment of the application, the software source code is compiled on the source-side device to generate m files. These m files can perform different functions. After being archived, these m files constitute the first system component, where m ≥ 1 and m is a positive integer.

[0133] For example, if the software source code is the source code of the HarmonyOS system, and after compilation it will generate system components, then the system components can be considered as the HarmonyOS system running on electronic devices.

[0134] These m files can be distributed across different layers of the system architecture. For example, if m=100, 10 files belong to the application layer, 40 files belong to the application framework layer, 40 files belong to the system library layer, and 10 files belong to the kernel layer.

[0135] For example, if m=100, there are 10 files belonging to the application layer, 30 files belonging to the application framework layer, 40 files belonging to the system library, 10 files belonging to the hardware adaptation layer, and 10 files belonging to the kernel layer.

[0136] Alternatively, the binary file mentioned above can also be called a library. A library is a binary form of executable code that can be loaded into memory and executed by software. Libraries can be divided into static libraries and dynamic libraries; dynamic libraries can also be called shared libraries. All data in a static library is integrated into the code during compilation, while functions in a dynamic library are not compiled into the code during compilation; instead, they are called when the relevant function is executed. This application does not limit the type of library in its embodiments.

[0137] In this embodiment of the application, the software source code can be compiled on a Linux system. While Ubuntu can be used to compile the software source code, this is not a limitation; for example, Lubuntu can also be used.

[0138] In one embodiment, when compiling software source code using Ubuntu, it is necessary to set up the environment. The setup of the environment can refer to existing technologies and will not be described in detail here.

[0139] In one embodiment, the compilation of software source code can also be performed on an Ubuntu image that has already been set up with various environments.

[0140] Once the environment is set up, or in an already set up Ubuntu environment, the source code can be compiled to generate system components.

[0141] Optionally, developers can edit the software source code, such as adding or deleting parts of the source code. After compilation, adding source code can generate more than m files, while deleting part of the source code can generate fewer than m files.

[0142] S402, select n files to generate a system software tool development kit.

[0143] Specifically, after compiling the software source code, m files are generated. These m files, when archived, constitute the first system component, where m ≥ 1 and m is a positive integer. Among these m files are n files that indicate the external interfaces of the system layer. These can also be understood as the interfaces that the software needs to expose to the outside world, or in other words, the interfaces that can be associated with the system layer of the software through these n files. Furthermore, these n files can be considered a collection of external interfaces of the system layer. These n files are then archived to form a system software tool development package, where n ≤ m.

[0144] It should be noted that these n files can indicate interfaces to different layers within the system layer. For example, if n=10, three files can indicate the application framework layer interface, three files can indicate the system library interface, and four files can indicate the kernel layer interface. Because these n files can indicate interfaces to different layers, during software development, they can be used to connect to different system layers, thereby extending the capabilities of the system layer.

[0145] For example, in one scenario, software source code is compiled to obtain a first system component. This first system component does not have a camera function, but it can have a camera interface at the system layer. The camera interface can be understood as an interface that supports the camera function at the system layer. For example, there is a camera driver at the kernel layer, but there is no functional module for the camera function in the system library. Therefore, electronic devices equipped with the first system component cannot realize the camera function. However, through the method provided in the embodiments of this application, the corresponding camera driver file can be exposed (also called an interface) and released through a system software toolkit. After obtaining the system software toolkit, the original design manufacturer (ODM), original equipment manufacturer (OOEM), and third-party developers can develop source code for the camera function based on the system software toolkit. After compiling the source code for the camera function and the system software toolkit, a third system component can be obtained. This third system component has the camera function, and electronic devices equipped with the third system component can realize the camera function.

[0146] For example, in another scenario, the software source code is compiled to obtain a first system component. This first system component retains a 5G communication interface at the system layer. Since the chip used by the electronic device equipped with the first system component does not have 5G communication function code, the 5G communication interface can be exposed through a system software tool development kit. ODMs, OEMs, third-party developers, etc. can supplement the 5G communication function code based on the system software tool development kit. After compiling the 5G communication function code and the system software tool development kit, a fourth system component can be obtained. By installing the fourth system component in an electronic device with a chip that has 5G communication function code, the electronic device will have 5G communication capabilities.

[0147] For example, in another scenario, the software source code is compiled to obtain a first system component, which is installed in a smart speaker. This first system component retains a display interface at the system layer and can be released through a system software toolkit. ODMs, OEMs, and third-party developers can then add display function code based on the system software toolkit. After compiling the display function code and the system software toolkit, a fifth system component can be obtained. When a smart speaker equipped with the fifth system component is connected to a display, the smart speaker and the display can work together because the fifth system component has display functionality.

[0148] In summary, the first system component can be considered as a software with basic functions that can ensure operation in various electronic devices. However, the system layer interface can be released through the system software tool development kit, and then ODMs, OEMs, third-party developers, etc. can extend the system layer capabilities based on the first system component, such as the various functions described above.

[0149] For example, these n files can be implemented through software source code. That is, when writing the software source code, the files that need to indicate the system layer interface are determined, and after compilation, these n files are generated.

[0150] Optionally, the system software tool development kit may also include module configuration files, which are used to indicate the functions of n files.

[0151] In existing technologies, SDKs are not released by compiling the software source code. Instead, they are released as stubs of the software source code. For details on the specific implementation, please refer to existing technologies.

[0152] To ensure API and ABI compatibility when ODMs, OEMs, and third-party developers develop second system components based on the system software tool development kit, the first system component and the system software tool development kit need to be built at once.

[0153] A build can be understood as the software source code being compiled to generate the first system component, and then the system software tool development package being released based on the first system component. During this process, the m files in the first system component will not change, and no files will be added or removed from the first system component.

[0154] The following section will introduce methods to ensure that the first system components and system software tool development kits are built on the first attempt.

[0155] When the source code is compiled, one or more configuration files will be generated. These configuration files indicate the specific locations of the n files. They can also indicate the location of the n files in the system software tool development kit after the system software tool development kit is generated, and change the n files to a format that can participate in the compilation of system-level extension capability code.

[0156] It should be noted that if one or more of the n files can directly participate in the compilation of system-level extension capability code, then the format of the one or more files does not need to be changed.

[0157] For example, after compiling the software source code, a native.xml configuration file can be generated. The native.xml configuration file can indicate the specific location of the binary files in the system library that need to be exposed to the outside world. For example, if there are q files in the system library, by parsing the configuration file, the p files in the system library that need to be exposed to the outside world can be automatically selected.

[0158] For example, the specific code is as follows: <config> <copy_file from>=”vendor / Huawei / system_ext / adapter_sdk / Android.bp.sdk” to=” vendor / XXX / Android.bp” / > < / config> As shown in the code above, when parsing the native.xml configuration file, the Android.bp.sdk file located at vendor / Huawei / system_ext / adapter_sdk is copied and placed into the system software tool development kit (SDK) at the path vendor / XXX. The Android.bp.sdk file is then renamed to Android.bp. This is to enable Android.bp to participate in the compilation of extended system-level capability code. Since the software source code can generate Android.bp.sdk after compilation, Android.bp.sdk cannot participate in the compilation process. Simply copying and placing Android.bp.sdk into the SSDK will not allow it to participate in the compilation; therefore, it needs to be changed to Android.bp, which can participate in the compilation process.

[0159] For example, after compiling the software source code, a framework_boot_jar.xml configuration file can be generated. The framework_boot_jar.xml configuration file can indicate the specific location of the binary files that need to be exposed in the application framework layer. The specific code is as follows: <config> <copy_file from>=”out / target / common / obj / JAVA_LIBRARIES / voip-common_intermediates / classes.jar” to=”voip-common / voip-common.jar” / > < / config> As can be seen from the code above, when parsing the framework_boot_jar.xml configuration file, classes.jar located at out / target / common / obj / JAVA_LIBRARIES / voip-common_intermediates is copied and placed into the system software tool development package (SDK). The path in the SSD is voip-common, and classes.jar is renamed to voip-common.jar.

[0160] It should be noted that the embodiments in this application only use framework_boot_jar.xml and native.xml configuration files as examples, but should not constitute any limitation.

[0161] After parsing the configuration file and executing the code within it, you can obtain the files that need to be exposed to the outside world at different layers of the system, as well as their paths in the system software tool development kit.

[0162] For example, taking a system library as an example, after compiling the software source code, the configuration files for the files that need to be developed in the system library and their paths are as follows: native_bin.xml, native_include.xml, native_lib.xml, etc. The above configuration files can be the files that need to be developed and their paths corresponding to different functional modules in the system library. After parsing the configuration files and executing the code in the configuration files, the paths in the system software tool development package can be: bin / , include / , lib / .

[0163] In summary, by compiling the software source code to generate a configuration file and executing the configuration file, the files that need to be exposed in the system layer are copied and copied to the system software tool development kit. Since the copying can be performed automatically after the software source code is compiled, it can be ensured that the first system component and the system software tool development kit are built at the same time.

[0164] As can be seen from the above, the generated system software tool development kit contains n pre-compiled files. Since these n files have been compiled and associated with the system layer, ODMs and OEMs can extend the system layer through this system software tool development kit.

[0165] S403, releases the system software tool development kit.

[0166] After generating the system software tool development kit, the system software tool development kit can be released. ODMs, OEMs, third-party developers, etc., can then extend the system-level capabilities based on the system software tool development kit.

[0167] S404, based on the system software tool development kit, generates a second system component.

[0168] After receiving the system software tool development kit, the target side can develop different functions based on the system software tool development kit, extend the system layer capabilities, and then generate a second system component. This second system component contains all the functions of the first system component as well as the functions extended based on the system software tool development kit.

[0169] The target side can be understood as the target device using the system software tool development kit.

[0170] The following section will describe the detailed process of generating the second system component on the target side.

[0171] After obtaining the system software tool development kit (SDK), the target side can write source code to expand the capabilities of the system layer as needed. Then, it can compile the SSD and the source code of the written system extension components to obtain the system extension components, which extend the capabilities of the system layer. For example, if the SSD exposes a communication interface that connects to multiple modules in the system layer, the target side can write source code for 5G communication functionality based on the SSD. Then, by compiling the SSD and the 5G communication functionality source code, the target side obtains the system extension components, which then possess 5G communication capabilities.

[0172] After the target side generates the system extension component, since the system extension component is developed based on the system software tool development package released by the first system component, and the system software tool development package has one or more interfaces pointing to the system layer of the first system component, the system extension component can call the first system component by calling the interface, that is, the system extension component and the first system component are merged to generate the second system component. Thus, the second system component contains all the functions of the first system component and the functions of the system extension component.

[0173] To ensure that the first system component and the system extension component can be combined to generate the second system component, the version of the system software development kit used to compile the system extension component must be consistent with the version of the system software development kit released based on the first system component.

[0174] For example, such as Figure 5 As shown in (a) of this application, assuming the software in this embodiment is HarmonyOS 2.0, its external release may include a first system component and a system software tool development kit (SDK) based on the first system component, with the SSD version being 1.2.0. The ODM develops a first system extension component and a second system extension component based on this SSD, which can be named ODM1.0 and ODM2.0. Since both the first and second system extension components are developed based on the 1.2.0 version of the SSD, their interfaces are compatible with the first system component, allowing the ODM to combine the first and second system extension components with the first system component.

[0175] For example, such as Figure 5 As shown in (b) of this application, assuming the software in this embodiment is HarmonyOS 2.0, its external release may include a first system component and a system software tool development kit (SDK) based on the first system component, wherein the version of the SSD is 1.2.0. However, the ODM develops a third system extension component based on the SSD version 1.10. Since the third system extension component is developed based on the SSD version 1.1.0, it cannot be combined with the first system component.

[0176] In this embodiment, the first system component is generated by compiling the software source code, and the files that need to be made public are developed externally in the form of a system software tool development kit. The first system component and the system software tool development kit are released from the same source, which ensures that the system layer can be extended through the system software tool development kit, enriching the capabilities of the system layer. ODMs, OEMs, third-party developers, etc. can customize based on the system software tool development kit, improving the user experience and reducing the development difficulty.

[0177] Figure 6 This is a schematic structural diagram of a source-side device according to an embodiment of this application. It should be understood that... Figure 6 The source-side device 600 shown is merely an example. The source-side device in this embodiment may also include other modules or units, or include components related to... Figure 6 Modules with similar functions, or not necessarily including Figure 6 All modules in it.

[0178] Figure 6 The source-side device 600 shown may include a compilation module 610, a generation module 620, and a publishing module 630, wherein each module included in the source-side device 600 may be implemented by software and / or hardware.

[0179] Compiler module 610 is used to compile software source code.

[0180] The generation module 620 is used to generate the first system component; it is also used to execute the configuration file to generate the system software tool development kit.

[0181] Release module 630 is used to release the first system components and system software tool development kits.

[0182] In some possible implementations, the source-side device 600 may include a processor coupled to a memory for executing program instructions in the memory. When the processor executes the program instructions in the memory, it performs the operations executed by the compilation module 610, the generation module 620, and the release module 630, thereby achieving... Figure 4 Methods for implementing the intermediate source side device.

[0183] Optionally, the source-side device may also include a memory.

[0184] In possible implementations, the source-side device can be a chip, for example, a chip that can be integrated into a development device.

[0185] Figure 7 The target-side device 700 shown may include a receiving module 710, a generating module 720, and a publishing module 730. It should be understood that... Figure 7 The target-side device 700 shown is merely an example; the source-side device in this application embodiment may also include other modules or units, or include components related to... Figure 7 Modules with similar functions, or not necessarily including Figure 6 All modules in it.

[0186] The receiving module 710 is used to receive the first system component and the system software tool development kit.

[0187] The generation module 720 is used to generate system extension components based on the system software tool development kit; it is also used to generate a second system component based on the first system component and the system extension components.

[0188] Module 730 is used to publish the second system component.

[0189] In some possible implementations, the target-side device 700 may include a processor coupled to a memory for executing program instructions in the memory. When the processor executes the program instructions in the memory, it implements the operations performed by the receiving module 710, the generating module 720, and the publishing module 730, thereby achieving... Figure 4 Methods for implementing the target-side device.

[0190] Optionally, the target-side device may also include a memory.

[0191] In possible implementations, the target device can be a chip, for example, a chip that can be integrated into a development device.

[0192] It should be noted that the first system component described above can also be referred to as the first software, and the second system component can also be referred to as the second software.

[0193] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0194] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0195] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0196] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0197] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. It should be understood that the processor in the embodiments of this application can be a central processing unit (CPU), but it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor.

[0198] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0199] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A system for implementing software development, characterized in that, The system includes a source-side device and a target-side device, wherein... The source-side device is used to acquire n files of the first software to generate a system software tool development kit, and to publish the system software tool development kit. The n files are system layer files of the first software. The system software tool development kit includes the n files, where n≥1 and n is a positive integer. The first software and the system software tool development kit are built at once. During the build process, the files in the first software will not change, and no files will be added or removed from the first software. The target-side device is used to acquire the first software and the system software tool development kit, use the system software tool development kit to compile the source code of the extension component to generate the extension component, and merge the first software and the extension component to generate the second software; The first software includes a configuration file, which indicates the first path of the n files at the system layer and the second path at the system software tool development package. The configuration file is generated when the source code of the first software is compiled. The source-side device is specifically used to execute the configuration file, copy the n files to the second path in the system software tool development package to generate the system software tool development package, and publish the system software tool development package; Before merging the first software and the extended component to generate the second software, the target-side device is also used to detect the compatibility between the first software and the extended component. The merging of the first software and the extended components to generate the second software includes: When the first software and the extended component are compatible, the target-side device merges the first software and the extended component to generate the second software; The target-side device is further configured to detect the compatibility between the first software and the extended component, including: The target-side device detects the version of the first system software tool development kit released by the first software and the version of the second system software tool development kit used by the extended component; When the first software and the extended component are compatible, it includes: When the version of the first system software tool development kit is the same as the version of the second system software tool development kit used by the extended component, the first software and the extended component are compatible.

2. The system according to claim 1, characterized in that, The system software tool development kit also includes: a module configuration file, which is used to indicate the functions of the n files; The target-side device is specifically used to compile the source code of the extension component according to the module configuration file and using the system software tool development kit to generate the extension component.

3. The system according to claim 1 or 2, characterized in that, The source-side device is also used to compile the software source code of the first software to generate m files, where m ≥ n and m is a positive integer; The m files include the n files.

4. The system according to claim 1 or 2, characterized in that, The system layer includes an application framework layer and / or a system library and / or a hardware adaptation layer and / or a kernel layer.

5. A method for implementing software development, characterized in that, The method includes: Obtain n files from the first software to generate a system software tool development kit, and release the system software tool development kit. The n files are system layer files of the first software. The system software tool development kit includes the n files, where n≥1 and n is a positive integer. The first software and the system software tool development kit are built at once. During the build process, the files in the first software will not change, and no files will be added or removed from the first software. The first software also includes a configuration file, which indicates the first path of the n files in the system layer and the second path in the system software tool development package. The configuration file is generated when the source code of the first software is compiled. The step of obtaining n files from the first software to generate a system software tool development kit and releasing the system software tool development kit includes: The configuration file is executed to copy the n files to the second path in the system software tool development package to generate the system software tool development package, and the system software tool development package is then published.

6. The method according to claim 5, characterized in that, The system software tool development kit also includes: module configuration files; The module configuration file is used to indicate the functions of the n files.

7. The method according to claim 5 or 6, characterized in that, The method further includes: Compile the source code of the first software to generate m files, where m ≥ n and m is a positive integer; The m files include the n files.

8. The method according to claim 5 or 6, characterized in that, The system layer includes an application framework layer and / or a system library and / or a hardware adaptation layer and / or a kernel layer.

9. A method for implementing software development, characterized in that, The method includes: Obtain a first software and a system software tool development kit. The system software tool development kit includes n files, which are system layer files of the first software. The first software and the system software tool development kit are built at once. During the build process, the files in the first software will not change, and no files will be added or removed from the first software. The source code of the extension component is compiled using the system software tool development kit to generate the extension component; The extended component and the first software are combined to generate the second software; The first software includes a configuration file, which indicates the first path of the n files at the system layer and the second path at the system software tool development package. The configuration file is generated when the source code of the first software is compiled. Before merging the extended component and the first software to generate the second software, the method further includes: Detect the compatibility between the first software and the extended components; The step of merging the extended component and the first software to generate the second software includes: When the first software and the extended component are compatible, the extended component and the first software are merged to generate the second software; The process of detecting the compatibility between the first software and the extended component includes: The version of the first system software tool development kit released by the first software and the version of the second system software tool development kit used by the extended components are detected. When the first software and the extended component are compatible, it includes: When the version of the first system software tool development kit is the same as the version of the second system software tool development kit used by the extended component, the first software and the extended component are compatible.

10. The method according to claim 9, characterized in that, The system software tool development kit also includes: a module configuration file, which is used to indicate the functions of the n files; The process of compiling the source code of the extension component using the system software tool development kit to generate the extension component includes: Based on the module configuration file, the source code of the extension component is compiled using the system software tool development kit to generate the extension component.

11. The method according to claim 9 or 10, characterized in that, The system layer includes an application framework layer and / or a system library and / or a hardware adaptation layer and / or a kernel layer.

12. An electronic device, characterized in that, It includes one or more processors; when the one or more processors are running, the electronic device performs the method of any one of claims 5 to 8, or performs the method of any one of claims 9 to 11.

13. A computer program product, characterized in that, When run on a computer, the computer performs the method of any one of claims 5 to 8, or performs the method of any one of claims 9 to 11.

14. A computer-readable storage medium, characterized in that, Includes computer instructions that, when executed on an electronic device, cause the electronic device to perform the method of any one of claims 5 to 8, or to perform the method of any one of claims 9 to 11.

15. A chip, characterized in that, The chip includes a processor and a data interface. The processor reads instructions stored in the memory through the data interface to execute the method as described in any one of claims 5 to 8, or to execute the method as described in any one of claims 9 to 11.

Citation Information

Patent Citations

  • Development and manufacturing method and device of vehicle-mounted system SDK

    CN110502239A