Interface state control method and device and electronic equipment

By turning on all interfaces when the module of the electronic device is powered on, and closing or opening a specific data interface according to the received instructions, the problem that the main control module cannot communicate normally with the functional module and the user cannot use the data interface, and the implementation of the Dynamic control of interface status and efficient management of resources.

CN119441084AActive Publication Date: 2025-02-14VIVO MOBILE COMM CO LTD

Patent Information

Application Number
CN202411344801.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-25
Publication Date
2025-02-14
Estimated Expiration
2044-09-25

AI Technical Summary

Technical Problem

When the main control module cannot communicate normally with the functional module, the user cannot use the specific data interface in the functional module.

Method used

Dynamic control of interface status is ensured by turning on all interfaces when the first module is detected to be powered on, and specific data interfaces are turned off or turned on when corresponding instructions are received.

Benefits of technology

Regardless of whether the control interface is normal or not, it can ensure the normal use of the data interface, reduce resource losses, and enable specific interfaces when needed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119441084A_ABST
    Figure CN119441084A_ABST
Patent Text Reader

Abstract

The invention discloses an interface state control method and device and electronic equipment, and belongs to the technical field of electronic equipment. The method provided by the embodiment of the invention comprises the following steps: opening a plurality of interfaces under the condition of detecting that a first module is powered on; under the condition that the control interface receives a first instruction sent by the second module, all the data interfaces are closed, and the first instruction is used for indicating to close all the data interfaces; and under the condition that the control interface receives a second instruction sent by the second module, a first data interface in the data interfaces is opened, and the second instruction is used for indicating to open the first data interface.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the technical field of electronic equipment, and specifically relates to a method and device for controlling an interface state, and an electronic device. Background Art

[0002] In the related art, the function module of the electronic device has one or more data interfaces. The opening or closing of these data interfaces is controlled by the main control module of the electronic device. When the user needs to use a specific data interface among these data interfaces, the main control module notifies the function module to start the corresponding specific data interface. However, in the related art, after the function module of the electronic device is powered on, all the data interfaces of the function module are closed. Therefore, when the main control module cannot communicate normally with the function module, the user cannot use the specific data interface in the function module. Summary of the invention

[0003] The purpose of the embodiments of the present application is to provide a method, device and electronic device for controlling the interface status, which can solve the problem that when the main control module cannot communicate normally with the functional module, the user cannot use the specific data interface in the functional module.

[0004] In a first aspect, an embodiment of the present application provides a method for controlling an interface state, which is applied to a first module of an electronic device, wherein the first module includes multiple interfaces, the multiple interfaces include a control interface and a data interface, and the control interface is connected to a second module of the electronic device; the method includes:

[0005] When detecting that the first module is powered on, enabling the multiple interfaces;

[0006] When the control interface receives a first instruction sent by the second module, closing all data interfaces, wherein the first instruction is used to instruct closing all data interfaces;

[0007] When the control interface receives the second instruction sent by the second module, a first data interface among the data interfaces is enabled, wherein the second instruction is used to instruct to enable the first data interface.

[0008] In a second aspect, a device for controlling an interface state is provided, which is applied to a first module of an electronic device, wherein the first module includes a plurality of interfaces, the plurality of interfaces include a control interface and a data interface, the control interface is connected to a second module of the electronic device, and the device includes:

[0009] A first processing module, configured to enable the multiple interfaces when detecting that the first module is powered on;

[0010] A second processing module, configured to close all data interfaces when the control interface receives a first instruction sent by the second module, wherein the first instruction is used to instruct to close all data interfaces;

[0011] A third processing module is configured to enable a first data interface among the data interfaces when the control interface receives a second instruction sent by the second module, wherein the second instruction is used to instruct to enable the first data interface.

[0012] In a third aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the method described in the first aspect are implemented.

[0013] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0014] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.

[0015] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.

[0016] In the embodiment of the present application, when the control interface is normal, closing the data interface through the above-mentioned first instruction can reduce unnecessary resource loss, and when the user needs to use a specific data interface, the above-mentioned second instruction can open the specific data interface, thereby ensuring that the user can use the data interface of the first module normally. When an abnormality occurs in the control interface, since each interface is in an open state after the first module is powered on, it can also ensure that the user can use the data interface of the first module normally. Therefore, regardless of whether the control interface is normal, that is, regardless of whether the first module can communicate normally with the second module, the above scheme can ensure the normal use of the data interface of the first module. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 This is one of the flow charts of the method for controlling the interface status of an embodiment of the present application;

