谢谢版主们的回答,问题解决了。我之前的程序运行时时钟处于FEI模式,因此我没有关闭时钟监控,不会在VLPS状态下GPIO中断唤醒引发reset,但是后来我移植的综合程序时钟处于PEE模式,没有关闭时钟监控,导致了reset ;
datasheet的原文为:
CME0 bit should be set to a logic 0 before the MCG enters
any Stop mode. Otherwise, a reset request may occur while in Stop mode。