A system and method for detecting whether an Apple device is inserted

By designing a logic control unit and a plug-and-unplug detection unit in the USB port to detect the signals on the D+, D- and VBUS lines, the problem of being unable to wake up the USB port output power after first plugging in the Apple cable is solved, and the normal charging of Apple devices is realized.

CN110417085BActive Publication Date: 2024-10-25SHENZHEN INJOINIC TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910673001.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-07-24
Publication Date
2024-10-25
Estimated Expiration
2039-07-24

AI Technical Summary

Technical Problem

In a USB port with insertion detection function, after first plugging in the Apple charging cable, after light load or pressing the button to shut down, and then plugging in an iPhone or other device, the USB port cannot wake up normally to output power, resulting in the inability to charge the Apple device.

Method used

A system is designed, including a logic control unit, a VBUS plug and pull detection unit, a DP plug and pull detection unit, a DM plug and pull detection unit, a signal debounce and a rising edge detection unit, by detecting the signals on the D+, D- and VBUS lines , determine whether a charging device is inserted, and turn on VBUS power supply when the insertion conditions are met to ensure that the USB port outputs power to wake up.

Benefits of technology

It solves the problem that devices such as Apple phones cannot be charged after first plugging in the Apple cord and then lightly loading or pressing the button to shut down, ensuring that Apple devices can charge normally.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110417085B_ABST
    Figure CN110417085B_ABST
Patent Text Reader

Abstract

The present invention discloses a system and method for detecting whether an Apple device is inserted. The system comprises a logic control unit, a VBUS plug-in detection unit, a VBUS power supply unit, a DP plug-in detection unit, a DM plug-in detection unit, a first signal de-jitter, a rising edge detection unit, a second signal de-jitter, a rising edge detection unit and a third signal de-jitter, a rising edge detection unit. The present invention solves the problem that an Apple cable is first inserted, lightly loaded or the device is turned off by pressing a button, and then an Apple mobile phone or other device cannot be charged when it is inserted into a lightning port.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of charging devices, and in particular to a system and method for detecting whether an Apple device is inserted. Background Art

[0002] In applications such as mobile power supplies and car chargers, in order to save power consumption, the power output of the USB port that is not connected to a mobile phone or other charging device will be turned off. When a mobile phone or other charging device is detected to be plugged in, the USB port power will be turned on to charge the mobile phone.

[0003] Or in applications with multiple USB fast charging output ports, for USB ports that are not connected to charging devices such as mobile phones, you also need to turn off the power of their output ports. When a mobile phone is detected to be connected, turn on the power of the corresponding output port. This way, fast charging can be switched between multiple USB ports.

[0004] For general Android phones, the charging cable is usually an ordinary USB cable, which is divided into two types, one is USBA port to microUSB port, and the other is USB A port to typec USB port. For USB A port to micro USB port, it generally includes VBUS, D-, D+, ID, GND; for USB A port to typec USB port, it generally includes VBUS, D-, D+, CC, GND, among which the CC line is not at the A port end, and is pulled up to VBUS through a resistor inside the wire, and there is a CC line at the typec port end.

[0005] There is usually no IC in ordinary USB charging cables, so this type of cable will not wake up the USB port when it is inserted into a USB port with insertion detection function. It will not wake up the USB port until the other end of the cable is connected to a mobile phone. The charging circuit is as follows: Figure 1 shown.

[0006] As for the lightning interface of Apple devices, Apple has made a separate USB to lightning cable, and there is an IC in the middle of the cable. The IC consumes power on VBUS, which is equivalent to an impedance between VBUS and GND.

[0007] According to the insertion detection technology described in the patent "A USB Insertion Automatic Identification and Power Supply System", when an Apple charging cable (Apple USB A port to Lightning port, or Apple Type-C port to Lightning port) is inserted into a USB port with insertion detection function, the USB port power supply will be awakened; while inserting an ordinary Android phone charging cable into a USB port with insertion detection function will not wake up the USB port power supply. The difference between the two is that there is an impedance between VBUS and GND in the Apple charging cable, while there is no such impedance between VBUS and GND in the Android charging cable.

