Function control method, function control device, storage medium and electronic device

By receiving status change events in the terminal device and searching the functional relationship library, the functional status adjustment strategy is determined, which solves the problem of functional control efficiency and accuracy, simplifies the software code complexity and adapts to the development of functional diversification.

CN113918246BActive Publication Date: 2024-08-27GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111258420.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-27
Publication Date
2024-08-27
Estimated Expiration
2041-10-27

AI Technical Summary

Technical Problem

In the existing technology, in terminal equipment with numerous functions, the efficiency and accuracy of function control are reduced, and the maintenance cost of software code logic increases, making it difficult to control various functions simply and effectively.

Method used

By receiving the status change event of the target function, the relationship between the target function and the associated function is found in the pre-configured functional relationship library, the status adjustment strategy is determined, and the status adjustment process is simplified.

Benefits of technology

It achieves fast and accurate function status adjustment, reduces the complexity and calculation time of logical judgment, and adapts to the development trend of functional diversification and complexity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113918246B
    Figure CN113918246B
Patent Text Reader

Abstract

The present disclosure provides a function control method, a function control device, a computer-readable storage medium and an electronic device, and relates to the field of computer technology. The function control method comprises: receiving a state change event for a target function; searching for the relationship between the target function and the associated function of the target function in a pre-configured function relationship library; and determining the state adjustment strategy of the target function or the associated function based on the state change event, the relationship between the target function and the associated function. The present disclosure improves the efficiency and accuracy of function control.
Need to check novelty before this filing date? Find Prior Art

Description

Background Art

[0002] With the development of diversified terminal devices, terminal devices can provide more and more functions. For example, the camera application can provide a flash function to facilitate users to shoot in poor lighting conditions; it can provide an image blur processing function to highlight the focus area of ​​the captured image; it can provide a beauty mode or filter function to beautify the captured image; it can also provide an HDR (High-Dynamic Range) mode to enrich the details of the captured image, etc. However, there is often a logical mutual exclusion relationship between the above functions, and some functions cannot be turned on at the same time. For example, in order to avoid the influence of the flash on the imaging effect, when the flash is turned on, the HDR mode cannot be turned on at the same time; or when the HDR mode is turned on, the flash cannot be turned on at the same time.

[0003] Therefore, the prior art usually judges the logical relationship between functions in turn through a step-by-step judgment process to determine whether different functions are compatible. However, as the functions of the device continue to increase, the judgment process will become lengthy and complicated, which often leads to reduced function control efficiency and accuracy; in addition, it will also increase the maintenance cost of software code logic. Therefore, how to simply and effectively control various functions in the terminal device is a problem that needs to be solved urgently in the prior art. Summary of the invention

[0004] The present disclosure provides a function control method, a function control device, a computer-readable storage medium and an electronic device, thereby improving, at least to a certain extent, the problem in the prior art that it is difficult to maintain high function control efficiency and accuracy when there are many functions.

[0005] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.

[0006] According to a first aspect of the present disclosure, a function control method is provided, comprising: receiving a state change event for a target function; searching for a relationship between the target function and an associated function of the target function in a preconfigured function relationship library; and determining a state adjustment strategy for the target function or the associated function based on the state change event, the relationship between the target function and the associated function.

[0007] According to a second aspect of the present disclosure, a function control device is provided, including: an event receiving module, used to receive a state change event for a target function; a relationship search module, used to search for the relationship between the target function and the associated function of the target function in a pre-configured function relationship library; a policy determination module, used to determine the state adjustment policy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function.

[0008] According to a third aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the function control method of the first aspect and possible implementation methods thereof are implemented.

[0009] According to a fourth aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing executable instructions of the processor, wherein the processor is configured to execute the function control method of the first aspect and possible implementation thereof by executing the executable instructions.

[0010] The technical solution disclosed in this disclosure has the following beneficial effects:

[0011] Receive a state change event for a target function; search for the relationship between the target function and the associated function of the target function in a pre-configured function relationship library; determine the state adjustment strategy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function. On the one hand, this exemplary embodiment proposes a new function control method, which does not need to go through a lengthy multi-level logic judgment process to determine the state adjustment strategy of different functions. It can return the logical relationship of all associated functions associated with the target function by searching in a pre-configured function relationship library. According to the logical relationship, the function is effectively and quickly adjusted in state. The adjustment process simplifies the complexity of the software code, saves a lot of logic judgment operation time, and has high accuracy. On the other hand, this exemplary embodiment can convert the relationship between functions into a static function relationship library. In the case of a large number of functions, the logical relationship between functions can still be quickly determined based on the function relationship library, which can adapt to the development trend of functional diversification and complexity and be applied to different terminal devices.

