Part Number:MSP432P401R
Tool/software: Code Composer Studio
Hi,
I would like to make my MSP432P401R MCU behaves differently depending on supply voltage.
(For example, MCU executes a program with LDO_VCORE0 48MHz in 2.8V ~ 3.3V range, and runs another program with LDO_VCORE0 8MHz in 2.0V~2.8V.)
Before configuring MCU power modes, I searched for how to check MCU is in different Vcc range.
And I found SVSMH monitor mode of PSS in several MSP432 datasheet and technical reference. The mode checks if Vcc falls below the device-specific threshold and generates an interrupt.
Therefore, I downloaded pss_monitor example in 'Resource Explorer,' and tested the example in different trigger voltage levels.
But checking different Vcc ranges requires multiple PSS_IRQ configuration as far as I understand.
The reason why I thought like that is "there is only one interrupt condition form PSS that is triggered by SVSMH module while operating in the monitor mode. (by MSP432P4xx SimpleLink™ Microcontrollers Technical Reference Manual (Rev. H) 7.2.4)".
So, I think re-configuring PSS_IRQ several times to next trigger point whenever it called might work.
Example scenario:
1. At first, PSS interrupt was configured to happen when voltage level 7 (=2.8V).
2. Supply voltage dropped near to 2.8V, and the interrupt occurred.
3. I disabled and enabled the PSS interrupt again to occur when voltage level 4 (=2.25V).
4. If the interrupt occurred again because of low supply voltage 2.25V, PSS interrupt was reconfigured again to the voltage level 1 (=1.62V)
The rough psuedo code I tried to implement the program is followed:
main() {
while(1) {
set_new_PSS_IRQ(next_trigger_point);
}
}
PSS_IRQ() {
if(PSS_getTrigger() == 2.8V)
next_trigger_point = 2.25V;
else if(PSS_getTrigger() == 2.25V)
next_trigger_point = 1.62V;
disable_PSS_IRQ();
}
The program was build and executed without an error, but an unexpected result turned out.
I thought if current-voltage is near to 2.8V, only initial PSS IRQ occurred and stayed in main's while(1) before supply-voltage drops to 2.25V.
However, re-configured PSS interrupt (whose trigger point is 2.25V and then 1.62V) kept occurring despite its current-voltage near of 2.8V.
I seemed like the very first PSS interrupt trigger point is satisfied(2.8V), and all PSS interrupt occurs regardless of trigger point re-configuration to me.
Q1. Is PSS interrupt re-configuring in a project possible?
Q2. Is there any other way to execute MCU differently depending on Vcc range>
Sincerely, Koo