Equipment function configuration method, function menu rendering method and equipment

By adjusting the device function configuration method, when facing the needs of new models, only the functional components need to be adjusted, the target configuration file is generated and deployed to the device, which solves the problem of long development time of equipment function and difficulty in maintaining it, and achieves efficient device function configuration.

CN119512610APending Publication Date: 2025-02-25GUANGZHOU SHIZHEN INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311031981.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-15
Publication Date
2025-02-25

AI Technical Summary

Technical Problem

In the prior art, when facing the needs of new models proposed by users or the market, R&D personnel need to create new code branches for the new models and make adjustments, resulting in a long time to develop equipment functions and difficulty in subsequent maintenance.

Method used

Provide a method for configuring device functions. By obtaining device function configuration tasks, pulling and displaying original configuration files based on the browser, adjusting functional components according to configuration requirements, generating target configuration files, and adding them to the built-in resource package with code files. , deploy to the target device to render the function menu.

Benefits of technology

It reduces the development time of equipment functions, reduces the development difficulty, improves the configuration efficiency of equipment functions of new models, and does not need to create new code branches for new models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119512610A_ABST
    Figure CN119512610A_ABST
Patent Text Reader

Abstract

The invention provides an equipment function configuration method, and a function menu rendering method and equipment. The method comprises the following steps: acquiring an equipment function configuration task; pulling and displaying an original configuration file based on a browser installed on the configuration equipment, wherein the original configuration file comprises a plurality of functional components; adjusting a functional component in the original configuration file according to the configuration requirement, and determining the adjusted original configuration file as a target configuration file; and pulling the code file, adding the target configuration file and the code file to a built-in resource bundle, and deploying the built-in resource bundle to a target device corresponding to the target machine type. According to the method and the device, when a new type demand proposed by a user or a market is faced, the configuration of the device function can be completed only by adjusting the functional component in the original configuration file according to the configuration demand of the new type, the development time of the device function is shortened, meanwhile, research and development personnel do not need to newly build a code branch for the new type, the development difficulty is reduced, and the development efficiency is improved. And the function configuration efficiency of the new type of equipment is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method for configuring device functions, a method for rendering a function menu, and a device. Background Art

[0002] Currently, the function menu can set many functions when the device leaves the factory. The function menu undertakes a lot of function setting items, such as system upgrade, PQ debugging, etc. In the process of business development, it is often necessary to add models to users and adjust the function menu function items according to user needs.

[0003] However, in the prior art, in order to meet the needs of new models proposed by users or the market, R&D personnel need to create a new code branch for the new model, make adjustments, and then release a customer channel package, which results in a long development time for the device functions of the new model and difficulty in subsequent maintenance. Summary of the invention

[0004] In view of this, the embodiments of the present invention provide a method for configuring device functions, a method for rendering a function menu, and a device to solve the problem that the development time of device functions is long and the subsequent maintenance is difficult.

[0005] In a first aspect, an embodiment of the present invention provides a method for configuring a device function, which is applied to configuring a device, and the method includes:

[0006] Acquire a device function configuration task, wherein the device function configuration task carries a target model of the device function to be configured and a configuration requirement of the target model;

[0007] Pulling and displaying an original configuration file based on a browser installed on the configuration device, wherein the original configuration file includes a plurality of functional components;

[0008] Adjusting the functional components in the original configuration file according to the configuration requirements, and determining the adjusted original configuration file as the target configuration file;

[0009] Pull the code file, add the target configuration file and the code file to the built-in resource package, and deploy the built-in resource package to the target device corresponding to the target model, wherein the code file includes the function code corresponding to each functional component, and the target device is used to pull the corresponding function code from the code file according to the target function component in the configuration file to render the function menu.

[0010] Furthermore, before acquiring the device function configuration task, the method further includes:

[0011] Obtaining a device function configuration file, wherein the device function configuration file includes a function code corresponding to each function item;

[0012] Parsing the key fields of the function code in the device function configuration file, and abstracting the key fields into function components corresponding to the function items;

[0013] The original configuration file is constructed based on the functional components.

[0014] Further, adjusting the functional components in the original configuration file according to the configuration requirements and determining the adjusted original configuration file as the target configuration file includes:

[0015] Copying the original configuration file to obtain a configuration file copy corresponding to the original configuration file, and displaying the configuration file copy on the browser;

