Communication method and device, electronic equipment, power supply equipment and storage medium

By using the first and second protocol modules in the electronic device to identify the role of the device and determine the communication protocol, the problems of complex design and low communication efficiency in the prior art are solved, and a more efficient charging process is achieved.

CN119543406APending Publication Date: 2025-02-28BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311110582.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-30
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

When existing electronic devices are compatible with different high-power charging protocols, they are complex in design and low communication efficiency, resulting in low efficiency during charging.

Method used

The first and second protocol modules are adopted to identify the device role through physical connections, and decide whether to use the second communication protocol to establish a communication connection based on the role results, simplifying the structure of the second protocol module.

Benefits of technology

On the premise of ensuring communication effect, the structure of the second protocol module is simplified, the cost is reduced, and the efficiency of the charging process is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119543406A_ABST
    Figure CN119543406A_ABST
Patent Text Reader

Abstract

The invention provides a communication method and device, electronic equipment, power supply equipment and a storage medium, and the electronic equipment comprises a first protocol module and a second protocol module. The first protocol module is used for establishing physical connection with power supply equipment and identifying an equipment role result; the second protocol module is used for determining whether to adopt a second communication protocol to establish communication connection with the power supply equipment according to the role identification result; and the first protocol module is also used for determining to adopt a first communication protocol to establish communication connection with the electronic equipment. According to the embodiment, the communication connection is established through the second protocol module in the master-slave mode, so that the structure of the second protocol module can be simplified on the premise of ensuring the communication effect, and the cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of control technology, and in particular to a communication method and device, electronic equipment, power supply equipment, and storage medium. Background Art

[0002] At present, with the rapid development of high-power charging technology, the charging power of electronic devices has also increased. Electronic devices can be connected to power supply equipment using a single-wire physical channel and charged at high power.

[0003] In order to be compatible with different high-power charging protocols, the electronic device is provided with multiple protocol modules, each module is provided with a transmitting submodule TX and a receiving submodule RX, resulting in a more complex design and low communication efficiency. Summary of the invention

[0004] The present disclosure provides a communication method and device, an electronic device, a power supply device, and a storage medium to solve the above technical problems.

[0005] According to a first aspect of the present disclosure, there is provided an electronic device, comprising a first protocol module and a second protocol module;

[0006] The first protocol module is used to establish a physical connection with the power supply device and identify the device role result;

[0007] The second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification result;

[0008] The first protocol module is further used to determine whether to use the first communication protocol to establish a communication connection with the electronic device.

[0009] Optionally, the second protocol module of the electronic device and the second protocol module of the power supply device are implemented in a master-slave mode.

[0010] Optionally, when the electronic device is a slave device, the second protocol module determines whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification role result, including: in response to receiving a communication signal generated by the power supply device according to the second communication protocol, establishing a communication connection based on the second communication protocol with the power supply device.

[0011] Optionally, the second protocol module of the electronic device includes: a processing unit, a communication holding branch, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the communication holding branch, the signal transmitting branch and the signal receiving branch respectively;

[0012] The communication holding branch is used to be electrically connected to the second power line to establish a physical connection with the power supply device;

[0013] The signal transmission branch is used to transmit a communication signal according to the control signal of the processing unit;

[0014] The signal receiving branch is used to receive a communication signal from the power supply device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the power supply device according to the communication signal.

[0015] Optionally, the communication holding branch includes: a first resistor and a first switch device; a first end of the first resistor is electrically connected to the communication interface of the electronic device, and a second end of the first resistor is electrically connected to a first end of the first switch device; a second end of the first switch device is electrically connected to a second power line, and a control end of the first switch device is electrically connected to the processing unit;

[0016] The first switch device is used to turn on the first resistor and the second power line when receiving a control signal from the processing unit.

[0017] Optionally, the signal transmission branch includes: a signal transmission unit and a branch control unit; the input end of the signal transmission unit is electrically connected to the processing unit, and the output end of the signal transmission unit is electrically connected to the branch control unit; the branch control unit is electrically connected to the communication interface of the electronic device and the third power line respectively;

[0018] The branch control unit is used to connect the communication interface and the third power line according to the control signal output by the signal transmitting unit.

[0019] Optionally, the branch control unit includes: a second resistor and a second switch device; a first end of the second resistor is electrically connected to the communication interface of the electronic device, and a second end of the second resistor is electrically connected to a first end of the second switch device; a second end of the second switch device is electrically connected to a second power line, and a control end of the second switch device is electrically connected to the signal transmitting unit;

[0020] The second switch device is used to turn on the second resistor and the second power line when receiving the control signal of the signal transmitting unit;

[0021] The resistance value of the second resistor is smaller than the resistance value of the first resistor in the communication maintaining branch.

[0022] Optionally, the second protocol module includes: a processing unit, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the signal transmitting branch and the signal receiving branch respectively;

[0023] The signal transmission branch is used to transmit a communication signal according to the control signal of the processing unit;

[0024] The signal receiving branch is used to receive a communication signal from the power supply device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the power supply device according to the communication signal.

[0025] Optionally, the signal transmission branch includes: a fourth resistor and a fourth switch device; the first end of the fourth resistor is electrically connected to the first power line, and the second end of the fourth resistor is electrically connected to the first end of the fourth switch device; the second end of the fourth switch device is electrically connected to the communication interface of the electronic device, and the control end of the fourth switch device is electrically connected to the processing unit;

[0026] The fourth switch device is used to turn on the fourth resistor and the communication interface when receiving a control signal from the processing unit.

[0027] According to a second aspect of the present disclosure, there is provided a power supply device, including: a first protocol module and a second protocol module;

[0028] The first protocol module is used to establish a physical connection with the electronic device and identify the device role result;

[0029] The second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the electronic device according to the role recognition result;

[0030] The first protocol module is further used to determine whether to use the first communication protocol to establish a communication connection with the electronic device.

[0031] Optionally, the second protocol module of the power supply device and the second protocol module of the electronic device are implemented in a master-slave mode.

[0032] Optionally, when the power supply device is the main device, the second protocol module determines whether to use the second communication protocol to establish a communication connection with the power supply device based on the identification role result, including: generating a communication signal according to the second communication protocol and sending it to the electronic device, so that the electronic device establishes a communication connection based on the second communication protocol with the power supply device after receiving the communication signal.

[0033] Optionally, the second protocol module of the power supply device includes: a processing unit, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the signal transmitting branch and the signal receiving branch respectively;

[0034] The signal transmission branch is used to transmit a communication signal matching a second communication protocol according to a control signal of the processing unit;

[0035] The signal receiving branch is used to receive a communication signal from the electronic device and transmit the signal to the processing unit, so that the processing unit determines whether to establish a communication connection based on the second communication protocol with the electronic device according to the communication signal.

