On Fri, Aug 12, 2011 at 11:17 AM, Antonio Borneo <[email protected]> wrote: > in Jlink code in src/jtag/drivers/jlink.c > there is the following: > static int jlink_init(void) > { > .... > /* > * The next three instructions were added after discovering a problem > * while using an oscilloscope. > * For the V8 SAM-ICE dongle (and likely other j-link device variants), > * the reset line to the target microprocessor was found to cycle only > * intermittently during emulator startup (even after encountering the > * downstream reset instruction later in the code). > * This was found to create two issues: > * 1) In general it is a bad practice to not reset a CPU to a known > * state when starting an emulator and > * 2) something critical happens inside the dongle when it does the > * first read following a new USB session. > * Keeping the processor in reset during the first read collecting > * version information seems to prevent errant > * "J-Link command EMU_CMD_VERSION failed" issues. > */ > > LOG_INFO("J-Link initialization started / target CPU reset initiated"); > jlink_simple_command(EMU_CMD_HW_TRST0); > jlink_simple_command(EMU_CMD_HW_RESET0); > usleep(1000); > > During JLink initialization OpenOCD forces nTRST and nSRST. > Personally I do not like it, since I use to attach OpenOCD on running > boards and I want to start debugging without resetting the CPU. > In my personal build of OpenOCD I always comment the nSRST part. > I never got the problem reported in the comment above, but I only have > JLink version 5 and 6. > > What about removing these two code lines instead of cutting nTRST and > nSRST wires?
Thanks a lot for the information. I will try to borrow a V8 from my colleague and try this out over the weekend. -- Xiaofan _______________________________________________ Openocd-development mailing list [email protected] https://lists.berlios.de/mailman/listinfo/openocd-development
