source [find arm-usb-ocd.ocd]
source [find stm32.ocd]

$_TARGETNAME configure -work-area-phys 0x20000000 -work-area-size 0x10000 -work-area-backup 0

set _FLASHNAME $_CHIPNAME.flash
#flash bank <name> <driver> <base> <size> <chip_width> <bus_width>
flash bank $_FLASHNAME stm32x 0x08000000 0x00040000 0 0 $_TARGETNAME