[0018] Figure 2 is a schematic diagram of an interface of the first module of an embodiment of the present application;

[0019] Figure 3 This is a second flow chart of the method for controlling the interface status of an embodiment of the present application;

[0020] Figure 4 This is a third flow chart of the method for controlling the interface status of an embodiment of the present application;

[0021] Figure 5 is a module schematic diagram of a device for controlling an interface state according to an embodiment of the present application;

[0022] Figure 6 It is one of the structural block diagrams of the electronic device according to the embodiment of the present application;

[0023] Figure 7 This is the second structural block diagram of the electronic device according to the embodiment of the present application. DETAILED DESCRIPTION

[0024] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.

[0025] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.

[0026] The following is a detailed description of the interface status control method provided by the embodiment of the present application through specific embodiments and application scenarios in conjunction with the accompanying drawings.

[0027] like Figure 1 As shown, an embodiment of the present application provides a method for controlling an interface state, which is applied to a first module of an electronic device, wherein the first module includes multiple interfaces, the multiple interfaces include a control interface and a data interface, and the control interface is connected to a second module of the electronic device; the method includes:

[0028] Step 101: when it is detected that the first module is powered on, enable the multiple interfaces.

[0029] In the embodiment of the present application, the data interface includes at least one input interface and at least one output interface. Optionally, the input interface and the output interface correspond one to one.

[0030] For example, Figure 2 As shown, the first module includes input interface 1, input interface 2, output interface 1 and output interface 2. Among them, input interface 1 corresponds to output interface 1, and input interface 2 corresponds to output interface 2, that is, data is input from input interface 1 and output from output interface 1; or data is input from input interface 2 and output from output interface 2.

[0031] Step 102: When the control interface receives a first instruction sent by the second module, close all data interfaces, wherein the first instruction is used to instruct to close all data interfaces.

[0032] In the embodiment of the present application, after the second module detects that the first module is powered on, it sends a first instruction to the first module, so that the first module closes all data interfaces according to the first instruction, thereby achieving the purpose of saving resources and power consumption.

[0033] Optionally, the second module is a main control module of the electronic device. For example, the main control module is an electronic controller. The main control module controls the opening or closing of each data interface of the first module by sending instructions.

[0034] Step 103: When the control interface receives a second instruction sent by the second module, enable a first data interface among the data interfaces, wherein the second instruction is used to instruct to enable the first data interface.

[0035] In an embodiment of the present application, when the second module receives a request from a user to use the first data interface, it sends a second instruction to the first module, and the first module opens the first data interface according to the second instruction. For example, the first data interface includes a first access interface and a first output interface.

[0036] Optionally, the user is other modules in the electronic device except the first module, or is a user.

[0037] In the embodiment of the present application, when the control interface is normal, closing the data interface through the above-mentioned first instruction can reduce unnecessary resource loss, and when the user needs to use a specific data interface, the above-mentioned second instruction can open the specific data interface, thereby ensuring that the user can use the data interface of the first module normally. When an abnormality occurs in the control interface, since each interface is in an open state after the first module is powered on, it can also ensure that the user can use the data interface of the first module normally. Therefore, regardless of whether the control interface is normal, that is, regardless of whether the first module can communicate normally with the second module, the above scheme can ensure the normal use of the data interface of the first module.

[0038] Optionally, the method further includes:

[0039] When the control interface receives the third instruction sent by the second module, the first data interface is closed, wherein the third instruction is used to close the first data interface.

[0040] In an embodiment of the present application, when the second module learns that the user no longer needs to use the first data interface of the first module, it sends the third instruction to the first module through the control interface, and the first module closes the first data interface according to the third instruction to avoid energy waste.

[0041] Optionally, the first instruction or the second instruction is an instruction transmitted via a serial communication protocol.

[0042] In the embodiment of the present application, the first module and the second module transmit the first instruction or the second instruction through a serial communication protocol, so that the first module opens or closes the corresponding interface according to the corresponding instruction. Exemplarily, the serial communication protocol can be an Inter-Integrated Circuit (I2C) protocol, a Serial Peripheral Interface (SPI) protocol, etc.