[0036] Optionally, the signal transmission branch includes: a third resistor and a third switch device; the first end of the third resistor is electrically connected to the first power line, and the second end of the third resistor is electrically connected to the first end of the third switch device; the second end of the third switch device is electrically connected to the communication interface of the power supply device, and the control end of the third switch device is electrically connected to the processing unit;

[0037] The third switch device is used to turn on the third resistor and the communication interface when receiving a control signal from the processing unit.

[0038] Optionally, the second protocol module of the power supply device includes: a processing unit, a communication holding branch, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the communication holding branch, the signal transmitting branch and the signal receiving branch respectively;

[0039] The communication holding branch is used to be electrically connected to the second power line to establish a physical connection with the electronic device;

[0040] The signal transmission branch is used to transmit a communication signal matching the second communication protocol according to the control signal of the processing unit;

[0041] The signal receiving branch is used to receive a communication signal from the electronic device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the electronic device using a second communication protocol according to the communication signal.

[0042] Optionally, the communication maintaining branch includes: a fifth resistor and a fifth switch device; the first end of the fifth resistor is electrically connected to the communication interface of the power supply device, and the second end of the fifth resistor is electrically connected to the first end of the fifth switch device; the second end of the fifth switch device is electrically connected to the second power line, and the control end of the fifth switch device is electrically connected to the processing unit;

[0043] The fifth switch device is used to turn on the first resistor and the second power line when receiving a control signal from the processing unit.

[0044] Optionally, the signal transmission branch includes: a signal transmission unit and a branch control unit; the input end of the signal transmission unit is electrically connected to the processing unit, and the output end of the signal transmission unit is electrically connected to the branch control unit; the branch control unit is electrically connected to the communication interface and the second power line of the power supply device respectively;

[0045] The branch control unit is used to conduct the communication interface of the power supply device and the second power line according to the control signal output by the signal transmitting unit.

[0046] Optionally, the branch control unit includes: a sixth resistor and a sixth switch device; the first end of the sixth resistor is electrically connected to the communication interface of the power supply device, and the second end of the sixth resistor is electrically connected to the first end of the sixth switch device; the second end of the sixth switch device is electrically connected to the second power line, and the control end of the sixth switch device is electrically connected to the signal transmitting unit;

[0047] The sixth switch device is used for switching on the sixth resistor and the second power line when receiving the control signal of the signal transmitting unit;

[0048] The resistance value of the sixth resistor is smaller than the resistance value of the fifth resistor in the communication maintaining branch.

[0049] According to a third aspect of the present disclosure, a communication method is provided, comprising an electronic device as described in any one of the first aspect, a power supply device as described in any one of the second aspect, and a charging bus, wherein the electronic device is electrically connected to the power supply device via the charging bus; the electronic device establishes a physical connection with the power supply device via the charging bus, and determines a corresponding communication protocol based on the physical connection to establish a communication connection.

[0050] According to a fourth aspect of the present disclosure, a communication method is provided, applicable to the electronic device according to any one of the first aspects, the method comprising:

[0051] In response to establishing a physical connection with the first protocol module of the power supply device, waiting for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol;

[0052] In response to receiving the communication signal within the preset time period, a response signal to the communication signal is generated according to the second communication protocol and sent to the power supply device through the physical connection to establish a communication connection with the power supply device based on the second communication protocol.

[0053] Optionally, generating a response signal to the communication signal according to the second communication protocol includes:

[0054] generating a control signal according to a second communication protocol;

[0055] The second switch device of the branch control unit in the second protocol module is controlled to be turned on or off according to the control signal to generate a response signal to the communication signal.

[0056] Optionally, the method further comprises:

[0057] In response to not receiving a communication signal sent by the power supply device within a preset time period, establishing a communication connection with the power supply device based on a first communication protocol.

[0058] According to a fifth aspect of the present disclosure, a communication method is provided, applicable to the power supply device according to any one of the second aspects, the method comprising:

[0059] In response to establishing a physical connection with a first protocol module of an electronic device, generating a communication signal according to a second communication protocol and sending the communication signal to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal;

[0060] In response to receiving a response signal returned by the electronic device within a preset time period, a communication connection is established with the electronic device based on the second communication protocol.

[0061] Optionally, generating a communication signal according to a second communication protocol includes:

[0062] generating a control signal according to a second communication protocol;

[0063] The fifth switch device of the branch control unit in the second protocol module is controlled to be turned on or off according to the control signal to generate the communication signal.

[0064] Optionally, the method further comprises:

[0065] In response to not receiving a response signal returned by the electronic device within a preset time period, establishing a communication connection with the electronic device based on a first communication protocol.

[0066] According to a sixth aspect of the present disclosure, a communication device is provided, applicable to the electronic device according to any one of the first aspects, the device comprising:

[0067] A communication signal receiving module, configured to, in response to establishing a physical connection with the first protocol module of the power supply device, wait for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol;

[0068] A response signal generating module is used to generate a response signal of the communication signal according to the second communication protocol in response to receiving the communication signal within the preset time period, and send it to the power supply device through the physical connection, so as to establish a communication connection with the power supply device based on the second communication protocol.

[0069] Optionally, the response signal generating module includes:

[0070] A control signal generating unit, configured to generate a control signal according to a second communication protocol;

[0071] A response signal generating unit is used to control the second switch device of the branch control unit in the second protocol module to be turned on or off according to the control signal, so as to generate a response signal to the communication signal.

[0072] Optionally, the device further comprises:

[0073] The communication connection establishing module is used to establish a communication connection with the power supply device based on a first communication protocol in response to not receiving a communication signal sent by the power supply device within a preset time period.

[0074] According to a seventh aspect of the present disclosure, a communication device is provided, applicable to the power supply device according to any one of the second aspects, the device comprising:

[0075] a communication signal sending module, configured to generate a communication signal according to a second communication protocol in response to establishing a physical connection with the first protocol module of the electronic device, and send the communication signal to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal;

[0076] The communication connection establishing module is used to establish a communication connection with the electronic device based on the second communication protocol in response to receiving a response signal returned by the electronic device within a preset time period.

[0077] Optionally, the communication signal sending module includes:

[0078] A control signal generating unit, configured to generate a control signal according to a second communication protocol;

[0079] A communication signal generating unit is used to control the fifth switch device of the branch control unit in the second protocol module to be turned on or off according to the control signal to generate the communication signal.

[0080] Optionally, the device further comprises:

[0081] The communication connection establishing module is further used to establish a communication connection with the electronic device based on the first communication protocol in response to not receiving a response signal returned by the electronic device within a preset time period.

[0082] According to an eighth aspect of the present disclosure, there is provided an electronic device, including:

