Author Topic: M0 power switch?  (Read 1864 times)

aliocha12

  • NewMember
  • *
  • Posts: 8
M0 power switch?
« on: October 17, 2019, 09:55:13 PM »
I would like to know the best way to wire a switch to turn off a LiPo-powered M0. I can place a switch between USB+ and the  LiPo+, but the battery won't charge under USB unless the switch is on. I would like to charge while the switch is in the OFF position so the M0 won't keep drawing current. For example, I use the EN pin on the Adafruit Feather to accomplish this.

Felix

  • Administrator
  • Hero Member
  • *****
  • Posts: 6866
  • Country: us
    • LowPowerLab
Re: M0 power switch?
« Reply #1 on: October 17, 2019, 11:24:43 PM »
On the feathers I believe the EN pin is a feature of the LDO they use to cut power to the board.

IMO you don't really need a switch for this function. On the MoteinoM0 I put a MOSFET from the battery that automatically switches power from the battery to USB when USB is plugged in. This way the M0 would still be powered from USB, and battery would charge without any load attached to it.

If you don't want the M0 to do anything during charging or while USB is plugged in, what you can do is detect when the USB is plugged in via the BatteryMonitor (on A5) and sleep it (see this thread and the M0 guide - Reading VIN section as well).

aliocha12

  • NewMember
  • *
  • Posts: 8
Re: M0 power switch?
« Reply #2 on: October 28, 2019, 11:27:46 PM »
The M0 does not seem to be charging the LiPo battery I have connected and the charge light does not come on when the USB is plugged in. Do I need to put it in charging mode or something like that? The LiPo does power the M0, however, on its own. Thanks.

Felix

  • Administrator
  • Hero Member
  • *****
  • Posts: 6866
  • Country: us
    • LowPowerLab
Re: M0 power switch?
« Reply #3 on: October 29, 2019, 08:47:59 AM »
What's the no load voltage of the LiPo?

aliocha12

  • NewMember
  • *
  • Posts: 8
Re: M0 power switch?
« Reply #4 on: November 04, 2019, 09:38:54 AM »
It was completely discharged, so zero.

aliocha12

  • NewMember
  • *
  • Posts: 8
Re: M0 power switch?
« Reply #5 on: November 05, 2019, 10:27:31 PM »
I tried another fresh lipo and let the voltage drop to 3.1, then connected the USB, the voltage at lipo terminals is 3.1, and charge light is not on.

Felix

  • Administrator
  • Hero Member
  • *****
  • Posts: 6866
  • Country: us
    • LowPowerLab
Re: M0 power switch?
« Reply #6 on: November 06, 2019, 08:40:38 AM »
Maybe it's a damaged charge IC.