Best AVR development environment? (windows) - Page 1
Forum section: electronics / general

author: 8086
author_rank: Super Contributor
timestamp: March 22, 2014, 07:32:39 pm
content: As per title, would like your opinions on this.I've not really worked with AVRs before (except using arduino bootloader) so anything goes.

author: jmaja
author_rank: Frequent Contributor
timestamp: March 22, 2014, 08:16:34 pm
content: Depends on what you like. I like to work in unix like environment using shell. Thus I use cygwin with makefiles and Emacs. But I still use Atmel Studio for debugging and programmin (unless I use a bootloader + avrdude). You get the compiling tools when you install Atmel Studio. The path is quite well hidden, but you'll find it.

author: dannyf
author_rank: Super Contributor
timestamp: March 22, 2014, 09:25:03 pm
content: Probably no consistent answer - as what's best is highly subjective.IAR - high quality and feature rich compiler. Most reliable and supports the full range of chips. Utilitarian and consistent UI. Most expensive.CB + gcc-avr - clean and fast interface. Large user base so good user support. Least expensive in $s, but lacks commercial support.AVR/Atmel Studio: modern UI. Free. 6.0 is bloated so 5.x is the way to go in my view.ICCAVR/CVAVR: somewhere between gcc-avr and IAR. Good wizard.I personally use CB + Atmel's avr tool chain and found it to be well behaved. If I had to code a project for a living, I would go with IAR.Other alternatives you may try include VS + VAX + gcc-avr. Or simply an editor + make + gcc-avr. SI, UE, PN+, or sublime text, etc. SI does a superb job in code analysis. sublime is superb visually. The later category also allows you to work on other chips, if you have the respective compilers. For people transitioning from cmd environment, they are particularly attractive.

author: vvanders
author_rank: Regular Contributor
timestamp: March 23, 2014, 03:10:44 am
content: +1 on V6 Atmel Studio. I find VS with VAX combo to be one of my most productive development environments.

author: Kremmen
author_rank: Super Contributor
timestamp: March 23, 2014, 09:19:46 am
content: +1 (or is it +2 already?) for Atmel Studio.Bloated? Who cares - gigabytes are cheap and the Studio works right out of the box. No f-ing recursive exercise to set up the environment to set up the environment to set up the development tools. Eclipse and the rest is OK if you are already familiar with that stuff, otherwise don't combine that exercise with this - you will only get frustrated. Some still favor command line tools. I don't understand why - the 60s are long gone - but then i don't really care either...

author: Bored@Work
author_rank: Super Contributor
timestamp: March 23, 2014, 10:02:35 am
content: Quote from: Kremmen on March 23, 2014, 09:19:46 amSpoken like a true lone warrior hacking away in his closet all day.In the corporate environment gigabytes, integration, manageability etc. still matter. Especially with an outsourced, standardized, secured, locked down, mostly centralized IT environment. Vendors better offer superior value when trying to force-feed their customers with such bloatware, which of course happens to not fit into the existing IT environment, doesn't interwork with existing, standardized tools, being it installation, but of course also in production, Can't be beaten into shape to be working within the framework of established processes, increases system management costs, requires an endless stream of manual workarounds, tears holes into the IT security, requires special drivers, etc.There is only so much people in a corporate IT environment are willing to bear with.AVR Studio 5 was what pushed us over the edge to finally drop Atmel AVRs. The MCUs are so-so. But then Atmel broke previous promises of a cross-platform environment, and instead delivered the broken, bloated, only adding negative value Studio 5 POS. And the only kind of support you got from Atmel for that POS was that we had to shut up, because that POS was supposed to be perfect.Atmel Studio 6 just gained more bloat, still runs on the wrong operating system, is impossible to integrate with all that is right and holly for us and crashes a bit less often than Studio 5. Nothing in Studio 6 made us reconsider AVRs.

author: firewalker
author_rank: Super Contributor
timestamp: March 23, 2014, 10:11:20 am
content: Quote from: Bored@Work on March 23, 2014, 10:02:35 amThey should use Mono.Have you tried MPLAB X? Is it ok? Last time I tried it o GNU/Linux it needed a specific JRE in order to run.Alexander.