[0083] Processor and memory;

[0084] The memory is used to store a computer program executable by the processor;

[0085] The processor is configured to execute the computer program in the memory to implement the method as described in any one of the fourth aspects.

[0086] According to a ninth aspect of the present disclosure, there is provided a power supply device, including:

[0087] Processor and memory;

[0088] The memory is used to store a computer program executable by the processor;

[0089] Wherein, the processor is configured to execute the computer program in the memory to implement the method as described in any one of the fifth aspects.

[0090] According to a tenth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided, and when an executable computer program in the storage medium is executed by a processor, the method described in any one of the fourth and fifth aspects can be implemented.

[0091] The technical solution provided by the embodiments of the present disclosure may have the following beneficial effects:

[0092] In the scheme of this embodiment, the electronic device includes a first protocol module and a second protocol module; the first protocol module is used to establish a physical connection with the power supply device and identify the device role result; the second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification role result; the first protocol module is also used to determine whether to use the first communication protocol to establish a communication connection with the electronic device. In this way, in this embodiment, the communication connection is established through the second protocol module in the master-slave mode, which can simplify the structure of the second protocol module and reduce costs while ensuring the communication effect.

[0093] 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

[0094] Figure 1 The present invention is a schematic diagram of hardware connection between a power supply device and an electronic device according to an embodiment of the present invention.

[0095] Figure 2 The present invention is a block diagram of an electronic device according to an embodiment of the present invention.

[0096] Figure 3 The present invention is a circuit diagram of an electronic device according to an embodiment of the present invention.

[0097] Figure 4 A schematic diagram of a communication signal according to an embodiment of the present disclosure.

[0098] Figure 5 The figure is a schematic diagram of a second protocol module in an electronic device according to an embodiment of the present disclosure.

[0099] Figure 6A schematic diagram of a communication signal according to an embodiment of the present disclosure.

[0100] Figure 7 The present invention is a block diagram of a power supply device according to an embodiment of the present invention.

[0101] Figure 8 This is a schematic diagram of a second protocol module in a power supply device according to an embodiment of the present disclosure.

[0102] Fig. 9 A schematic diagram of a communication signal according to an embodiment of the present disclosure.

[0103] Fig.10 The present invention is a circuit diagram of a power supply device according to an embodiment of the present invention.

[0104] Fig.11 A schematic diagram of a communication signal according to an embodiment of the present disclosure.

[0105] Fig.12 The present invention is a flow chart of communication between a power supply device and an electronic device according to an embodiment of the present invention.

[0106] Fig.13 The present invention is a flow chart of communication between a power supply device and an electronic device according to an embodiment of the present invention.

[0107] Fig.14 The present invention is a flow chart of a communication method according to an embodiment of the present invention.

[0108] Fig.15 The present invention is a flow chart of a communication method according to an embodiment of the present invention.

[0109] Fig.16 The present invention is a block diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0110] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices consistent with some aspects of the present disclosure as detailed in the appended claims.

[0111] To solve the above technical problems, the embodiments of the present disclosure provide a communication method and device, an electronic device, a power supply device, and a storage medium. When there is a need for charging, the electronic device is connected to the power supply device through a charging bus for charging. Figure 1 The present invention is a schematic diagram of a physical connection architecture between an electronic device and a power supply device according to an embodiment of the present invention.

[0112] The inventive concept of the disclosed solution is that the power supply device and the electronic device include a second protocol module, and the two second protocol modules are implemented in a master-slave mode to achieve the effect of simplifying the second protocol modules.

[0113] Based on the above inventive concept, the present disclosure provides an electronic device, see Figure 2 ,include:

[0114] A first protocol module 1 and a second protocol module 2;

[0115] The first protocol module 1 is used to establish a physical connection with the power supply device and identify the device role result;

[0116] The second protocol module 2 is used to determine whether to use the second communication protocol to establish a communication connection with the power supply device according to the role identification result;

[0117] The first protocol module 1 is further used to determine to establish a communication connection with the electronic device using the first communication protocol.

[0118] It should be noted that the above-mentioned device role refers to identifying whether the electronic device is a source device (or master device) or a sink device (or slave device). When the charging bus is electrically connected to the power supply device and the electronic device respectively, the pull-up resistor of the communication interface of the power supply device is pulled up to the first level line, and the pull-down resistor of the communication interface of the electronic device is pulled down to the second level line, so that the power supply device can be determined to be a source device and the electronic device is a sink device. In other words, the first protocol module 1 can determine that it is a device role result of a sink device according to the pull-down resistor being pulled down to the second level line or the sink current.

[0119] In one embodiment, see Figure 3 The second protocol module of the electronic device includes: a processing unit 31, a communication holding branch 32, a signal transmitting branch 33 and a signal receiving branch 34. The processing unit 31 is electrically connected to the communication holding branch 32, the signal transmitting branch 33 and the signal receiving branch 34 respectively.

[0120] The communication holding branch 32 is used to be electrically connected to a second power line (such as a ground line, GND) to establish a physical connection with the power supply device;

[0121] The signal transmission branch 33 is used to transmit a communication signal according to the control signal of the processing unit 31;

[0122] The signal receiving branch 34 is used to receive a communication signal from the power supply device and transmit it to the processing unit 31, so that the processing unit determines whether to establish a communication connection with the power supply device according to the communication signal.

[0123] Continue to see Figure 3The communication holding branch 32 includes: a first resistor R1 and a first switch device Q1; the first end of the first resistor R1 is electrically connected to the communication interface of the electronic device, and the second end of the first resistor R1 is electrically connected to the first end of the first switch device Q1; the second end of the first switch device Q1 is electrically connected to the second power line, and the control end of the first switch device Q1 is electrically connected to the processing unit 31; the first switch device Q1 is used to conduct the first resistor R1 and the second power line when receiving the control signal of the processing unit 31. In this way, the communication holding circuit 32 can pull the potential at the communication interface down to the potential on the second power line, and when the second power line is a ground line, the potential of the communication interface can be pulled down to the ground.

[0124] It should be noted that the first switch device Q1 can be implemented by a transistor, a relay, a field effect transistor or other devices, which are not limited here. The subsequent second switch device, the third switch device, the fourth switch device, the fifth switch device and the sixth switch device can be implemented by the same or different devices as the first switch device Q1. In the case where the on or off function can be achieved, the corresponding solution falls within the protection scope of the present disclosure.

[0125] Continue to see Figure 3 The signal transmission branch 33 includes: a signal transmission unit TX and a branch control unit 331; the input end of the signal transmission unit TX is electrically connected to the processing unit 31, and the output end of the signal transmission unit TX is electrically connected to the branch control unit 331; the branch control unit 331 is electrically connected to the communication interface and the third power line of the electronic device respectively; the branch control unit is used to connect the communication interface and the third power line according to the control signal output by the signal transmission unit TX, so as to pull the potential of the communication interface down to the potential of the third power line, that is, the signal transmission branch 33 can output a low-level communication signal.