[0012] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.

[0014] Figure 1 A flow chart showing a function control method of the prior art;

[0015] Figure 2 A schematic diagram showing a system architecture in this exemplary embodiment;

[0016] Figure 3 A structural diagram of an electronic device according to the exemplary embodiment is shown;

[0017] Figure 4 A flow chart showing a function control method in this exemplary embodiment;

[0018] Figure 5 A sub-flow chart showing a function control method in this exemplary embodiment;

[0019] Figure 6 Another sub-flow chart of a function control method in this exemplary embodiment is shown;

[0020] Figure 7 A flow chart showing another function control method in this exemplary embodiment;

[0021] Figure 8 A structural block diagram of a function control device in this exemplary embodiment is shown. DETAILED DESCRIPTION

[0022] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the example embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.

[0023] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.

[0024] In the prior art, the function control process is explained by taking the flash, HDR mode and beauty mode as examples. Figure 1 As shown, the function control method may include the following steps:

[0025] Step S110, turning on the flashlight;

[0026] Step S120, determining whether the flash mode and the HDR mode are mutually exclusive;

[0027] If it is not a mutually exclusive relationship, executing step S130, keeping the HDR mode switch unchanged;

[0028] If it is a mutually exclusive relationship, executing step S140, determining whether the HDR mode is turned on;

[0029] If the HDR mode is on, executing step S150, turning off the HDR mode switch;

[0030] If the HDR mode is off, continue to execute step S160 to determine whether the flash mode and the beauty mode are mutually exclusive;

[0031] If it is not a mutually exclusive relationship, execute step S180 to keep the switch of the beauty mode unchanged;

[0032] If it is a mutually exclusive relationship, executing step S170, determining whether the beauty mode is turned on;

[0033] If it is in the on state, execute step S190 to turn off the switch of the beauty mode.

[0034] In the prior art, when controlling the functions of a terminal device, it is necessary to traverse all related functions to determine whether a certain function has a logically mutually exclusive relationship with other functions. From the above steps, it can be seen that this judgment process will become rapidly complicated as the number of functions increases. When there are a large number of functions that require logical judgment, the logic maintenance cost of the software code will increase, and the complexity of the judgment process will cause abnormalities in the judgment process, affecting the final control result of the function.

[0035] In view of the above problems, an exemplary embodiment of the present disclosure provides a function control method. Figure 2 1 shows a system architecture diagram of the operating environment of this exemplary embodiment. Figure 2 As shown, the system architecture 200 may include a terminal device 210 and a server 220, which communicate with each other through a network. The terminal device 210 may include but is not limited to a smart phone, a tablet computer, a game console, a camera or a wearable device, etc. The server 220 may be a backend server that provides Internet services.

[0036] The function control method provided in the embodiment of the present disclosure can be directly executed by the terminal device 210, for example, the terminal device 210 receives the state change event of the target function and searches for the relationship between the target function and the related function, so as to adjust the state of the function; it can also be executed by the server 220, for example, after the terminal device 210 receives the state change event of the target function, it sends a relationship search request to the server 220, and the server 220 executes the relationship between the target function and the related function, and returns the state adjustment instruction to the terminal device 210, and the terminal device 210 adjusts the state of the function, etc. The present disclosure does not make specific limitations on this.

[0037] An exemplary embodiment of the present disclosure provides an electronic device for implementing a function control method, which may be Figure 2 The terminal device 210 and the server 220 in the embodiment of the present invention are as follows. The electronic device at least comprises a processor and a memory, the memory is used to store executable instructions of the processor, and the processor is configured to execute the function control method by executing the executable instructions.

[0038] Below Figure 3 The mobile terminal 300 in the embodiment is taken as an example to exemplify the structure of the electronic device. It should be understood by those skilled in the art that, in addition to the components specifically used for mobile purposes, Figure 3 The construction in can also be applied to fixed type equipment.

[0039] like Figure 3As shown, the mobile terminal 300 may specifically include: a processor 310, an internal memory 321, an external memory interface 322, a USB (Universal Serial Bus) interface 330, a charging management module 340, a power management module 341, a battery 342, an antenna 1, an antenna 2, a mobile communication module 350, a wireless communication module 360, an audio module 370, a speaker 371, a receiver 372, a microphone 373, an earphone interface 374, a sensor module 380, a display screen 390, a camera module 391, an indicator 392, a motor 393, a button 394 and a SIM (Subscriber Identification Module) card interface 395, etc.