author: dannyf
author_rank: Super Contributor
timestamp: March 23, 2014, 12:00:08 pm
content: A lesson to be learned from the divergence of opinions is that don't ask people for their judgment ("ABC is the best development environment") - what's best is highly subjective and a perfectly valid reason for me to like an environment may be a perfect reason for you to avoid it. Having just the "judgment" does not help you.Instead, ask people the basis of their judgment ("ABC is the best development environment because X, Y, and Z"). You can then assess if those X, Y, and Z apply to you and if you should discount a like or dislike.The issue with Internet is that a monkey with a keyboard can come cross as Shakespeare. The only way for you to tell that monkey with a keyboard is if you ask the next question(s).

author: jmaja
author_rank: Frequent Contributor
timestamp: March 23, 2014, 12:59:19 pm
content: Quote from: Kremmen on March 23, 2014, 09:19:46 amWith command line in a good shell (not DOS nor cmd.exe!) you can just do many things so much easier and faster once you have learned them. The ones who have already learned them can't really understand why people want to use tools like Atmel Studio, Excel etc.

author: Kremmen
author_rank: Super Contributor
timestamp: March 24, 2014, 05:42:03 pm
content: Regarding questions of opinion and shooting from the hip, i recommend Nobel prizewinner Daniel Kahneman's book "Thinking, Fast and Slow". Once you understand the concept of System 1 and System 2, then responses like Bored@work's become rather easier to understand.B@w, you are wrong on all counts by the way.

author: dannyf
author_rank: Super Contributor
timestamp: March 24, 2014, 07:14:33 pm
content: -recommend Nobel prizewinner Daniel Kahneman's book "Thinking, Fast and Slow". -you don't need to think fast and slow. Instead, you just need to think, period.it does not take a brilliant mind to understand that not everyone thinks and works the same way.all it takes is a half-functioning brain to recognize that what works for me may not work for you, vice versa.unfortunately that kind of common sense is beyond the comprehension of too many people.

author: G0HZU
author_rank: Super Contributor
timestamp: March 24, 2014, 07:14:53 pm
content: I haven't done much with AVRs recently but I always wrote stuff for them in assembler. So my response may not be useful...I started off with a third party command line system and a homemade programmer which produced a combination I quite liked because it was quick.When I started writing more complex code eg for 3D lookup tables with full interpolation and stuff like CRC routines I went across to Atmel Studio 4 and found it to be quite powerful for debugging. I also used IDA Pro to disassemble my own code if I hit a particularly strange problem.Most of the stuff I wrote was to do with engine/motor control using various lookup tables. eg 16x8 tables with full interpolation. I also used to use AVRs as a piggy interface to hack into other systems.I found the above setup to be very useful for coding in assembler and I don't think it held me back in any way. If I was writing very simple stuff in assembler I would always use the command line interface rather than Atmel Studio because it was far quicker.I also made my own encrypted bootloader and associated loader GUI to allow really rapid code changes via USB/Serial.Note that some of the Atmel AVR 'Mega' datasheets are (were?) very lazy because the assembly code snippets were often generic and were pasted into datasheets where they didn't actually apply to the device in the datasheet. So they are of limited use! But there's a lazy disclaimer about this in the datasheet somewhere. I guess this is less relevant if you program in a higher language.

author: Bored@Work
author_rank: Super Contributor
timestamp: March 24, 2014, 08:34:32 pm
content: Quote from: firewalker on March 23, 2014, 10:11:20 amThere is actually a rumor around that Atmel is indeed trying to get the shit running on Linux using Mono. We laughed very hard when we heard this.Quote from: Kremmen on March 24, 2014, 05:42:03 pmI don't care about your opinion. We have objective reasons.It takes our competitor roughly four weeks to push out a new firmware release. They claim it is three weeks, but our observation tells us it is typically four weeks, sometimes six weeks.The time is measured from end of coding, e.g. after a bug was found and fixed, until the firmware reaches the customer. It including tests, signing off the release by higher ups, etc.Compare that with us. It takes us two hours - yes, two hours - to push out a new release. Version controlled, traceable changes, build, automatically regression tested, packaged, manually signed off by someone higher up with the right to sign it off, made available.That is a competitive advantage we are not willing to give up or compromise, just because an arrogant MCU manufacturer thinks they know what their customers need, provides no support but a rubbish tool, and ignores any feedback. If a tool does not fit in our environment, if it can't be properly integrated, if the bloatware just makes trouble, or if it crashes, we don't care what some Nobel price winner says.

