Skip to content

Commit

Permalink
fixup! fixup! cpu/sam0_common: flashpage: split RWWEE and normal func…
Browse files Browse the repository at this point in the history
…tions
  • Loading branch information
benpicco committed Aug 4, 2020
1 parent 65c7efa commit 9bc2824
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cpu/sam0_common/periph/flashpage.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,9 @@ static void _erase_page(void* page, void (*cmd_erase)(void))
/* erase given page (the ADDR register uses 16-bit addresses) */
_unlock();

/* ??? */
/* ADDR drives the hardware (16-bit) address to the NVM when a command is executed using CMDEX.
* 8-bit addresses must be shifted one bit to the right before writing to this register.
*/
#if defined(CPU_SAMD21) || defined(CPU_SAML21)
page_addr >>= 1;
#endif
Expand Down

0 comments on commit 9bc2824

Please sign in to comment.