[0126] It should be noted that the third power line can provide different level signals for the signal transmission branch 33, such as 0V voltage or other non-zero voltage, which can be set according to specific scenarios. In one example, the third power line is electrically connected to the second power line, and both are ground lines.

[0127] Continue to see Figure 3, the branch control unit 331 includes: a second resistor R2 and a second switch device Q2. The first end of the second resistor R2 is electrically connected to the communication interface of the electronic device, and the second end of the second resistor R2 is electrically connected to the first end of the second switch device Q2; the second end of the second switch device Q2 is electrically connected to the third power line, and the control end of the second switch device Q2 is electrically connected to the signal transmitting unit TX; the second switch device Q2 is used to turn on the second resistor R2 and the third power line when receiving the control signal of the signal transmitting unit TX. In this way, when the second switch device Q2 is turned on, the branch control unit 331 can pull down the potential of the communication interface of the electronic device to the ground line, and the signal transmitting branch 33 can output a low-level communication signal at this time; when the second switch device Q2 is turned off, the branch control unit 331 will not pull down the potential of the communication interface of the electronic device. Due to the existence of the first resistor R1, the communication interface of the electronic device can be at a high level at this time, and the signal transmitting branch 33 can output a high-level communication signal at this time, and the following is obtained. Figure 4 communication signals shown.

[0128] It should be noted that, in one example, the resistance value of the second resistor R2 is smaller than the resistance value of the first resistor R1 in the communication holding branch 32, so that the difference between the two resistance values ​​is as large as possible, for example, the resistance value of the first resistor R1 is 5.1 Kohm, and the resistance value of the second resistor R2 is 100 ohm. In this way, after the second resistor R2 is connected in parallel to the first resistor R1, the equivalent resistance of the two is as small as possible, that is, the potential of the communication interface of the electronic device is forced to be pulled down to the potential of the third power line as much as possible.

[0129] In another embodiment, see Figure 5 , the second protocol module includes: a processing unit 51, a signal transmitting branch 52 and a signal receiving branch 53; the processing unit 51 is electrically connected to the signal transmitting branch 52 and the signal receiving branch 53 respectively;

[0130] The processing unit 51 is used to generate a control signal according to the second communication protocol;

[0131] The signal transmission branch 52 is used to transmit a communication signal according to the control signal of the processing unit 51;

[0132] The signal receiving branch 53 is used to receive a communication signal from the power supply device and transmit it to the processing unit 51, so that the processing unit 51 determines whether to use the second communication protocol to establish a communication connection with the power supply device according to the communication signal.

[0133] Continue to see Figure 5, the signal transmission branch 52 includes: a fourth resistor R4 and a fourth switch device Q4; a first end of the fourth resistor R4 is electrically connected to the first power line (such as power supply, VCC), and a second end of the fourth resistor R4 is electrically connected to the first end of the fourth switch device Q4; a second end of the fourth switch device Q4 is electrically connected to the communication interface of the electronic device, and a control end of the fourth switch device Q4 is electrically connected to the processing unit 51; the fourth switch device Q4 is used to turn on the fourth resistor R4 and the communication interface when receiving a control signal from the processing unit 51, at which time the level of the first power line can be transmitted to the communication interface, and the potential at the communication interface is a high level signal; and disconnect the fourth resistor R4 and the communication interface when the control signal of the processing unit 51 is not received, at which time the level of the first power line cannot be transmitted to the communication interface, and the potential at the communication interface is a low level, and the following is obtained. Figure 6 communication signals shown.

[0134] Based on the above inventive concept, the present disclosure also provides a power supply device, see Figure 7 ,include:

[0135] The first protocol module is used to establish a physical connection with the electronic device and identify the device role result;

[0136] The second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the electronic device according to the role recognition result;

[0137] The first protocol module is further used to determine to use the first communication protocol to establish a communication connection with the electronic device.

[0138] In one embodiment, the power supply device and Figure 2 to Figure 4 The electronic device shown is adapted, and the second protocol modules of the power supply device and the electronic device are implemented in a master-slave mode. Figure 8 The second protocol module of the power supply device includes: a processing unit 81, a signal transmitting branch 82 and a signal receiving branch 83. The processing unit 81 is electrically connected to the signal transmitting branch 82 and the signal receiving branch 83 respectively.

[0139] The signal transmission branch 82 is used to transmit a communication signal matching the second communication protocol according to the control signal of the processing unit 81;

[0140] The signal receiving branch 83 is used to receive a communication signal from the electronic device and transmit it to the processing unit 81, so that the processing unit 81 determines whether to establish a communication connection based on the second communication protocol with the electronic device according to the communication signal.

[0141] Continue to see Figure 8, the signal transmission branch 82 includes: a third resistor R3 and a third switch device Q3; the first end of the third resistor R3 is electrically connected to the first power line (such as VCC), and the second end of the third resistor R3 is electrically connected to the first end of the third switch device Q3; the second end of the third switch device Q3 is electrically connected to the communication interface of the power supply device, and the control end of the third switch device Q3 is electrically connected to the processing unit 81; the third switch device Q3 is used to turn on the third resistor R3 and the communication interface when receiving the control signal of the processing unit 81, thereby pulling the potential at the communication interface to the potential VCC of the first level line; and disconnect the third resistor R3 and the communication interface when not receiving the control signal of the processing unit 81, so that the potential at the communication interface is pulled down by the electronic device to the potential of the second level line, and the following is obtained. Fig. 9 communication signals shown.

[0142] In one embodiment, the power supply device and Figure 5-6 The electronic device shown is adapted, and the second protocol modules of the power supply device and the electronic device are implemented in a master-slave mode. Fig.10 The second protocol module of the power supply device includes: a processing unit 101, a communication holding branch 102, a signal transmitting branch 103 and a signal receiving branch 104; the processing unit 101 is electrically connected to the communication holding branch 102, the signal transmitting branch 103 and the signal receiving branch 104 respectively;

[0143] The communication holding branch 102 is used to be electrically connected to the second power line to establish a physical connection with the electronic device;

[0144] The signal transmission branch 103 is used to transmit a communication signal matching the second communication protocol according to the control signal of the processing unit 101;

[0145] The signal receiving branch 104 is used to receive a communication signal from the electronic device and transmit it to the processing unit 101, so that the processing unit 101 determines whether to establish a communication connection with the electronic device using the second communication protocol according to the communication signal.