[0043] Optionally, the first module includes but is not limited to at least one of a power management module and a multimedia processing module. The first module may be any functional module including a plurality of interfaces in the electronic device.

[0044] Through the solution of the present application, when the control interface is normal, the normal use of the interfaces of the above-mentioned power management module, multimedia processing module, etc. can be guaranteed while avoiding unnecessary resource loss. When the control interface is abnormal, the normal use of the interfaces of the above-mentioned power management module, multimedia processing module, etc. can also be guaranteed.

[0045] The overall process of the interface status control method of the present application is described below in conjunction with the embodiments.

[0046] In the embodiments of the present application, Figure 3 As shown, the process includes:

[0047] Step 301: The first module is powered on.

[0048] Step 302: The first module enables all interfaces.

[0049] After the power supply is connected, the first module will be initialized. During the initialization process, the first module opens all interfaces and is ready to receive communication instructions from the second module. The second module is specifically a main control module of the electronic device.

[0050] Step 303: The second module sends a first instruction using a communication protocol, where the first instruction is used to instruct to close all data interfaces.

[0051] The communication protocol is a communication protocol for directly exchanging data between the first module and the second module, such as an I2C protocol, an SPI protocol, etc.

[0052] Step 304: The first module closes all data interfaces.

[0053] Step 305: The second module learns that the user needs to use the first data interface, and uses the communication protocol to send a second instruction to the first module, where the second instruction is used to instruct to open the first data interface.

[0054] The user is another module connected to the corresponding input or output of the first module, and the output or input of the user depends on the input interface or output interface of the first module being in an open state.

[0055] Step 306: The first module opens the first data interface.

[0056] After receiving the second instruction to open the first data interface sent to this module by the second module through the communication protocol, the first module executes according to the instruction content. At this time, the first data interface has its corresponding functions to ensure that the functions involved by the user and the first module are normal.

[0057] Step 307: The first data interface is used normally.

[0058] At this time, the corresponding function of the first data interface works normally.

[0059] Step 308: When the second module learns that the user no longer needs to use the first data interface, a third instruction is sent through the communication protocol, where the third instruction is used to close the first data interface.

[0060] Step 309: The first module closes the first data interface.

[0061] After receiving the instruction to close the first data interface sent to this module by the second module through the communication protocol, the first module executes according to the instruction content. At this time, the first data interface no longer has its corresponding function, and the functions in which the user and the first module participate are no longer running.

[0062] Step 310: The first module is powered off.

[0063] After the first module is powered off, all interfaces are closed.

[0064] In the above process, the control interface works normally, and the above first instruction and the second instruction can ensure the normal use of the interface of the above first module under the premise of avoiding unnecessary resource loss.

[0065] In the embodiments of the present application, Figure 4 As shown, the process includes:

[0066] Step 401: The first module is powered on.

[0067] Step 402: The first module enables all interfaces.

[0068] After the power supply is connected, the first module will be initialized. During the initialization process, the first module opens all interfaces and is ready to receive communication instructions from the main control module.

[0069] Step 403: The second module sends a first instruction using a communication protocol, where the first instruction is used to instruct to close all data interfaces.

[0070] The communication protocol is a communication protocol for directly exchanging data between the first module and the second module, such as an I2C protocol, an SPI protocol, etc.

[0071] Step 404: The control interface is abnormal, and all data interfaces of the first module remain in an open state.

[0072] Due to the abnormality of the control interface, the first module cannot receive the first instruction, and all data interfaces of the first module remain in an open state.

[0073] Step 405: The second module learns that the user needs to use the first data interface, and uses the communication protocol to send a second instruction to the first module, where the second instruction is used to instruct to open the first data interface.

[0074] The user is another module connected to the corresponding input or output of the first module, and the output or input of the user depends on the input interface or output interface of the first module being in an open state.

[0075] Step 406: The control interface is abnormal, and all data interfaces of the first module remain in an open state.

[0076] Due to the abnormality of the control interface, the first module cannot receive the above-mentioned second instruction, and all data interfaces of the first module remain in an open state. At this time, the first data interface has its corresponding function, which can ensure that the functions involved by the user and the first module are normal.

[0077] Step 407: The first data interface is used normally.

[0078] At this time, the corresponding function of the first data interface works normally.

[0079] Step 408: When the second module learns that the user no longer needs to use the first data interface, a third instruction is sent through the communication protocol, where the third instruction is used to close the first data interface.

