Re: [OpenOCD-devel] cJTAG on CC2538

2013-10-11 Thread Damjan Marion

On Oct 11, 2013, at 6:27 PM, Paul Fertser  wrote:

> On Fri, Oct 11, 2013 at 06:12:37PM +0200, Damjan Marion wrote:
>> I tried to do that with following:
>> 
>> jtag newtap $_CHIPNAME unknown0 -irlen 4
>> jtag configure $_CHIPNAME.unknown0 -event setup "my_proc $_CHIPNAME.unknown0"
>> 
>> but my_proc is not called, Instead I'm getting following:
>> 
>> Error: JTAG scan chain interrogation failed: all ones
>> Error: Check JTAG interface, timings, target power, etc.
>> Error: Trying to use configured scan chain anyway...
>> Error: cc2538.unknown0: IR capture error; saw 0x0f not 0x01
>> Warn : Bypassing JTAG setup events due to errors
>> Warn : gdb services need one or more targets defined
>> 
>> Is this why you had on your mind?
> 
> Yes, what happens if you run "irscan" now from the telnet interface?

When I do:
> irscan cc2538.unknown0 0x3f -endstate DRPAUSE

debug shows:

Debug: 522 134864 ftdi.c:460 ftdi_execute_scan(): IR scan, 4 bits, end in 
DRPAUSE

So looks like it is working correctly ….

Damjan
--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


Re: [OpenOCD-devel] cJTAG on CC2538

2013-10-11 Thread Paul Fertser
On Fri, Oct 11, 2013 at 06:12:37PM +0200, Damjan Marion wrote:
> I tried to do that with following:
> 
> jtag newtap $_CHIPNAME unknown0 -irlen 4
> jtag configure $_CHIPNAME.unknown0 -event setup "my_proc $_CHIPNAME.unknown0"
> 
> but my_proc is not called, Instead I'm getting following:
> 
> Error: JTAG scan chain interrogation failed: all ones
> Error: Check JTAG interface, timings, target power, etc.
> Error: Trying to use configured scan chain anyway...
> Error: cc2538.unknown0: IR capture error; saw 0x0f not 0x01
> Warn : Bypassing JTAG setup events due to errors
> Warn : gdb services need one or more targets defined
> 
> Is this why you had on your mind?

Yes, what happens if you run "irscan" now from the telnet interface?

-- 
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:fercer...@gmail.com

--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


Re: [OpenOCD-devel] cJTAG on CC2538

2013-10-11 Thread Damjan Marion

On Oct 11, 2013, at 2:57 PM, Paul Fertser  wrote:

> On Fri, Oct 11, 2013 at 02:41:31PM +0200, Damjan Marion wrote:
>> On Sep 23, 2013, at 11:04 AM, Paul Fertser  wrote:
>>> On Wed, Sep 18, 2013 at 04:50:33PM +0200, Damjan Marion wrote:
 So to speak 1149.1 with this device special sequence needs to be sent to 
 this device to switch from cJTAG to JTAG mode.
 Sequence is described in the user manual[1] on page 179.
 Seems that Segger tool does exactly the same.
>>> 
>>> It looks like it should be possible with irscan and drscan OpenOCD
>>> commands (documented in the Info manual), you can take a look at
>>> target/am335x.cfg for inspiration.
>> 
>> I cannot use irscan as it is too early. My understanding is that it needs to 
>> be done in post-reset handler which happens before 
>> irlenght is properly set so irscan executes with 1 bit irlength.
> 
> But I think you can specify a dummy tap (without expected-id) with the
> proper length and then after you do the magic sequence you can disable
> it and enable other taps with "jtag tapdisable" and "jtag tapenable",
> see Info "TAP Declaration" and config files that are doing similar
> tricks.

I tried to do that with following:

jtag newtap $_CHIPNAME unknown0 -irlen 4
jtag configure $_CHIPNAME.unknown0 -event setup "my_proc $_CHIPNAME.unknown0"