[0146] Continue to see Fig.10 The communication maintaining branch 102 includes: a fifth resistor R5 and a fifth switch device Q5; the first end of the fifth resistor R5 is electrically connected to the communication interface of the power supply device, and the second end of the fifth resistor R5 is electrically connected to the first end of the fifth switch device Q5; the second end of the fifth switch device Q5 is electrically connected to the second power line, and the control end of the fifth switch device Q5 is electrically connected to the processing unit 101; the fifth switch device Q5 is used to turn on the fifth resistor R5 and the second power line when receiving the control signal of the processing unit 101, and at this time, the potential at the communication interface is pulled down to the potential of the second power line, thereby establishing a physical connection with the electronic device.

[0147] Continue to see Fig.10The signal transmission branch 103 includes: a signal transmission unit TX and a branch control unit 1031; the input end of the signal transmission unit TX is electrically connected to the processing unit 101, and the output end of the signal transmission unit TX is electrically connected to the branch control unit 1031; the branch control unit 1031 is electrically connected to the communication interface and the third power line of the power supply device respectively; the branch control unit 1031 is used to turn on the communication interface and the third power line of the power supply device according to the control signal output by the signal transmission unit TX, at which time the potential of the communication interface of the power supply device is pulled down to the potential of the third power line, and a low-level signal is output at this time; and disconnect the communication interface and the third power line of the power supply device when the control signal output by the signal transmission unit TX is not received, at which time the potential of the communication interface of the power supply device is pulled up by the electronic device to the potential of the first power line, and a high-level signal is output at this time, and the following is obtained: Fig.11 communication signals shown.

[0148] It should be noted that the third power line can provide different level signals, such as 0V voltage or other non-zero voltage, for the signal transmission branch 103, which can be set according to specific scenarios. In one example, the third power line is electrically connected to the second power line, and both are ground lines.

[0149] In one embodiment, see Fig.10 , the branch control unit 1031 includes: a sixth resistor R6 and a sixth switch device Q6; the first end of the sixth resistor Q6 is electrically connected to the communication interface of the power supply device, the second end of the sixth resistor R6 is electrically connected to the first end of the sixth switch device Q6; the second end of the sixth switch device Q6 is electrically connected to the second power line, and the control end of the sixth switch device Q6 is electrically connected to the signal transmitting unit TX;

[0150] The sixth switching device Q6 is used to turn on the sixth resistor R6 and the second power line when receiving the control signal of the signal transmitting unit TX, so that the potential of the communication interface of the power supply device can be pulled down to the potential of the second power line, and a low-level signal can be output at this time; and to disconnect the sixth resistor R6 and the second power line when the control signal of the signal transmitting unit TX is not received, and at this time the potential of the communication interface of the power supply device is pulled up by the electronic device to the potential of the first power line, and a high-level signal can be output at this time.

[0151] It should be noted that, in one example, the resistance value of the sixth resistor R6 is smaller than the resistance value of the fifth resistor R5 in the communication holding branch 102, so that the difference between the two resistance values ​​is as large as possible, for example, the resistance value of the fifth resistor R5 is 5.1 Kohm, and the resistance value of the sixth resistor R6 is 100 ohm. In this way, after the sixth resistor R6 is connected in parallel to the fifth resistor R5, the equivalent resistance of the two is as small as possible, that is, the potential of the communication interface of the power supply device is forced to be pulled down to the potential of the second power line as much as possible.

[0152] Combine the following Figure 2 to Figure 4 The electronic equipment shown is Figure 8 The power supply device shown in the figure describes the communication method between the electronic device and the power supply device, see Fig.12 ,include:

[0153] When the electronic device and the power supply device are respectively plugged into the charging bus, the first protocol module of the electronic device and the first protocol module of the power supply device respectively identify the device role results. At this time, the power supply device is a source device and the electronic device is a sink device. The second protocol module can inherit the above device role results. Assuming that the second communication protocol used by the second protocol module stipulates that the source device initiates a handshake, the power supply device can control the third switch device Q3 to turn on to access the first power line, and the electronic device controls the first switch device Q1 to turn on to access the second power line. In this way, a current path is formed between the first power line, the third resistor R3, the third switch device Q3, the charging bus, the first resistor R1, the first switch device Q1 and the second power line, that is, the power supply device and the electronic device establish a physical connection.

[0154] The power supply device can enable the signal transmission branch, and the electronic device can enable the signal receiving branch to work. The processing unit of the power supply device can control the signal transmission branch TX to output a control signal according to the second communication protocol, and the control signal can control the third switch device Q3 to turn on or off, thereby forming a Fig. 9 The communication signal shown can be transmitted to the signal receiving branch of the electronic device through the charging bus.

[0155] The electronic device can wait for receiving the communication signal within a preset time. If the communication signal is received within the preset time, the processing unit of the electronic device can generate a response signal of the communication signal according to the second communication protocol. That is, the processing unit of the electronic device can control the second switch device Q2 to be turned on or off, thereby forming a Figure 4 The response signal of the communication signal exemplified. The signal receiving branch of the power supply device may receive the response signal, and the power supply device may establish a communication connection based on the second communication protocol with the electronic device.

[0156] It should be noted that this example only describes the process of establishing a communication connection between the power supply device and the electronic device through one communication. In actual scenarios, multiple communications can be performed in combination with the requirements of the communication protocol, such as three-way handshake communication. The process of each communication is similar. For details, please refer to the above content to achieve the effect of establishing a communication connection.

[0157] If the electronic device does not receive the above communication signal within a preset time period, the first protocol module of the electronic device and the first protocol module of the power supply device establish a communication connection based on the first communication protocol.

[0158] In this way, in this embodiment, the communication connection is established through the second protocol module in the master-slave mode, which can simplify the structure of the second protocol module and reduce costs while ensuring the communication effect.

[0159] Combine the following Figure 5-6 The electronic equipment shown is Fig.10 and Fig.11 The power supply device shown in the figure describes the communication method between the electronic device and the power supply device, see Fig.13 ,include:

[0160] When the electronic device and the power supply device are respectively plugged into the charging bus, the first protocol module of the electronic device and the first protocol module of the power supply device respectively identify the device role results. At this time, the power supply device is a source device and the electronic device is a sink device. The second protocol module can inherit the above device role results. Assuming that the second communication protocol used by the second protocol module stipulates that the source device initiates a handshake, the electronic device can control the fourth switch device Q4 to turn on to access the first power line, and the power supply device controls the fifth switch device Q5 to turn on to access the second power line. In this way, a current path is formed between the first power line, the fourth resistor R4, the fourth switch device Q4, the charging bus, the fifth resistor R5, the fifth switch device Q5 and the second power line, that is, the power supply device and the electronic device establish a physical connection.