[0040] The processor 310 may include one or more processing units, for example, the processor 310 may include an AP (Application Processor), a modem processor, a GPU (Graphics Processing Unit), an ISP (Image Signal Processor), a controller, an encoder, a decoder, a DSP (Digital Signal Processor), a baseband processor and / or an NPU (Neural-Network Processing Unit), etc. The encoder may encode (i.e., compress) the image or video data; the decoder may decode (i.e., decompress) the bitstream data of the image or video to restore the image or video data.

[0041] In some implementations, the processor 310 may include one or more interfaces, and may be connected to other components of the mobile terminal 300 through different interfaces.

[0042] The internal memory 321 may be used to store computer executable program codes, which may include instructions. The internal memory 321 may include volatile memory, non-volatile memory, etc. The processor 310 executes various functional applications and data processing of the mobile terminal 300 by running instructions stored in the internal memory 321 and / or instructions stored in a memory provided in the processor.

[0043] The external memory interface 322 can be used to connect an external memory, such as a Micro SD card, to expand the storage capacity of the mobile terminal 300. The external memory communicates with the processor 310 through the external memory interface 322 to implement a data storage function, such as storing music, video and other files.

[0044] The USB interface 330 is an interface that complies with USB standard specifications and can be used to connect a charger to charge the mobile terminal 300, or to connect headphones or other electronic devices.

[0045] The charging management module 340 is used to receive charging input from a charger. While charging the battery 342, the charging management module 340 can also power the device through the power management module 341; the power management module 341 can also monitor the status of the battery.

[0046] The wireless communication function of the mobile terminal 300 can be implemented by antenna 1, antenna 2, mobile communication module 350, wireless communication module 360, modulation and demodulation processor and baseband processor. Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. The mobile communication module 350 can provide solutions for wireless communications including 2G / 3G / 4G / 5G applied to the mobile terminal 300. The wireless communication module 360 ​​can provide wireless communication solutions including WLAN (Wireless Local Area Networks) (such as Wi-Fi (Wireless Fidelity) network), BT (Bluetooth), GNSS (Global Navigation Satellite System), FM (Frequency Modulation), NFC (Near Field Communication), IR (Infrared) and the like applied to the mobile terminal 300.

[0047] The mobile terminal 300 can realize the display function and display the user interface through the GPU, the display screen 390 and the AP. The mobile terminal 300 can realize the shooting function through the ISP, the camera module 391, the encoder, the decoder, the GPU, the display screen 390 and the AP, and can also realize the audio function through the audio module 370, the speaker 371, the receiver 372, the microphone 373, the headphone interface 374 and the AP.

[0048] The sensor module 380 may include a depth sensor 3801 , a pressure sensor 3802 , a gyroscope sensor 3803 , an air pressure sensor 3804 , etc., to realize different sensing detection functions.

[0049] The indicator 392 may be an indicator light, which may be used to indicate the charging status, power change, message, missed call, notification, etc. The motor 393 may generate a vibration prompt, or may be used for touch vibration feedback, etc. The buttons 394 include a power button, a volume button, etc.

[0050] The mobile terminal 300 may support one or more SIM card interfaces 395 for connecting a SIM card to implement functions such as calls and data communications.

[0051] Figure 4 An exemplary process of the function control method is shown, which can be executed by the terminal device 310 or the server 320, including the following steps S410 to S430:

[0052] Step S410: receiving a state change event for a target function.

[0053] Among them, the target function refers to the function in the application that the current user or system needs to operate or adjust. For example, when the user opens the camera application to take a photo, the flash needs to be turned on, and the flash is the target function; or when the user performs a blur function on the image in the image processing application, the virtual function is the target function; or when the user records in the recording application, the microphone function is the target function, etc. The state change event refers to the change demand operation initiated for the state of the target function or the state event that has changed the state, such as the change operation of the flash from the off state to the on state, the change operation of the HDR mode from the off state to the on state, the change operation of the portrait mode from the on state to the off state, etc.; or the flash has been switched from the off state to the on state, etc. Among them, the operation of changing the state can include multiple ways, such as the user can trigger the change of the state of the target function by clicking the function button, or can trigger the change of the state of the target function through voice interaction, etc. When the terminal receives the state change event for the target function, according to the attributes of the actual state change event, it can be considered that the current user or system has the need to change the state of the target function, or the state of the target function has changed.

[0054] Step S420: searching for the relationship between the target function and the associated functions of the target function in a pre-configured function relationship library.

