// Waiting some time to be sure stm32 is in a stable state // regarding GPIO configuration ////////// Stop the HW WDOG ////////// // Read status of option bytes mem32 0x40023C14, 1 // Unlock option bytes flash register w4 0x40023C08, 0x08192A3B w4 0x40023C08, 0x4C5D6E7F // Check that the flash has been unlocked mem32 0x40023C14, 1 // Deactivate HW WDG w4 0x40023c14, 0x0FFFAAEC w4 0x40023c14, 0x0FFFAAEE w4 0x40023c14, 0x0FFFAAED // Reset the core so that changes are taken into account r ////////// end of stop HW WDOG ////////// // Put an infinite loop in place and jump into it w4 0x20000000, 0xE7FEE7FE setpc 0x20000000 // GPIOC pins as input (NRF_SWCLK) w4 0x40020800 0x00000000 // GPIOD pins as input (NRF_SWDIO) w4 0x40020C00 0x00000000 q