According to an embodiment, the electronic device may receive power from an external device even in the power saving mode to detect the specific event. The input/output interface (e.g., the input/output interface 240 of
Alternatively, the electronic device may further include a circuit capable of supplying power, such as a super cap or a small battery, or may be in a state of being TA connected to an external device. In this case, the electronic device and the external device may detect a specific event and perform a relevant operation even when supply of the VBUS power is cut off.
In operation 707, the electronic device may change the ID in response to the specific event. For example, the electronic device may change the ID from the second ID to the first ID. The specific event may be, for example, acquisition of a user input. The electronic device may be, for example, a keyboard connected to the electronic device through a pogo pin and supporting USB communication. In this case, when the user input is acquired through the keyboard, the electronic device may change the ID.
In operation 709, the electronic device may again perform connection with the external device, and transmit data to or receive data from the external device. Due to the change of the ID, the connection with the external device may be triggered.