[0008] For USB ports with insertion detection function, they generally have the function of detecting whether the VBUS load current is lightly loaded. When the VBUS load current is detected to be less than the set light load current (such as 50mA) and lasts for a period of time (such as 32 seconds), it is considered that the mobile phone is fully charged, and the USB port power output will be automatically turned off to reduce system power consumption. Or when a mobile phone or Apple charging cable is plugged in, when a key is pressed to forcibly turn off the USB port power, the USB port power output will also be turned off. When the USB port power is turned off by plugging in a mobile phone or Apple charging cable, the USB port insertion detection circuit will not wake up the USB port output power until it detects that the mobile phone or Apple cable is unplugged, and then the USB port output power is awakened when the mobile phone or Apple cable is plugged in again.

[0009] The above method has a problem with Apple charging cables. When an Apple charging cable is first inserted into a USB port with insertion detection function, the USB port output power will be awakened. When the load is light for a period of time, or the USB port power is turned off by a button, the USB port insertion detection circuit always detects that there is a load connected to the USB port. Because there is an impedance from VBUS to GND on the Apple cable, when an Apple phone or other device is inserted into the lightning port of the Apple cable, the USB port output power cannot be awakened, and the Apple phone or other device cannot be charged normally. Summary of the invention

[0010] Based on the deficiencies of the prior art, the present invention provides a system and method for detecting whether an Apple device is inserted, so as to solve the problem that an Apple cable is first inserted, a light load is applied or the device is turned off by a button, and then an Apple phone or other device cannot be charged when inserted into the lightning port.

[0011] The technical solution of the present invention is:

[0012] A system for detecting whether an Apple device is plugged in, characterized by comprising: a logic control unit, a VBUS plug detection unit, a VBUS power supply unit, a DP plug detection unit, a DM plug detection unit, a first signal de-jittering, a rising edge detection unit, a second signal de-jittering, a rising edge detection unit, and a third signal de-jittering, a rising edge detection unit;

[0013] The DP plug detection unit is used to detect whether a charging device is plugged into the D+ line. The signal input end of the DP plug detection unit is connected to the D+ line, and the signal output end of the DP plug detection unit is connected to the input end of the first signal de-jittering and rising edge detection unit;

[0014] The DM plug-in detection unit is used to detect whether a charging device is plugged into the D-line. The signal input end of the DM plug-in detection unit is connected to the D-line, and the signal output end of the DM plug-in detection unit is connected to the input end of the second signal de-jittering and rising edge detection unit;

[0015] The signal input end of the VBUS plug-in detection unit is connected to the VBUS line, and the signal output end of the VBUS plug-in detection unit is connected to the input end of the third signal de-jittering and rising edge detection unit;

[0016] The output ends of the three signal de-jittering and rising edge detection units are respectively connected to the logic control unit, and the logic control unit is used to receive the feedback signals of the three signal de-jittering and rising edge detection units respectively;

[0017] The logic control unit is also connected to the VBUS power supply unit, and is used to send a signal indicating that the VBUS power supply is turned off to the logic control unit when the VBUS power supply unit turns off the power supply;

[0018] The logic control unit is also respectively connected to the DP plug-in detection unit and the DM plug-in detection unit for detection, and is used to control the start of the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit for detection after receiving the signal that the VBUS power supply unit is turned off, and monitor whether the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit have an insertion signal given. When a signal is inserted, the three units respectively output a high level, and when the output of any one of the three signals in the three signal de-jitter and rising edge detection unit is a high level, the VBUS power supply unit is turned on for power supply.

[0019] Furthermore, the circuit structures of the DP plug-in detection unit and the DM plug-in detection unit are the same, and both include a voltage comparator, the output end of the voltage comparator is the output end of each corresponding unit, the positive phase end or the negative phase end of the voltage comparator is connected to the output end of the threshold voltage generating unit, and the threshold voltage generating unit provides a reference threshold voltage for the positive phase end or the negative phase end of the voltage comparator. Correspondingly, the negative phase end or the positive phase end of the voltage comparator corresponds to the D+ line or the D- line of the USB line, respectively, and the output end of the voltage comparator is connected to the input end unit of the corresponding signal de-jittering and rising edge detection unit. The negative phase end or the positive phase end of the voltage comparator is also connected to a power supply module, and the power supply module is controlled to be turned on by the logic control unit. The voltage comparator is used to output a high-level signal indicating that a device is inserted when an imbalance in the voltage between its positive phase end and the negative phase end is detected.

[0020] Furthermore, the VBUS plug-in detection unit, the VBUS power supply unit, the DP plug-in detection unit, the DM plug-in detection unit, and the logic control unit are integrated on an IC chip.

[0021] Furthermore, the threshold voltage generating unit provides a reference voltage of 2V for the voltage comparator.