[0016] Based on the browser, adjusting the functional components in the configuration file copy according to the configuration requirements, and using the target machine model as the file name of the configuration file copy to obtain an adjusted configuration file copy;

[0017] Identify the adjusted copy of the profile as the target profile.

[0018] Furthermore, adjusting the functional components in the configuration file copy according to the configuration requirements includes one or more of the following:

[0019] Adding a functional component corresponding to the configuration requirement to the copy of the configuration file;

[0020] Removing the functional components corresponding to the configuration requirements in the copy of the configuration file;

[0021] Adjusting the arrangement order of functional components in the copy of the configuration file according to the configuration requirements;

[0022] Modify the component name of the functional component in the copy of the configuration file according to the configuration requirements.

[0023] Furthermore, the file format of the original configuration file is XML format.

[0024] Furthermore, before deploying the target configuration file to the target device corresponding to the target model, the method further includes:

[0025] Triggering a verification mechanism to take effect based on the target configuration file;

[0026] In response to the verification mechanism taking effect, verifying the format of the target functional component in the target configuration file;

[0027] If the format check passes, verifying the function of the target functional component in the target configuration file;

[0028] When the function verification of the functional component passes, a configuration package is generated based on the target configuration file.

[0029] In a second aspect, an embodiment of the present invention provides a method for rendering a function menu, which is applied to a target device, and the method includes:

[0030] Receiving a function menu rendering request, and triggering a rendering mechanism to take effect based on the function menu rendering request, wherein the rendering mechanism is used to render the function menu of the target device;

[0031] Read the target model corresponding to the target device;

[0032] Reading a target configuration file corresponding to the target model from a pre-deployed built-in resource package, and parsing the target configuration file to obtain a target functional component, wherein the target configuration file is obtained by adjusting the functional components in the original configuration file by the configuration device based on the configuration requirements of the target model;

[0033] A function menu corresponding to the target device is rendered based on the target function component and the code file in the built-in resource package.

[0034] Furthermore, the rendering of a function menu corresponding to the target device based on the target function component and the code file in the built-in resource package includes:

[0035] Read the function code corresponding to the target function component from the code file of the built-in resource package;

[0036] The function code is compiled to render a function menu corresponding to the target device.

[0037] In a third aspect, an embodiment of the present invention provides a device for configuring a device function, including:

[0038] An acquisition module, used for acquiring a device function configuration task, wherein the device function configuration task carries a target model of the device function to be configured and a configuration requirement of the target model;

[0039] A display module, used to pull and display an original configuration file based on a browser installed on the configuration device, wherein the original configuration file includes multiple functional components;

[0040] A processing module, configured to adjust the functional components in the original configuration file according to the configuration requirements, and determine the adjusted original configuration file as the target configuration file;

[0041] The deployment module is used to pull the code file, add the target configuration file and the code file to the built-in resource package, and deploy the built-in resource package to the target device corresponding to the target model. The code file includes the function code corresponding to each functional component, and the target device is used to pull the corresponding function code from the code file according to the target function component in the configuration file to render the function menu.

[0042] In a fourth aspect, an embodiment of the present invention provides a device for rendering a function menu, comprising:

[0043] A receiving module, used for receiving a built-in resource package sent by a configuration device, and triggering a rendering mechanism to take effect based on the built-in resource package, wherein the rendering mechanism is used for rendering a function menu of a target device;

[0044] A reading module, used for reading the target model corresponding to the target device;

[0045] A parsing module, configured to read a target configuration file corresponding to the target model from a pre-deployed built-in resource package, and parse the target configuration file to obtain a target functional component, wherein the target configuration file is obtained by adjusting the functional components in the original configuration file by the configuration device based on the configuration requirements of the target model;

[0046] The rendering module is used to render the function menu corresponding to the target device based on the target function component and the code files in the built-in resource package.

[0047] In a fifth aspect, an embodiment of the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, computer instructions being stored in the memory, and the processor executing the method of the above-mentioned first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0048] In a sixth aspect, an embodiment of the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the method of the first aspect or any corresponding embodiment thereof.

[0049] When facing the demand for new models proposed by users or the market, the method provided in the embodiment of the present application only needs to adjust the functional components in the original configuration file according to the configuration requirements of the new model to complete the configuration of the new model device functions, thereby reducing the development time of the device functions. At the same time, there is no need for R&D personnel to create a new code branch for the new model, which reduces the development difficulty and improves the configuration efficiency of the new model device functions. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0051] Figure 1 is a flowchart of a method for configuring device functions according to some embodiments of the present invention;

