A pd fast charging control circuit and method supporting upgrading of mcu firmware

By adding a pass-through selection module for I2C and CC terminals inside the PD fast charging control circuit chip, the problem of inconvenient MCU firmware upgrades in small home devices is solved, and an efficient firmware upgrade method is realized.

CN117667150BActive Publication Date: 2026-11-20SINMIKRO ELEKTRONIKS KO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311705306.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-12
Publication Date
2026-11-20
Estimated Expiration
2043-12-12

AI Technical Summary

Technical Problem

In small home appliances, especially electric scooters, it is difficult to upgrade the MCU firmware after the device is assembled. Existing technology methods make the upgrade inconvenient and slow.

Method used

A pass-through selection module for the I2C and CC terminals is added inside the PD fast charging control circuit chip. The MCU module controls the switch to realize direct interaction between the USB interface and the MCU, and the signal lines of the I2C and CC interfaces are used for firmware upgrades.

Benefits of technology

This enables direct firmware upgrades for MCUs without increasing the number of chip pins, improving upgrade efficiency and convenience while avoiding inconvenience for consumers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117667150B_ABST
    Figure CN117667150B_ABST
Patent Text Reader

Abstract

The application provides a PD fast charging control circuit supporting upgrading of MCU firmware and a method thereof, the method comprising: outputting two high-level signals by an RTL digital circuit when receiving an upgrade handshake command transmitted by a host; when a USB plug is connected, VBUS_DET is high level, at this time, VBUS_DET and the RTL digital circuit output high-level signals, so that the c end of the first switch and the second switch is connected to the a end; when the RTL digital circuit receives a pass-through start I2C signal, the c end of the first switch and the second switch is connected to the a end, at this time, the pass-through selection module is started; after the upgrade is completed, the VBUS_DET signal becomes low level, the RTL digital circuit output is also low level, so that the c end of the pass-through selection module is connected to the b end, at this time, the pass-through selection module is closed. Without increasing the number of PD fast charging control circuit chip pins, the pass-through selection module with an I2C end and a CC end is added in the PD fast charging control circuit chip, so that the USB interface and the MCU can directly interact.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of firmware upgrade technology, and more specifically to a PD fast charging control circuit that supports upgrading MCU firmware and a method for using the circuit. Background Technology

[0002] In small home environments, many devices have a strong need for fast charging. For example, electric scooters often utilize USB Type-C & PD technology and the PD fast charging protocol to quickly charge the battery pack. In these types of products, since there's no need for USB data transfer, they mostly use a more streamlined USB interface, such as... Figure 1 As shown:

[0003] To comply with USB interface specifications and reduce design complexity, in this type of scenario, the USB interface is typically directly connected to the Type-C & PD Controller. The MCU in the device controls the Type-C & PD Controller to perform operations such as fast charging protocol interaction and fast charging management. (A diagram of this connection method is shown below.) Figure 2 As shown.

[0004] However, this connection method poses a significant challenge to upgrading the MCU firmware in small home devices (especially after assembly into a complete device). Generally, MCU upgrades and programming can be done using firmware. However, for small home devices like electric scooters, the MCU, Type-C & PD controller, and Type-C interface are already integrated into the device. Continuing to use firmware for upgrades would cause great inconvenience to consumers and significantly reduce speed. Therefore, addressing these shortcomings has become an urgent problem to be solved in upgrading the MCU firmware of small home devices. Summary of the Invention

[0005] This invention provides a PD fast charging control circuit and method that supports MCU firmware upgrades. The circuit and method mainly utilize hardware circuit modifications to enable direct interaction between the USB interface and the MCU without increasing the number of pins on the PD fast charging control circuit chip.

[0006] The present invention achieves the above objectives through the following technical solutions:

[0007] A PD fast charging control circuit supporting MCU firmware upgrades is disclosed. The PD fast charging control circuit is connected to the MCU module via an I2C interface and to a USB interface via a CC interface. The I2C interface includes an SCL terminal, an SDA terminal, and an INT terminal. The CC interface includes a CC1 terminal and a CC2 terminal. The PD fast charging control circuit comprises:

[0008] The system includes a configuration control circuit, an RTL digital circuit, a PD fast charging control module, a USB PD control module, a USB Type-C current detection module, a VCONN control module, a receive control module, a VBUS detection and discharge module, a switch module, and a pass-through selection module. The pass-through selection module includes a first switch and a second switch. Terminal a of the first switch is connected between the SDA terminal and the configuration control circuit, terminal b of the first switch is connected to the RTL digital circuit, and terminal c of the first switch is connected to the CC1 terminal. Terminal a of the second switch is connected between the SCL terminal and the configuration control circuit, terminal b of the first switch is connected to the RTL digital circuit, and terminal c of the second switch is connected to the CC2 terminal.

[0009] The configuration control circuit is connected to the VCONN control module and the USB Type-C current detection module, respectively. The RTL digital circuit is connected to the PD fast charging control module. The PD fast charging control module is connected to the USB Type-C current detection module, the VCONN control module, the switch module, and the VBUS detection and discharge module, respectively. The VCONN control module is connected to the receiving control module, and the receiving control module is connected to the switch module.

[0010] A further embodiment is that the switch module includes a third switch, a fourth switch, a fifth switch, and a sixth switch. The first and second ends of the third switch and the first and second ends of the fourth switch are grounded. The third end of the third switch is connected to the second end of the fifth switch, and the third end of the fourth switch is connected to the second end of the sixth switch. The first ends of the fifth switch and the sixth switch are respectively connected to a current source.

[0011] A further proposed solution is that the opening and closing of the first and second switches are controlled by the RTL digital circuit through register commands written by the MCU module.

[0012] A PD fast charging control method that supports MCU firmware upgrades, applied to the aforementioned PD fast charging control circuit that supports MCU firmware upgrades, includes the following steps:

[0013] Upon receiving the upgrade handshake command from the host, i.e., after the I2C interface and configuration control circuit transmit a specific upgrade command, the RTL digital circuit outputs two high-level signals. When the USB plug is connected, VBUS_DET is high. At this time, VBUS_DET and the high-level signal transmitted by the RTL digital circuit are ANDed to produce a high-level signal, which makes the c terminals of the first switch and the second switch connected to the a terminal.

[0014] When the RTL digital circuit receives a pass-through enable I2C signal from the configuration control circuit, it connects the c-terminals of the first and second switches to the a-terminal, and the pass-through selection module is enabled.

[0015] After the upgrade is complete, the programmer automatically disconnects from the USB interface. At this time, the VBUS_DET signal is not detected, the VBUS_DET signal becomes low, and the output signal of the AND gate inside the RTL digital circuit is also low, so that the c terminal of the pass-through selection module is connected to the b terminal. At this time, the pass-through selection module is turned off.

[0016] According to the PD fast charging control method for supporting MCU firmware upgrade provided by the present invention, the RTL digital circuit receives the upgrade success command transmitted from the PD fast charging control module and sends a high-level signal to the pass-through selection module. During the upgrade, VBUS_DET is high level. The two high-level signals are output as a high-level signal after passing through the AND gate of the RTL digital circuit. The first switch and the second switch receive the high-level signal to enable the pass-through selection module.

[0017] According to the PD fast charging control method for supporting MCU firmware upgrades provided by the present invention, when upgrading the MCU firmware, the host and the device to be upgraded are connected via a USB interface and the connection is maintained continuously.

[0018] Upon receiving the upgrade command, the MCU module writes to the register via the I2C interface, enabling the configuration control circuit to control the RTL digital circuit to enable the pass-through selection module. At this time, the two signal lines of the I2C interface and the two signal lines of CC are connected, i.e., SDA is connected to CC1 and SCL is connected to CC2, and the device begins the upgrade.

[0019] Once the upgrade is successful, the MCU module detects the success and prompts you to disconnect from the device.