[0055] Among them, the associated function refers to a function that has an associated relationship with the target function. For example, in the camera application, users can use multiple functions such as flash, HDR mode, beauty mode, filter, background blur, etc. when taking pictures. When the flash is the target function, the associated function can be HDR mode, beauty mode, filter, background blur, etc.; when the HDR mode is the target function, the associated function can be flash, beauty mode, filter, background blur, etc. Other functions that are not related to the realization of the target function do not belong to the associated function. For example, the flash in the camera application is irrelevant to the variable speed playback function in the audio and video application, so the variable speed playback does not belong to the associated function of the flash. The associated function can belong to the same application as the target function, for example, the flash and HDR both belong to the camera application; the associated function can also belong to a different application from the target function, such as the beauty mode in the camera application and the filter function in other image processing applications; the associated function can also be a hardware function, such as the microphone function used in both the video application and the recording application, that is, a hardware function of the terminal itself.

[0056] The function relationship library may refer to a database including the logical relationship between different functions, which may be a pre-configured function relationship file. The exemplary embodiment may record the logical relationship between each function and its associated functions in the form of a table, and generate a function relationship library based on the logical relationship. The logical relationship may include mutually exclusive relationships between functions, such as the flash function and the HDR mode function cannot be turned on at the same time, which is a mutually exclusive relationship; or compatible relationships, such as the beauty and filter functions can be turned on at the same time, which is a non-mutually exclusive relationship or a compatible relationship; or other relationships, such as when a certain function is turned on, another function will also be turned on, etc.

[0057] When the system receives a state change event for a target function, it can search for the relationship between the target function and the associated functions of the target function in a pre-configured function relationship library. For example, after receiving an operation to turn on the flash, it can search for the relationship between the flash and HDR mode, beauty mode, filter, background blur and other functions in the function relationship library to determine the logical relationship with these associated functions.

[0058] In the function relationship library, the relationship between the target function and the associated function of the target function can be stored in the form of coding, for example, in the form of binary coding. When it is a mutually exclusive relationship, it can be coded as "1", and when it is a non-mutually exclusive relationship, it can be coded as "0", etc. The coding form is not limited to this, and the present disclosure does not make specific limitations on this. The relationship between the found target function and the associated function of the target function can also be returned in the form of coding. For example, when searching for the relationship between the flash and the HDR mode and the beauty mode, the returned code includes "10", which means that the flash is mutually exclusive with the HDR mode, but not mutually exclusive with the beauty mode, etc. Among them, the search can be performed according to the identification of the target function. For example, this exemplary embodiment can binary encode all searchable functions, and then the relationship between the target function and the associated function can be determined by searching the binary code of the target function.

[0059] Step S430: determining a state adjustment strategy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function.

[0060] After receiving a state change event for a target function, this exemplary embodiment can determine a state adjustment strategy for the target function and the associated functions by finding the relationship between the target function and the associated functions, and then execute a function state adjustment process. This exemplary embodiment can determine the state adjustment strategy of the target function and the associated function according to the state change event, the relationship between the target function and the associated function, and the current state of the associated function, wherein, for the associated function that is in a non-mutually exclusive relationship with the target function, it can be determined according to actual needs or system performance to adjust its state or keep its state unchanged; and for the associated function that is in a mutually exclusive relationship with the target function, the state adjustment strategy can specifically include: first, when the state change event is an event that triggers the state of the target function to be changed, such as the operation of the user clicking the flashlight on button, and the current state of the associated function does not need to be adjusted, for example, when the user clicks the flashlight on button, the current HDR mode switch is in the off state, then only the target function can be adjusted without adjusting the state of the associated function, for example, only the flashlight needs to be turned on; second, when the state change event is an event that triggers the state of the target function to be changed, and the current state of the associated function needs to be adjusted, such as when the HDR mode switch is in the on state and idle state, wherein the idle state indicates that the function is currently in a switch adjustable state, for example, although the HDR mode is in the on state, it is not currently used, or has not been used for a period of time, or the current user is shooting When shooting, it is not necessary to use the HDR mode, etc., then it is necessary to adjust the status of both the target function and the associated function, such as turning on the flash and turning off the HDR mode switch at the same time; third, when the state change event is that the state of the target function has changed, for example, the user has turned on the flash, at this time when the current state of the associated function needs to be adjusted, then only the state of the associated function can be adjusted, such as turning off the HDR mode switch; fourth, when the state change event is an event that triggers the change of the state of the target function, but at this time the current state of the associated function cannot be adjusted, where the "cannot be adjusted" means that the associated function is in a non-idle state such as running or an adaptive function mode adapted to the current scene, then it can be determined not to adjust the state of the target function and the associated function, for example, when the user has turned on the HDR mode as needed or is using the HDR mode, clicks the button to turn on the flash, then the flash is not turned on, and the HDR mode is not turned off, that is, the current function state is kept unchanged. In this case, a prompt message can also be sent to the user according to actual needs, indicating that the function state cannot be updated at present, or confirming the user's function adjustment requirements, whether to confirm the update of the function state, etc. The specific adjustment strategy can be analyzed and determined according to the actual situation.

