0

Can someone tell me if it's possible AND safe to use Atmel Studio with Arduino Starter Kit? I'm a newbie to firmware in general and I don't want to "brick" my Arduino Uno Microcontroller. I don't quite know if the micro controller has been programmed in read only or special memory to make it Arduino compatible and me messing with Atmel Studio could mess it up. In other words, I want to know I can get back to programming through the Arduino IDE and continue working on the projects in the starter kit book. I've done about half of them.

1) Can someone tell me if it's doable, safe and WHY? 2) Any hints or gotchas or examples on how to do it?

My motivation is that I'm taking a job as a C# Windows programmer but will be exposed (I believe) to AVR and Atmel Studio and wanted to get familiar with it by just playing a little bit. Arduino libraries seems to hide a lot of the messy details (such as setting a pin output) which is fine, but it would probably be good to do those messy details myself and be familiar with the actual tools they will use at work.

I have searched for a "tutorial for dummies" that says what settings to pick, etc. to no avail.

Thanks Dave

P.S. If the answer is NO WAY is it safe or desirable, perhaps a recommendation for an AVR development kit (cheaper is better!). Actually, this is probably not a bad idea anyhow. Many Thanks!

1 Answer 1

1

There are many tutorials on programming Arduino boards (or any other AVR MCU) with Atmel Studio:

Creating new project: https://asensar.com/blog/2013/how-to-setup-atmel-studio-for-arduino-development/

Configuring Avrdude for firmware upload: https://asensar.com/blog/2013/how-to-integrate-avrdude-with-atmel-studio/ http://www.instructables.com/id/How-to-Load-Programs-to-an-Arduino-UNO-From-Atmel-/

Please see this post too: Atmel studio 7 - my own libraries

Nothing to afraid of, just don't mess with lock fuses (relevant only if you decide to play with ISP programmer and arvdude/avrdudess). Use Arduino USB virtual COM port connection for firmware uploading, just like in Arduino IDE.

With Atmel Studio you don't have rich libraries available like in Arduino platform, instead you will have to program MCU, its peripherals (and other devices connected, if any) by directly accessing MCU registers. This requires some knowledge on MCU hardware (but it is a natural choice if you want to learn that). Eventually you can build your own wrapper libraries similar to one in Arduino.

Check Procyon AVR library too - much better choice than digging Arduino library sources (a bit old but still relevant, I always recommend it as a starting point for AVR library development:) http://www.procyonengineering.com/embedded/avr/avrlib/

5
  • You are fairly mistaken in the library claim, atmel studio comes with the large ASF library Oct 7, 2016 at 17:29
  • Thank you very much Flanker for your answer (which is marked as such) It's good to know that I can't mess it up! I got a surprise looking at Atmel Studio ... it won't work with my Mac without jumping through a bunch of hoops. I'm trying CrossPack ( obdev.at/products/crosspack/download.html ) which does work on Macs. Any experience with it? Luckily, I also have an old PC kicking around, so I can download Atmel Studio (if PC will actually boot up :)) Thanks again.
    – Dave
    Oct 7, 2016 at 21:39
  • @Chris Stratton yes but ASF seems more suitable for ARM based MCUs.
    – Flanker
    Oct 8, 2016 at 4:55
  • @Dave - Atmel Studio is for Windows only, maybe you can use Parallel Desktop or Virtualbox virtualization tools to "run" Windows inside MacOS. Another option would be to setup avr gcc toolchain in MacOS - maxembedded.com/2015/06/…
    – Flanker
    Oct 8, 2016 at 4:57
  • If you have installed the Arduino IDE, you already have a working avr-gcc that you can use in a more traditional manner with the Arduino overhead, too. And you can download the atmel ASF library or anything else you want to use in stand alone form. An IDE and a compiler are ultimately two different things. Oct 8, 2016 at 6:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.