[0020] According to the PD fast charging control method that supports MCU firmware upgrade provided by the present invention, when the VBUS detection and discharge module does not detect the VBUS signal transmitted from the host, the RTL digital circuit recognizes that the pass-through selection module is not closed, and closes the pass-through selection module, disconnecting the SDA and SCL terminals of the I2C interface from the CC1 and CC2 terminals of the CC interface.

[0021] According to the PD fast charging control method that supports MCU firmware upgrade provided by the present invention, during the upgrade, the host also controls the device to be upgraded to set the detection flag bit according to the upgrade handshake command;

[0022] Based on the detection flag set in the device to be upgraded, the system controls the device to receive the firmware to be upgraded sent by the host via the I2C protocol and updates the firmware received by the device last time.

[0023] Based on the firmware update status within the device to be upgraded, control the device to change the corresponding detection flag bit, and then repeat the above steps.

[0024] When the device to be upgraded confirms that it has received the upgrade completion command sent by the host, it clears the corresponding detection flag and completes the firmware upgrade update of the device.

[0025] According to the PD fast charging control method for supporting MCU firmware upgrade provided by the present invention, when setting the detection flag bit, the device to be upgraded is controlled to respond to the upgrade handshake command and receive the host's request query for its relevant detection flag bit, and then the detection flag bit is assigned the corresponding logical value.

[0026] The upgrade handshake command includes the status information of the previous firmware upgrade, the current firmware upgrade instruction, and the adjustment parameters required by the device to be upgraded.

[0027] According to the PD fast charging control method that supports MCU firmware upgrades provided by the present invention, the VBUS detection and discharge module is used to filter VBUS_DET. Since VBUS_DET is generated by VBUS after voltage division by resistors, it is ANDed with the signal transmitted from the RTL digital circuit after filtering.

[0028] Therefore, compared with the prior art, the present invention has the following beneficial effects:

[0029] 1. Without changing other parts of the PD fast charging control circuit, the present invention adds a pass-through selection module containing two I2C signal lines and two CC signal lines inside the USB Type C and PD. The opening and closing of the two sets of switches of the pass-through selection module are controlled by the RTL digital circuit by the MCU writing commands to the register.

[0030] 2. Without increasing the number of pins on the Type C&PD Controller chip, this invention adds a pass-through selection module between the I2C and CC terminals inside the Type C&PD Controller chip, enabling the USB interface and the MCU to interact directly under certain circumstances, and allowing for hardware self-reset after each successful upgrade.

[0031] 3. Since small home devices cannot interact with the MCU via the Type-C & PD Controller module on the USB interface, this invention can indirectly bypass this module and interact directly with the MCU.

[0032] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments. Attached Figure Description

[0033] Figure 1 This is a schematic diagram of a typical fast charging control circuit in existing technology.

[0034] Figure 2 This is a circuit diagram of a conventional fast charging protocol application in existing technology.

[0035] Figure 3 This is a circuit schematic diagram of an embodiment of a PD fast charging control circuit that supports MCU firmware upgrades according to the present invention. Detailed Implementation

[0036] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the described embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0037] An embodiment of a PD fast charging control circuit that supports MCU firmware upgrades

[0038] See Figure 2 and Figure 3 This embodiment provides a PD fast charging control circuit that supports MCU firmware upgrades, comprising: a PD fast charging control circuit connected to an MCU module via an I2C interface, and a PD fast charging control circuit connected to a USB interface via a CC interface. The I2C interface includes an SCL terminal, an SDA terminal, and an INT terminal, and the CC interface includes a CC1 terminal and a CC2 terminal. The PD fast charging control circuit includes:

[0039] The system includes a configuration control circuit, an RTL digital circuit, a PD fast charging control module, a USB PD control module, a USB Type-C current detection module, a signal line detection module, a VCONN control module, a receive control module, a VBUS detection and discharge module, a switch module, and a pass-through selection module. The pass-through selection module includes a first switch K1 and a second switch K2. Terminal a of the first switch K1 is connected between the SDA terminal and the configuration control circuit, terminal b of the first switch K1 is connected to the RTL digital circuit, and terminal c of the first switch K1 is connected to the CC1 terminal. Terminal a of the second switch K2 is connected between the SCL terminal and the configuration control circuit, terminal b of the first switch K1 is connected to the RTL digital circuit, and terminal c of the second switch K2 is connected to the CC2 terminal.