[0022] A method for detecting whether an Apple device is inserted, the method is based on a system for detecting whether an Apple device is inserted, comprising:

[0023] Step 1, after the VBUS power supply unit turns off the power supply, a signal OFF indicating that the VBUS power supply is turned off is sent to the logic control unit;

[0024] Step 2: After receiving the OFF signal, the logic control unit enables and controls the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit, and simultaneously enables the corresponding signal de-jittering and rising edge detection units. When the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit are all enabled, monitor whether an insertion signal is given;

[0025] Step 3: When any of the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit detects an insertion signal, the corresponding signal de-jitter and rising edge detection unit outputs a high level to the logic control unit to wake up the VBUS power supply unit to supply power.

[0026] The beneficial effects of the present invention are as follows: first insert the Apple cable, lightly load or press the button to shut down, and then insert an Apple mobile phone or other device into the lightning port to solve the problem that the device cannot be charged. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1 It is a structural schematic diagram of the prior art;

[0028] Figure 2 It is a schematic diagram of the system structure of the present invention;

[0029] Figure 3 This is a circuit diagram of a DP plug-in detection unit;

[0030] Figure 4 One of the circuit structure diagrams for generating a threshold voltage;

[0031] Figure 5 This is the second diagram of the threshold voltage generating circuit structure. DETAILED DESCRIPTION

[0032] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0033] like Figure 2-3 As shown, a system for detecting whether an Apple device is inserted includes a logic control unit, a VBUS plug detection unit, a VBUS power supply unit, a DP plug detection unit, a DM plug detection unit, a first signal de-jitter, a rising edge detection unit, a second signal de-jitter, a rising edge detection unit, and a third signal de-jitter, a rising edge detection unit;

[0034] The DP plug detection unit is used to detect whether a charging device is plugged into the D+ line. The signal input end of the DP plug detection unit is connected to the D+ line, and the signal output end is connected to the input end of the first signal de-jittering and rising edge detection unit;

[0035] The DM plug-in detection unit is used to detect whether a charging device is plugged into the D-line. The signal input end of the DM plug-in detection unit is connected to the D-line, and the signal output end is connected to the input end of the second signal de-jittering and rising edge detection unit;

[0036] The signal input end of the VBUS plug detection unit is connected to the VBUS line, and the signal output end is connected to the input end of the third signal de-jittering and rising edge detection unit;

[0037] The output ends of the three signal de-jittering and rising edge detection units are respectively connected to the logic control unit, and the logic control unit is used to receive the feedback signals of the three signal de-jittering and rising edge detection units respectively;

[0038] The logic control unit also includes three enable output terminals, each of which provides an enable signal to the VBUS plug-in detection unit, the DP plug-in detection unit, the DM plug-in detection unit and their corresponding signal de-jitter and rising edge detection units at the same time;

[0039] The logic control unit is also connected to the VBUS power supply unit, and is used to send a signal indicating that the VBUS power supply is turned off to the logic control unit when the VBUS power supply unit turns off the power supply;

[0040] The main functions of the logic control unit are as follows:

[0041] When the VBUS power supply unit turns off the power supply, it sends a signal OFF indicating that the VBUS power supply is turned off to the logic control unit; after receiving the OFF signal, the logic control unit controls the opening of the VBUS plug-in detection unit (EN_VBUSDET=1), the DP plug-in detection unit (EN_D+DET=1), and the DM plug-in detection unit (EN_D-DET=1). When the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit are all enabled, they keep monitoring whether there is an insertion signal.

[0042] When one of the three signals D-_PLUGIN_D, D+_PLUGIN_D, and VBUS_PLUGIN_D is 1, it means that a load is inserted and the VBUS power supply unit is turned on.

[0043] The circuit structures of the DP plug detection unit and the DM plug detection unit of this embodiment are the same, and both include a voltage comparator. The output end of the voltage comparator is the output end of the corresponding unit. The positive phase end of the voltage comparator of this embodiment is connected to the output end of the threshold voltage generating unit. The threshold voltage generating unit provides a reference threshold voltage for the positive phase end of the voltage comparator. Figure 4 and 5 As shown, the threshold voltage generating unit can be provided by two voltage-dividing resistors, and the threshold voltage generating unit provides a reference voltage for the voltage comparator; the negative phase end of the voltage comparator in the DP plug-in detection unit is connected to the D+ of the USB line, and the negative phase end of the voltage comparator in the DM plug-in detection unit is connected to the D- of the USB line. Of course, this is just one of the connection methods. The threshold voltage generating unit, the USB line and the enable end can also be interchangeably connected to the positive phase end and the negative phase end of the voltage comparator according to the above connection method, that is, the threshold voltage generating unit is connected to the negative phase end of the voltage comparator, and the rest are connected to the positive phase end of the voltage comparator. The output end of the voltage comparator is connected to the corresponding signal de-jitter and the input end unit of the rising edge detection unit, and the negative phase end of the voltage comparator is also connected to a power supply module.