[0161] The power supply device can enable the signal transmission branch, and the electronic device can enable the signal receiving branch to work. The processing unit of the power supply device can control the signal transmission branch TX to output a control signal according to the second communication protocol, and the control signal can control the sixth switch device Q6 to turn on or off, thereby forming a Fig.11 The communication signal shown can be transmitted to the signal receiving branch of the electronic device through the charging bus.

[0162] The electronic device can wait for receiving the communication signal within a preset time. If the communication signal is received within the preset time, the processing unit of the electronic device can generate a response signal of the communication signal according to the second communication protocol. That is, the processing unit of the electronic device can control the fourth switch device Q4 to be turned on or off, thereby forming a Figure 6 The response signal of the communication signal exemplified. The signal receiving branch of the power supply device may receive the response signal, and the power supply device may establish a communication connection based on the second communication protocol with the electronic device.

[0163] It should be noted that this example only describes the process of establishing a communication connection between the power supply device and the electronic device through one communication. In actual scenarios, multiple communications can be performed in combination with the requirements of the communication protocol, such as three-way handshake communication. The process of each communication is similar. For details, please refer to the above content to achieve the effect of establishing a communication connection.

[0164] If the electronic device does not receive the above communication signal within a preset time period, the first protocol module of the electronic device and the first protocol module of the power supply device establish a communication connection based on the first communication protocol.

[0165] In this way, in this embodiment, the communication connection is established through the second protocol module in the master-slave mode, which can simplify the structure of the second protocol module and reduce costs while ensuring the communication effect.

[0166] Based on the contents of the above embodiments, the present disclosure also provides a communication method suitable for electronic devices, see Fig.14 , including step 141 and step 142.

[0167] In step 141, in response to establishing a physical connection with the first protocol module of the power supply device, waiting for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol;

[0168] In step 142, in response to receiving the communication signal within the preset time period, a response signal to the communication signal is generated according to the second communication protocol and sent to the power supply device through the physical connection to establish a communication connection with the power supply device based on the second communication protocol.

[0169] In one embodiment, generating a response signal to the communication signal according to the second communication protocol includes:

[0170] generating a control signal according to a second communication protocol;

[0171] The second switch device of the branch control unit in the second protocol module is controlled to be turned on or off according to the control signal to generate a response signal to the communication signal.

[0172] In one embodiment, the method further comprises:

[0173] In response to not receiving a communication signal sent by the power supply device within a preset time period, establishing a communication connection with the power supply device based on a first communication protocol.

[0174] It should be noted that the communication method embodiment shown in this embodiment matches the content of the interaction process between the above-mentioned electronic device and the power supply device. You can refer to the content of the above-mentioned interaction embodiment and will not repeat it here.

[0175] Based on the contents of the above embodiments, the present disclosure also provides a communication method suitable for power supply equipment, see Fig.15 , including step 151 and step 152.

[0176] In step 151, in response to establishing a physical connection with a first protocol module of an electronic device, a communication signal is generated according to a second communication protocol and sent to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal;

[0177] In step 152, in response to receiving a response signal returned by the electronic device within a preset time period, a communication connection is established with the electronic device based on the second communication protocol.

[0178] In one embodiment, generating a communication signal according to a second communication protocol includes:

[0179] generating a control signal according to a second communication protocol;

[0180] The fifth switch device of the branch control unit in the second protocol module is controlled to be turned on or off according to the control signal to generate the communication signal.

[0181] In one embodiment, the method further comprises:

[0182] In response to not receiving a response signal returned by the electronic device within a preset time period, establishing a communication connection with the electronic device based on a first communication protocol.

[0183] It should be noted that the communication method embodiment shown in this embodiment matches the content of the interaction process between the above-mentioned electronic device and the power supply device. You can refer to the content of the above-mentioned interaction embodiment and will not repeat it here.

[0184] On the basis of a communication method provided in an embodiment of the present disclosure, an embodiment of the present disclosure further provides a communication device, which is applicable to the above-mentioned electronic device, and the device includes:

[0185] A communication signal receiving module, configured to, in response to establishing a physical connection with the first protocol module of the power supply device, wait for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol;

[0186] A response signal generating module is used to generate a response signal of the communication signal according to the second communication protocol in response to receiving the communication signal within the preset time period, and send it to the power supply device through the physical connection, so as to establish a communication connection with the power supply device based on the second communication protocol.

[0187] In one embodiment, the response signal generating module includes:

[0188] A control signal generating unit, configured to generate a control signal according to a second communication protocol;

[0189] A response signal generating unit is used to control the second switch device of the branch control unit in the second protocol module to be turned on or off according to the control signal, so as to generate a response signal to the communication signal.

[0190] In one embodiment, the device further comprises:

[0191] The communication connection establishing module is used to establish a communication connection with the power supply device based on a first communication protocol in response to not receiving a communication signal sent by the power supply device within a preset time period.

[0192] It should be noted that the device embodiment shown in this embodiment matches the content of the above method embodiment, and the content of the above method embodiment can be referred to, which will not be repeated here.

[0193] On the basis of a communication method provided in an embodiment of the present disclosure, an embodiment of the present disclosure further provides a communication device, which is applicable to the above-mentioned power supply device, and the device includes:

[0194] a communication signal sending module, configured to generate a communication signal according to a second communication protocol in response to establishing a physical connection with the first protocol module of the electronic device, and send the communication signal to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal;

[0195] The communication connection establishing module is used to establish a communication connection with the electronic device based on the second communication protocol in response to receiving a response signal returned by the electronic device within a preset time period.

[0196] In one embodiment, the communication signal sending module includes:

[0197] A control signal generating unit, configured to generate a control signal according to a second communication protocol;

[0198] A communication signal generating unit is used to control the fifth switch device of the branch control unit in the second protocol module to be turned on or off according to the control signal to generate the communication signal.

[0199] In one embodiment, the device further comprises:

[0200] The communication connection establishing module is further used to establish a communication connection with the electronic device based on the first communication protocol in response to not receiving a response signal returned by the electronic device within a preset time period.

[0201] It should be noted that the device embodiment shown in this embodiment matches the content of the above method embodiment, and the content of the above method embodiment can be referred to, which will not be repeated here.

[0202] Fig.161 is a block diagram of an electronic device according to an exemplary embodiment. For example, the electronic device 1600 may be a smart phone, a computer, a digital broadcast terminal, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0203] Reference Fig.16 The electronic device 1600 may include one or more of the following components: a processing component 1602 , a memory 1604 , a power component 1606 , a multimedia component 1608 , an audio component 1610 , an input / output (I / O) interface 1612 , a sensor component 1614 , a communication component 1616 , and an image acquisition component 1618 .

