Bricked my SAM4S xplained pro - No device detected. Error 4109

Go To Last Post
7 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

While trying to configure sleep mode, I bricked my SAM4S xplained pro. When I plug the xplaine pro into AS7, its see it when I plug it in (the window pops up with the xplained pro info). Clicking the device programming and click read, I get the error:

 

No device detected. Error 4109

Unable to enter programming mode. Verify device selection, interface settings, target power, security bit, and connections to the target device.

 

Trying to erase the chip through atprogram doesn't work either:

C:\Program Files (x86)\Atmel\Studio\7.0\atbackend>atprogram -i SWD -t edbg -d SAM4SD32C chiperase
Firmware check OK
[ERROR] Could not set device properties. Make sure you have selected correct device and interface, and that the hardware connections are correct.

Any ideas how to fix this?

This topic has a solution.

"When all else fails, read the directions"

Last Edited: Fri. Jun 2, 2017 - 11:29 PM
This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I found this post about how to do a manual chip erase.

 

In case that post disappears, here is what is says:

 

phillynj wrote:

The Atmel SAM4S is pretty easy to "brick", by e.g. an infinite sleep loop. This prevents reprogramming, since the debugger can't communicate with the chip. To solve this, you need to erase the chip. I ran into this issue with a custom board, and then confirmed it with the SAM4S Xplained Pro. Unfortunately, the SAM4S Xplained Pro has no test point or jumper for the erase pin. This was confirmed by Atmel support, which suggested that I would attach a wire directly to pin 87 of the processor in order to assert it high and induce erasing of the chip. Pretty difficult on a processor with 0.5mm pitch.

Fortunately, I discovered that the erase pin is accessible through an exposed via on the back of the board. Simply connect the via circled in red in the image below to the VCC test point (I used a paper clip), and then supply power to the board to trigger the erase.

 

 

Simply applying 3.3v to the ERASE Pin when I plug it in erased the chip and I am back in business. Now I just need to find out how to make it sleep without bricking it!

 

 

"When all else fails, read the directions"

Last Edited: Fri. Jun 2, 2017 - 11:10 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You can mark your own post as "solution" for others to come...

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Grottenolm wrote:

You can mark your own post as "solution" for others to come...

Yes...I did already.

"When all else fails, read the directions"

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello, I just suddenly can not program my SAM4S board with the error 'flash controller error'. But I can read the chip's signature. I also tried to manually erase the chip. But still does not work. Do you have any clue about it?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

After you erase the chip, can you program it? I usually load a simple blink code to just to if its working

"When all else fails, read the directions"

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

No, I can not program it. It still shows the 'flash controller error'.