[0052] Figure 2 is a schematic diagram of a configuration process of a target configuration file according to some embodiments of the present invention;

[0053] Figure 3 is a flowchart of a method for rendering a function menu according to some embodiments of the present invention;

[0054] Figure 4 is a structural block diagram of a device for configuring a device function according to an embodiment of the present invention;

[0055] Figure 5 is a structural block diagram of a rendering device for a function menu according to an embodiment of the present invention;

[0056] Figure 6 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0057] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0058] At present, in order to meet the needs of new models proposed by users or the market, R&D personnel are required to design the functions of new models according to the needs of new models, create new code branches for new models, and write the corresponding function codes for the functions. There are many processes from design to development, which leads to a long development time for the device functions of new models. As a result, when more and more new models are proposed by users or the market, it is impossible to flexibly configure the functions of new models.

[0059] Based on this, an embodiment of the present invention provides a method for configuring device functions, a method for rendering a function menu, and a device. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0060] In this embodiment, a method for configuring device functions is provided. Figure 1 is a flow chart of a method for configuring a device function according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0061] Step S11, obtaining a device function configuration task, wherein the device function configuration task carries a target machine type of the device function to be configured and a configuration requirement of the target machine type.

[0062] The method provided in the embodiment of the present application is applied to a configuration device, and the configuration device can be a mobile terminal, such as a mobile phone, a tablet computer, etc., or a computer. Specifically, the configuration device can detect the target model of the device function to be configured input by the user and the configuration requirements of the target model. It can be understood that the configuration requirements can be which functions the target model needs and the order of the functions, etc. Then, a device function configuration task is generated based on the target model and configuration requirements input by the user. The functions can be "image mode", "image hue", "image saturation", "touch disable", etc.

[0063] It should be noted that, in order to improve the development efficiency of device functions, the embodiment of the present application can obtain a device function configuration file, abstract the function code in the device function configuration file into function components, and use the abstracted function components to construct the original configuration file in Json format. Specifically, the following steps A1-A3 are included:

[0064] Step A1: Obtain a device function configuration file, wherein the device function configuration file includes a function code corresponding to each function item.

[0065] In an embodiment of the present application, the configuration device may obtain a pre-written device function configuration file, where the device function configuration file includes function codes corresponding to all function items of the function menu.

[0066] Step A2: parse the key fields of the function code in the device function configuration file, and abstract the key fields into function components corresponding to the function items.

[0067] In an embodiment of the present application, the configuration device can parse the identification fields in each function code in the device function configuration file, for example: the "action" field, the "title" field. Then traverse the content after the "title" field and the "action" field. Then use the identification field and the content after the identification field as the key field, for example: the key field can be: action = "burnVideor", action = "router" title = "burn-in video", title = "bass test", etc. Finally, the key field is abstracted into the functional component corresponding to the functional item, and the abstracted functional component can be:

[0068] remoteWakeup, / / remote wakeup

[0069] enterMachineSn, / burn product serial number

[0070] enterModel, / / burning model

[0071] allUpdate, / / update all

[0072] firmwareUpdate, / single firmware upgrade

[0073] toPictureMode, / / Enter image mode

[0074] toWhiteBalance, / / Enter white balance

[0075] maxBackLight, / / maximum backlight

[0076] Step A3, constructing an original configuration file based on the functional components.

[0077] In the embodiment of the present application, the abstracted functional components are used to construct the original configuration file in the Json format.

[0078] It should be noted that the embodiment of the present application pre-configures an original configuration file containing all functional components. When subsequently configuring the device functions of the new model, the original configuration file can be dynamically configured using the configuration requirements of the new model. That is, the functional components in the original configuration file can be plugged in and out according to the configuration requirements, making the functional configuration of the new model more flexible, which is conducive to improving the development efficiency of the new model device functions.

[0079] Step S12: Pulling and displaying an original configuration file based on a browser installed on the configuration device, wherein the original configuration file includes a plurality of functional components.