[0204] The processing component 1602 generally controls the overall operation of the electronic device 1600, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 1602 may include one or more processors 1620 to execute computer programs. In addition, the processing component 1602 may include one or more modules to facilitate interaction between the processing component 1602 and other components. For example, the processing component 1602 may include a multimedia module to facilitate interaction between the multimedia component 1608 and the processing component 1602. In an example, the processor 1620 may implement the scheme of the above-mentioned power supply control method.

[0205] The memory 1604 is configured to store various types of data to support operations on the electronic device 1600. Examples of such data include computer programs for any application or method operating on the electronic device 1600, contact data, phone book data, messages, pictures, videos, etc. The memory 1604 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0206] The power supply component 1606 provides power to various components of the electronic device 1600. The power supply component 1606 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 1600. The power supply component 1606 may include a power supply chip, and the controller may communicate with the power supply chip to control the power supply chip to turn on or off the first switching device, so that the battery supplies power to the mainboard circuit or does not supply power.

[0207] The multimedia component 1608 includes a screen that provides an output interface between the electronic device 1600 and the target object.

[0208] In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input information from a target object. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation.

[0209] The audio component 1610 is configured to output and / or input audio file information. For example, the audio component 1610 includes a microphone (MIC), and when the electronic device 1600 is in an operation mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive external audio file information. The received audio file information can be further stored in the memory 1604 or sent via the communication component 1616. In some embodiments, the audio component 1610 also includes a speaker for outputting audio file information.

[0210] The I / O interface 1612 provides an interface between the processing component 1602 and a peripheral interface module, which may be a keyboard, a click wheel, a button, etc.

[0211] The sensor component 1614 includes one or more sensors for providing various aspects of status assessment for the electronic device 1600. For example, the sensor component 1614 can detect the open / closed state of the electronic device 1600, the relative positioning of the components, such as the display screen and the keypad of the electronic device 1600, and the sensor component 1614 can also detect the position change of the electronic device 1600 or a component, the presence or absence of contact between the target object and the electronic device 1600, the orientation or acceleration / deceleration of the electronic device 1600, and the temperature change of the electronic device 1600. In this example, the sensor component 1614 can include a magnetic sensor, a gyroscope, and a magnetic field sensor, and can also include an inertial sensor, an image sensor, etc., wherein the magnetic field sensor includes at least one of the following: a Hall sensor, a thin film magnetoresistive sensor, and a magnetic liquid acceleration sensor.

[0212] The communication component 1616 is configured to facilitate wired or wireless communication between the electronic device 1600 and other devices. The electronic device 1600 can access a wireless network based on a communication standard, such as WiFi, 2G, 3G, 4G, 5G, or a combination thereof. In an exemplary embodiment, the communication component 1616 receives broadcast information or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 1616 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0213] In an exemplary embodiment, the electronic device 1600 may be implemented by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components.

[0214] In an exemplary embodiment, the present disclosure also provides a non-transitory computer-readable storage medium, and when an executable computer program in the storage medium is executed by a processor, the above-mentioned method can be implemented.

[0215] In an exemplary embodiment, a chip is also provided, the chip including a processor and an interface for reading a computer program through the interface to implement the above method. The chip may be a conventional CPU (central processing unit) chip, a GPU (graphics processing unit) chip, etc., or an acceleration chip dedicated to artificial intelligence technology, such as an AI (Artificial Intelligence) accelerator, etc.

[0216] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the disclosure disclosed herein. The present disclosure is intended to cover any variations, uses, or adaptations that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.

[0217] 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. An electronic device, characterized in that: including a first protocol module and a second protocol module; The first protocol module is used to establish a physical connection with the power supply device and identify the device role result; The second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification result; The first protocol module is further used to determine whether to use the first communication protocol to establish a communication connection with the electronic device.

2. The electronic device according to claim 1, characterized in that: The second protocol module of the electronic device and the second protocol module of the power supply device are implemented in a master-slave mode.

3. The electronic device according to claim 2, characterized in that: When the electronic device is a slave device, the second protocol module determines whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification role result, including: in response to receiving a communication signal generated by the power supply device according to the second communication protocol, establishing a communication connection based on the second communication protocol with the power supply device.

4. The electronic device according to claim 2, characterized in that: The second protocol module of the electronic device comprises: a processing unit, a communication holding branch, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the communication holding branch, the signal transmitting branch and the signal receiving branch respectively; The communication holding branch is used to be electrically connected to the second power line to establish a physical connection with the power supply device; The signal transmission branch is used to transmit a communication signal according to the control signal of the processing unit; The signal receiving branch is used to receive a communication signal from the power supply device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the power supply device according to the communication signal.

5. The electronic device according to claim 4, characterized in that: The communication holding branch includes: a first resistor and a first switch device; a first end of the first resistor is electrically connected to the communication interface of the electronic device, and a second end of the first resistor is electrically connected to a first end of the first switch device; a second end of the first switch device is electrically connected to a second power line, and a control end of the first switch device is electrically connected to the processing unit; The first switch device is used to turn on the first resistor and the second power line when receiving a control signal from the processing unit.

6. The electronic device according to claim 4, characterized in that: The signal transmission branch includes: a signal transmission unit and a branch control unit; the input end of the signal transmission unit is electrically connected to the processing unit, and the output end of the signal transmission unit is electrically connected to the branch control unit; the branch control unit is electrically connected to the communication interface of the electronic device and the third power line respectively; The branch control unit is used to connect the communication interface and the third power line according to the control signal output by the signal transmitting unit.

7. The electronic device according to claim 6, characterized in that: The branch control unit includes: a second resistor and a second switch device; a first end of the second resistor is electrically connected to the communication interface of the electronic device, and a second end of the second resistor is electrically connected to a first end of the second switch device; a second end of the second switch device is electrically connected to a second power line, and a control end of the second switch device is electrically connected to the signal transmitting unit; The second switch device is used to turn on the second resistor and the second power line when receiving the control signal of the signal transmitting unit; The resistance value of the second resistor is smaller than the resistance value of the first resistor in the communication maintaining branch.

8. The electronic device according to claim 2, characterized in that: The second protocol module includes: a processing unit, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the signal transmitting branch and the signal receiving branch respectively; The signal transmission branch is used to transmit a communication signal according to the control signal of the processing unit; The signal receiving branch is used to receive a communication signal from the power supply device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the power supply device according to the communication signal.

9. The electronic device according to claim 8, characterized in that: The signal transmission branch includes: a fourth resistor and a fourth switch device; the first end of the fourth resistor is electrically connected to the first power line, and the second end of the fourth resistor is electrically connected to the first end of the fourth switch device; the second end of the fourth switch device is electrically connected to the communication interface of the electronic device, and the control end of the fourth switch device is electrically connected to the processing unit; The fourth switch device is used to turn on the fourth resistor and the communication interface when receiving a control signal from the processing unit.