[0040] The receiving control module exists as a receiver or source accessory mode control.

[0041] The configuration control circuit is connected to the VCONN control module and the USB Type-C current detection module, respectively. The RTL digital circuit is connected to the PD fast charging control module. The PD fast charging control module is connected to the USB Type-C current detection module, the VCONN control module, the switch module, and the VBUS detection and discharge module, respectively. The VCONN control module is connected to the receiving control module, and the receiving control module is connected to the switch module.

[0042] The RTL digital circuit receives upgrade commands from the I2 interface and configuration control circuit, outputting a high level to control the switch's activation during the upgrade process, in conjunction with the high level of VBUS_DET. The shutdown process occurs when the programmer automatically shuts down the USB interface upon completion of the upgrade. When no VBUS voltage is detected, VBUS_DET goes low, outputting a low voltage after passing through an AND gate. This connects the collector (C) of the pass-through selection module's switch to the base (B) of the switch, thus shutting down the pass-through selection module.

[0043] In this embodiment, the switch module includes a third switch K3, a fourth switch K4, a fifth switch K5, and a sixth switch K6. The first and second ends of the third switch K3 and the first and second ends of the fourth switch K4 are grounded. The third end of the third switch K3 is connected to the second end of the fifth switch K5. The third end of the fourth switch K4 is connected to the second end of the sixth switch K6. The first ends of the fifth switch K5 and the sixth switch K6 are respectively connected to a current source.

[0044] The opening and closing of the first switch K1 and the second switch K2 are controlled by the RTL digital circuit through commands written into the register by the MCU module.

[0045] An embodiment of a PD fast charging control method that supports MCU firmware upgrades

[0046] A PD fast charging control method that supports MCU firmware upgrades, applied to the aforementioned PD fast charging control circuit that supports MCU firmware upgrades, includes the following steps:

[0047] Upon receiving the upgrade handshake command from the host, i.e., after the I2C interface and configuration control circuit transmit a specific upgrade command, the RTL digital circuit outputs two high-level signals. When the USB plug is connected, VBUS_DET is high. At this time, VBUS_DET and the high-level signal transmitted by the RTL digital circuit are ANDed to produce a high-level signal, which makes the c terminals of the first switch K1 and the second switch K2 both connected to the a terminal.

[0048] When the RTL digital circuit receives the pass-through enable I2C signal from the configuration control circuit, it controls the c terminals of the first switch K1 and the second switch K2 to be connected to the a terminal, at which point the pass-through selection module is enabled.

[0049] After the upgrade is complete, the programmer automatically disconnects from the USB interface. At this time, the VBUS_DET signal is not detected, the VBUS_DET signal becomes low, and the output signal of the AND gate inside the RTL digital circuit is also low, so that the c terminal of the pass-through selection module is connected to the b terminal. At this time, the pass-through selection module is turned off.

[0050] In this embodiment, the RTL digital circuit receives the upgrade success command from the PD fast charging control module and sends a high-level signal to the pass-through selection module. During the upgrade, VBUS_DET is high. The two high-level signals are output as a high-level signal after passing through the AND gate of the RTL digital circuit. The first switch K1 and the second switch K2 receive the high-level signal, which enables the pass-through selection module to turn on.

[0051] In this embodiment, when upgrading the MCU firmware, the host and the device to be upgraded are connected via a USB interface and the connection is maintained continuously.

[0052] Upon receiving the upgrade command, the MCU module writes to the register via the I2C interface, enabling the configuration control circuit to control the RTL digital circuit to enable the pass-through selection module. At this time, the two signal lines of the I2C interface and the two signal lines of CC are connected, i.e., SDA is connected to CC1 and SCL is connected to CC2, and the device begins the upgrade.

