Other Parts Discussed in Thread: BQ27426, MSP430FR5869
I have a project using the MSP430FR5869 paired with the TPS65721 and BQ27426. I'm trying to use the ACTIVE and PGOOD interrupts detect when external power is applied or removed so I can update an icon on an attached display. My program does this:
(1) During initialization, mask all interrupts in IRMASK0, IRMASK1, IRMASK2 except M_CH_ACTIVE and M_CH_PGOOD, and then clear any pending interrupts by reading IR0, IR1, IR2 registers.
(2) When the TPS65721's INT pin goes low, an interrupt in my program sets a flag and does nothing else.
(3) In my program's main loop, if the flag is set, read the CHGSTATUS register, check the CH_PGOOD and CH_ACTIVE flags, then reset the INT pin by reading IR0, IR1, IR2 registers.
Is this the intended implementation of the interrupt pin and registers? In particular, when should the IR registers be read/reset?
Thanks,
Adam J.