MAX14720 Library for MAX32620HSP (MAXREFDES100#)
Dependents: HSP_PMIC_Demo HSP_SpO2 HSP_ECG HSP_ECG_LeadOFF_Detection
Fork of MAX14720 by
Diff: MAX14720.cpp
- Revision:
- 7:2e9f6e70b34f
- Parent:
- 3:cdd88a3d3d24
- Child:
- 8:2c3f2da51c5d
diff -r 06450093da48 -r 2e9f6e70b34f MAX14720.cpp
--- a/MAX14720.cpp Thu Oct 06 17:10:56 2016 +0000
+++ b/MAX14720.cpp Thu Oct 06 21:33:25 2016 +0000
@@ -122,15 +122,15 @@
}
if (boostEn == BOOST_ENABLED) {
result = writeReg(REG_BOOST_CFG, 0x00);
+ if (result == MAX14720_ERROR) return result;
}
- if (result == MAX14720_ERROR) return result;
result = writeReg(REG_BOOST_VSET, data);
if (result == MAX14720_ERROR) return result;
if (boostEn == BOOST_ENABLED) {
data = (boostEn << 3) | (boostEMI << 1) | (boostInd);
result = writeReg(REG_BOOST_CFG, data);
+ if (result == MAX14720_ERROR) return result;
}
- if (result == MAX14720_ERROR) return result;
return 0;
}

PMIC with buck-boost/buck regulator, switches and LDO for wearable watches MAX14720