I would like to wakeup MAX17320 using a pushbutton switch.
The datasheet shows a circuit but it is not working on my setup:

What is the best way to do it?
KCC's Quizzes AQQ305 about a mutual exponentiation equation
1. Quote of the month: "A train station is where a train stops. A bus station is where a bus stops. I have a work station on my desk, so..." - unknown
2. Quiz AQQ305 about finding a mutual exponential equation
Good luck, and try to be among the
View All
September Monthly Blog Quiz! Read the blog, take the quiz, and you could win a gift card
Quiz: How Well Do You Know Adaptive Power Switching?
Is your I/O module overheating? The AD74416H's Adaptive Power Switching (APS) can cut heat dissipation by up to 40% — but how well do you really understand how it works?
Read the blog first: Cooling
View All
MAX17320
Recommended for New Designs
The MAX17320 is a 38µA IQ stand-alone pack-side fuel gauge IC with protector, battery internal self-discharge detection, and optional SHA-256 authentication...
Datasheet
MAX17320 on Analog.com
I would like to wakeup MAX17320 using a pushbutton switch.
The datasheet shows a circuit but it is not working on my setup:

What is the best way to do it?
Hey jai123 ,
Thanks for reaching out. Pushbutton wake-up on the MAX17320 works through the ALRT pin, and a few configuration details must be in place for it to work:
nConfig.PBen (1B0h) must be set to 1 and saved to NVM. You can confirm it's active by reading HProtCfg2.PBEN (0F1h).
The button only wakes the part from Ship or DeepShip mode. It will not wake it from Undervoltage Shutdown (only a charger can), and the pack voltage must be at least 4.2V.
ALRT should not be used for anything else. Please check that nProtCfg.OvrdEn = 0, and that alert output (Aen/ALSH) isn't active.
The button must hold ALRT low for longer than ~100ms, and ALRT should have a pull-up so it idles high.
To help us look further, could you share:
Your nConfig, nProtCfg and HProtCfg2 values (or your .INI file)
How you're putting the part to sleep (SHIP command, communication drop, or undervoltage)
Pack voltage and cell count
A scope capture of ALRT during a button press
Best,
Doug
Hi jai123 ,
Thanks for the details. The warm-vs-cold behavior points to where the settings are stored.
The MAX17320 reloads its settings from NVM every time it powers up. Writing nConfig (0x1B0) or Config (0x00B) from firmware only changes the working copy, which is lost when the cells are disconnected. The factory NVM default for nConfig is 0x2290, which has PBen = 0. So on a cold connect, pushbutton wake is disabled until your firmware runs again. On a warm cycle, your firmware has already set PBen, which is why the button works then.
To confirm:
After a cold connect, and before your firmware writes anything, read nConfig (0x1B0) and HProtCfg2 (0x0F1). HProtCfg2 is read-only but reports whether pushbutton wake is actually active (PBEN bit). I expect PBen/PBEN = 0.
To fix: 2. Save your configuration to NVM once: nConfig = 0x2690, plus nPackCfg, nODSCTh, nIPrtTh1, nBalTh, nProtCfg, etc. Use the Copy NV Block procedure in the datasheet: unlock CommStat, write the registers, send E904h, check NVError, then do a full reset. 3. NVM can only be written 7 times, so please check how many writes remain first (command E29B, then read 0x1FD), and write all the settings in one pass.
After that, the settings should persist through a cold connect and the button should wake the part. Let me know what the step 1 readback shows.
Best,
Douglas
FOR CONTEXT jai123 replied:
RAM Config (00Bh) reads 0x2610.
nConfig = 0x2690
PBen = 1
nConfig = 0x2690
nPackCfg 0xA100
nProtCfg 0x0100 (DeepShip 0, ALRT override 0)
nODSCTh 0x0A04
nBalTh 0x046A
Hi jai123 ,
Thanks, that rules out the NVM settings. PBen is set in both nConfig and Config, so pushbutton wake is configured correctly.
To narrow down the cold-boot case, could you check:
Best,
Doug
To wakeup from cold boot, I was providing a short 9V pulse on the PCKP pin and it works normally after.
Hey jai123 ,
Thank you, this is helpful.
Since PBen is already programmed in NVM and survives a cold power cycle, I no longer think the issue is related to the pushbutton configuration itself.
Two things stand out:
ALRT currently has no pull-up. The pushbutton wake mechanism depends on the ALRT signal transitioning from a valid high level to low. If ALRT is floating during a cold startup, the device may never detect a valid button event. As a first test, I would recommend adding a pull-up on ALRT (for example 100 kΩ, or 47 kΩ if preferred) to an always-available logic rail rather than to a rail that is only present after the system powers up.
The cells are connected one at a time. During cold installation the gauge temporarily sees one populated cell and one missing cell. Since the device does not respond on I²C afterward, it is possible that startup is entering an undervoltage-related shutdown condition. The fact that both a charger connection and a 9 V pulse on PCKP can recover the part makes this explanation plausible.
Could you try the following experiments:
Two additional questions: when the charger wakes the device and it remains in an error state, which fault bits are being reported in Status/ProtStatus immediately after wakeup? Also are you using your own board or is this implementation on a EVKIT
Best,
Douglas