In order to have a more human readable and also address care-free way to deal with the EEEPROM, my idea was as follows:
- link a global struct variable into the FlexRAM memory area (starts at 0x14000000)
__DATA(FLEX_RAM) MyStruct myStructVariable;
Note: this is done above the main() function
- read and write via the SDK function
writeToFlexRam((uint32_t)&myStructVariable.value1, (uint8_t*)&someValue, sizeof(someValue));
Unfortunately this leads to a hard fault. Whenever I link the variable to another RAM, let's say RAM2, no hard fault occurs.
What's wrong with my approach? Any ideas?
Thanks in advance