6

When I'm on the go, I want to use internet tethering and debugging over USB to develop mobile apps with my Pixel 3A, but I don't want to charge the phone, because I want to waste energy on my MacBook as little as possible.

Is it possible to disable charging when the device is connected to my laptop, if so how? I know that I can set up debugging over WiFi and use a mobile hotspot, but I can't stand my hotspot performance and WiFi drains energy from my laptop as well.

Martin Braun
  • 441
  • 1
  • 3
  • 13
  • If your phone is rooted there are apps which can disable charging while the phone is connected via USB. On an unroofed device the only possibility I see is to manipulate the USB cable by cutting the +5 V power cable inside the USB cable.Not sure if t!his would really work and then it needs to be an USB-C cable makes it much more complicated. An USB adapter could also do the trick, unfortunately I only know the opposite (charge only no data connection). – Robert Jul 30 '21 at 19:38
  • @Robert I'm using USB-C which allows me to reach high data throughput (LTE). Unfortunately, the device is not rooted, but I would also welcome answers that require a rooted device as well (for future reference). However, it would not help me right now, unless I decide to get GrapheneOS in the near future (something that I have in mind for a while, already). – Martin Braun Jul 30 '21 at 20:07
  • 1
    Some details on how charging can be disabled on some rooted device can be found here: https://android.stackexchange.com/questions/54902/disable-usb-charging There are also read-to use apps that make use of this and e.g. allow to limit charging to 40-60% so that the phone never runs out of power, e.g. this open source app: Battery Charge Limit - ROOT – Robert Jul 31 '21 at 16:43

1 Answers1

3

I was looking for a solution that doesn't require root and I came across one. When USB tethering is on, I can get into its settings by touching on the notification:

swipe down and tap on the "USB tethering turned on" notification Toggle "Charge connected device"

There is a toggle that allows me to disable charging for this session.

Funny thing is I had to enable the toggle to disable charging, the option should be called "Don't charge connected device" instead.

Martin Braun
  • 441
  • 1
  • 3
  • 13
  • 2
    Turning 'Charge connected device' on will charge the device connected to your Android device. I.e. If you have your Android phone connected to your laptop and you turn on 'Charge connected device' it will charge your laptop (assuming it can be charged through the USB port you connected your phone to, e.g. MacBook with USB-C charging) – samaitch Feb 08 '22 at 12:21
  • 2
    @samaitch I really appreciate your comment. Suddenly it makes sense, but now my solution is not what I am after. It's a neat side-effect and can be used when the host device rejects charging (like on a fully charged laptop), though. So my solution will lengthen the session of my MacBook, yet still shorten the session of my Mobile. Given the fact that charging results in net loss of energy in all circumstances, I still hope there is a better solution to enable tethering without any charging in either direction whatsoever. – Martin Braun Feb 08 '22 at 16:59
  • 1
    For the record, on my stock Android Nokia 5.3, which recently was upgraded to Android 12, I don't see that 'Charge connected device' option at all. – MarnixKlooster ReinstateMonica Nov 26 '22 at 16:47
  • 1
    To get to that USB page I have to do Settings > Connected devices > USB, and it has no option to toggle charging. This is on standard Android 9 (moto e6), and also (IIRC) on Android 11 Go (on a cheap phone). I had the cheap phone tethered all day every day for cheap internet access. After 6 months the battery bulged, and I guess the constant full charge contributed to that. It would be good to be able to control when it charges, to let the battery cycle normally, and not get too full. – j77h Mar 25 '23 at 01:54
  • @samaitch , I understand what you are telling but in practical the trick by Martin-braun is working. I observed 0 % change in my android after 30 minutes turning ON "charge connected device". – Parmanand Patidar Aug 10 '23 at 13:21
  • I couldn't find that menu on Oreo, where is it? – Unknown123 Dec 28 '23 at 07:28
  • This answer is also helpful when using USB tethering for networking. When I enable "charge connected device", it means the phone tries to charge the laptop. It can't do this (can't deliver meaningful power I suppose), so neither device is charging the other, which is the outcome I want – Tim Richardson Mar 26 '24 at 22:21