[0080] In the embodiment of the present application, firstly, it is detected whether there is a startup instruction for any browser installed on the configuration device, and if there is a startup instruction for the browser, the startup instruction is responded to and the browser is run. Secondly, a file opening instruction triggered in the browser is detected, the file opening instruction is responded to, the file storage address is obtained, and the original configuration file is pulled according to the file storage address, and the original configuration file is displayed on the browser.

[0081] Step S13, adjusting the functional components in the original configuration file according to the configuration requirements, and determining the adjusted original configuration file as the target configuration file.

[0082] In the embodiment of the present application, the functional components in the original configuration file are adjusted according to the configuration requirements, and the adjusted original configuration file is determined as the target configuration file, including the following steps B1-B3:

[0083] Step B1, copying the original configuration file, obtaining a configuration file copy corresponding to the original configuration file, and displaying the configuration file copy on the browser.

[0084] In the embodiments of the present application, Figure 2 As shown, after the configuration device detects that the original configuration file is opened in the browser, it detects whether there is a copy instruction for the original configuration file in the browser. If there is a copy instruction, the original configuration file is copied according to the copy instruction to obtain a configuration file copy corresponding to the original configuration file, and the configuration file copy is displayed in the browser.

[0085] It should be noted that copying the original configuration file, on the one hand, facilitates the subsequent configuration of the copied configuration file copy, and on the other hand, after adjusting the functional components according to the configuration requirements, it is convenient for the user to compare and optimize the configuration file copy with the original configuration file.

[0086] Step B2: Based on the browser, the functional components in the configuration file copy are adjusted according to the configuration requirements, and the target machine model is used as the file name of the configuration file copy to obtain the adjusted configuration file copy.

[0087] In the embodiment of the present application, in the browser, the functional components in the configuration file copy are adjusted according to the requirement information indicated in the configuration requirement, and the specific adjustment operation includes: one or more of the following: adding the functional components corresponding to the configuration requirement in the configuration file copy; removing the functional components corresponding to the configuration requirement in the configuration file copy; adjusting the arrangement order of the functional components in the configuration file copy according to the configuration requirement; modifying the component names of the functional components in the configuration file copy according to the configuration requirement. Among them, the requirement information in the configuration requirement can be one or more, which is not specifically limited here.

[0088] As an example, the configuration requirement is to add a new functional component "optical test mode". In this case, the functional component "optical test mode" is added to the configuration file copy.

[0089] Or, the configuration requirement is to adjust the arrangement order of "redGain, / / red gain", "greenGain, / / green gain", and "blueGain, / / blue gain". At this time, the original arrangement order is adjusted in the copy of the configuration file. The adjusted arrangement order is: "blueGain, / / blue gain", "redGain, / / red gain", and "greenGain, / / green gain".

[0090] Or, the configuration requirement is to modify the component name of the functional component "firmwareVersion, / / single firmware version" to "firmwareVersion, / / firmware version". At this time, obtain "firmwareVersion, / / single firmware version" from the configuration file copy and change its name to "firmwareVersion, / / firmware version".

[0091] In an embodiment of the present application, after the functional components in the configuration file copy are configured, the configured configuration file copy is displayed on a browser installed on the configuration device so that the user can view the configured configuration file copy or make corresponding adjustments to the configured configuration file.

[0092] In the embodiment of the present application, after the user confirms that the configuration of the configuration file copy is complete, the configuration device reads the target model and uses the target model as the file name of the configuration file copy to obtain an adjusted configuration file copy.

[0093] Step B3: determine the adjusted configuration file copy as the target configuration file.

[0094] In the embodiment of the present application, the adjusted copy of the configuration file is determined as the target configuration file, and the file format of the target configuration file is set to XML format. By setting the target configuration file to XML format, the purpose is to facilitate technicians to directly open the configuration file in the browser to configure the function, making the configuration process of the device function more convenient, even for less experienced technicians can complete the corresponding function configuration, and also reducing the difficulty of device function development.

[0095] The method provided in the embodiment of the present application configures the functional components of the configuration file copy of the original configuration file in the browser without writing code. The functional components only need to be configured according to the user's configuration requirements, which lowers the development threshold of the configuration file and improves the development efficiency of the configuration file of the new model. At the same time, the configuration in the form of configuration files facilitates subsequent maintenance.

[0096] Step S14, pull the code file, add the target configuration file and the code file to the built-in resource package, and deploy the built-in resource package to the target device corresponding to the target model, wherein the code file includes the function code corresponding to each functional component, and the target device is used to pull the corresponding function code from the code file according to the target function component in the configuration file to render the function menu.

