Discussion group dedicated to the Philips LPC2000 family of ARM MCUs
Debugging lpc2368 problem using OpenOCD - ragh...@signal-networks.com - Jun 19 5:42:15 2008
Dear all,
We are working on keil MCB2300 (lpc2368) board. Following tools are used to build target
image:
Software:
gcc 4.3.1
gdb 6.8
open ocd latest
newlib 1.16
binutils 2.18.50
Hardware:
Keil MCB2300
parallel wiggler jtag
All source codes for above software are downloaded from net and tool chain is made for
arm processor using x86 host machine and Cent OS 5(gcc 4.1.2).
GPIO demo example given with keil kit is converted build using gcc.
Aim of the example is to glow LED connected to port2.0 to port2.7 one by one.
Following observations are noted:
Built with No optimization with delay functions able to glow LED. works fine. Able to
debug through openocd using gdb step by step.
Built with optimization level one or above with delay functions program is not working
properly.
Built with No optimization with timer interrupt (no delay functions). interrupt function
is not going to be called. corresponding registers values are read through openocd
it seems to be timer is working(This might be error in startup files).
my question is
1) Why with optimization not able to debug?
2) Timer register is found to be getting updated but timer interrupt function not
triggered(verified interrupt vector table and found to be fine)
can any one help to resolve this issues?
thanks in advance
Rags.
------------------------------------

(You need to be a member of lpc2000 -- send a blank email to lpc2000-subscribe@yahoogroups.com )
Re: Debugging lpc2368 problem using OpenOCD - "n.focking" - Jun 19 10:52:47 2008
Hello Rags.
to 1):
For debugging you need debug symbols (e.g. dwarf-2). Make sure
you have something like this when invoking GCC: "gcc -gdwarf-2 ..."
I'm also not sure whether debbuging will work at all with optimize.
to 2):
-enable a timer match interrupt in TxIR
-write VicVectAddrX
-write a "1" to the corresponding bit in VicIntEnable
hope this helps.
n.focking
--- In l...@yahoogroups.com, raghavendra@... wrote:
>
> Dear all,
>
> We are working on keil MCB2300 (lpc2368) board. Following tools are
used to build target image:
>
> Software:
> gcc 4.3.1
> gdb 6.8
> open ocd latest
> newlib 1.16
> binutils 2.18.50
>
> Hardware:
> Keil MCB2300
> parallel wiggler jtag
>
> All source codes for above software are downloaded from net and tool
chain is made for arm processor using x86 host machine and Cent OS
5(gcc 4.1.2).
>
> GPIO demo example given with keil kit is converted build using gcc.
> Aim of the example is to glow LED connected to port2.0 to port2.7
one by one.
>
> Following observations are noted:
>
> Built with No optimization with delay functions able to glow LED.
works fine. Able to debug through openocd using gdb step by step.
> Built with optimization level one or above with delay functions
program is not working properly.
> Built with No optimization with timer interrupt (no delay
functions). interrupt function is not going to be called.
corresponding registers values are read through openocd
> it seems to be timer is working(This might be error in startup files).
>
> my question is
> 1) Why with optimization not able to debug?
> 2) Timer register is found to be getting updated but timer interrupt
function not triggered(verified interrupt vector table and found to be
fine)
>
> can any one help to resolve this issues?
>
> thanks in advance
> Rags.
>
------------------------------------

(You need to be a member of lpc2000 -- send a blank email to lpc2000-subscribe@yahoogroups.com )
Re: Re: Debugging lpc2368 problem using OpenOCD - Raghavendra - Jun 25 4:47:52 2008
Dear focking
Thanks for your suggestions. These problem are fixed by enabling interrupt bit in user
mode in startup files.
With regards,
rags
----- Original Message -----
From: n.focking
To: l...@yahoogroups.com
Sent: Thursday, June 19, 2008 8:22 PM
Subject: [lpc2000] Re: Debugging lpc2368 problem using OpenOCD
Hello Rags.
to 1):
For debugging you need debug symbols (e.g. dwarf-2). Make sure
you have something like this when invoking GCC: "gcc -gdwarf-2 ..."
I'm also not sure whether debbuging will work at all with optimize.
to 2):
-enable a timer match interrupt in TxIR
-write VicVectAddrX
-write a "1" to the corresponding bit in VicIntEnable
hope this helps.
n.focking
--- In l...@yahoogroups.com, raghavendra@... wrote:
>
> Dear all,
>
> We are working on keil MCB2300 (lpc2368) board. Following tools are
used to build target image:
>
> Software:
> gcc 4.3.1
> gdb 6.8
> open ocd latest
> newlib 1.16
> binutils 2.18.50
>
> Hardware:
> Keil MCB2300
> parallel wiggler jtag
>
> All source codes for above software are downloaded from net and tool
chain is made for arm processor using x86 host machine and Cent OS
5(gcc 4.1.2).
>
> GPIO demo example given with keil kit is converted build using gcc.
> Aim of the example is to glow LED connected to port2.0 to port2.7
one by one.
>
> Following observations are noted:
>
> Built with No optimization with delay functions able to glow LED.
works fine. Able to debug through openocd using gdb step by step.
> Built with optimization level one or above with delay functions
program is not working properly.
> Built with No optimization with timer interrupt (no delay
functions). interrupt function is not going to be called.
corresponding registers values are read through openocd
> it seems to be timer is working(This might be error in startup files).
>
> my question is
> 1) Why with optimization not able to debug?
> 2) Timer register is found to be getting updated but timer interrupt
function not triggered(verified interrupt vector table and found to be
fine)
>
> can any one help to resolve this issues?
>
> thanks in advance
> Rags.
>
[Non-text portions of this message have been removed]
------------------------------------

(You need to be a member of lpc2000 -- send a blank email to lpc2000-subscribe@yahoogroups.com )