[0044] The DP plug detection unit is taken as an example to illustrate the principle of the DP plug detection unit detecting whether there is an inserted device: when the threshold voltage generating unit is connected to the positive phase end of the voltage comparator, the enable end of the logic control unit controls the start of the power module, turns on a current source to irrigate D+, or changes a form, does not use a current source, but uses a pull-up resistor; or a power supply with a very small output load capacity is connected to D+, when there is no load connected to D+, the D+ voltage is close to the power supply voltage VCC, VCC is generally 3.3v, when connected to an Apple mobile phone or other device, the D+ inside the mobile phone will have a pull-down resistor, which will consume about 2-3uA of current, causing the voltage on D+ to drop below the threshold voltage generated by the threshold voltage generating unit. This embodiment provides a threshold voltage of 2v. When it drops below 2V (this voltage is not a fixed value and can be adjusted), the voltage comparator will detect it, thereby sending a D+_PLUGIN signal as high.

[0045] The first signal de-jitter and rising edge detection unit starts working only when EN_D+DET=1, and performs de-jitter and rising edge detection on the input D+_PLUGIN signal. When the valid rising edge of the D+_PLUGIN signal is detected, it is considered that load insertion is detected on D+, and the output D+_PLUGIN_D=1.

[0046] When the D+_PLUGIN signal is high, it can be determined that a mobile phone is plugged in, thereby waking up the USB port to output power and then charging the mobile phone and other devices.

[0047] When EN_D+DET=0, the unit circuit does not work and the output D+_PLUGIN_D=0.

[0048] When connected in the opposite direction, adjust the voltage setting values ​​of the two input terminals of the voltage comparator accordingly to ensure that when a device is plugged into D+, the D+_PLUGIN signal is high.

[0049] The function of the first signal de-jitter and rising edge detection unit is to eliminate the jitter of the plug-in detection signal; when there is a load on D+, the power is turned off and no valid detection signal is issued. A valid detection signal will not be issued until the load on D+ is unplugged and then plugged in again.

[0050] Similarly, when EN_D-DET=1, the second signal de-jitter and rising edge detection unit starts to work, de-jitters and detects the rising edge of the input D-_PLUGIN signal. When the valid rising edge of the D-_PLUGIN signal is detected, it is considered that load insertion is detected on D-, and the output D-_PLUGIN_D=1.

[0051] When EN_D-DET=0, the circuit does not work and the output D-_PLUGIN_D=0.

[0052] The function of this unit is to eliminate the jitter of the plug-in detection signal. When there is a load on D-, it will shut down and no valid detection signal will be issued. A valid detection signal will not be issued until the load on D- is unplugged and then plugged in.

[0053] The third signal de-jitter and rising edge detection unit starts working only when EN_VBUSDET=1, and performs de-jitter and rising edge detection on the input VBUS_PLUGIN signal. When the valid rising edge of the VBUS_PLUGIN signal is detected, it is considered that load insertion is detected on VBUS, and VBUS_PLUGIN_D=1 is output.

[0054] When EN_VBUSDET=0, the unit circuit does not work and outputs VBUS_PLUGIN_D=0.

[0055] The function of this unit circuit is to eliminate the jitter of the plug-in detection signal; when there is a load on VBUS and the device is shut down, no valid detection signal will be issued until the load on VBUS is unplugged and then plugged in, then a valid detection signal will be issued.

[0056] In this embodiment, the VBUS plug-in detection unit, the VBUS power supply unit, the DP plug-in detection unit, the DM plug-in detection unit, and the logic control unit are integrated on an IC chip.

[0057] A method for detecting whether an Apple device is inserted, the method is based on the above-mentioned system for detecting whether an Apple device is inserted, comprising:

[0058] Step 1, after the VBUS power supply unit turns off the power supply, a signal OFF indicating that the VBUS power supply is turned off is sent to the logic control unit;