[0080] Step 409: The control interface is abnormal, and all data interfaces of the first module remain in an open state.

[0081] Due to the abnormality of the control interface, the first module cannot receive the third instruction, and all data interfaces of the first module remain open.

[0082] Step 410: The first module is powered off.

[0083] After the first module is powered off, all interfaces are closed.

[0084] In the above process, the control interface is abnormal and the first module and the second module cannot communicate normally. However, since the interfaces are in the open state after the first module is powered on, the user can still use the data interface of the first module normally when the first module and the second module cannot communicate normally.

[0085] The interface state control method provided in the embodiment of the present application can be executed by the interface state control device. In the embodiment of the present application, the interface state control method executed by the interface state control device is taken as an example to illustrate the interface state control device provided in the embodiment of the present application.

[0086] like Figure 5 As shown, an embodiment of the present application provides a device 500 for controlling an interface state, which is applied to a first module of an electronic device, wherein the first module includes a plurality of interfaces, wherein the plurality of interfaces include a control interface and a data interface, and the control interface is connected to a second module of the electronic device, and the device includes:

[0087] A first processing module 501 is configured to enable the multiple interfaces when it is detected that the first module is powered on;

[0088] A second processing module 502, configured to close all data interfaces when the control interface receives a first instruction sent by the second module, wherein the first instruction is used to instruct to close all data interfaces;

[0089] The third processing module 503 is used to enable a first data interface among the data interfaces when the control interface receives a second instruction sent by the second module, wherein the second instruction is used to instruct to enable the first data interface.

[0090] Optionally, the device of the embodiment of the present application further includes:

[0091] The fourth processing module is used to close the first data interface when the control interface receives the third instruction sent by the second module, wherein the third instruction is used to close the first data interface.

[0092] Optionally, the first instruction or the second instruction is an instruction transmitted via a serial communication protocol.

[0093] Optionally, the first module includes at least one of a power management module and a multimedia processing module.

[0094] Optionally, the second module is a main control module of the electronic device.

[0095] In the embodiment of the present application, when the control interface is normal, closing the data interface through the above-mentioned first instruction can reduce unnecessary resource loss, and when the user needs to use a specific data interface, the above-mentioned second instruction can open the specific data interface, thereby ensuring that the user can use the data interface of the first module normally. When an abnormality occurs in the control interface, since each interface is in an open state after the first module is powered on, it can also ensure that the user can use the data interface of the first module normally. Therefore, regardless of whether the control interface is normal, that is, regardless of whether the first module can communicate normally with the second module, the above scheme can ensure the normal use of the data interface of the first module.

[0096] The control device of the interface state in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc. It can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., and the embodiment of the present application is not specifically limited.

[0097] The interface state control device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0098] The interface status control device provided in the embodiment of the present application can achieve Figures 1 to 4 To avoid repetition, the various processes implemented by the method embodiment are not described here.

[0099] Alternatively, if Figure 6 As shown, an embodiment of the present application also provides an electronic device 600, including a processor 601 and a memory 602, wherein the memory 602 stores programs or instructions that can be executed on the processor 601, and when the program or instructions are executed by the processor 601, the various steps of the embodiment of the control method of the above-mentioned interface state are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.

[0100] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.

[0101] Figure 7 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.

[0102] The electronic device 700 includes but is not limited to: a radio frequency unit 701, a network module 702, an audio output unit 703, an input unit 704, a sensor 705, a display unit 706, a user input unit 707, an interface unit 708, a memory 709, and a processor 710.

[0103] Those skilled in the art will appreciate that the electronic device 700 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 710 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 7 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.

[0104] The processor 710 is configured to enable the multiple interfaces when detecting that the first module is powered on; to disable all data interfaces when the control interface receives a first instruction sent by the second module, wherein the first instruction is used to instruct to disable all data interfaces; and to enable a first data interface among the data interfaces when the control interface receives a second instruction sent by the second module, wherein the second instruction is used to instruct to enable the first data interface. Optionally, the processor 710 is also configured to disable the first data interface when the control interface receives a third instruction sent by the second module, wherein the third instruction is used to disable the first data interface.

[0105] Optionally, the first instruction or the second instruction is an instruction transmitted via a serial communication protocol.

[0106] Optionally, the first module includes at least one of a power management module and a multimedia processing module.

[0107] Optionally, the second module is a main control module of the electronic device.

