Flash Partition in S32K144 - FLASH_DRV_CommandSequence() function call issue

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Flash Partition in S32K144 - FLASH_DRV_CommandSequence() function call issue

957件の閲覧回数
vishwadn
Contributor II

Hi, I am trying to run the Flash Partition Example code from S32DS on S32K144EVB.  Function FLASH_DRV_CommandSequence() is leading to default ISR when called. Interestingly it works fine when we do STEP IN of each instruction in that function, but if function is run at once, its going to default ISR.

Directive START_FUNCTION_DEFINITION_RAMSECTION is defined above the function definition to load into RAM.

Please let me know what changes/configurations to be done to make it work.

ラベル(1)
0 件の賞賛
返信
6 返答(返信)

932件の閲覧回数
Senlent
NXP TechSupport
NXP TechSupport

Hi@vishwadn

Could you please have a try the below two methods.

1.Perform a mass erase.
The FlexNVM memory is partitioned to EEPROM use and is blocked for some erase commands (Erase Sector and Erase Block). As a consequence, loading the program to flash memory may fail on some debuggers. Please perform a mass erase operation on Flash to remove this partitioning after running the example to be able to update your application on target.

2.Define FLASH_TARGET to disable cache and try again.

/* Disable cache to ensure that all flash operations will take effect instantly,
* this is device dependent */
#ifndef FLASH_TARGET
#ifdef S32K144_SERIES
    MSCM->OCMDR[0u] |= MSCM_OCMDR_OCM1(0x3u);
    MSCM->OCMDR[1u] |= MSCM_OCMDR_OCM1(0x3u);
#endif /* S32K144_SERIES */
#endif /* FLASH_TARGET */

 

0 件の賞賛
返信

900件の閲覧回数
vishwadn
Contributor II

Hi Senlent,

     I tried with both methods you mentioned above but issue is still there. Below are observations with and without methods you mentioned above:

1) Without above methods - No Mass erase and no cache disable:

Control is jumping to default ISR at FLASH_DRV_CommandSequence() and this function is called from FLASH_DRV_SetFlexRamFunction()

2) Without above methods - Mass erase and  cache disable, FLASH_TARGET defined:

Control is jumping to default ISR at FLASH_DRV_CommandSequence() and this function is called from FLASH_DRV_DEFlashPartition()

0 件の賞賛
返信

895件の閲覧回数
Senlent
NXP TechSupport
NXP TechSupport

Hi@vishwadn

Thank you for the information you provided, I will confirm with you again:
1. You have not made any modifications to the routine
2. Can you tell me the part number of your MCU?
3. What IDE and RTM version are you using?
4. Tell me which debugger you use
I will try to reproduce your problem. If I cannot reproduce it, I can't give you a reasonable explanation.

0 件の賞賛
返信

878件の閲覧回数
vishwadn
Contributor II

Hi Senlent,

    Below are details you asked for:

1. You have not made any modifications to the routine - No
2. Can you tell me the part number of your MCU - S32K144 EVM - SCH-29248 REV C1
3. What IDE and RTM version are you using - S32DS 3.5 and S32SDK_S32K1XX_RTM_4.0.1
4. Tell me which debugger you use - PE Open SDA

0 件の賞賛
返信

843件の閲覧回数
Senlent
NXP TechSupport
NXP TechSupport

Hi@vishwadn

This is a known bug and has been fixed in the new version.

Senlent_0-1715660665437.png

You can modify it like this:

"peripherals_flash_FTFC.c"

Senlent_1-1715660682012.png

 

0 件の賞賛
返信

639件の閲覧回数
346500452
Contributor III

Hi@Senlent 

What do you mean by the new version? SDK or S32DS?

And where can find the table in picture.

tku

0 件の賞賛
返信