[0097] In the embodiment of the present application, before deploying the built-in resource package to the target device corresponding to the target model, the method further includes the following steps C1-C4:

[0098] Step C1, triggering the verification mechanism to take effect based on the target configuration file.

[0099] In an embodiment of the present application, after obtaining the target configuration file of the target model, it is detected whether the user triggers a submission operation. If the submission operation triggered by the user is detected, a trigger verification mechanism is activated, and the verification mechanism is used to verify the format and function of the target configuration file.

[0100] Step C2, in response to the verification mechanism taking effect, the format of the target functional component in the target configuration file is verified;

[0101] In the embodiment of the present application, the response verification mechanism takes effect, first traverses the format of the target function component in the target configuration file, determines whether the format of the target function component is correct, and if there is a target function component with an incorrect format, generates a prompt message to prompt the user to adjust the target function component with the incorrect format. If there is no target function component with an incorrect format, it is determined that the format verification passes.

[0102] Step C3, if the format verification passes, verify the function of the target functional component in the target configuration file;

[0103] In the embodiment of the present application, when the format check passes, the function of the target functional component in the target configuration file is checked, specifically, whether the functional parameters of the functional component in the target configuration file match the standard functional parameters. If the functional parameters match the standard functional parameters, it means that the functional parameters are correct, indicating that the target functional component can be used normally later. If the functional parameters do not match the standard functional parameters, it means that the functional parameters are abnormal, indicating that the target functional component may not be used later.

[0104] Step C4: if the functional component passes the functional verification, a configuration package is generated based on the target configuration file.

[0105] After the target configuration file corresponding to the new model is configured, the method provided in the embodiment of the present application automatically verifies the format and parameters of the functional components in the target configuration file by triggering the verification mechanism, thereby ensuring that the subsequent new model devices can normally perform the rendering of the function menu according to the target configuration file.

[0106] In an embodiment of the present application, the target configuration file is deployed to the target device corresponding to the target model, including: adding the target configuration file and the code file to the built-in resource package; deploying the built-in resource package to the target device. Specifically, the pulled code file includes the function code corresponding to each functional component. It can be understood that the code file is a complete function code corresponding to the functional component. Add the code file and the target configuration file to the built-in resource package, deploy the built-in resource package to the target device, and the target device can subsequently directly obtain the corresponding function code according to the target functional component in the target configuration file to render the corresponding function menu.

[0107] Therefore, the method provided in the embodiment of the present application only needs to configure the functional components, without the need to write functional codes. It only needs to deploy the built-in resource package carrying the configuration files and code files on the target device, and the device can quickly complete the rendering of the function menu by matching the corresponding function codes according to the configured functional components.

[0108] When facing the demand for new models proposed by users or the market, the method provided in the embodiment of the present application only needs to adjust the functional components in the original configuration file according to the configuration requirements of the new model to complete the configuration of the new model device functions, thereby reducing the development time of the device functions. At the same time, there is no need for R&D personnel to create a new code branch for the new model, which reduces the development difficulty and improves the configuration efficiency of the new model device functions.

[0109] Figure 3 is a flowchart of a method for rendering a function menu according to an embodiment of the present invention. Figure 3 As shown, an embodiment of the present invention provides a method for rendering a function menu, the method comprising:

[0110] Step S21, receiving a function menu rendering request, and triggering a rendering mechanism to take effect based on the function menu rendering request, wherein the rendering mechanism is used to render a function menu of a target device.

[0111] The method provided in the embodiment of the present application is applied to the target device, that is, the device of the target model. After the target device is powered on and running, the user can send a function menu rendering request. After receiving the function menu rendering request, the target device triggers the rendering mechanism to take effect, that is, automatically enters the rendering process of the function menu.

[0112] Step S22, reading the target model corresponding to the target device.

[0113] In the embodiment of the present application, the target device can read the target model from pre-stored device attribute information.

[0114] Step S23, reading the target configuration file corresponding to the target model from the pre-deployed built-in resource package, and parsing the target configuration file to obtain the target functional components, wherein the target configuration file is obtained by adjusting the functional components in the original configuration file based on the configuration requirements of the target model.

[0115] In the embodiment of the present application, the target device can query the target configuration file corresponding to the target model from the built-in resource package deployed at the factory, and parse the target function component carried by it from the target configuration file. The target function component can be a "bass test component", a "touch disable component", etc.