[0053] Once the upgrade is successful, the MCU module detects the success and prompts you to disconnect from the device.

[0054] In this embodiment, when the VBUS detection and discharge module does not detect the VBUS signal transmitted from the host, the RTL digital circuit recognizes that the pass-through selection module is not closed, and closes the pass-through selection module, disconnecting the SDA and SCL terminals of the I2C interface from the CC1 and CC2 terminals of the CC interface.

[0055] In this embodiment, during the upgrade process, the host also controls the device to be upgraded to set a detection flag bit according to the upgrade handshake command;

[0056] Based on the detection flag set in the device to be upgraded, the system controls the device to receive the firmware to be upgraded sent by the host via the I2C protocol and updates the firmware received by the device last time.

[0057] Based on the firmware update status within the device to be upgraded, control the device to change the corresponding detection flag bit, and then repeat the above steps.

[0058] When the device to be upgraded confirms that it has received the upgrade completion command sent by the host, it clears the corresponding detection flag and completes the firmware upgrade update of the device.

[0059] When setting the detection flag, control the device to be upgraded to respond to the upgrade handshake command and receive the host's request for its relevant detection flags, and then assign the corresponding logical value to the detection flag.

[0060] The upgrade handshake command includes the previous firmware upgrade status information, the current firmware upgrade instruction, and the adjustment parameters required by the device to be upgraded. This enables firmware transmission and upgrade updates. This embodiment improves the versatility of the device in the firmware upgrade control system and expands the applicable scenarios of the firmware upgrade control method.

[0061] In this embodiment, a VBUS detection and discharge module is used to filter VBUS_DET. Since VBUS_DET is generated by dividing VBUS through resistors, it is ANDed with the signal transmitted from the RTL digital circuit after filtering. Therefore, the purpose of filtering VBUS_DET in the VBUS detection and discharge module is that VBUS_DET, generated by dividing VBUS through resistors, may contain glitches and needs to be filtered before it can be ANDed with the signal transmitted from the RTL digital circuit.

[0062] In practical applications, for small home devices, the main components for programming and upgrading include a PD fast charging control circuit and an MCU module. The PD fast charging control circuit primarily implements standard USB PD fast charging functionality. In normal usage scenarios, the MCU module is used for implementing fast charging protocols, charging management, and controlling small home appliances. In device upgrade scenarios, communication with devices such as computers is achieved via the Type-C & PD Controller, receiving data transmitted from the computer and writing it to the device's storage.

[0063] The PD fast charging control circuit includes an RTL digital circuit. The RTL digital circuit's function is to output two high-level signals when a specific upgrade command is received from the I2C interface and the configuration control circuit. When the USB plug is connected, VBUS_DET is high. At this time, the AND operation between VBUS_DET and the high-level signal from the RTL digital circuit results in a high-level signal, naturally causing switch 'c' to connect to 'a'.

[0064] Therefore, the principle behind enabling and disabling the pass-through selection module is as follows:

[0065] Enabling the pass-through selection module: When the RTL digital circuit receives the pass-through enable I2C signal from the I2C interface and the configuration control circuit, the 'c' switches controlling the pass-through selection module are all connected to 'a', and the pass-through selection module is enabled.

[0066] Disabling the pass-through selection module: After the upgrade is complete, the programmer will automatically disconnect from the USB interface, at which point the VBUS_DET signal will not be detected. The VBUS_DET signal becomes low, so the output signal of the AND gate is also low, naturally causing the 'c' pins of the pass-through selection module's switches to be connected to 'b', thus disabling the pass-through selection module.

[0067] Therefore, the process of upgrading devices based on PD fast charging controllers includes:

[0068] This allows devices such as computers to be connected to small home appliances (such as electric scooters) via a USB interface. Since the upgrade process relies on the VBUS voltage provided by the computer or other device, the computer and scooter must remain connected.

