Bad microcontroller memory - Page 1
Forum section: electronics / general

author: michaelym
author_rank: Regular Contributor
timestamp: November 11, 2012, 08:08:15 am
content: I'm using a Silicon Labs c8051f124 microcontroller.Here are my symptoms:When I tried downloading my code, the Silabs IDE returned a message that the "CRC comparison failed'.Next I tried a "Memory Fill" to fill the memory with all ones, and it failed too. When I checked the memory map a certain area of the memory doesn't get written.I next tried another board and it worked fine.My conclusion:I have a bad flash memory in my microcontroller, and should swap out the chip.Does anyone have other ideas?

author: mrflibble
author_rank: Super Contributor
timestamp: November 11, 2012, 02:59:19 pm
content: Curious results during flashing ==> Check check double check all your supply voltages. And your programmer.

author: free_electron
author_rank: Super Contributor
timestamp: November 11, 2012, 07:10:54 pm
content: you tried another board : identical board ? in that case the microcontroller could be bad.check for missing decoupling caps close to the cpu. during flash the cpu neds to create the program voltage and draws peak currents. if the local decoupling caps are missing you can get flash program errors

author: michaelym
author_rank: Regular Contributor
timestamp: November 12, 2012, 06:21:49 am
content: Thank you for your responsesYes I tried two different (identical) debug adapters and 3 identical boards, Only one board gave me the problem.I will check the decoupling caps, although the same addresses go bad every time.

author: NiHaoMike
author_rank: Super Contributor
timestamp: November 17, 2012, 06:21:11 am
content: The chip is most likely bad, replace it.

author: amyk
author_rank: Super Contributor
timestamp: November 17, 2012, 10:38:33 am
content: Take care of the replacement too, be sure to follow ESD precautions.An ESD event or supply glitch during the original programming could cause too much charge to be forced onto the floating gate, making the bit overprogrammed and "stuck" at 0. If the bits don't set after a few more erase cycles then they're gone for good.

author: michaelym
author_rank: Regular Contributor
timestamp: November 25, 2012, 09:27:56 am
content: I replaced the chip and it's working fine now.

author: michaelym
author_rank: Regular Contributor
timestamp: November 29, 2012, 10:50:31 am
content: Problem solved!The program was using the code memory for storage. there was one variable being written once every second. So after a little more than 24 hours it went through enough wright cycles to fry those bits.

author: amyk
author_rank: Super Contributor
timestamp: November 30, 2012, 01:52:58 pm
content: According to the datasheet, 20k minimum and 100k typical endurance... but in my experience I'd say 10k would be a safe limit.

author: SeanB
author_rank: Super Contributor
timestamp: November 30, 2012, 05:56:48 pm
content: It took me about 3 days to kill a flash memory on my EEEPC, used it as swap just to see how long it would last. After 2 days I had a good kernel dump on the screen, and it had locked up. Depowdered and checked the disk, fine, but had bad blocks......... not good on an EXT3 filesystem and with a swap partition as well. Wiped and installed Puppy on the new one.

author: ivan747
author_rank: Super Contributor
timestamp: November 30, 2012, 07:06:00 pm
content: Quote from: SeanB on November 30, 2012, 05:56:48 pmI want to hack mine before it becomes too obsolete.