KV31F Tower havings issues with PE and Flash driver combo

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

KV31F Tower havings issues with PE and Flash driver combo

Jump to solution
741 Views
stevenneves
Contributor I

I have run both the flash_example and flash_demo and simply tried replicating this logic within a new project (for a bootloader) using Processor Expert.  I am aware of the demo/example using the bare metal platform library rather than PE but that appears to be the only difference.  My main issue appears to be centered around:

 

g_FlashLaunchCommand = (pFLASHCOMMANDSEQUENCE)RelocateFunction((uint32_t)__ram_func , LAUNCH_CMD_SIZE ,(uint32_t)FlashCommandSequence);

 

Whether I'm calling FlashEraseSector, FlashReadResource, FlashProgram, etc.  They all call:

 

ret = pFlashCommandSequence(pSSDConfig);

 

This always returns 0x20 (FTFx_ERR_ACCERR)

 

Attached is my test project, at this point I really can not tell a difference between the demo and my test application in regards to utilizing this driver.

 

Thanks in advance.

 

EDIT: 

Hardware: TWRKV31F120M

IDE: KDS 3.0

SDK: KSDK 1.3

Original Attachment has been moved to: FlashTest.zip

Labels (1)
Tags (2)
0 Kudos
1 Solution
562 Views
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Steven Neves:

Flash erase/program operations are not possible in HSRUN mode (maximum frequency). Try setting Clock Configuration 4 in your project:

pastedImage_0.png

Then generate code, build and try again. I hope this helps.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
3 Replies
563 Views
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Steven Neves:

Flash erase/program operations are not possible in HSRUN mode (maximum frequency). Try setting Clock Configuration 4 in your project:

pastedImage_0.png

Then generate code, build and try again. I hope this helps.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
562 Views
stevenneves
Contributor I

Thank worked.  Thank you very much.  Is this documented anywhere by chance?

0 Kudos
562 Views
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Steven:

I am glad it worked. This limitation is documented in the Reference Manual:

pastedImage_1.png

Regards!

Jorge Gonzalez

0 Kudos