[0069] Click on Device Upgrade on your computer. The computer will then prompt you to click the "Start Upgrade" button for small home devices. After you click this button, you will be taken to the next step.

[0070] At this point, the MCU module writes to the register via the I2C interface, enabling the configuration control circuit to control the RTL digital circuit to enable the pass-through selection module. The two I2C signal lines and the two CC signal lines are then connected (i.e., SDA is connected to CC1, and SCL is connected to CC2), and the device upgrade begins.

[0071] Once the device upgrade is successful, the MCU detects the success and then prompts the computer and other devices to disconnect from the small home appliance.

[0072] When VBUS_DETECT cannot detect VBUS transmitted from devices such as computers, the RTL digital circuit will recognize that the pass-through selection module is not closed and close the pass-through selection module, that is, disconnect the I2C SDA and SCL from CC1 and CC2.

[0073] In summary, this invention, without altering other parts of the PD fast charging control circuit, adds a pass-through selection module containing two I2C signal lines and two CC signal lines inside the USB Type-C and PD interfaces. The on / off state of the two sets of switches in the pass-through selection module is controlled by the RTL digital circuit via commands written to the MCU register. This invention, without increasing the number of pins on the Type-C & PD Controller chip, enables direct interaction between the USB interface and the MCU under certain conditions by adding a pass-through selection module with I2C and CC terminals inside the Type-C & PD Controller chip, and allows for hardware self-reset after each successful upgrade. Since small home devices cannot interact with the MCU via the Type-C & PD Controller module on the USB interface, this invention can indirectly bypass this module and interact directly with the MCU.

[0074] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0075] It should be understood that the embodiments described above are merely illustrative. The embodiments described herein can be implemented in hardware, software, firmware, middleware, microcode, or any combination thereof. For hardware implementation, the processing unit can be implemented within 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), processors, controllers, microcontrollers, microprocessors, and / or other electronic units designed to perform the functions described herein, or combinations thereof.

[0076] The above embodiments are merely preferred embodiments of the present invention and should not be construed as limiting the scope of protection of the present invention. Any non-substantial changes and substitutions made by those skilled in the art based on the present invention shall fall within the scope of protection claimed by the present invention.

Claims

1. A PD fast charging control circuit that supports MCU firmware upgrades, characterized in that, The PD fast charging control circuit is connected to the MCU module via an I2C interface and to the USB interface via a CC interface. The I2C interface includes an SCL terminal, an SDA terminal, and an INT terminal. The CC interface includes a CC1 terminal and a CC2 terminal. The PD fast charging control circuit includes: The system includes a configuration control circuit, an RTL digital circuit, a PD fast charging control module, a USB PD control module, a USB Type-C current detection module, a VCONN control module, a receive control module, a VBUS detection and discharge module, a switch module, and a pass-through selection module. The pass-through selection module includes a first switch and a second switch. Terminal a of the first switch is connected between the SDA terminal and the configuration control circuit, terminal b of the first switch is connected to the RTL digital circuit, and terminal c of the first switch is connected to the CC1 terminal. Terminal a of the second switch is connected between the SCL terminal and the configuration control circuit, terminal b of the first switch is connected to the RTL digital circuit, and terminal c of the second switch is connected to the CC2 terminal. The configuration control circuit is connected to the VCONN control module and the USB Type-C current detection module, respectively. The RTL digital circuit is connected to the PD fast charging control module. The PD fast charging control module is connected to the USB Type-C current detection module, the VCONN control module, the switch module, and the VBUS detection and discharge module, respectively. The VCONN control module is connected to the receiving control module, and the receiving control module is connected to the switch module.

2. The circuit according to claim 1, characterized in that: The switch module includes a third switch, a fourth switch, a fifth switch, and a sixth switch. The first and second ends of the third switch, the first and second ends of the fourth switch are grounded. The third end of the third switch is connected to the second end of the fifth switch, the third end of the fourth switch is connected to the second end of the sixth switch, and the first ends of the fifth switch and the sixth switch are respectively connected to a current source.

