S32K3 Read/Write Flash with C40-Driver

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

S32K3 Read/Write Flash with C40-Driver

Jump to solution
6,342 Views
JoDo
Contributor III

Hi,

I want to read and write some data to the internal flash of the S32K344. I use the C40 Dreiver for this and the example from the S32DS. If I do delete -> write -> read once, it works fine and I can see the change immediately in the memory browser. But the second time it seems to have no effect in flash memory. If I restart the code with the debugger, I can see the changed data in flash from the second write. 

What else needs to be taken care of so that each erase->write operation immediately writes the data to flash memory?

Regards,

JoDo

0 Kudos
Reply
1 Solution
6,313 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @JoDo,

I had to copy your code to C40_Ip_Example_S32K344 from RTD 1.0.0 2010_10 version as I don't have the older version that you use.

Anyway, without any modification, I can see the data in the memory after the second write.

danielmartynek_0-1638797191542.png

 

What debugger do you use?

Can you update to the new RTD?

 

Regards,

Daniel

 

View solution in original post

0 Kudos
Reply
6 Replies
5,775 Views
Skannan
Contributor I

what is c40? Is it standard or what?

 

Tags (1)
0 Kudos
Reply
6,308 Views
Guofred
Contributor III

thanks for sharing this information. it looks the flash had been written successful in the second time after restarting the code with the debugger, i also think due to the software version or debugger setting cause this issue.  

0 Kudos
Reply
6,290 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @Guofred,

Since I can't reproduce it, I'm not sure I full understand the issue.

You read the flash with core and the debugger.

Do they both show the same issue, or is it just the debugger (memory view)?

 

Thanks,

BR, Daniel

0 Kudos
Reply
6,314 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @JoDo,

I had to copy your code to C40_Ip_Example_S32K344 from RTD 1.0.0 2010_10 version as I don't have the older version that you use.

Anyway, without any modification, I can see the data in the memory after the second write.

danielmartynek_0-1638797191542.png

 

What debugger do you use?

Can you update to the new RTD?

 

Regards,

Daniel

 

0 Kudos
Reply
6,269 Views
JoDo
Contributor III

Hi @danielmartynek and @Guofred ,

Thank you very much for the answer. 

I checked the code with the new RTD version and the flash could be read and written several times. It seems that the problem was indeed in the old RTD version.

The strange thing was that I could write several times and could also read the data in memory, but it stopped working once I ran the read function.

However, with the new RTD version everything works fine.
Tank you for the advice!

Regards,

JoDo

0 Kudos
Reply
6,261 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @JoDo,

Thanks for the update,

I'm glad it works now,

 

BR, Daniel

0 Kudos
Reply