Hello,
I am confused about the results from the following execution for listing the sizes of my MK60DN256VLL10.
In addition, how can I tell MQX to switch to the other bank at reset?
Would you please advise?
Thanks.
FlashMemory = fopen("flashx:", NULL);
if (FlashMemory == NULL)
{
printf("\n!!!! Unable to open file flashx:");
}
else
{
fseek(FlashMemory, 0, IO_SEEK_END);
printf("\nCurrent flash size = %d Bytes\n", ftell(FlashMemory)); // This yields 131,072 bytes.
}
fclose (FlashMemory);
FlashMemory = fopen("flashx:bank0", NULL);
if (FlashMemory == NULL)
{
printf("\n!!!! Unable to open file flashx:bank0");
}
else
{
fseek(FlashMemory, 0, IO_SEEK_END);
printf("\nFlash Bank0 size = %d Bytes\n", ftell(FlashMemory)); // This yields 262,144 bytes.
}
fclose (FlashMemory);
FlashMemory = fopen("flashx:bank1", NULL);
if (FlashMemory == NULL)
{
printf("\n!!!! Unable to open file flashx:bank1");
}
else
{
fseek(FlashMemory, 0, IO_SEEK_END);
printf("\nFlash Bank1 size = %d Bytes\n", ftell(FlashMemory)); // This yields 262,144 bytes too!
}
fclose (FlashMemory);