[0061] In an exemplary embodiment, the above step S430 may include:

[0062] When the state change event is enabling the target function, according to the relationship between the target function and the associated functions, the state of the associated functions that are mutually exclusive with the target function is adjusted to disabled, and the target function is enabled.

[0063] Among them, enabling the target function can mean that the state of the target function is currently off, and the user or system has the need to enable the target function, but it has not been enabled yet. At this time, according to the relationship between the target function and the associated functions, the state of the associated functions that are mutually exclusive with the target function can be adjusted to disabled so that they cannot be turned on, and the target function can be enabled. For example, after receiving the operation of turning on the flash, the HDR mode is disabled, and the HDR mode cannot be turned on during the process of turning on the flash. Only when a state change event of turning off the flash is received, the state of the associated function can be readjusted according to the state change event.

[0064] It should be noted that in actual use, if after enabling the target function, the user has the need to enable an associated function that is mutually exclusive with the target function, for example, when the user turns on the flash to take a photo, and clicks on the HDR mode option and wants to turn on the HDR mode, the terminal can send a prompt message to the user to ask the user whether to turn on the HDR mode and turn off the flash; or ignore the user's operation and continue to use the flash; or prompt the user that the HDR mode cannot be turned on at present, etc.

[0065] In summary, in this exemplary embodiment, a state change event for a target function is received; in a pre-configured function relationship library, the relationship between the target function and the associated function of the target function is searched; and according to the relationship between the state change event, the target function and the associated function, the state adjustment strategy of the target function or the associated function is determined. On the one hand, this exemplary embodiment proposes a new function control method, which does not need to go through a lengthy multi-level logic judgment process to determine the state adjustment strategy of different functions. Only by searching in a pre-configured function relationship library, the logical relationship of all associated functions associated with the target function can be returned. According to the logical relationship, the function is effectively and quickly adjusted in state. The adjustment process simplifies the complexity of the software code, saves a lot of logic judgment operation time, and has high accuracy. On the other hand, this exemplary embodiment can convert the relationship between functions into a static function relationship library. In the case of a large number of functions, the logical relationship between functions can still be quickly determined based on the function relationship library, which can adapt to the development trend of functional diversification and complexity and be applied to different terminal devices.

[0066] In an exemplary embodiment, the target function and the associated function are both functions within the target application set; and / or the target function is a function within the target application set, and the associated function is a function of the hardware module.

[0067] Among them, the target application set refers to the collection of all or part of the applications in the terminal device, the target function can be any function in the target application set, for example, it can be a function in the camera application, it can also be a function in the recording application, etc., and the associated function of the target function can include all other functions in the target application set except the target function. Specifically, it can belong to the same application as the target function, such as both are functions in the camera, or it can belong to different applications, for example, the target function is a function in the camera application, and the associated function belongs to a function in the recording application, etc.

[0068] In addition, the associated function can also be a function of a hardware module. For example, in a camera application, the microphone function is an associated function of the video recording function. In a recording application, the microphone function is also an associated function of the audio recording function. Among them, the microphone function is a function of the hardware module of the terminal device, not a function of any application.

[0069] In an exemplary embodiment, if Figure 5 As shown, the above functional relationship library can be established by the following steps:

[0070] Step S510, for each function in the target application set, generating relationship data corresponding to each function according to the relationship between each function and its associated functions;

[0071] Step S520: establishing a function relationship library of the target application set based on the identifier of each function in the target application set and the relationship data corresponding to each function.

