SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

AT91EB40A, EB55, EB42 Evaluation Boards , AT91RM9200-DK, RM3400-DK will be the focus of the discussions: hardware guidance, embedded software, use,...

Moderator: nferre

MGen
Posts: 12
Joined: Thu Jul 02, 2015 3:33 pm

SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Thu Jul 02, 2015 4:18 pm

Hi ARM people!

I am new to ARM world but will going to like it. :) My forthcoming project require such an MCU like SAMV70/E70/S70, so I have ordered this eval. board and started reading the docs.
I am getting started using C for an MCU, previously I've used 8-bit AVRs fully in assembly (very large code). I use C/C++ for over 15 years on PC (as well as asm), the problem is not this one.

Everything is clear, works, except one thing with Atmel Studio 6.2. If I compile and debug an app. (either in flash or in SRAM), my variables on stack are wrong, wrongly displayed by the AS. Disassembly code and processor view shows the right value but the memory view and watch windows. (They show the same wrong value.) The address of the variable is ok accoring to the processor view.
I don't really like to enter disassembly window every time to identify and check my variables' value. :/
Have this happened to any of You?

I use ARM GNU toolchain and use the EDBG interface for debugging, Atmel Studio 6.2.1563 SP2.
Please help, it's a pain step-by-step debugging without a working watch...
Thanks in advance!
meolsen
Posts: 2
Joined: Tue Jun 25, 2013 8:53 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Thu Jul 02, 2015 4:38 pm

This is an issue with how Studio 6.2 handled the dcache on the Cortex-M7. 

Try the 7.0 Beta (http://www.avrfreaks.net/forum/atmel-studio-70-beta) which should have a fix for that.
MGen
Posts: 12
Joined: Thu Jul 02, 2015 3:33 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Thu Jul 02, 2015 5:28 pm

Hm. Thought the data cache is quite "transparent" for the debug unit of the MCU. But it sounds as a valid cause... Thanks a lot, I'm gonna try AS 7.0 beta! :)
MGen
Posts: 12
Joined: Thu Jul 02, 2015 3:33 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Thu Jul 02, 2015 10:06 pm

Ok, have 7.0 beta. I am having troubles except that watch works now, after I could transfer an old example project (6.2 software package) to the 7.0 beta.

Is there any by-default-working version of this software package? Which I should not "repair" manually. (The 6.2 and 7.0 seem to work on some different basis.)
My goal first is to understand the whole system (develop studio with C/C++ and SAM), but it's very hard if I have to try to "repair" every single example. They do compile and start but not well (other CPU clock source is set etc.). Using 6.2 I am unable to watch the variables. Exact knowledge of the whole system is necessary, because I need to write more bootloaders, apps running on a special RtOS (implemented by myself). In clear assembly, this would work finely but I don't want to since the source code would be more than 4-5MB text and uncontrollable. :(

(Besides, I very dislike the look of the VS 2013 based thing. Disassembly window (that is important for me) is two-colored, no simple highlight, icons looks different, useless parts of some of the windows, just to mention some.)

Why is that so that 7.0 defines the max CPU frequency to 120MHz? Why isn't 300MHz accepted?
gerhardf
Posts: 552
Joined: Thu Dec 02, 2004 2:28 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Fri Jul 03, 2015 8:12 am

hello,
is there any reason for using this tool chain, beside the fact that it is for free?

my recommendation:
download a kickstart version of a commercial tool chain and give it a try. you will never start AS again.

regards
gerhard
MGen
Posts: 12
Joined: Thu Jul 02, 2015 3:33 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Fri Jul 10, 2015 4:11 pm

Hi,

there was the only reason that I use VS 2010 for my other works (PC app.s) and I am content with it, I like it, I know it. AS 6.2 uses its shell. (And free of course. :) I am not that big company to buy anything.)

I had been truggling with AS 7.0 beta from previous week. The "not working watch" problem seemed to be solved by it BUT:
 - VS 2013 shell is weird (looking and functional). Some things works as not expected.
 - the watch issue is NOT solved. There are still quite much variables (on stack) that I am unable to watch.
 - protecting the flash (and to speed-up downloading), I was trying to use/debug the examples from SRAM. Unfortunately AS 7.0 starts the code RANDOMLY from flash or SRAM... while As 6.2 works 100%.

So I uninstalled 7.0 and want never see it again. (Not only because of these...)

For 6.2:
 - if I disable dcache, watch works but the examples (maybe because of DMA or just lower speed, i don't really know) are not working.
 - if I disable icache, running from SRAM is not working at all.

So I am currently polishing the flash and unable to watch the variables. I am rather disappointed.

The idea of changing to something commercial -even if it takes time to learn- is a way to get rid of all these annoying stuffs. :/
Thanks!
Vasiliy_Ekra
Posts: 4
Joined: Fri Aug 28, 2015 2:44 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Fri Sep 11, 2015 3:26 pm

I have the same troubles with debugging SAMV71. Incorrect watches, locals, somtimes can not set or show breakpoint. Using Atmel Studio 7 does not solve the problem.
I tried to disable I cash and D cash. And I removed all cash depending operations from source code. And problem solved. Everything works good but without cash.
It is hard to remove all cash depending operations from all drivers, so it is not good way. Why atmel doesn't do anything to help CortexM7 users?
Maybe one definition that exclude all cash depending instructions from source code?
MGen
Posts: 12
Joined: Thu Jul 02, 2015 3:33 pm

Re: SAMV71 Xplained Ultra + Atmel Studio, debug watch fails

Sat Oct 01, 2016 6:01 pm

Hi people!

I have been using AS7 for about a year now, did not update it until now. The old debug watch (cache writeback while debugging) problem did not occur until now... I updated AS7 to have some weird things solved maybe, but nothing changed. Except that the old debug watch bug is present in AS7 too... :cry:

What the *** is going on at developing AS?

It's just a notification if some happens to update to the new AS7. (ver. 7.0.1006)

EDIT: bug has been fixed in AS 7.0.1188 (web install). So I can continue my work.

Return to “Evaluation and Development Boards”

Who is online

Users browsing this forum: No registered users and 1 guest