Home arrow Support arrow Forums

Luminary Micro Forums

<< Start < Prev 1 2 3 4 5 6 7 8 Next > End >>

cb1

Platinum Boarder
Click here to see the profile of this user

2008/07/07 15:07

Re:CodeSourcery, DriverLib and first steps

Hi Ravaz,

You are excellent poster - your care & expertise are valued/appreciated by many.

Now I see a new JTAG issue! (thus the OpenOCD saga continues - HOW could the new user KNOW what to do?)

By contrast - I happened to "win" a small IAR-ARM Dev Sys at a seminar few weeks ago. Gave this to a new, programming hire and she generated ~40 lines of new code - IN THE FIRST MORNING - on the job. Like the good "appliance operators" we are - we just "plugged in" our new JTAG - and were ON THE AIR INSTANTLY - with NO Drama. And imho - THIS IS HOW IT SHOULD BE!

Expect that she will soon be posting to LMI forums - but with micro usage/application issues - NOT a Dev Tool issue...

login or register to reply

femtotech

Expert Boarder
Click here to see the profile of this user

2008/07/07 16:18

Re:CodeSourcery, DriverLib and first steps

The default makedefs doesn't contain debug information for the gcc compiler.

So I added -g -D DEBUG -O1 to the CFLAGS.

The good news is I was able to debug a simple application.

The bad news is that one time it works and several times it doesn't.
It doesn't seem reliable at all. I hope it's due to my lack of knowledge.

The same thing applies to the LM Programmer Utility. Often it hangs and I need to close, cycling the power on the board, restart the utility and try to download firmware. Something like "plug 'n pray".

Why is so difficult to download and debug a piece of code?

Anyway, I thank you very much for the help you're giving me.

Marco

login or register to reply

ravaz

Platinum Boarder
Click here to see the profile of this user

2008/07/07 20:51

Re:CodeSourcery, DriverLib and first steps

If the problem exist with the LMI programmer means your is not related with OpenOCD.
What board are you using?

You normally should already have the debug information in the makedefs, what example are you using?

login or register to reply

femtotech

Expert Boarder
Click here to see the profile of this user

2008/07/08 00:18

Re:CodeSourcery, DriverLib and first steps

Thank you ravaz for your patience!

I'm using the EK-LM3S6965 board and the following examples: hello world, blinky, uart echo.

I admit I was wrong when I said the -g option is not included. Actually it is, but it is under a ifdef:

ifdef DEBUG
CFLAGS+=-g -D DEBUG
endif

How to set the environment variable DEBUG? Which value should it have? I tried to set to '1' in Eclipse under C/C++ Build -> Build variable and C/C++ Build -> Environment, but I'm not sure I did the right thing.

Same thing applies if I create a new "make target" and pass the "all DEBUG=1" parameter to make command.

Anyway, the debugger (when working) tells me "No symbol table is loaded. Use the "file" command." And no source file is shown in debug perspective.

I don't know why only one time I was able to debug. Perhaps I did the right thing without know what I was doing :(

Thanks again
Marco

Post edited by: femtotech, at: 2008/07/08 00:34

login or register to reply

femtotech

Expert Boarder
Click here to see the profile of this user

2008/07/08 00:45

Re:CodeSourcery, DriverLib and first steps

Yeah!

Perhaps I figured out the problem!!!
I must add "gcc/filename.axf" in the C/C++ Application textbox in the Debug Configuration.

Right now I've successfully debugged the examples I wrote before. I'm happy :-)

Marco

login or register to reply

ravaz

Platinum Boarder
Click here to see the profile of this user

2008/07/08 00:49

Re:CodeSourcery, DriverLib and first steps

happy to ear is working!!!

You absolutelly need to add the axf file in order to give to the debugger a reference between source and binary code.

Please keeep us updated about your work....

login or register to reply
<< Start < Prev 1 2 3 4 5 6 7 8 Next > End >>