File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -20,12 +20,12 @@ fn main() -> ! {
2020 if let Some ( mut p) = pac:: Peripherals :: take ( ) {
2121 let _ = p. RCC . configure ( ) . freeze ( & mut p. FLASH ) ;
2222
23- const OFFSET_START : u32 = 32 * 1024 ;
24- const OFFSET_END : u32 = 33 * 1024 ;
23+ // All examples use the first 16K of flash for the program so we use the first page after that
24+ const OFFSET_START : u32 = 16 * 1024 ;
25+ const OFFSET_END : u32 = OFFSET_START + 1024 ;
2526 // Unlock flash before writing
2627 let mut unlocked_flash = p. FLASH . unlocked ( ) ;
2728
28- // All examples use the first 16K of flash for the program so we use the first page after that
2929 NorFlash :: erase ( & mut unlocked_flash, OFFSET_START , OFFSET_END ) . unwrap ( ) ;
3030
3131 // Write some data to the start of that page
You can’t perform that action at this time.
0 commit comments