Dear sirs,
we're wondering if it's correct to use the SNVS module for temporary storage of some variables, in order to keep their value even after a Reset Software.
As example:
#include "fsl_snvs_lp.h"
int main(void){
...
uint32_t registers[4];
SNVS_LP_Init(SNVS);
registers[0]=SNVS->LPGPR_ALIAS[0];
registers[1]=SNVS->LPGPR_ALIAS[1];
registers[2]=SNVS->LPGPR_ALIAS[2];
registers[3]=SNVS->LPGPR_ALIAS[3];
PRINTF("Registers:%u,%u,%u,%u\n",registers[0],registers[1],registers[2],registers[3]);
registers[0]++;
registers[1]+=2;
registers[2]+=3;
registers[3]+=4;
SNVS->LPGPR_ALIAS[0]=registers[0];
SNVS->LPGPR_ALIAS[1]=registers[1];
SNVS->LPGPR_ALIAS[2]=registers[2];
SNVS->LPGPR_ALIAS[3]=registers[3];
SNVS_LP_Deinit(SNVS);
NVIC_SystemReset();
...
}
The example seems to work fine, but at Chapter 19.2 - SNVS introduction of IMXRT1060 Reference Manual (we're using MIMXRT1060-EVK board) we read:
"SNVS incorporates both security and non-security functionality. The SNVS non-security functionality is described in this document, but the SNVS security functionality is described only in the Security Reference Manual."
We don't know if some security-related features can affect general purpose registers.
BR
Daniele
Solved! Go to Solution.
Hello Daniele,
If I understood correctly, you want to use the SNVS_LP General Purpose Registers, right? If this is the case, then the security features won't affect these registers at all.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hello Daniele,
If I understood correctly, you want to use the SNVS_LP General Purpose Registers, right? If this is the case, then the security features won't affect these registers at all.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------