10. A power supply device, characterized in that: include: a first protocol module and a second protocol module; The first protocol module is used to establish a physical connection with the electronic device and identify the device role result; The second protocol module is used to determine whether to use the second communication protocol to establish a communication connection with the electronic device according to the role recognition result; The first protocol module is further used to determine whether to use the first communication protocol to establish a communication connection with the electronic device.

11. The power supply device according to claim 10, characterized in that: The second protocol module of the power supply device and the second protocol module of the electronic device are implemented in a master-slave mode.

12. The power supply device according to claim 11, characterized in that: When the power supply device is the main device, the second protocol module determines whether to use the second communication protocol to establish a communication connection with the power supply device according to the identification role result, including: generating a communication signal according to the second communication protocol and sending it to the electronic device, so that the electronic device establishes a communication connection based on the second communication protocol with the power supply device after receiving the communication signal.

13. The power supply device according to claim 11, characterized in that: The second protocol module of the power supply device comprises: a processing unit, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the signal transmitting branch and the signal receiving branch respectively; The signal transmission branch is used to transmit a communication signal matching a second communication protocol according to a control signal of the processing unit; The signal receiving branch is used to receive a communication signal from the electronic device and transmit the signal to the processing unit, so that the processing unit determines whether to establish a communication connection based on the second communication protocol with the electronic device according to the communication signal.

14. The power supply device according to claim 13, characterized in that: The signal transmission branch includes: a third resistor and a third switch device; the first end of the third resistor is electrically connected to the first power line, and the second end of the third resistor is electrically connected to the first end of the third switch device; the second end of the third switch device is electrically connected to the communication interface of the power supply device, and the control end of the third switch device is electrically connected to the processing unit; The third switch device is used to turn on the third resistor and the communication interface when receiving a control signal from the processing unit.

15. The power supply device according to claim 11, characterized in that: The second protocol module of the power supply device includes: a processing unit, a communication holding branch, a signal transmitting branch and a signal receiving branch; the processing unit is electrically connected to the communication holding branch, the signal transmitting branch and the signal receiving branch respectively; The communication holding branch is used to be electrically connected to the second power line to establish a physical connection with the electronic device; The signal transmission branch is used to transmit a communication signal matching the second communication protocol according to the control signal of the processing unit; The signal receiving branch is used to receive a communication signal from the electronic device and transmit it to the processing unit, so that the processing unit determines whether to establish a communication connection with the electronic device using a second communication protocol according to the communication signal.

16. The power supply device according to claim 15, characterized in that: The communication holding branch includes: a fifth resistor and a fifth switch device; the first end of the fifth resistor is electrically connected to the communication interface of the power supply device, and the second end of the fifth resistor is electrically connected to the first end of the fifth switch device; the second end of the fifth switch device is electrically connected to the second power line, and the control end of the fifth switch device is electrically connected to the processing unit; The fifth switch device is used to turn on the first resistor and the second power line when receiving a control signal from the processing unit.

17. The power supply device according to claim 15, characterized in that: The signal transmission branch includes: a signal transmission unit and a branch control unit; the input end of the signal transmission unit is electrically connected to the processing unit, and the output end of the signal transmission unit is electrically connected to the branch control unit; the branch control unit is electrically connected to the communication interface of the power supply device and the second power line respectively; The branch control unit is used to conduct the communication interface of the power supply device and the second power line according to the control signal output by the signal transmitting unit.

18. The power supply device according to claim 17, characterized in that: The branch control unit includes: a sixth resistor and a sixth switch device; the first end of the sixth resistor is electrically connected to the communication interface of the power supply device, and the second end of the sixth resistor is electrically connected to the first end of the sixth switch device; the second end of the sixth switch device is electrically connected to the second power line, and the control end of the sixth switch device is electrically connected to the signal transmitting unit; The sixth switch device is used for conducting the sixth resistor and the second power line when receiving the control signal of the signal transmitting unit; The resistance value of the sixth resistor is smaller than the resistance value of the fifth resistor in the communication maintaining branch.

19. A communication system, characterized in that: It comprises the electronic device as described in any one of claims 1 to 9, the power supply device and the charging bus as described in any one of claims 10 to 18, wherein the electronic device is electrically connected to the power supply device via the charging bus; the electronic device establishes a physical connection with the power supply device via the charging bus, and determines a corresponding communication protocol based on the physical connection to establish a communication connection.

20. A communication method, characterized in that: Applicable to the electronic device according to any one of claims 1 to 9, the method comprising: In response to establishing a physical connection with the first protocol module of the power supply device, waiting for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol; In response to receiving the communication signal within the preset time period, a response signal to the communication signal is generated according to the second communication protocol and sent to the power supply device through the physical connection to establish a communication connection with the power supply device based on the second communication protocol.

21. A communication method, characterized in that: Applicable to the power supply device according to any one of claims 10 to 18, the method comprising: In response to establishing a physical connection with a first protocol module of an electronic device, generating a communication signal according to a second communication protocol and sending the communication signal to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal; In response to receiving a response signal returned by the electronic device within a preset time period, a communication connection is established with the electronic device based on the second communication protocol.

22. A communication device, characterized in that: Applicable to the electronic device according to any one of claims 1 to 9, the device comprising: A communication signal receiving module, configured to, in response to establishing a physical connection with the first protocol module of the power supply device, wait for receiving a communication signal within a preset time period; the communication signal is generated by the power supply device according to the second communication protocol; A response signal generating module is used to generate a response signal of the communication signal according to the second communication protocol in response to receiving the communication signal within the preset time period, and send it to the power supply device through the physical connection, so as to establish a communication connection with the power supply device based on the second communication protocol.

23. A communication device, characterized in that: Applicable to the power supply equipment according to any one of claims 10 to 18, the device comprising: a communication signal sending module, configured to generate a communication signal according to a second communication protocol in response to establishing a physical connection with the first protocol module of the electronic device, and send the communication signal to the electronic device through the physical connection, so that the electronic device generates a response signal in response to the communication signal; The communication connection establishing module is used to establish a communication connection with the electronic device based on the second communication protocol in response to receiving a response signal returned by the electronic device within a preset time period.

24. An electronic device, characterized in that: include: Processor and memory; The memory is used to store a computer program executable by the processor; The processor is configured to execute the computer program in the memory to implement the method according to claim 20.

25. A power supply device, characterized in that: include: Processor and memory; The memory is used to store a computer program executable by the processor; The processor is configured to execute the computer program in the memory to implement the following The method of claim 21.

26. A non-transitory computer-readable storage medium, characterized in that: When the executable computer program in the storage medium is executed by a processor, the method according to claim 20 or 21 can be implemented.