author: firewalker
author_rank: Super Contributor
timestamp: March 24, 2014, 10:03:33 pm
content: Quote from: Bored@Work on March 24, 2014, 08:34:32 pmIt would be easier to start from scratch using ones and zeros.Alexander.

author: Rigby
author_rank: Super Contributor
timestamp: March 24, 2014, 11:58:40 pm
content: Quote from: Bored@Work on March 24, 2014, 08:34:32 pmWho is "our competitor" and who is "us"?

author: dannyf
author_rank: Super Contributor
timestamp: March 25, 2014, 12:16:35 am
content: "our competitor": that neighborhood weirdo living across the street."us": those who pretend to live a life of others.

author: vvanders
author_rank: Regular Contributor
timestamp: March 25, 2014, 01:16:47 am
content: Quote from: jmaja on March 23, 2014, 12:59:19 pmIt's not as well advertised as it should be but VS has a pretty solid command window that has short text based aliases for everything you can do from the menus. "of <file>" has autocomplete and I guarantee that I can move around a project much faster than someone on the command line because it has enough context to provide what I'm looking for.Much like VI each tool has an investment required to get the most out of it and certain things will work better in situations over others.

author: hans
author_rank: Super Contributor
timestamp: March 25, 2014, 08:43:00 am
content: PowerShell in VS is a lot better than normal CMD window. At least it has piping.Mono is absolutely useless on Linux. Or be very regretful about the choice of C# to develop an application thatshouldrun over multiple platforms, instead of C++/Qt or Java. I think it's really a big miss for Atmel.I've never liked AVR Studio 5 or 6 though. AS5 tried to ruin my Visual Studio C# installation by overriding some settings which meant I couldn't start solutions from explorer (it started in AS5 and said "nope can't do C#, bye now"), some keyboard shortcuts were reset (also in combination with ReSharper) and panes were moved (not a real big deal).Therefore, the last time I programmed an AVR (which was a tiny ATTINY btw, so not a "big" project) I installed AVR Studio 4 and used AVR-GCC from Arduino libraries. Not a big PITA to setup at all, and it seems to work OK & run smoothly.I run MPLAB X on Linux and Windows, and it works out of the box. No extra JRE required. In contrast, XILINX ISE 14.7 was a much bigger pain to even start on Linux.

author: fake-name
author_rank: Regular Contributor
timestamp: March 25, 2014, 10:02:43 am
content: Quote from: Bored@Work on March 24, 2014, 08:34:32 pmYou do realize that this hasabsolutely NOTHINGto do with whether they use AS6 or not, right?Are you seriously blaming their release times on theIDE? Shit, I could write a toolchain that emulated a freaking mouse and did automated builds using AS6/VS, and still get it done in less then 4 weeksincluding writing the tools to do all the automation, and there wouldn't even be a reason to do so since AS6 includes a full version of make anyways, as well as most of the GNU utilities compiled for windows anyways.Your "competitor" having shit release times tells you about their internal political issues, and nothing else.

author: Kremmen
author_rank: Super Contributor
timestamp: March 25, 2014, 10:52:35 am
content: Quote from: Bored@Work on March 24, 2014, 08:34:32 pmI would rather say the opposite: your reasons appear very much subjective. Also, your overly polemic way to express your opinions makes it difficultand ultimately fruitless to comment in detail so i won't bother.Just let me say this much: AS6 supports SVN integration using the AnkhSVN plugin and from there it is a short step to continuous integration using say Jenkins (or MS Team Foundation Suite if that floats your boat) and then we are not really any more talking about AS6 being somehow different or limited. So i say you are not really making a point. It is obvious issues you mention have very little to do with the tools in use and very much with the processes used - or lack of them. Conversely your advantage is not based in avoiding AS6.Kahneman is silent on the issue of software tools. On the other hand he has a lot to say about human behavior and the reasons and mechanisms explaining same. You and many others in this forum and elsewhere prove his points.

author: senso
author_rank: Frequent Contributor
timestamp: March 25, 2014, 12:22:28 pm
content: If AS6 is THAT bad, you can use the Arduino IDE

author: zapta
author_rank: Super Contributor
timestamp: March 25, 2014, 12:25:51 pm
content: Quote from: senso on March 25, 2014, 12:22:28 pmThat's exactly what I am doing and it works well for me.