[0059] Step 2: After receiving the OFF signal, the logic control unit enables and controls the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit, and simultaneously enables the corresponding signal de-jittering and rising edge detection units. When the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit are all enabled, monitor whether an insertion signal is given;

[0060] Step 3: When any of the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit detects an insertion signal, the corresponding signal de-jitter and rising edge detection unit outputs a high level to the logic control unit to wake up the VBUS power supply unit to supply power.

[0061] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A system for detecting whether an Apple device is plugged in, characterized in that: It includes a logic control unit, a VBUS plug-in detection unit, a VBUS power supply unit, a DP plug-in detection unit, a DM plug-in detection unit, a first signal de-jitter, a rising edge detection unit, a second signal de-jitter, a rising edge detection unit, and a third signal de-jitter, a rising edge detection unit; The DP plug detection unit is used to detect whether a charging device is plugged into the D+ line. The signal input end of the DP plug detection unit is connected to the D+ line, and the signal output end of the DP plug detection unit is connected to the input end of the first signal de-jittering and rising edge detection unit; The DM plug-in detection unit is used to detect whether a charging device is plugged into the D-line. The signal input end of the DM plug-in detection unit is connected to the D-line, and the signal output end of the DM plug-in detection unit is connected to the input end of the second signal de-jittering and rising edge detection unit; The signal input end of the VBUS plug-in detection unit is connected to the VBUS line, and the signal output end of the VBUS plug-in detection unit is connected to the input end of the third signal de-jittering and rising edge detection unit; The output ends of the three signal de-jittering and rising edge detection units are respectively connected to the logic control unit, and the logic control unit is used to receive the feedback signals of the three signal de-jittering and rising edge detection units respectively; The logic control unit is also connected to the VBUS power supply unit, and is used to send a signal indicating that the VBUS power supply is turned off to the logic control unit when the VBUS power supply unit turns off the power supply; The logic control unit is also respectively connected to the DP plug-in detection unit and the DM plug-in detection unit for detection, and is used to control the start of the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit for detection after receiving the signal that the VBUS power supply unit is turned off, and monitor whether the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit have an insertion signal given. When a signal is inserted, the three units respectively output a high level, and when the output of any one of the three signals in the three signal de-jitter and rising edge detection unit is a high level, the VBUS power supply unit is turned on for power supply.

2. The system for detecting whether an Apple device is inserted as claimed in claim 1, characterized in that: The circuit structures of the DP plug-in detection unit and the DM plug-in detection unit are the same, and both include a voltage comparator, wherein the output end of the voltage comparator is the output end of each corresponding unit, and the positive phase end or the negative phase end of the voltage comparator is connected to the output end of the threshold voltage generating unit, and the threshold voltage generating unit provides a reference threshold voltage for the positive phase end or the negative phase end of the voltage comparator. Correspondingly, the negative phase end or the positive phase end of the voltage comparator corresponds to the D+ line or the D- line of the USB line, respectively, and the output end of the voltage comparator is connected to the input end unit of the corresponding signal de-jittering and rising edge detection unit. The negative phase end or the positive phase end of the voltage comparator is also connected to a power supply module, and the power supply module is controlled to be turned on by the logic control unit. The voltage comparator is used to output a high-level signal indicating that a device is inserted when an imbalance in the voltage between its positive phase end and negative phase end is detected.

3. The system for detecting whether an Apple device is inserted as claimed in claim 1 or 2, characterized in that: The VBUS plug-in detection unit, the VBUS power supply unit, the DP plug-in detection unit, the DM plug-in detection unit, and the logic control unit are integrated on an IC chip.

4. The method for detecting whether an Apple device is inserted as claimed in claim 2, characterized in that: The threshold voltage generating unit provides a reference voltage of 2V for the voltage comparator.

5. A method for detecting whether an Apple device is inserted, characterized in that: The method is based on the system according to any one of claims 1 to 4, comprising: Step 1, after the VBUS power supply unit turns off the power supply, a signal OFF indicating that the VBUS power supply is turned off is sent to the logic control unit; Step 2: After receiving the OFF signal, the logic control unit enables and controls the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit, and simultaneously enables the corresponding signal de-jittering and rising edge detection units. When the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit are all enabled, monitor whether an insertion signal is given; Step 3: When any of the VBUS plug-in detection unit, the DP plug-in detection unit, and the DM plug-in detection unit detects an insertion signal, the corresponding signal de-jitter and rising edge detection unit outputs a high level to the logic control unit to wake up the VBUS power supply unit to supply power.