On Fri, Mar 13, 2015 at 10:34:12AM +0100, Tomas Vanek wrote:
> >If you've configured that testbit to loop in ROM code, it's never too
> >late. If you didn't, it means the user issued "reset run", so there's
> >nowhere to hurry. Please show a log where 2596 + a mod to attempt
> >debugport init up to, say, 10 times fails.
> I meant too late from tcl script point of view. arp_waitstate has timed out
> operation.
> How could script to retry if it raises and error?

Just catch the error and add a for loop or something like that.

> >If, say, 10 tries is enough even for PSoC4, I'd settle on a hardcoded
> >value. Or probably nsrst_delay should be performed after sysresetreq
> >too, that would seem somewhat logical.
> >
> PSoC4 programming specification is very unclear on that:
> 
> The times of internal reset (<1 ms) and boot code (<100 us)
> are not specified exactly. Because they depend on the CPU
> clock and the size of the code, they can be vary in different
> revisions of the chip.
> In this case, the recommended way to enter Test mode suc-
> cessfully is to start sending the acquire sequence right after
> XRES is toggled (or power supplied in Power Cycle mode).
> This sequence is sent iteratively until it succeeds.

But you set the testbit in advance, and it works, so probably there's
no need for any strong timer requirements. 

> I'd recommend a new parameter as adapter_nsrst_delay
> can be used because of capacitor on srst line
> (and in this case there is nonsense to apply it after sysresetreq).

I have a suspicion that if you retry debugport init several times
after sysresetreq, that would just work, and neither nsrst_delay nor
new parameter are needed.

-- 
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:[email protected]

------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to