[0072] This exemplary embodiment can take each function in the target application set as a benchmark, generate relationship data between functions according to the relationship between each function and its associated functions, and establish a function relationship library for the target application set based on the identifier of each function and the relationship data corresponding to each function. The identifier of the function can refer to the code that reflects the function. For example, each function in the target application set can be encoded, such as function A is encoded as "0000001", function B is encoded as "0000010", function C is encoded as "0000100", and function D is encoded as "0001000". Further, according to the identifier of each function and the corresponding relationship data, a function relationship library of the target application set can be established. The function relationship library can include multiple relationship sub-libraries, each of which corresponds to the relationship data of each application in the target application set; the function relationship library can also be a library integrated according to the relationship data of all applications in the target application set, etc. The form of the function relationship library is not specifically limited in this disclosure.

[0073] Furthermore, the above-mentioned relationship data may include a relationship value string, and the relationship value string may refer to coded data that can represent the relationship data. Then the above-mentioned step S510 may include:

[0074] A relational numerical string corresponding to each function is generated according to whether each function and its associated functions are mutually exclusive. The first numerical value in the relational numerical string represents a mutually exclusive relationship, and the second numerical value in the relational numerical string represents a non-mutually exclusive relationship.

[0075] Among them, the first value and the second value are both coded values, and different numerical representations can be used according to different coding methods. For example, in this exemplary embodiment, the first value can be "1" to indicate a mutually exclusive relationship, and the second value can be "2" to indicate a non-mutually exclusive relationship, such as a compatible relationship or other relationship. Each value in the relationship value string can represent the relationship data between a function and another function. For example, as shown in Table 1 below, a relationship table showing whether function E and function F are mutually exclusive with other associated functions is shown:

[0076] Table 1

[0077] Function A Function B Function C Function D Function E 0 1 1 0 Function F 1 0 0 1

[0078] According to Table 1 above, whether function E and other functions A, B, C, and D are mutually exclusive, a relational value string corresponding to function E can be generated as "000110", indicating that function E is mutually exclusive with function B and function C, but non-mutually exclusive with function A and function D; according to whether function F is mutually exclusive with function A, B, function C, and function D, a relational value string corresponding to function F can be generated as "001001", indicating that function F is mutually exclusive with function A and function D, but non-mutually exclusive with function B and function C, wherein the character length of the specific relational value string can be customized as needed, and the present disclosure does not make specific limitations on this.

[0079] It should be noted that when the target application set has a total of n functions, the relationship value of each function can be set to occupy k bits. For example, let k=1 as mentioned above, and "1" and "0" are used to represent mutually exclusive or non-mutually exclusive relationships. Then the relationship value string corresponding to each function can be k*n bits, one of which can be left to represent the relationship between itself, or k*(n-1) bits, etc. The present disclosure does not make specific limitations on this.

[0080] The corresponding function relationship library can be generated according to the generated relationship value string, and the logical relationship between the function and other functions can be determined by parsing the relationship value string in the function relationship library.

[0081] In addition, in this exemplary embodiment, in addition to the relationship data between the above functions, the function relationship library may also include other information. For example, when the function relationship library is a function relationship configuration file, the function relationship configuration file may include one or more of function relationship, configuration file information, function binary bit information, and function relationship information. The configuration file information, function binary bit information, and function relationship information may be represented by the following exemplary code:

[0082] Configuration file information:

[0083] Version: 3.2.1 / / Indicates the version number of the functional relationship configuration file

[0084] Date: 2021 / 09 / 20 11:20:30 / / indicates the date and time when the functional relationship profile was generated

[0085] Source: Tools v1.2.0 / / Indicates the source of the functional relationship configuration file, such as automatically generated by Tools v1.2.0 software on the computer.

[0086] Function binary bit information:

[0087] Function A: 0000001 / / Function A is represented by the 0th bit in binary

[0088] Function B: 0000010 / / Function B is represented by the first bit of binary

[0089] Function C: 0000100 / / Function C is represented by the second bit in binary

[0090] Function D: 0001000 / / Function D is represented by the third bit in binary

[0091] Functional relationship information:

[0092] Mutual exclusion: 1 / / Mutual exclusion is represented by binary 1

[0093] Not mutually exclusive: 0 / / Not mutually exclusive is represented by binary 0

[0094] In an exemplary embodiment, if Figure 6 As shown, the above step S510 may further include the following steps:

[0095] Step S610, obtaining a function requirement document, and determining, according to the function requirement document, unstructured relationship information between each function and associated functions of each function in the target application set;

[0096] Step S620: convert the unstructured relationship information into structured relationship information, and generate relationship data corresponding to each function according to the structured relationship information.

[0097] In order to improve the automation of generating or maintaining the function relationship library, this exemplary embodiment may generate relationship data corresponding to each function by acquiring a function requirement file, loading the function requirement file, and extracting relationship information from the function requirement file.

