Adafruit Holiday Shipping Deadlines 2018: Attention! Place all UPS 3 Day orders by 11am ET Thursday 12/13/2018
0

ASK AN EDUCATOR! – “What is the best path if you want to progress from Arduino to bare AVRs? “

David asks:

What is the best path if you want to progress from Arduino to bare AVRs? There seems to be a range of toolchains of varying currency around so google requires a lot of digging to find if what you have is actually current. Ditto some ICSPs seem to have no windows 7 support which can be a trap if that’s your OS of choice. Another way to word the question would be ‘what is the easiest way to work with AVRs while still being able to use things like the internal oscilator and timer interupts’?

Well David, the results are in and it looks like the transition shouldn’t be too hard. It looks like AVR Studio is the way to go as far as IDE and offers debugging. You will need an AVR Dragon or the monster SKT500 for programming. As tz commented:

The AVR “Dragon” available from Digikey and other places works with the AVR studio environment as well as with avrdude (the programmer under Arduino). It can do ISP, JTAG, dW, serial or parallel high-voltage programming, I use jumpers and have added a ZIF socket

tz also wisely mentioned that because Arduino is compiled with gcc:

Any Arduino (or compatible – with the right chip and bootloader) can run pure embedded by replacing main() with init(). I just did that for my radar detector interface. You need a trivial sketch (which is never executed), but “init” is called as the first thing from the Arduino environment’s “main()”, so if you just don’t return, you can set all the registers as if you were doing a makefile and C programs. There are a few gotchas and I may not have found all cases (mainly I needed to declare things volatile if the interrupt would modify them and the main routine would read them – this is technically correct but I didn’t have to do it with the command-line direct install tools).

Bruce also nicely pointed you should take your question:

…over to avrfreaks.net. There are several very helpful and very knowledgeable AVR developers over there who could help you with this, and you’ll want to get familiar with those forums anyway as you get deeper into the mysteries of your future AVR projects. Browse the FAQs in the forum for a while and if you don’t feel like your question was fully answered, introduce yourself and ask away. Here’s a good jumping off point, I think.

Lianna has also given a quick tutorial in the 3rd comment for using an Arduino for programming non-bootloaded AVRs. This doesn’t give you the debugging capability of AVR Studio, but does offer an alternative to programming the base set of Arduino ICs.

Thanks again everyone for your feedback and wisdom, and I hope this has helped to answer your question! If anyone else has something to add feel free to leave a comment!

Don’t forget, everyone is invited to ask a question!

Click here!

“Ask an Educator” questions are answered by Adam Kemp, a high school teacher who has been teaching courses in Energy Systems, Systems Engineering, Robotics and Prototyping since 2005.


Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, or even use Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for MakeCode, CircuitPython, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.

Join 9,200+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython – Python on Microcontrollers is here!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Follow Adafruit on Instagram for top secret new products, behinds the scenes and more https://www.instagram.com/adafruit/


Maker Business — Japanese word working and more in December’s issue of HackSpace magazine!

Wearables — Solder-less magic

Electronics — = != ==.

Biohacking — Finding Bliss with Anandamide

Python for Microcontrollers — sysfs is dead! long live libgpiod! libgpiod for linux & Python running hardware @circuitpython @micropython @ThePSF #Python @Adafruit #Adafruit

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !



1 Comment

  1. Hi all, and thanks for all the responses. Thought there had to be directions from classic Arduino that didn’t involve command lines straight up, and now I’ve got several.

    Again, thanks.

    David

Sorry, the comment form is closed at this time.