cancel
Showing results for 
Search instead for 
Did you mean: 

crash system with EEPROM emulation in STM32F0xx microcontrollers

juliensineau9
Associate II
Posted on April 19, 2013 at 11:04

Hello,

For my tests, i use a STM32F0 discovery and i download on the ST website, the

EEPROM emulation in STM32F0xx microcontrollers

software.

http://www.st.com/web/en/catalog/tools/PF258153

When i run this demo project with �Vision 4, the execution of this sofware causes a crash of my debug session.

I remark that the crash

happens when

the loop

is used to write

the data

is

larger than the

page size

. But when i execute the same software in step by step, no crash happens !

I suppose that a timing problem.

Can you help me ?

#stm32f0-eeprom-emulation-bug #forum-says-no
6 REPLIES 6
juliensineau9
Associate II
Posted on April 25, 2013 at 11:37

up

Posted on April 25, 2013 at 11:51

Crashes how exactly, and on what instruction? You provide no code/process to demonstrate the failure. Does it fail every time? The first time? When you run it a dozen times, or modify it?

Before kicking posts, consider why they are being ignored.
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
juliensineau9
Associate II
Posted on April 25, 2013 at 16:02

I found alone !!!

FLASH_SetLatency(); !!!

Steps for reproduce this bug:

- Buy the F0 Discovery board

- Download the exemple

EEPROM emulation in STM32F0xx microcontrollers

(

http://www.st.com/web/en/catalog/tools/PF258153

)

- Load

- Run

- Crash !!!

It

is clear

this time?

emalund
Associate III
Posted on April 25, 2013 at 17:14

Steps for reproduce this bug:

 

- Buy the F0 Discovery board

sure, I'll run out and spend some money to help you for free

Crashes how exactly, and on what instruction? You still provide no code/process to demonstrate the failure. Does it fail every time? The first time?

 

 

anyhow, I have a good guess.  you forget that flash is page based and using some ''EEPROM bytes'' in a page that contains code, of course, makes that page erase.

Erik
Posted on April 25, 2013 at 18:14

It

is clear

this time?

 

Not much frankly, does it output a message saying ''Crash!!!'', or can you figure out where it is by stopping the CPU in the debugger? Does it get stuck in a loop, the Hard Fault handler?

Other useful information might be what tool chain you're using?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
kevinliao
Associate II
Posted on September 04, 2015 at 09:25

Hi, ST sirs,

I also have the write data eeprom will ''crash'' problem, 

I found that when the value of data = 0x00, the system will crash.

Is that need spacial process when data value = 0x00.

By the way, why the data eeprom need erase process?

When will the data eeprom need be erase?

I just do the read and write procedure.  

Thank you. 

Kevin