target remote tcp:localhost:3333 define flash_test1 monitor arm semihosting enable monitor reset halt set confirm off file build/test1.elf load build/test1.elf set confirm on monitor stm32f1x.cpu mwb 0x20000000 0x5a 20480 end monitor reset halt