[0108] In the embodiment of the present application, when the control interface is normal, closing the data interface through the above-mentioned first instruction can reduce unnecessary resource loss, and when the user needs to use a specific data interface, the above-mentioned second instruction can open the specific data interface, thereby ensuring that the user can use the data interface of the first module normally. When an abnormality occurs in the control interface, since each interface is in an open state after the first module is powered on, it can also ensure that the user can use the data interface of the first module normally. Therefore, regardless of whether the control interface is normal, that is, regardless of whether the first module can communicate normally with the second module, the above scheme can ensure the normal use of the data interface of the first module.

[0109] It should be understood that in the embodiment of the present application, the input unit 704 may include a graphics processor (Graphics Processing Unit, GPU) 7041 and a microphone 7042, and the graphics processor 7041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 706 may include a display panel 7061, and the display panel 7061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 707 includes a touch panel 7071 and at least one of other input devices 7072. The touch panel 7071 is also called a touch screen. The touch panel 7071 may include two parts: a touch detection device and a touch controller. Other input devices 7072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.

[0110] The memory 709 can be used to store software programs and various data. The memory 709 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 709 may include a volatile memory or a non-volatile memory, or the memory 709 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 709 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.

[0111] The processor 710 may include one or more processing units; optionally, the processor 710 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 710.

[0112] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned interface status control method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0113] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.

[0114] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned interface status control method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0115] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0116] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the control method embodiment of the interface status as described above, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0117] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0118] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0119] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. A method for controlling an interface state, applied to a first module of an electronic device, wherein the first module comprises a plurality of interfaces, the plurality of interfaces comprises a control interface and a data interface, and the control interface is connected to a second module of the electronic device; characterized in that: The method comprises: When detecting that the first module is powered on, enabling the multiple interfaces; When the control interface receives a first instruction sent by the second module, closing all data interfaces, wherein the first instruction is used to instruct closing all data interfaces; When the control interface receives the second instruction sent by the second module, a first data interface among the data interfaces is enabled, wherein the second instruction is used to instruct to enable the first data interface.

2. The method according to claim 1, characterized in that Also includes: When the control interface receives the third instruction sent by the second module, the first data interface is closed, wherein the third instruction is used to close the first data interface.

3. The method according to claim 1, characterized in that The first instruction or the second instruction is an instruction transmitted through a serial communication protocol.

4. The method according to claim 1, characterized in that: The first module includes at least one of a power management module and a multimedia processing module.

5. The method according to claim 1, characterized in that The second module is a main control module of the electronic device.

6. A device for controlling an interface state, applied to a first module of an electronic device, wherein the first module comprises a plurality of interfaces, the plurality of interfaces comprises a control interface and a data interface, the control interface is connected to a second module of the electronic device, characterized in that: The device comprises: A first processing module, configured to enable the multiple interfaces when detecting that the first module is powered on; A second processing module, configured to close all data interfaces when the control interface receives a first instruction sent by the second module, wherein the first instruction is used to instruct to close all data interfaces; A third processing module is configured to enable a first data interface among the data interfaces when the control interface receives a second instruction sent by the second module, wherein the second instruction is used to instruct to enable the first data interface.

7. The device according to claim 6, characterized in that Also includes: The fourth processing module is used to close the first data interface when the control interface receives the third instruction sent by the second module, wherein the third instruction is used to close the first data interface.

8. The device according to claim 6, characterized in that The first instruction or the second instruction is an instruction transmitted through a serial communication protocol.

9. The device according to claim 6, characterized in that The first module includes at least one of a power management module and a multimedia processing module.

10. The device according to claim 6, characterized in that The second module is a main control module of the electronic device.

11. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the method for controlling the interface state as described in any one of claims 1 to 5 are implemented.

12. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the method for controlling the interface status according to any one of claims 1 to 5 are implemented.

13. A computer program product, characterized in that The method comprises computer instructions, which, when executed by a processor, implement the steps of the method for controlling the interface state as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Electronic device and analog signal port multiplexing method

    CN102831094A

  • Electronic equipment and control method

    CN104635535A

  • GPFA-based multichannel different-speed data transmission system

    CN105975416A

  • Onsite sensor and application method thereof

    CN107131962A

  • Power adjustment method and electronic device

    CN108549477A

Cited By

  • Interface state control method and apparatus, and electronic device

    WO2026067172A1