S32K342 Flash module

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

S32K342 Flash module

跳至解决方案
4,489 次查看
qazx
Contributor III

I have example code for flash module.

How to check the flash module is working fine, I have checked in Physical address also its given random values in that memory. 

How to write ,read and erase on Flash memory?

I checked in flash registers also, I don't know which registers I need to look on it.
Can you give me the solution for this?

I attached the memory location pic also.

 

标记 (1)
0 项奖励
回复
1 解答
4,341 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi @qazx 

attached are possible reasons. The first one is usually the source of issues.

Regards,

Lukas

在原帖中查看解决方案

0 项奖励
回复
7 回复数
4,148 次查看
qazx
Contributor III

Hello @lukaszadrapa 

I have tried flashing only with internal sector flash , i cant  to do write operation .
In user manual some limitations is there for C40_internal flash.
How to do the write operation in flash.
I can able to read from memory , its showing default value FFFFFFFF. 

0 项奖励
回复
4,455 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi @qazx 

First step is to check the PEG flag:

lukaszadrapa_0-1675157145680.png

 

lukaszadrapa_1-1675157169819.png

Second step is to read the programmed data back from flash for confirmation it was programmed correctly. Notice that it may be necessary to invalidate the data cache if data cache is enabled and if previous data are already cached.

And two important notes:

1. User is allowed to program only fully erased double-word. Cumulative programming is not allowed.

lukaszadrapa_2-1675157354549.png

2. Read-while-write is supported only between read partitions / blocks. It is not possible to access a partition which is being programmed or erased. The code must be executed from another partition or from RAM.

lukaszadrapa_3-1675157572027.png

Regards,

Lukas

4,440 次查看
qazx
Contributor III
PEG bit field is 0. What i have to change?
0 项奖励
回复
4,426 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Well, what kind of example code do you have? Is that your own code or is that an example from RTD package? If it is from RTD - which one and which version of RTD? Is that original RTD example or modified one?

Regards,

Lukas

0 项奖励
回复
4,412 次查看
qazx
Contributor III
It"s a RTD package code.

package version is - SW32K3_RTD_4.4_2.0.0

Example code name - Fls_Example_S32K342.

Origional RTD example and i checked for internal sector only so i commanded the external sector code.
0 项奖励
回复
4,397 次查看
qazx
Contributor III

Hello @lukaszadrapa 

 

Can you share the detail, why the PEG register is not updating to 1.
PEG register value in 0 only not changing.

0 项奖励
回复
4,342 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi @qazx 

attached are possible reasons. The first one is usually the source of issues.

Regards,

Lukas

0 项奖励
回复