From: Perry N. <mai...@pe...> - 2021-04-28 01:09:30
|
Hello! I am having issues reliably communicating with the mEDBG interface on my SAMD10 Xplained Mini board. I was using it fine for a while with some simple programs (flashing and GDB), but after adding a lot more components to my program, I find that I must erase the board in Microchip/Atmel Studio before OpenOCD with communicate with it again. Studio seems to have no problem talking to it. The components I added were a second UART, EIC, and CRC but it seems more likely that the larger program size in general caused the issue. I double checked that the onboard debugger has the latest firmware. Here is my openocd.conf: # # Atmel SAMD10 Xplained mini evaluation kit. # http://www.atmel.com/tools/atsamd10-xmini.aspx telnet_port 4444 gdb_port 3333 source [find interface/cmsis-dap.cfg] # chip name set CHIPNAME at91samd10d14 source [find target/at91samdXX.cfg] And here is the debug output from attempting to connect: Info : 211 75 cmsis_dap_usb.c:760 cmsis_dap_get_caps_info(): CMSIS-DAP: SWD Supported Info : 212 75 cmsis_dap_usb.c:762 cmsis_dap_get_caps_info(): CMSIS-DAP: JTAG Supported Info : 213 83 cmsis_dap_usb.c:853 cmsis_dap_swd_open(): CMSIS-DAP: Interface Initialised (SWD) Info : 214 91 cmsis_dap_usb.c:740 cmsis_dap_get_version_info(): CMSIS-DAP: FW Version = Debug: 215 99 cmsis_dap_usb.c:925 cmsis_dap_init(): CMSIS-DAP: Packet Size = 64 Debug: 216 107 cmsis_dap_usb.c:936 cmsis_dap_init(): CMSIS-DAP: Packet Count = 1 Info : 217 115 cmsis_dap_usb.c:781 cmsis_dap_get_status(): SWCLK/TCK = 1 SWDIO/TMS = 1 TDI = 0 TDO = 0 nTRST = 0 nRESET = 1 Info : 218 155 cmsis_dap_usb.c:979 cmsis_dap_init(): CMSIS-DAP: Interface ready Debug: 219 155 core.c:1598 adapter_khz_to_speed(): convert khz to interface specific speed value Debug: 220 155 core.c:1601 adapter_khz_to_speed(): have interface set up Debug: 221 163 core.c:1598 adapter_khz_to_speed(): convert khz to interface specific speed value Debug: 222 163 core.c:1601 adapter_khz_to_speed(): have interface set up Info : 223 163 core.c:1386 adapter_init(): clock speed 400 kHz Debug: 224 163 openocd.c:140 handle_init_command(): Debug Adapter init complete Debug: 225 163 command.c:143 script_debug(): command - ocd_command ocd_command type ocd_transport init Debug: 226 163 command.c:143 script_debug(): command - ocd_transport ocd_transport init Debug: 228 163 transport.c:239 handle_transport_init(): handle_transport_init Debug: 229 179 cmsis_dap_usb.c:810 cmsis_dap_swd_switch_seq(): JTAG-to-SWD Debug: 230 193 cmsis_dap_usb.c:599 cmsis_dap_swd_run_queue(): Executing 2 queued transactions Debug: 231 193 cmsis_dap_usb.c:622 cmsis_dap_swd_run_queue(): DP read reg 0 0 Debug: 232 193 cmsis_dap_usb.c:622 cmsis_dap_swd_run_queue(): DP write reg 0 1e Debug: 233 205 cmsis_dap_usb.c:660 cmsis_dap_swd_run_queue(): SWD ack not OK: 0 JUNK Debug: 234 205 command.c:626 run_command(): Command failed with error code -4 User : 235 205 command.c:687 command_run_line(): in procedure 'init' in procedure 'ocd_bouncer' Debug: 236 205 command.c:626 run_command(): Command failed with error code -4 User : 237 205 command.c:687 command_run_line(): A previous user here had the same problem with the SAM4E Xplained Pro: https://sourceforge.net/p/openocd/mailman/openocd-user/thread/CALzF3cbm8zgKUnZyhPrT5qakC3qAFgvfUMYMWSKQdmZEkpEJvQ%40mail.gmail.com/#msg35716779 Any ideas? Thanks! Perry |