[0098] The functional requirements document refers to the requirement information that exists in the development, maintenance or update phase of each project, which can be expressed in the form of a list, such as Table 2 or Table 3 below:

[0099] Table 2

[0100] Feature 1 Feature 2 Feature 3 Feature 4 Function A Mutual Exclusion Not mutually exclusive Mutual Exclusion Not mutually exclusive Function B Mutual Exclusion Mutual Exclusion Not mutually exclusive Mutual Exclusion

[0101] Table 3

[0102] Feature 1 Feature 2 Feature 3 Feature 4 Function A √ × √ × Function B √ √ × √

[0103] Usually, the above-mentioned functional requirement file expresses the logical relationship between functions in the form of unstructured information. Table 2 and Table 3 are only schematic representations here. Other expressions that can reflect the logical relationship between functions can be used as functional requirement files. Among them, the unstructured relationship information is data information that cannot be directly processed by the computer and is close to the user's language understanding. For example, the above-mentioned "mutually exclusive", "non-mutually exclusive", "√", or "×" can be directly understood by the user, but the computer cannot understand the information, that is, unstructured relationship information. When the system extracts the unstructured relationship information from the functional requirement file, it needs to be converted into structured relationship information. The structured relationship information is computer language information that can be processed by the computer. For example, the above relationship can be converted into binary encoding to represent the mutually exclusive and non-mutually exclusive relationship, so as to uniformly encode all unstructured relationship information. Finally, the relationship data corresponding to each function is generated through the structured relationship information that can be processed by the computer, and then a functional relationship library is established. For example, a binary configuration file is generated according to the binary relationship data, and the generated configuration file can also be exported as needed.

[0104] In an exemplary embodiment, the function control method may further include:

[0105] The function relationship library is stored in a partition corresponding to the target application set in the hardware abstraction layer.

[0106] Taking into account that each project or platform in the system has an independent vendor partition, and the relationship between functions (such as mutually exclusive relationship) is related to the project or platform, for example, function A and function B are mutually exclusive on the Qualcomm platform, but are non-mutually exclusive on the MTK (MediaTek) platform. Therefore, in this exemplary embodiment, the function relationship library (such as function relationship configuration file) can be stored in the vendor partition of the target application set in the HAL (Hardware Abstraction Layer) to realize one project or platform to configure an independent function relationship library, and multiple projects or platforms do not affect each other.

[0107] Figure 7 A flow chart of another function control method is shown, which may specifically include the following steps:

[0108] At the application layer 710, execution

[0109] Step S711, receiving a state change event for a target function;

[0110] Step S712, obtaining a function relationship configuration file 721 from the hardware abstraction layer 720;

[0111] Step S713, parsing the function relationship configuration file 721;

[0112] Step S714, searching for the relationship between the target function and the associated functions according to the function relationship configuration file 721;

[0113] Step S715 , determining a state adjustment strategy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function.

[0114] The exemplary embodiment of the present disclosure also provides a function control device. Figure 8 As shown, the function control device 800 may include: an event receiving module 810, used to receive a state change event for a target function; a relationship search module 820, used to search for the relationship between a target function and an associated function of the target function in a pre-configured function relationship library; a strategy determination module 830, used to determine the state adjustment strategy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function.

[0115] In an exemplary embodiment, the target function and the associated function are both functions within the target application set; and / or, the target function is a function within the target application set, and the associated function is a function of the hardware module.

[0116] In an exemplary embodiment, a function relationship library is established by the following modules: a relationship data generation module, which is used to generate relationship data corresponding to each function in the target application set according to the relationship between each function and the associated function of each function; a function relationship library establishment module, which is used to establish the function relationship library of the target application set based on the identification of each function in the target application set and the relationship data corresponding to each function.

[0117] In an exemplary embodiment, the relationship data includes a relationship value string; the relationship data generation module includes: a relationship value string generation unit, which is used to generate a relationship value string corresponding to each function based on whether each function and the associated functions of each function are mutually exclusive, wherein the first value in the relationship value string represents a mutually exclusive relationship, and the second value in the relationship value string represents a non-mutually exclusive relationship.

[0118] In an exemplary embodiment, the function control method may further include: a storage module, configured to store the function relationship library into a partition corresponding to the target application set in the hardware abstraction layer.

[0119] In an exemplary embodiment, the relationship data generation module includes: a relationship information determination unit, which is used to obtain a function requirement file, and determine the unstructured relationship information between each function and the associated functions of each function in the target application set based on the function requirement file; a relationship data generation unit, which is used to convert the unstructured relationship information into structured relationship information, and generate relationship data corresponding to each function based on the structured relationship information.

