From: Jean-Christian de R. <jc...@ec...> - 2014-12-10 01:34:30
|
Le 27. 11. 14 15:01, Paul Fertser a écrit : > Hi, > > On Thu, Nov 27, 2014 at 02:33:09AM +0100, Jean-Christian de Rivaz wrote: >> I initially tried with the FTDI Icebear probe using the >> swd-resistor-hack.cfg (see my OP). It work fairly well but can fail when >> programming the flash. I suspect that this can be caused by a SWD WAIT. > Please see if http://openocd.zylin.com/#/c/2268/ helps. > >>> WAIT handling is not yet implemented at >>> all, so for the target devices like nrf51 that really need it, we can >>> only suggest using cmsis-dap or stlink for now. >> I am afraid that I don't understand correctly this part. Should I use >> cmsis-dap or stlinkfor the SAMD21 ? > Likely not, I hope 2268 will solve the issue. Correct, but using bad and unreliable workaround. I have investigated modifications of my patch to resend the last operation when a WAIT response is received. Using an logic analyser that decode SWD protocol I have found that the SAMD21 do not reply to the resent operations and do not reply to the multiple W_ABORT after that. Adding delay up to 100ms after the WAIT response don't change the situation. I don't understand why resending the last operation after a WAIT response don't work like mentioned into the "ARM Debug Interface v5® Architecture Specification" document. I am lost here. Jean-Christian |