Øyvind Harboe wrote:
> You can find lengthy discussions in the old mailing list archives
> on why OpenOCD should do nothing on connect and give the startup
> script complete control on how to connect to the target.

Can you summarize?

By startup script do you mean OpenOCD TCL or GDB init script?

I agree that giving OpenOCD TCL full control over target init allows
for full flexibility, but the lameness comes from the related lacking
usability.


> Today you can add a few commands to gdb init script to do what you
> need/want:
> 
> target remote localhost:3333
> monitor reset init
> # Now the target is ready to be talked to by GDB.

If reset init is always neccessary then why should it ever be
explicit?


> Some scenarios where halt won't work:
> 
> - jtag has been disabled
> - jtag router needs to be re-initialized
> - target is not powered on
> - an RC oscillator is used and we first need to set up the right
> communication frequency.

What good is GDB in these cases?

If halt doesn't work when halt is required (to make GDB work right)
then there should of course be an error that bubbles up into GDB.


> What does the manual say?

I think this is so basic that it needs to just work<tm> without
having to look at the manual.


> Does it need to be improved?

Maybe also, but I think the basic OpenOCD + GDB experience can be
improved a lot by code changes alone. I just don't know where they
should go. :\


> How can we point the user in the right direction?

I like to think less about pointing and more about making sure the
user ends up in the right direction automatically.


> We have removed "halt" code on connect in the past that caused all
> sorts of headaches.

Note that I am not advocating halt on connect.

The fundamental requirement is that GDB and OpenOCD (and of course
hardware) are always in sync. Once that has been satisfied it becomes
possible to look at smart higher level logic, such as automatically
setting particular hardware states where handy. The first problem is
likely more difficult.


//Peter

------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure 
contains a definitive record of customers, application performance, 
security threats, fraudulent activity, and more. Splunk takes this 
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to