[0120] In an exemplary embodiment, the policy determination module includes: a state adjustment unit, which is used to adjust the state of the associated function that is mutually exclusive with the target function to disabled according to the relationship between the target function and the associated function when the state change event is to enable the target function, and enable the target function.

[0121] The specific details of each part of the above device have been described in detail in the implementation method part, so they will not be repeated here.

[0122] The exemplary embodiments of the present disclosure further provide a computer-readable storage medium, which can be implemented in the form of a program product, including program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps according to various exemplary embodiments of the present disclosure described in the above “Exemplary Method” section of this specification, for example, to execute Figure 4 , Figure 5 , Figure 6 or Figure 7The program product may be in the form of a portable compact disk read-only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present disclosure is not limited thereto, and in this document, a readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, apparatus, or device.

[0123] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory, a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0124] Computer readable signal media may include data signals propagated in baseband or as part of a carrier wave, in which readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Readable signal media may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0125] The program code embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.

[0126] Program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., through the Internet using an Internet service provider).

[0127] It will be appreciated by those skilled in the art that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or implementations combining hardware and software aspects, which may be collectively referred to herein as "circuit", "module" or "system". Those skilled in the art will readily think of other implementations of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptive changes of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The specification and implementation are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the claims.

[0128] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims

1. A function control method, characterized in that: include: Receive state change events for target functions; In a pre-configured function relationship library, searching for a relationship between the target function and a function associated with the target function; Determining a state adjustment strategy for the target function or the associated function according to the state change event, the relationship between the target function and the associated function; The target function and the associated function are both functions within the target application set; and / or, the target function is a function within the target application set, and the associated function is a function of a hardware module; The functional relationship library is established in the following way: For each function in the target application set, generating relationship data corresponding to each function according to the relationship between each function and the associated function of each function; Establishing a function relationship library of the target application set based on the identifier of each function in the target application set and the relationship data corresponding to each function; The relation data includes a relation value string; The generating, according to the relationship between each function and the associated function of each function, the relationship data corresponding to each function comprises: According to whether each function and its associated functions are mutually exclusive, a relational value string corresponding to each function is generated, wherein the first value in the relational value string represents a mutually exclusive relationship, and the second value in the relational value string represents a non-mutually exclusive relationship.

2. The method according to claim 1, characterized in that The method further comprises: The function relationship library is stored in a partition corresponding to the target application set in the hardware abstraction layer.

3. The method according to claim 1, characterized in that For each function in the target application set, generating relationship data corresponding to each function according to the relationship between each function and the associated function of each function, includes: Acquire a function requirement document, and determine, based on the function requirement document, unstructured relationship information between each function in the target application set and an associated function of each function; The unstructured relationship information is converted into structured relationship information, and the relationship data corresponding to each function is generated according to the structured relationship information.

4. The method according to claim 1, characterized in that: The determining, according to the state change event, the relationship between the target function and the associated function, a state adjustment strategy for the target function or the associated function includes: When the state change event is enabling the target function, according to the relationship between the target function and the associated functions, the state of the associated functions that are mutually exclusive with the target function is adjusted to disabled, and the target function is enabled.

5. A function control device, characterized in that: include: An event receiving module, used for receiving state change events for target functions; A relationship search module, used to search for the relationship between the target function and the associated functions of the target function in a pre-configured function relationship library; a policy determination module, configured to determine a state adjustment policy of the target function or the associated function according to the state change event, the relationship between the target function and the associated function; the target function and the associated function are both functions within the target application set; and / or the target function is a function within the target application set, and the associated function is a function of a hardware module; The functional relationship library is configured to be established in the following manner: For each function in the target application set, generating relationship data corresponding to each function according to the relationship between each function and the associated function of each function; Establishing a function relationship library of the target application set based on the identifier of each function in the target application set and the relationship data corresponding to each function; The relationship data includes a relationship value string; the relationship data corresponding to each function is generated according to the relationship between each function and the associated function of each function, and is configured as follows: According to whether each function and its associated functions are mutually exclusive, a relational value string corresponding to each function is generated, wherein the first value in the relational value string represents a mutually exclusive relationship, and the second value in the relational value string represents a non-mutually exclusive relationship.

6. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented.

7. An electronic device, characterized in that: include: processor; A memory, configured to store executable instructions of the processor; The processor is configured to perform the method of any one of claims 1 to 4 by executing the executable instructions.