3. The circuit according to claim 1 or 2, characterized in that: The opening and closing of the first and second switches are controlled by the RTL digital circuit through register commands written by the MCU module.

4. A PD fast charging control method that supports MCU firmware upgrades, characterized in that, This method is applied to a PD fast charging control circuit that supports MCU firmware upgrades as described in any one of claims 1 to 3, and includes the following steps: Upon receiving the upgrade handshake command from the host, i.e., after the I2C interface and configuration control circuit transmit a specific upgrade command, the RTL digital circuit outputs two high-level signals. When the USB plug is connected, VBUS_DET is high. At this time, VBUS_DET and the high-level signal transmitted by the RTL digital circuit are ANDed to produce a high-level signal, which makes the c terminals of the first switch and the second switch connected to the a terminal. When the RTL digital circuit receives the pass-through enable I2C signal from the configuration control circuit, it controls the c terminals of the first switch and the second switch to be connected to the a terminal, at which time the pass-through selection module is enabled. After the upgrade is complete, the programmer automatically disconnects from the USB interface. At this time, the VBUS_DET signal is not detected, the VBUS_DET signal becomes low, and the output signal of the AND gate inside the RTL digital circuit is also low, so that the c terminal of the pass-through selection module is connected to the b terminal. At this time, the pass-through selection module is turned off.

5. The method according to claim 4, characterized in that: The RTL digital circuit receives the upgrade success command from the PD fast charging control module and sends a high-level signal to the pass-through selection module. During the upgrade, VBUS_DET is high. The two high-level signals are ANDed by the RTL digital circuit and output as a high-level signal. The first switch and the second switch receive the high-level signal, which enables the pass-through selection module.

6. The method according to claim 4, characterized in that: When upgrading the MCU firmware, the host and the device to be upgraded are connected via USB interface and the connection is maintained at all times. Upon receiving the upgrade command, the MCU module writes to the register via the I2C interface, enabling the configuration control circuit to control the RTL digital circuit to enable the pass-through selection module. At this time, the two signal lines of the I2C interface and the two signal lines of CC are connected, i.e., SDA is connected to CC1 and SCL is connected to CC2, and the device begins the upgrade. Once the upgrade is successful, the MCU module detects the success and prompts you to disconnect from the device.

7. The method according to claim 4, characterized in that: When the VBUS detection and discharge module fails to detect the VBUS signal transmitted from the host, the RTL digital circuit recognizes that the pass-through selection module is not closed and closes the pass-through selection module, disconnecting the SDA and SCL terminals of the I2C interface from the CC1 and CC2 terminals of the CC interface.

8. The method according to any one of claims 4 to 7, characterized in that: During the upgrade process, the host also controls the device to be upgraded to set the detection flag bit according to the upgrade handshake command; Based on the detection flag set in the device to be upgraded, the system controls the device to receive the firmware to be upgraded sent by the host via the I2C protocol and updates the firmware received by the device last time. Based on the firmware update status within the device to be upgraded, control the device to change the corresponding detection flag bit, and then repeat the above steps. When the device to be upgraded confirms that it has received the upgrade completion command sent by the host, it clears the corresponding detection flag and completes the firmware upgrade update of the device.

9. The method according to claim 8, characterized in that: When setting the detection flag, control the device to be upgraded to respond to the upgrade handshake command and receive the host's request for its relevant detection flags, and then assign the corresponding logical value to the detection flag. The upgrade handshake command includes the status information of the previous firmware upgrade, the current firmware upgrade instruction, and the adjustment parameters required by the device to be upgraded.

10. The method according to any one of claims 4 to 7, characterized in that: The VBUS detection and discharge module is used to filter VBUS_DET. Since VBUS_DET is generated by VBUS through a resistor divider, after filtering, it is ANDed with the signal transmitted from the RTL digital circuit.

Citation Information

Patent Citations

  • PD fast charge control circuit and method

    CN116914889A

  • Power adapter and method for upgrading the power adapter

    US20180024842A1