MKR1400 Li-Po charging current issues

Hi all

Been having some issues with Li-Po charging with a MKR1400

So, current setup:

MKR1400 board with code running fine and as expected, 4Ah Li-Po attached via an ammeter, external supply ready into the VIN pin, USB cable ready

Currently laid out as a GPS/GPRS tracker for my own car

When charging the Li-Po I can monitor the current between the board and battery, it’s sitting close to what I set it to using the BQ24195 library, can also change charge voltages and cutoffs etc

I get the same charge current when powering the board from either VIN or USB

I get the same charge current when either the VIN or USB is disconnected then re-connected

However, charge current drops down to 100mA when powering the board from a single source and re-connecting either supply and will only return to the full charging current after a board reset via either the IDE, reset button or reset pin

I believe this is because the D+ and D- pins to the charge controller are left floating in the board design so when a supply is re-connected the charge controller looks to see what it’s connected to and goes to a failsafe mode

When the arduino is reset, something writes 0x36 into reg 0x00 on the bq24195l. the important part is the '6' which specifies an input current limit of 2A.

If you disconnect the USB power source with the battery attached the arduino will not reset since the battery keeps it running.

If you reconnect the USB power source the bq24195L assesses the power source. Since the D+/D- isn't implemented it can't tell what kind of power source it is.

As a result, the bq24195L writes a 'safe' value of 0x30 into reg 0x00 which limits input power to 100ma.

Charging then enters DPM mode and the charging voltage drops on the battery to limit the current.

If you then press the reset button the reset will revert reg 0x00 to a value of 0x36 and charging voltage pops back up.

Per this post:

So, what I’m thinking, every few seconds, or each loop, write 0x36 to address 0x00 and see if this cures the problem

Some issues -

Can’t use the I2C library alongside the serial1 port I’m currently using for GPS data

Haven’t worked out how to reset the board once the battery is sufficiently charged after being depleted to the point of the board shutting down (assuming that applying a supply to VIN should start the board as normal…., haven’t got that far yet!

Anybody else found a solution to this yet?

@arduinosupport

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.