but my_proc is not called, Instead I'm getting following:

Error: JTAG scan chain interrogation failed: all ones
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
Error: cc2538.unknown0: IR capture error; saw 0x0f not 0x01
Warn : Bypassing JTAG setup events due to errors
Warn : gdb services need one or more targets defined

Is this why you had on your mind?

Thanks,

Damjan
--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


Re: [OpenOCD-devel] cJTAG on CC2538

2013-10-11 Thread Paul Fertser
On Fri, Oct 11, 2013 at 02:41:31PM +0200, Damjan Marion wrote:
> On Sep 23, 2013, at 11:04 AM, Paul Fertser  wrote:
> > On Wed, Sep 18, 2013 at 04:50:33PM +0200, Damjan Marion wrote:
> >> So to speak 1149.1 with this device special sequence needs to be sent to 
> >> this device to switch from cJTAG to JTAG mode.
> >> Sequence is described in the user manual[1] on page 179.
> >> Seems that Segger tool does exactly the same.
> > 
> > It looks like it should be possible with irscan and drscan OpenOCD
> > commands (documented in the Info manual), you can take a look at
> > target/am335x.cfg for inspiration.
> 
> I cannot use irscan as it is too early. My understanding is that it needs to 
> be done in post-reset handler which happens before 
> irlenght is properly set so irscan executes with 1 bit irlength.

But I think you can specify a dummy tap (without expected-id) with the
proper length and then after you do the magic sequence you can disable
it and enable other taps with "jtag tapdisable" and "jtag tapenable",
see Info "TAP Declaration" and config files that are doing similar
tricks.

-- 
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:fercer...@gmail.com

--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


Re: [OpenOCD-devel] cJTAG on CC2538

2013-10-11 Thread Damjan Marion

On Sep 23, 2013, at 11:04 AM, Paul Fertser  wrote:

> On Wed, Sep 18, 2013 at 04:50:33PM +0200, Damjan Marion wrote:
>> So to speak 1149.1 with this device special sequence needs to be sent to 
>> this device to switch from cJTAG to JTAG mode.
>> Sequence is described in the user manual[1] on page 179.
>> Seems that Segger tool does exactly the same.
> 
> It looks like it should be possible with irscan and drscan OpenOCD
> commands (documented in the Info manual), you can take a look at
> target/am335x.cfg for inspiration.

I cannot use irscan as it is too early. My understanding is that it needs to be 
done in post-reset handler which happens before 
irlenght is properly set so irscan executes with 1 bit irlength.

I already asked this in separate thread but no responses so far….

Damjan


--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


Re: [OpenOCD-devel] cJTAG on CC2538

2013-09-23 Thread Paul Fertser
On Wed, Sep 18, 2013 at 04:50:33PM +0200, Damjan Marion wrote:
> So to speak 1149.1 with this device special sequence needs to be sent to this 
> device to switch from cJTAG to JTAG mode.
> Sequence is described in the user manual[1] on page 179.
> Seems that Segger tool does exactly the same.

It looks like it should be possible with irscan and drscan OpenOCD
commands (documented in the Info manual), you can take a look at
target/am335x.cfg for inspiration.

-- 
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:fercer...@gmail.com

--
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel


[OpenOCD-devel] cJTAG on CC2538

2013-09-18 Thread Damjan Marion

I'm trying to hook up opened to TI's CC2538 Cortex-M3 SoC and it's not going 
smooth.
Problem is that this device supports both 1149.1 and 1149.7 but default mode is 
1149.7/cJTAG.

So to speak 1149.1 with this device special sequence needs to be sent to this 
device to switch from cJTAG to JTAG mode.
Sequence is described in the user manual[1] on page 179.
Seems that Segger tool does exactly the same.

Anybody tried to accomplish similar thing with openocd?

Thanks,

Damjan


[1] http://www.ti.com/lit/ug/swru319c/swru319c.pdf
--
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
___
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel