I am trying to program an STM32F0 from a linux based processor. I have connections to the SWRST, SWDIO and SWCLK pins.
I have most of it working well, but when I go to write to the flash memory locations, it fails with the DAP controller reponding with ACK FAIL. My current technique is to access the flash memory controller registers @0x4002200 and to write to flash this way. Just like the flash programming examples in the STM32 datasheet
I have verified that I am able to erase flash. When I capture some traffic from my ST Link programming the part, it seems to use a very different approach that i can't figure out, it seems to be writing to addresses @0x20000000. My flash is @ 0x08000000.
Does anybody have experience with this? Is my approach completely wrong?