From 836413fd8a2418364ddbff8283ee0421d7871eb6 Mon Sep 17 00:00:00 2001 From: seaxwi <71350948+seaxwi@users.noreply.github.com> Date: Mon, 30 Sep 2024 14:44:43 +0200 Subject: [PATCH 1/4] Created "Recover an Arduino Opta with read-only flash memory" in a new "Opta" section --- ...rduino-Opta-with-read-only-flash-memory.md | 41 ++++++++++++++++++ .../Opta/img/github-download.png | Bin 0 -> 5525 bytes .../Opta/img/symbol_monitor.png | Bin 0 -> 448 bytes .../Opta/img/symbol_upload2.png | Bin 0 -> 1850 bytes 4 files changed, 41 insertions(+) create mode 100644 content/Hardware Support/Opta/Recover-an-Arduino-Opta-with-read-only-flash-memory.md create mode 100644 content/Hardware Support/Opta/img/github-download.png create mode 100644 content/Hardware Support/Opta/img/symbol_monitor.png create mode 100644 content/Hardware Support/Opta/img/symbol_upload2.png diff --git a/content/Hardware Support/Opta/Recover-an-Arduino-Opta-with-read-only-flash-memory.md b/content/Hardware Support/Opta/Recover-an-Arduino-Opta-with-read-only-flash-memory.md new file mode 100644 index 00000000..0f775839 --- /dev/null +++ b/content/Hardware Support/Opta/Recover-an-Arduino-Opta-with-read-only-flash-memory.md @@ -0,0 +1,41 @@ +--- +title: "Recover an Arduino Opta with read-only flash memory" +--- + +In certain situations, the QSPI flash memory on the Arduino Opta may become configured as read-only. + +The QSPI flash is likely read-only if: + +* You are unable to erase or overwrite the QSPI flash memory. +* You encounter an `Error formatting OTA partition` message when attempting to [partitioning the memory](https://support.arduino.cc/hc/en-us/articles/16206977438748-Reset-the-flash-memory-on-STM32H747-based-devices). + +The write protection can be removed by uploading a recovery sketch. + +---- + + + +Follow these steps: + +1. Download or copy the [unlockOptaNORFlash.ino](https://github.com/manchoz/unbrick-recover-readonly-flash-arduino-opta/blob/master/unlockOptaNORFlash/unlockOptaNORFlash.ino)[^1] sketch from GitHub. + +  + +1. Open the sketch in your editor: + + * Arduino IDE: Do one of the following: + + * Create a new sketch and paste the entire unlockOptaNORFlash sketch into the editor. + * Copy the .ino file into your [Sketchbook](https://support.arduino.cc/hc/en-us/articles/4412950938514-Open-the-Sketchbook-folder). Ensure that `unlockOptaNORFlash.ino` is inside a folder named `unlockOptaNORFlash`. + + * Cloud Editor: Open the [Sketches tab](https://app.arduino.cc/sketches) and click on the **Create** button in the top-right corner. Select **Import local file** in the dropdown menu and import `unlockOptaNORFlash.ino`. + +1. Connect your Opta to your computer and select it in the editor. + +1.  **Upload** the sketch. + +1. Click the  **Serial Monitor** button in the top-right corner or select Tools > Serial Monitor (IDE only). + +1. The process is complete when the line `---end---` appears in the serial output. + +[^1]: The sketch works by reinitializing the QSPI and configuring the hardware protection data pin as a GPIO input. The internal pull-up resistor of the QSPI flash is then used to deactivate the hardware flash protection. Through this approach, writing can be enabled, and the protection bits can be reset. Learn more about the procedure [here](https://github.com/manchoz/unbrick-recover-readonly-flash-arduino-opta). diff --git a/content/Hardware Support/Opta/img/github-download.png b/content/Hardware Support/Opta/img/github-download.png new file mode 100644 index 0000000000000000000000000000000000000000..3e81d2eb38866f9b829bc0d2ed93765ae758030c GIT binary patch literal 5525 zcmV;G6>92
m724YD9h*a!R+#bGhd
z=(tNrzy;xRLBS!T%%G!=j-yOML_|Kt6;Wo~*g|BD*#t>ggak%{BtX(3-RY#4`u^y2
zNJ92>r?cGmdFtt|>Z*HB)$RWExugDE|GmPi+T;hPKmx{J8D2g%ILBq8D9
zYCEE8-X|r!)#3I)!y?nrHdoM8K)s{IY}3}Xn!8Z7gTwI;-b3;`YuK2Y#^sk?#(>K&
zb-OLXqiH9-dW8@g`WuQ)6)|(>bZ)!#766KiPxILPCy0z5!MO30IDYInXV0Dm;D#H9
zv1{ip@(vzCr}yT*yYFK6?sWF&=HcV(&7iBU^yDeEi{Vj`bp$0d(-8wnN_vaoQIQ>P
zPe+OjIPO|C6zhqPkLz%c>GI1iYj&UffbO0m7qcHxJx*FIQf91r-%$KKtx*9(i~U
zA;H1?D>;SZ$B*;bCm+(k|D`N=a$(Iekr6`y`1s>b851*-h{y;I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