| Author |
Message |
|
|
Posted: Sep 06, 2011 - 08:01 PM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
Hi, I have just installed AVR Studio 5 and i am trying to run a simple example project from help files.
Now when i debug, I get a message
No Source Available
The source code cannot be displayed.
Call Stack location:
AVRGCC1.elf! no-debug-info
What is causing this problem and how do i fix it? |
|
|
| |
|
|
|
|
|
Posted: Sep 06, 2011 - 09:10 PM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
|
Quote:
i am trying to run a simple example project from help files.
If you had mentioned which example, then someone here might actually test the same project. W/o that information we can only guess: My guess at the most straight-forward reason is that the project was actually built without debug information.
1. Tell us what configuration you are building
2. Right-click the project, select Properties
3. Click the Toolchain tab, then select the AVR/GNU C node in the tree, and the Debugging sub-node
What do you have in the Debug Level drop down? |
|
|
| |
|
|
|
|
|
Posted: Sep 06, 2011 - 10:01 PM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
Thanks for your response. I am using this example from the Getting Started help files. It is based on atxmega128a1 device using AVR Simulator.
/*
* AVRGCC1.c
*
* Created: 9/4/2011 5:07:40 AM
*
*/
#include <avr/io.h>
#define MAXINT 200000
int main(void) {
unsigned int t=1000,k=0,l=5,pn=2; unsigned int primes[t]; primes[0]=2; primes[1]=3;
while (pn<t||primes[pn]<MAXINT)
{
for ( k = 0; k < pn; k++)
{
if(l% primes[k]==0)
goto otog;
else
{
if(k==pn) primes[pn++]=l;
}
}
otog: l+=2;
}
return 0;
}
The debug level in tool chain is Default -g2. |
|
|
| |
|
|
|
|
|
Posted: Sep 06, 2011 - 10:04 PM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
|
Quote:
Thanks for your response. I am using this example from the Getting Started help files.
Oh, come on! For someone to test out that example they would have to browse through them all to be able to fin the same exapmle, and set it up in the same way...
It has a name. Tell us that.
The quality of the answers you get is highly correlated to the quality of the question you ask.
Apart from that: Tell us (exactly) how you start debugging.
EDIT: Looking closer at your source code, it has no "real-world" effects at all. I suspect that the optimizer threw most of the code in your main() out.
Either make your code do something meaningful (in an AVR context),or turn off optimization (and live with the consequences of that). Also read this. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 12:40 AM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
|
Quote:
It has a name. Tell us that.
It doesn't have a name. It can be found at Help>Getting Started>New Project>
I made a new project and copy the code there to the project as instructed in the help.
Quote:
Either make your code do something meaningful (in an AVR context),or turn off optimization (and live with the consequences of that).
Optimization is set to NONE. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 01:17 AM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
|
Quote:
It doesn't have a name. It can be found at Help>Getting Started>New Project>
My Help menu does not have a "Getting started" item.
Could you tell us exactly how you set up the new project?
Repeat: Could you tell us exactly how you start debugging?
("exactly" means: Tell us every step you took, citing menu selections etc verbatim.)
Another option might be that you zip up the complete project directory tree and attach the zip file to a post here, and someone might be willing to take a look at it.
This might seem tedious for you, but without that we'd have to resort to guesswork and the chances that we are in the same ballpark as you are are slim. You won't be helped, and we will have wasted our time testing something other than what you have on your machine. Your call.. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 02:28 AM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
In AVR Studio 5, if you select help>View help or Ctrl+F1 the help page opens in browser. The heading of the help page says AVR Studio User Guide. On the left sub menu, 3rd option is Getting started. That's how i got there.
I selected File>New>Project. Then selected C Executable Project, then selected Device and okay. Named the project AVRGCC1.
Then i opened AVRGCC1.c from the solution explorer and copied the code from the example to this file.
Then i debugged it using Debug>Continue and Debug>Start Debugging and Break. Both gives the same message of No Source File.
I have uploaded the project directory in rar format. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 07:50 AM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
I downloaded your project and when I debug it works like a charm.
So this does not seem to have to do with the project per se.
What is the path to your project folder? Are there any special/national characters in that path? If you take a copy of the copmplete project and place it at e.g. C:\ , does it work better there? |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 09:44 PM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
I moved the project to C: so that the new location became C:\AVRGCC1\ but still got the error.
Also i tried debugging the Example project "Sensor Data Visualizer" on my UC3-Xplained Board using AVR-Dragon Debugger. First i selected 'Start Debugging and Break'. Then 'step in', 'step over' but when i 'step out', i still get No Source error. The error says that there is no .elf file, though i can see the file in solution explorer.
I have already reinstalled AVR Studio, but now it has started to look like something is wrong with my installation of windows as you can run it fine. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 10:05 PM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
Well, it turns out that after playing around with this a wee bit (doing some tests of code snippets not at all related to your problems), looking at the disassembly and perhaps some other manouvres ... I have the same problem. "Start debugging and break" does not have the expected effect (and the effect it had when I started up).
One possible explanation might be that I at one time had two instances of AVR Studio 5 running (one was on it's way to exit directly from a debugging session). The other was just started (by double-clicking a .avrsln file.
Or it might not be that: I fiddled around a wee bit with the small test code (commenting out and in code, changing code order, rebuilding for each change and testing to start debugging), and suddenly it started working again. |
|
|
| |
|
|
|
|
|
Posted: Sep 07, 2011 - 10:28 PM |
|


Joined: Mar 27, 2002
Posts: 18520
Location: Lund, Sweden
|
|
A wee bit more testing starts to reveal things, it seems:
The project is a junk project where I test all sorts of small C and AVR-related stuff. At this time it looks like this:
Code:
#include <avr/io.h>
#include <util/atomic.h>
unsigned char data[3000];
struct CD_TYPE
{
int title, artist;
int year;
double cost;
} ;
//structure declaration
struct CD_TYPE xyz;
void delay_ms (unsigned char del)
{
unsigned char x;
while (del > 0)
{
for (x=0; x<10; x++) asm ("nop");
del--;
}
}
int main(void)
{
while(1)
{
ATOMIC_BLOCK(ATOMIC_RESTORESTATE) {
PORTB = 0xFF;
}
delay_ms(2);
}
}
(Yes, you will recognize stuff from thread I have recently participated in...)
Now notice the ridiculously large array. If I remove that then starting debugging works as expected. Leaving it there makes the program go into an endless loop in what seems to be the startup code from avrlibc (run before main() is "called").
The disassembly (from the start to after the part that loops endlessly looks like this:
Code:
--- No source file -------------------------------------------------------------
00000000 RJMP PC+0x001A Relative jump
00000001 RJMP PC+0x0029 Relative jump
.
. <more vectors than you want to see here>
.
00000018 RJMP PC+0x0012 Relative jump
00000019 RJMP PC+0x0011 Relative jump
0000001A CLR R1 Clear Register
0000001B OUT 0x3F,R1 Out to I/O location
0000001C SER R28 Set Register
0000001D LDI R29,0x04 Load immediate
--- No source file -------------------------------------------------------------
0000001E OUT 0x3E,R29 Out to I/O location
0000001F OUT 0x3D,R28 Out to I/O location
00000020 LDI R17,0x0C Load immediate
00000021 LDI R26,0x00 Load immediate
00000022 LDI R27,0x01 Load immediate
00000023 RJMP PC+0x0002 Relative jump
00000024 ST X+,R1 Store indirect and postincrement
00000025 CPI R26,0xC2 Compare with immediate
00000026 CPC R27,R17 Compare with carry
00000027 BRNE PC-0x03 Branch if not equal
00000028 RCALL PC+0x001E Relative call subroutine
00000029 RJMP PC+0x0052 Relative jump
0000002A RJMP PC-0x002A Relative jump
--- C:\\Users\\Johan\\Documents\\AVRStudio\\SizeTest\\SizeTest\\Debug/.././SizeTest.c
{
0000002B PUSH R29 Push register on stack
0000002C PUSH R28 Push register on stack
0000002D RCALL PC+0x0001 Relative call subroutine
My observations show that the loop at addresses 0x00000024 to ox00000027 is looping endlessly. Throughout this looping R17 is constantly zero and R27 is constantly 0x08. The strange part is that R26 goes to 0x0A and then wraps to zero. Another way to express this would be to say that the C register goes from 0x0800 to 0x081A and then wraps back to 0x0800. This happens at the Store indirect and postcrement instruction at 0x00000024.
I suppose that this is the loop that zeroes statically allocated variables with no explicit initialization.
It is a fact that the loop never ends. My brain is still in flu-mode and I can not make it tell me if this is a bug in Simulator, or the expected behavior when the tool chain is fed such crap as a ridiculously large statically allocated variable.
Anyway, when you get the message about no source - do you have an option there to "show disassembly"? If so, then what are you seeing there. A loop very similar to the one I point to?
What does your avr-size report tell you on the consumption of different memories?
My test code above was built and simulated for an ATmega88.
HTH! |
|
|
| |
|
|
|
|
|
Posted: Sep 09, 2011 - 10:35 AM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
It is a fact that the loop never ends. My brain is still in flu-mode and I can not make it tell me if this is a bug in Simulator, or the expected behavior when the tool chain is fed such crap as a ridiculously large statically allocated variable.
Surely this depends where RAM "wraps". Remember that the AVR registers R0..R31 appear at addresses 0x0000 so if you start at 0x0060 or 0x0100 or wherever and keep writing 0 from that address onwards and then the address wraps round to 0x0000 the code will start over-writing the same R0..R31 that are being used as loop variables to do the clearing. I built your code in AS5 for mega16 and got:
Code:
00000060 <__do_clear_bss>:
60: 1c e0 ldi r17, 0x0C ; 12
62: a0 e6 ldi r26, 0x60 ; 96
64: b0 e0 ldi r27, 0x00 ; 0
66: 01 c0 rjmp .+2 ; 0x6a <.do_clear_bss_start>
00000068 <.do_clear_bss_loop>:
68: 1d 92 st X+, r1
0000006a <.do_clear_bss_start>:
6a: a2 32 cpi r26, 0x22 ; 34
6c: b1 07 cpc r27, r17
6e: e1 f7 brne .-8 ; 0x68 <.do_clear_bss_loop>
So if this starts writing over R17/26/27 it's not going to be fun! |
_________________
|
| |
|
|
|
|
|
Posted: Sep 11, 2011 - 05:54 PM |
|

Joined: Sep 06, 2011
Posts: 8
|
|
| Until now, I have tried almost every example project provided for UC3-Xplained board. Building the project and programming the board with the hex file works and and code executes fine. But debugging opens the same 'NO SOURCE AVAILABLE' windows. This is happening with every example project that i try to debug. Tried with optimization and without. Tried with all debug levels. The problems persists!! |
|
|
| |
|
|
|
|
|
Posted: Sep 12, 2011 - 08:14 PM |
|

Joined: Oct 14, 2007
Posts: 8
|
|
as I know this is a bug in AVR Studio 5.
It is a timing issue between the debug editor and the reset time of the device.
I have exactly the same problem. If I restart the debugger 100 times, than it may happen that it works for one or 2 times.
Hopefully this will be solved soon, in the meantime I use AVRstudio 32 or AVRstido 4, which are working. |
|
|
| |
|
|
|
|
|
Posted: Sep 17, 2011 - 01:18 AM |
|


Joined: Jan 03, 2004
Posts: 1637
Location: Apalachin, NY, USA
|
|
|
vision01 wrote:
But debugging opens the same 'NO SOURCE AVAILABLE' windows.
Are you really seeing NO SOURCE AVAILABLE or are you seeing No disassembly available? If the later, see my reply in this thread.
Don |
|
|
| |
|
|
|
|
|
Posted: Sep 22, 2011 - 08:42 PM |
|

Joined: Oct 14, 2007
Posts: 8
|
|
| it shows "NO SOURCE AVAILABLE " |
|
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 07:46 PM |
|


Joined: Aug 04, 2011
Posts: 96
Location: Hannover, Germany
|
|
Hello,
I refer to the original starting posting:
I got the same message with my first demo project.
It happens after "Start Debugging and Break" in Atmel Studio 5, using my valuable JTAGICE3 for debugging.
Solution to avoid the message: Atmel Studio 5, project properties "Toolchain / AVR/GNU C Compiler / Optimization" - Set the "Optimization Level" to "None (-O0)".
Besides that with optimization, irgnore the error and go to the proper source file and continue debugging. A typical reason & consequence is that the first breakpoint is unavailabe ( = no red breakpoint bullet, where you expected as you set it before ), or the reason is that the location where "Start Debugging and Break" is expected to stop ( = first instruction of/in main() ) does not exist as code, due to code optimizsation.
It's the same effect like with the message "The breakpoint will not currently be hit", see
http://8515.avrfreaks.net/index.php?nam ... cdbe706e91
Sincerely
Rolf |
_________________ http://www.hemmerling.com
SCADA Expertness - Quality Intensification for IT + Automation
Last edited by hemmerling on Sep 23, 2011 - 07:54 PM; edited 1 time in total
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 07:53 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
Solution to avoid the message: Atmel Studio 5, project properties "Toolchain / AVR/GNU C Compiler / Optimization" - Set the "Optimization Level" to "None (-O0)".
That's actually a terrible "solution"
See FAQ#4 and for more detail my tutorial:
Optimization and the importance of volatile in GCC
-O0 should be avoided like the plague (it's really only there for the compiler authors to be able to do some internal checks) |
_________________
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 07:56 PM |
|


Joined: Aug 04, 2011
Posts: 96
Location: Hannover, Germany
|
|
a)
Well really terrible for debugging ?
Is it a must to have code optimization during debugging ?
b)
I named the guilty party, and how to avoid it, and why it does not much care if it happens.
Sincerely
Rolf |
_________________ http://www.hemmerling.com
SCADA Expertness - Quality Intensification for IT + Automation
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 08:05 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
Is it a must to have code optimization during debugging ?
If you want the thing you debug to represent what you plan to deploy then "yes". As I say in the article - throw in a temporary volatile if there's something you really need to watch. |
_________________
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 08:29 PM |
|


Joined: Aug 04, 2011
Posts: 96
Location: Hannover, Germany
|
|
Hmmm.. how can you "throw a breakpoint" into a volatile variable ?
Maybe if you need a breakpoint at a specific point in the code, and want to be shure that it is not deleted by the optimizer, address a volatile variable at that point ?!
Sincerely
Rolf |
_________________ http://www.hemmerling.com
SCADA Expertness - Quality Intensification for IT + Automation
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 08:34 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
Admit it - you haven't read the article have you?
Bottom line: debug C+Asm |
_________________
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 09:01 PM |
|


Joined: Aug 04, 2011
Posts: 96
Location: Hannover, Germany
|
|
Guilty .
Please point me to the article .
I will read immediately.
Sincerely
Rolf |
_________________ http://www.hemmerling.com
SCADA Expertness - Quality Intensification for IT + Automation
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 09:37 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
Please point me to the article
I gave the link above.  |
_________________
|
| |
|
|
|
|
|
Posted: Sep 23, 2011 - 10:04 PM |
|


Joined: Aug 04, 2011
Posts: 96
Location: Hannover, Germany
|
|
I just read in the paper XMEGA-tutorial from the official World-Tour workshop
Quote:
Change project optimization.... Choose None (-O0 ). This is to be shure that the code associated with the breakpoint, is not optimized away by the compiler.
So my advice was compliant to the offical Atmel ASF Team mind .
But to be honest, as my sample project grows, I get the error "No Souce Code" even I setup the compiler optimization to -0O.
So it was not a final solution.
Sincerely
Rolf |
_________________ http://www.hemmerling.com
SCADA Expertness - Quality Intensification for IT + Automation
|
| |
|
|
|
|
|
Posted: Sep 24, 2011 - 12:21 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
So my advice was compliant to the offical Atmel ASF Team mind
Yes but to be honest they don't actually seem to have the first idea and -O0 is the "babies" way of debugging. Why not try the way the grown ups do it. The compiler only optimises away pointless code so if you cannot place a breakpoint it's because what the code is doing is pointless. |
_________________
|
| |
|
|
|
|
|
Posted: Oct 03, 2011 - 04:31 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
Well I've just been bitten by this bloody "no source available" thing in AS5. For the benefit of the developers I then dropped to a command prompt and used "avr-objdump -S projname.elf" and it showed me the source. So the problem isn't that the ELF doesn't contain it - it's that for some reason the debugger cannot "see" it.
BTW I'm offered a "Browse to find source" link but clicking it does not produce a file browser?!?
Oh and this was a project that previously had one .c file. Someone sent me a new one. I removed the original file. Added the new one. Then rebuilt - maybe this is relevant? |
_________________
|
| |
|
|
|
|
|
Posted: Oct 04, 2011 - 08:33 AM |
|

Joined: Jul 10, 2006
Posts: 78
Location: Switzerland
|
|
Hello to all,
I had the same problem during the ATMEL Hands on tour (XMega), and I was the only one with this problem on 20 person. We tried to reinstall completely AS5 + ASF on my winXP 32bit, still it was not working.
But we found that the "No source available" has something to do with the fuse settings and the bootloader. If the bootloader was selected by the reset, then we get this message, but if the application was selected by the reset, then the debugging could start, however not breaking in main, but in an obscur asm file (can't remember which one).
But the ATMEL rep. there could not understand either where the problem was exactly, they think it's a bug in AS5/ASF/JTagICE3 (circle the correct answer )
And of course the optimization had to bet set to -O0, if I wanted to be able to debug...
Best regards,
Kraal |
|
|
| |
|
|
|
|
|
Posted: Oct 04, 2011 - 09:19 AM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
But we found that the "No source available" has something to do with the fuse settings and the bootloader. If the bootloader was selected by the reset, then we get this message, but if the application was selected by the reset, then the debugging could start, however not breaking in main, but in an obscur asm file (can't remember which one).
How very curious - I eventually cured it last night by copying the source .c file into a different place and re-building. Nothing to so with fuses, bootloader or anything like that.
It does seem a pretty serious problem though - a debugger that cannot debug is hopeless. |
_________________
|
| |
|
|
|
|
|
Posted: Oct 04, 2011 - 09:40 AM |
|

Joined: Jul 10, 2006
Posts: 78
Location: Switzerland
|
|
Hi Clawson,
Can you please explain what you meant by relocating the source file ?
I can understand that the reset vector is altered by the fuse settings, but I don't know how the JTAG manage the bootloader and the application, and the starting point of the program (i.e. main() ).
Best regards,
Kraal |
_________________ Have a nice day,
Kraal
|
| |
|
|
|
|
|
Posted: Oct 04, 2011 - 10:36 AM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
Can you please explain what you meant by relocating the source file ?
Someone sent me a .c file. I downloaded it to my E:\, I then used File-New Project in AS5 and let it create AVRGCC4. Unfortunately, though I didn't want it, it created an AVRGCC4.c and added this to the project. So I right-clicked that and used "Remove" to remove it then I right-clicked the project and used Add-Existing Item and pointed it to the file in E:\. Apparently it copied the file to C:\AS5\AVRGCC4\AVRGCC4\. When I built this then clicked the Debug&break icon I got the no source message.
I just tried to recreate those steps (by first removing the file from the project and deleting it from the \AS5\... location) but this time it works.
God you gotta love this reliable software - it's not even deterministic when trying to recreate the bugs!
Maybe I'll try creating a whole new project which will inevitably be AVRGCC5 I guess?
EDIT: Oh yeah, that reminds me - this lack of libm.a is really bugging me. I now recall that another step I took was to add libm.a to be linked (because the C file uses math functions).
EDIT2: Nope it worked this time with AS5. So whether the debugger can "see" the source or not would appear to be completely random?!? |
_________________
|
| |
|
|
|
|
|
Posted: Oct 18, 2011 - 01:43 PM |
|

Joined: Oct 13, 2011
Posts: 14
|
|
| @ clawson, I am a beginner with AVR and dont follow your last post on this issue! I am experiencing the same issue when i optimise the program which i have to do. What would u recommend? Should i just switch to AVR studio 4.18? |
|
|
| |
|
|
|
|
|
Posted: Oct 18, 2011 - 03:23 PM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
Should i just switch to AVR studio 4.18?
Until this kind of issue is fixed then yes. |
_________________
|
| |
|
|
|
|
|
Posted: Nov 25, 2011 - 10:24 AM |
|

Joined: Jun 11, 2005
Posts: 44
|
|
This issue has nothing to do with optimization levels at all.
It's a bug, it has to be.
I notice it varies on my computer (which has a SSD disk) from day to day with no changes in projects. Some days I can start debugging fine, others I get no source available and everything is very slow.
Simple projects with single files and a simple counter on a port can give this error. It has the code, it has the elf and yet it has issues talking to the debugger and claims that the debugee does not support setting breakpoints at runtime (while in stopped/paused mode).
It also does not "run/pause" to start of main but instead defaults to disassembler and the resetvector. Same code, chip and debugger in Studio 4 works as expected with no slowness and no errors.
There must be a statefull- or timing-bug in the way the different modules of avr studio 5 is communicating... |
|
|
| |
|
|
|
|
|
Posted: Nov 25, 2011 - 10:26 AM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
|
|
|
|
Posted: Nov 25, 2011 - 10:31 AM |
|

Joined: Jun 11, 2005
Posts: 44
|
|
You are right regarding the -g flags however.
Especially when using multiple projects within a solution and compiling libraries. Often the default -g2 is lost in studio 5 and it reverts to -g0 causing issues with debugging.
Another thing to check, which has to do with the debugee reset timing is what clockrate you use on the debugger (for example the ice). Too low clockrate will actually cause issues due to the reset-timing.
Too high clockrate causes issues due to the ratio between internal clockrate and the debug signal rate.
On my sistem it works best if I stick between 1/4 and 1/6 F_CPU. |
|
|
| |
|
|
|
|
|
Posted: Nov 25, 2011 - 11:46 AM |
|


Joined: Jul 18, 2005
Posts: 62220
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
| Just to say this is not a debugger timing issue - I see it all the time (well most of the time) when simply using the Simulator. |
_________________
|
| |
|
|
|
|
|
Posted: Nov 25, 2011 - 04:23 PM |
|

Joined: Jun 11, 2005
Posts: 44
|
|
| I thought the simulator loaded like the debugger module? They appear to talk via some local tcp or such? That would allow same issue to affect both. |
|
|
| |
|
|
|
|
|
Posted: Dec 12, 2011 - 11:30 AM |
|

Joined: Jun 08, 2011
Posts: 8
|
|
|
Quote:
Just to say this is not a debugger timing issue - I see it all the time (well most of the time) when simply using the Simulator.
Yes it is a timing problem. I installed AS5 on a fresh W7-Installation, created a new fresh projecht wit the AVRGCC1.c, built it and tried to debug.
The Issue then sometimes occured, sometimes not, without any changes!
In my "normal" working OS (W7 too) it normally doesnt´t work, and sometimes rarely works. |
|
|
| |
|
|
|
|
|
Posted: Dec 13, 2011 - 01:13 AM |
|

Joined: Aug 15, 2011
Posts: 1
|
|
I'm seeing this same issue (no source available) while trying to debug a xmega128A1 with an AVR Dragon in the latest version of AS5. I don't have the same issue with the Simulator. No problems with AS4.
Have been back and forth with Atmel support who were unable to reproduce the issue or provide any answers. They left me with:
"We recommend you to test with AVR studio 5.1 (target release date : last week of December 2011 as of now)" |
|
|
| |
|
|
|
|
|
Posted: Dec 19, 2011 - 12:49 AM |
|

Joined: Jul 27, 2006
Posts: 1
|
|
|
vision01 wrote:
Hi, I have just installed AVR Studio 5 and i am trying to run a simple example project from help files.
Now when i debug, I get a message
No Source Available
The source code cannot be displayed.
Call Stack location:
AVRGCC1.elf! no-debug-info
What is causing this problem and how do i fix it?
I had same problem with AVR Studio 5.
I was trying to debug Atmega128 @ 16MHz with AVR Dragon
JTAG clock was 200kHz (default).
After ramping up the clock up to the max (avr studio reduced clock to 1,82MHz) debugging session was completed without any problem.
Hope it helps  |
|
|
| |
|
|
|
|
|
Posted: Jan 24, 2012 - 03:23 PM |
|

Joined: Jun 21, 2002
Posts: 92
Location: Hilden, Germany
|
|
Don't know, if this is still active: I had the problem to. I moved my program code from the start of the flash at 0x0000 up to 0x0200, because I wanted a bootloader to live at 0x0000.
(I joined the .hex-files together afterwards with screc_cat but wanted to debug my program at 0x0200.)
So I inserted the directive ".text" at "0x0200" in the "Memory"-Tab of the project settings. Compiled like a charm, the .lss-file showed me my code at the right place.
In the debugger it showed "Running", then "Ready" on the lower left corner. No cursor on the next instruction. If I hit PAUSE, I got the "No Source Available", no "Browse to Find Source" and "Show Disassembly" only showed "No dissassembly available".
kind regards,
Christian |
_________________ "It compiles! Ship it!"
|
| |
|
|
|
|
|