author: dannyf
author_rank: Super Contributor
timestamp: March 25, 2014, 01:02:20 pm
content: QuoteAnything would be a big winner against Arduino,There is a CB-based Arduino environment. I rarely use arduino ide to program my arduino boards: CB + gcc-avr does the job just fine.

author: Rigby
author_rank: Super Contributor
timestamp: March 25, 2014, 01:06:40 pm
content: What the heck is CB and why can't you just spell it out so that we know what it is?"I know of this magical tool that is perfect for what you're describing but I'm going to obfuscate the name so you never find it. here's a clue: f(x) = 2x-1."edit: are you talking about this?http://arduinodev.com/codeblocks/

author: jancumps
author_rank: Unknown
timestamp: March 25, 2014, 04:14:36 pm
content: Quote from: mojo-chan on March 25, 2014, 02:33:45 pmIn this case or in general?Regression testing is repetitive by implication. So why not trust an automated and maintained regression test suite?

author: Rigby
author_rank: Super Contributor
timestamp: March 25, 2014, 08:16:09 pm
content: regression testing can lead to lazy testing, reliance on the automation, and false faith in the automated testing results.If you have good devs who keep up on their test cases and/or test coverage statistics which show you what you're NOT testing, then it's actually not too bad. I've used tools where the test cases measured the amount of code that was tested, and any code that was meant for production that wasn't run in a test case was flagged as not-tested.

author: westfw
author_rank: Super Contributor
timestamp: March 26, 2014, 10:13:13 am
content: I believe he's saying that his cluster of high-end linux systems is able to automatically do things in parallel and quickly, that in a typical individual PC based environment take a lot of manual effort (and time) to accomplish. And that therefore, his company would be very foolish to give up those linux systems just because a vendor thinks that a windows-only tool is better.What's unsaid (and isn't really relevant) is this is probably due to some linux wizard having set this up. Using linux doesn't automatically get you such improvements, and using windows doesn't mean that you couldn't do similar things given (perhaps) an equivalent windows wizard. Meanwhile, he's ahead of his competitor and not inclined to change, just to get the bells and whistles of VS.The Arduino's "use external editor" feature works really nicely, for such a simple implementation, BTW. Whenever I need heavy editing features, I turn it on and use EMACS for editing my "sketch", with the Arduino IDE reduced to a one-click build/upload tool...

author: granz
author_rank: Regular Contributor
timestamp: March 26, 2014, 02:39:22 pm
content: I guess I'm late to the game. But I'll add another +1 to Atmel Studio V6. As mentioned by mojo, the auto-completion feature is what makes it the most valuable in my opinion. Also, if you've worked with Visual Studio in the past the learning curve is almost non-existent.I'm not biased against traditional command line tools--I still use a command line build environment for Linux driver development, something I am responsible for at my company. I just find that when I haven't worked on something for a while, I tend to forget whats-what. Atmel Studio / Visual Studio completely helps you out with intellisense (auto-complete).It's also important to note that there's no reason you can't just take your code files to another dev environment later on if you change your mind.

author: G0HZU
author_rank: Super Contributor
timestamp: March 26, 2014, 03:38:07 pm
content: QuoteI agree that it is easy to forget the commands etc. What I do here is add the series of relevant command lines as comments at the top of the assy file for future reference.I used to do everything with a batch file so I just typed a single letter and then pressed return to generate the hex file, program the fuses and program and verify the device and also run the program. All from a single keystroke + a carriage return.If any stage failed then it warned me onscreen.

author: granz
author_rank: Regular Contributor
timestamp: March 26, 2014, 03:44:37 pm
content: Quote from: G0HZU on March 26, 2014, 03:38:07 pmI was actually referring to auto-complete ("intellisense" in VS) in the source editor for functions, structure members etc, constants. etc. In the Linux world I still use makefiles + scripts for the reason you mention.

author: zapta
author_rank: Super Contributor
timestamp: March 26, 2014, 09:57:39 pm
content: Quote from: mojo-chan on March 26, 2014, 01:49:28 pmSame goes to non automated tests. Testing is a tricky thing. One way to address it, when possible, is a controlled ramped up release, this way you get feedback from the field before effecting all users.BTW, worked once with a testing guru. He used to emphasize that testing does not creates quality, it just measures it.