An electronic device comprising: a first connection means connectable to a first external device , wherein the first external device is connected to a battery ; a second connection means connectable to a second external device ; and a control means arranged to determine whether the first external device is connected to the first connection means, characterized in that : the first connection means is configured to be alternatively connectable to a battery ; the control means is arranged to prevent charging of the battery connected to the first external device with power supplied from the second external device connected to the second connection means , in a case where the first external device is connected to the first connection means , the second external device is connected to the second connection means , and the battery is not connected to the first connection means , and the control means is arranged to allow charging of the battery connected to the first connection means with power supplied from the second external device connected to the second connection means , in a case where the first external device is not connected to the first connection means , the second external device is connected to the second connection means , and the battery is connected to the first connection means . a first connection means connectable to a first external device , wherein the first external device is connected to a battery ; a second connection means connectable to a second external device ; and a control means arranged to determine whether the first external device is connected to the first connection means, characterized in that : the first connection means is configured to be alternatively connectable to a battery ; the control means is arranged to prevent charging of the battery connected to the first external device with power supplied from the second external device connected to the second connection means , in a case where the first external device is connected to the first connection means , the second external device is connected to the second connection means , and the battery is not connected to the first connection means , and the control means is arranged to allow charging of the battery connected to the first connection means with power supplied from the second external device connected to the second connection means , in a case where the first external device is not connected to the first connection means , the second external device is connected to the second connection means , and the battery is connected to the first connection means . the first connection means is configured to be alternatively connectable to a battery ; the control means is arranged to prevent charging of the battery connected to the first external device with power supplied from the second external device connected to the second connection means , in a case where the first external device is connected to the first connection means , the second external device is connected to the second connection means , and the battery is not connected to the first connection means , and the control means is arranged to allow charging of the battery connected to the first connection means with power supplied from the second external device connected to the second connection means , in a case where the first external device is not connected to the first connection means , the second external device is connected to the second connection means , and the battery is connected to the first connection means . <EOS>