summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usb-dfu-experiment/main.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/usb-dfu-experiment/main.c b/usb-dfu-experiment/main.c
index 31c2c4f..12de844 100644
--- a/usb-dfu-experiment/main.c
+++ b/usb-dfu-experiment/main.c
@@ -366,7 +366,11 @@ int USBDFU_handle_dnload(uint8_t altif, unsigned int offset,
switch (altif) {
case ALTIF_APP:
case ALTIF_FPGA:
+ /* SAM3U Errata 46.2.1.3 */
+ SetFlashWaitState(6);
rc = FLASHD_Write(addr, buf, len);
+ /* SAM3U Errata 46.2.1.3 */
+ SetFlashWaitState(2);
if (rc != 0) {
TRACE_ERROR("Error during write of DFU partition %u\n\r", altif);
dfu.status = DFU_STATUS_errPROG;
personal git repositories of Harald Welte. Your mileage may vary