Flash page is locked

Hi all, when i try to load a sketch to my arduino due, the dialog screen write:

"Flash page is locked
[ ] 0% (0/135 pages)"

and stop programming. I'm using the standard IDE Arduino v1.5.6-r2 and programming port. I've tryed to press the erase button for a few seconds but nothing changes. I've also tryed with different sketch but it not work at all. Can someone help me??


[edit]: If i use the native native port it work. Do I broke my board??

I have exactly the same problem....
Any explanation to that? How to fix it?
I couldn't find any information about this issue.
Thanks in advance.

Keep pressed the erase button. After 1 second press the reset button while keeping the erased button also pressed, wait 1 more second. Then, release both buttons.


The resolution to almost every uploading issue with the Due is to ERASE the Due by pressing the ERASE button, then pressing the RESET button. This will get you back to the native bootloader

Thank you for your tips.
I strictly followed your procedure with ERASE and RESET buttons. I tried few times.
Unfortunately, my Due still says that "flash page is locked". (I use BLINK example to check)
Does it mean that my Due is somehow broken?
It is highly unlikely, becouse I have been using it only for few (maybe two) days, it is plugged to laptop USB, with no external sensors/LEDs/etc wired.
I work with MEGA, UNO and Galileo for few months and it has never happend before. I mean I've never broke any board :slight_smile:

Any ideas?

I strictly followed your procedure with ERASE and RESET buttons. I tried few times.
Unfortunately, my Due still says that "flash page is locked".

Me too , I believe my board is super dead

Has any been able to fix this problem, or is the board really dead?

Same problem here.

Flash page is locked
[                              ] 0% (0/548 pages)

My Due was running for some weeks now, without a change to the uploaded code, and today I wanted to upload a newer version of my program and got this error message (The upload failed immediately).

The strage thing is that the upload is working, if you are holding the erase button at the very beginning of the upload process. (I think "page 0" has a problem and is skipped, when pressing the button at this moment).
It needs a bit of practice and luck (to release the erase button at the right moment), then I am able to get a valid upload and a fully working program on my Due.

The "Hold erase and then reset" is not working for me, I have tried it in many ways, and this problem occurres on both USB ports.

Has anyone an idea how to fix it, or is the flash storage broken?
Is it maybe possible to skip some pages of the upload process?

I had this happen with a variant of the Due that I'm using (SAM3A8C).
I have not found the actual cause - it started happening rather suddenly - but if I open up the Arduino IDE and just upload a "blink" sketch onto the device, next time I try to upload in Eclipse it works fine.

I had the same problem but solved it with Atmel SAM-BA In-system Programmer ,i connect the Arduino due to the native port and run the application (selecting sam3x8 -...) then erase flash and the program tell you that the flash is blocked if you want to unblock selec yes (ofcourse) and then select Enable Flash opción

if it does not repeat , I worked to 4 attempts

if it is reused programming port the problem reappears, it's no problem if only used native usb

Help me PLS.

I could not do otherwise. Emergency help.

ERASE, RESET //Write what problems have not disappeared, but I tried.

This error can happen if the sketch wants to write something into the flash, but the write operation fails, e.g. due to the some configuration error, like using different sub-type of SAM chip than in the board setup. If DueFlashStorage is used for flash writing, then turning on "FLASH_DEBUG" macro can help to track back the actual problem.

The should be fixed with "bossac.exe -u" command.