Patent ID: 9484759
Filing Date: 2016-11-01
CPC Classification: G06F,H02J

Claim Text:
1. A method for detecting connection of a type of charger, comprising: receiving a first reset signal from a processing unit in response to starting a control unit of an input-output circuit and receiving a power supply signal from an internal power supply, wherein the input output circuit comprises: a power supply detection circuit coupled to the control unit; a charger detection circuit coupled to the control unit, wherein the control unit comprises: an I 2 CI/F circuit having a first input, a first output, and a second output; and a logic gate having a first input, a second input, a third input, and an output, the first input of the logic gate coupled to the first input of the I 2 CI/F circuit; and wherein the charger redetection register includes a first input, a second input, a third input, and an output, wherein the first input of the charger redetection circuit is coupled to the first input of the I 2 CI/F circuit and to the first input of the logic gate, the second input of the charger redetection circuit is coupled to the first output of the I 2 CI/F circuit, and the third input of the charger redetection circuit is coupled to the second output of the I 2 CI/F circuit; setting the charger redetection register coupled to the control unit in response to receiving the first reset signal; detecting power supplied to a connector from an external source; performing a first charger kind detection process which includes monitoring a voltage of a first terminal and a voltage of a second terminal of the connector in response to the detected power supplied to the connector from the external source to detect an open, a pull up, and a pull down of at least one of the first terminal and the second terminal; generating a first comparison result in response to comparing the voltage of the first terminal with a first reference voltage; generating a second comparison result in response to comparing the voltage of the second terminal with a second reference voltage; generating a third comparison result in response comparing the voltage of the second terminal with a third reference voltage; and determining the first charger kind in accordance with the first comparison result, the second comparison result, and the third comparison result; resetting a charger redetection register within a control unit in response to the internal power supply; and starting a second charger kind detection process in response to detection of the power.