[0116] Step S24, rendering a function menu corresponding to the target device based on the target function component and the code file in the built-in resource package.

[0117] In an embodiment of the present application, a function menu corresponding to a target device is rendered based on a target function component and a code file in a built-in resource package, including: reading a function code corresponding to the target function component from a code file in the built-in resource package; and compiling the function code to render a function menu corresponding to the target device.

[0118] Specifically, the rendering process is as follows: first, render the first-level menu, then enter each sub-page in the first-level menu, obtain the corresponding target function component from the target configuration file according to the attributes of the sub-page, and read the function code corresponding to the target function component from the code file, and compile based on the function code to render the corresponding function to the sub-page. After all the sub-pages of the first-level menu are rendered, the function menu of the target device is obtained.

[0119] The method provided in the embodiment of the present application deploys the built-in resource package on the target device when the target device leaves the factory. When the target device subsequently renders the function menu, it directly reads the configuration file that matches its own model from the built-in resource package, and uses the configuration file to read the corresponding function code from the code file of the built-in resource package, compiles based on the function code, and completes the rendering of the function menu. The rendering efficiency of the function menu is improved.

[0120] In this embodiment, a device for configuring device functions is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0121] This embodiment provides a device configuration apparatus for a device function, such as Figure 4 As shown, including:

[0122] An acquisition module 41 is used to acquire a device function configuration task, wherein the device function configuration task carries a target model of the device function to be configured and a configuration requirement of the target model;

[0123] A display module 42, configured to pull and display an original configuration file based on a browser installed on the configuration device, wherein the original configuration file includes a plurality of functional components;

[0124] The processing module 43 is used to adjust the functional components in the original configuration file according to the configuration requirements, and determine the adjusted original configuration file as the target configuration file;

[0125] The deployment module 44 is used to pull the code file, add the target configuration file and the code file to the built-in resource package, and deploy the built-in resource package to the target device corresponding to the target model, wherein the code file includes the function code corresponding to each functional component, and the target device is used to pull the corresponding function code from the code file according to the target function component in the configuration file to render the function menu.

[0126] In an embodiment of the present application, the device function configuration apparatus also includes: a parsing module, used to obtain a device function configuration file, wherein the device function configuration file includes a function code corresponding to each function item; parse the key fields of the function code in the device function configuration file, and abstract the key fields into function components corresponding to the function items; and construct an original configuration file based on the function components.

[0127] In an embodiment of the present application, the processing module 43 is used to copy the original configuration file, obtain a configuration file copy corresponding to the original configuration file, and display the configuration file copy on a browser installed on a configuration device; based on the browser installed on the configuration device, adjust the functional components in the configuration file copy according to the configuration requirements, and use the target model as the file name of the configuration file copy to obtain an adjusted configuration file copy; and determine the adjusted configuration file copy as the target configuration file.

[0128] In an embodiment of the present application, the processing module 43 is used to add functional components corresponding to the configuration requirements in the configuration file copy; remove functional components corresponding to the configuration requirements in the configuration file copy; adjust the arrangement order of the functional components in the configuration file copy according to the configuration requirements; and modify the component names of the functional components in the configuration file copy according to the configuration requirements.

[0129] In the embodiment of the present application, the file format of the original configuration file is XML format.

[0130] In an embodiment of the present application, the configuration device of the device function also includes: a verification module, which is used to trigger the verification mechanism to take effect based on the target configuration file; in response to the verification mechanism taking effect, the format of the target configuration file is verified; if the format verification passes, the function of each functional component in the target configuration file is verified; if the function verification of the functional component passes, a configuration package is generated based on the target configuration file.

[0131] In the embodiment of the present application, the deployment module 44 is used to add the target configuration file to the built-in resource package; and deploy the built-in resource package to the target device.

[0132] In this embodiment, a rendering device for a function menu is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0133] This embodiment provides a rendering device for a function menu, such as Figure 5 As shown, including:

[0134] The receiving module 51 is used to receive the built-in resource package sent by the configuration device, and trigger the rendering mechanism to take effect based on the built-in resource package, wherein the rendering mechanism is used to render the function menu of the target device;

[0135] A reading module 52, used for reading a target model corresponding to a target device;

