Patent ID: 8242742

Claim:
A method for detecting a power source which is selected from the group consisting of a universal serial bus (USB) host and an alternating current (AC) adapter, said method comprising: receiving a power voltage from a power line of said power source; exchanging data via a first data line and a second data line between said power source and a USB client; generating a detection voltage on said first data line by a voltage divider, wherein said voltage divider comprises a first resistor coupled between a power pin and a detection pin, and a second resistor coupled between said detection pin and ground, wherein said power source comprises a transmitter in which said first data line and said second data line are coupled to each other if said power source is said AC adapter, and wherein said USB client comprises a third resistor; determining a voltage level of said detection voltage according to resistance values of said first resistor, said second resistor and said third resistor if said power source is said AC adapter; comparing said detection voltage on said data line with a first predetermined reference voltage; and identifying whether said power source is said USB host or said AC adapter according to a result of said comparing of said detection voltage with said first predetermined reference voltage.