Are there any examples for K64FX512 FlexNVM using SDK 2.3.0 (fsl_flash)

cancel
Showing results for 
Search instead for 
Did you mean: 

Are there any examples for K64FX512 FlexNVM using SDK 2.3.0 (fsl_flash)

260 Views
bioshazard
Contributor I

Hello, I am having a lot of problems using the SDK 2.3 for a K64FX512 project,

probably since I have been using processor expert before, which made things quite a bit easier it seems.

But right now this one is my primary concern:

I seem to be unable to use the flash driver at all.

If I run:

flash_config_t flashConfiguration;
result = FLASH_Init(&flashConfiguration);

It hardfaults at this line in fsl_flash.c:

    if (kStatus_FLASH_Success != flash_check_execute_in_ram_function_info(config))

If I call 

FLASH_PrepareExecuteInRamFunctions(&flashConfiguration);

first, it hardfaults at this line

copy_flash_run_command(flashExecuteInRamFunctionInfo->flashRunCommand);

Are there any examples available on:

  • how to use the driver in order to partition the FlexNVM
  • how to use the driver in order to use the FlexNVM as data storage
  • how to use the driver in order to use the EEE functionality

I would like to be able to use the FlexNVM as follows: 
64KiB as storage used by the EEE (Data which will be updated frequently 128bytes split as 32 - 96), 
and the other

64KiB to be available as data memory (To which I can write large data blocks (2KiB blocks only updated rarely).

I would probably get it working writing my own driver, but what would be the point in having an SDK then?!

Labels (1)
Tags (1)
0 Kudos
1 Reply

130 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi bioshazard,

flash_check_execute_in_ram_function_info(config) only check a few member in (config). copy_flash_run_command copy code to ram. They do not touch real hardware register. May the hardfault caused by inproperly initialize of the (config)?

There is not any example for the K64 flexNVM and flexRAM. You can refer to TWR-K65F180 SDK. K65's FTFE module is a bit complex than K64. But their structure and driver are similar.

Regards,

Jing

0 Kudos