On Thu, Nov 4, 2010 at 2:46 PM, Jonathan dumaresq <jdumar...@cimeq.qc.ca> wrote: > Hi all, > > I try to get my stm32 environnement working with gdb. I'm unable to get my > elf file loaded with gdb. Here my setup: > > Openocd.cfg > ///// > source [find interface/olimex-arm-usb-ocd.cfg] > source [find target/stm32.cfg] > > stm32.cpu configure -event gdb-flash-write-end { > reset init > } > > stm32.cpu configure -event gdb-flash-erase-start { > reset init > } > /////// > > All include file are default. > > Here how i lunch gdb > > Arm-none-eabi-gdb rtosdemo.elf > > > (gdb)target remote | openocd --pipe > (gdb)load rtosdemo.elf > (gdb) load > Loading section .text, size 0xa7d8 lma 0x0 > Debug: 408 139609 gdb_server.c:2145 gdb_input_inner(): received packet: > 'X0,3fb0 > :<binary-data>' > Debug: 409 139609 gdb_server.c:1388 gdb_write_memory_binary_packet(): addr: > 0x00 > 000000, len: 0x00003fb0 > Debug: 410 139609 target.c:1251 target_write_buffer(): writing buffer of > 16304 b > yte at 0x00000000
0x00000000 is most certainly the wrong place to be writing stuff... > Warn : 419 139828 arm_adi_v5.c:720 mem_ap_write_buf_u32(): Block write error > add > ress 0x0, wcount 0xfec > Error: 420 139828 gdb_server.c:1211 gdb_error(): unexpected error -107 > Load failed > (gdb) > > I have to admit that i'm a little bit lost there. Do i have something else > to do to get this work ? Yes, you need to fix your broken linker script (in case of GNU ld) to place your code in flash, which is located at 0x08000000, not 0x0. Regards, Andreas _______________________________________________ Openocd-development mailing list Openocd-development@lists.berlios.de https://lists.berlios.de/mailman/listinfo/openocd-development