[0136] The parsing module 53 is used to read the target configuration file corresponding to the target model from the pre-deployed built-in resource package, and parse the target configuration file to obtain the target functional components, wherein the target configuration file is obtained by adjusting the functional components in the original configuration file based on the configuration requirements of the target model by the configuration device;

[0137] The rendering module 54 is used to render the function menu corresponding to the target device based on the target function component and the code file in the built-in resource package.

[0138] In the embodiment of the present application, the rendering module 54 is used to read the function code corresponding to the target function component from the code file of the built-in resource package; compile the function code to render the function menu corresponding to the target device.

[0139] See also Figure 6 , Figure 6 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 6 As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system).

[0140] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.

[0141] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.

[0142] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created by the use of a computer device based on the presentation of a small program landing page, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0143] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.

[0144] The computer device further comprises a communication interface 30 for the computer device to communicate with other devices or a communication network.

[0145] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.

[0146] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A method for configuring a device function, characterized in that: Applied to configuring a device, the method comprises: Acquire a device function configuration task, wherein the device function configuration task carries a target model of the device function to be configured and a configuration requirement of the target model; Pulling and displaying an original configuration file based on a browser installed on the configuration device, wherein the original configuration file includes a plurality of functional components; Adjusting the functional components in the original configuration file according to the configuration requirements, and determining the adjusted original configuration file as the target configuration file; Pull the code file, add the target configuration file and the code file to the built-in resource package, and deploy the built-in resource package to the target device corresponding to the target model, wherein the code file includes the function code corresponding to each functional component, and the target device is used to pull the corresponding function code from the code file according to the target function component in the configuration file to render the function menu.

2. The method according to claim 1, characterized in that Before acquiring the device function configuration task, the method further includes: Obtaining a device function configuration file, wherein the device function configuration file includes a function code corresponding to each function item; Parsing the key fields of the function code in the device function configuration file, and abstracting the key fields into function components corresponding to the function items; The original configuration file is constructed based on the functional components.

3. The method according to claim 2, characterized in that The step of adjusting the functional components in the original configuration file according to the configuration requirements and determining the adjusted original configuration file as the target configuration file includes: Copying the original configuration file to obtain a configuration file copy corresponding to the original configuration file, and displaying the configuration file copy on the browser; Based on the browser, adjusting the functional components in the configuration file copy according to the configuration requirements, and using the target machine model as the file name of the configuration file copy to obtain an adjusted configuration file copy; Identify the adjusted copy of the profile as the target profile.

4. The method according to claim 3, characterized in that The adjusting the functional components in the configuration file copy according to the configuration requirements includes one or more of the following: Adding a functional component corresponding to the configuration requirement to the copy of the configuration file; Removing the functional components corresponding to the configuration requirements in the copy of the configuration file; Adjusting the arrangement order of functional components in the copy of the configuration file according to the configuration requirements; Modify the component name of the functional component in the copy of the configuration file according to the configuration requirements.

5. The method according to claim 1, characterized in that The file format of the original configuration file is XML format.

6. The method according to claim 1, characterized in that Before deploying the built-in resource package to the target device corresponding to the target model, the method further includes: Triggering a verification mechanism to take effect based on the target configuration file; In response to the verification mechanism taking effect, verifying the format of the target functional component in the target configuration file; If the format check passes, verifying the function of the target functional component in the target configuration file; When the function verification of the functional component passes, a configuration package is generated based on the target configuration file.

7. A method for rendering a function menu, characterized in that: Applied to a target device, the method comprises: Receiving a function menu rendering request, and triggering a rendering mechanism to take effect based on the function menu rendering request, wherein the rendering mechanism is used to render the function menu of the target device; Read the target model corresponding to the target device; Reading a target configuration file corresponding to the target model from a pre-deployed built-in resource package, and parsing the target configuration file to obtain a target functional component, wherein the target configuration file is obtained by adjusting the functional components in the original configuration file by the configuration device based on the configuration requirements of the target model; A function menu corresponding to the target device is rendered based on the target function component and the code file in the built-in resource package.

8. The method according to claim 7, characterized in that The rendering of the function menu corresponding to the target device based on the target function component and the code file in the built-in resource package includes: Read the function code corresponding to the target function component from the code file of the built-in resource package; The function code is compiled to render a function menu corresponding to the target device.

9. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the method according to any one of claims 1 to 8 by executing the computer instructions.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 8.