I would be very interested to ask for a list of repos of free open code, applicable to 8-bit avr-s and having relation to robotics - object avoidance, process controllers, battery management, etc. This would be of huge help for me, preventing me from wasting weeks and months to invent the wheel.

  • $\begingroup$ I think it would be better to ask a more specific question - ie. what code you want to use. $\endgroup$
    – ronalchn
    Oct 24, 2012 at 14:59
  • $\begingroup$ Please elaborate. Well-maintained open source libraries for those small buddies doesn't seem to be all that common (or my google-fu is terrible). My major concern is what should be the quality threshold - as there are plenty of example projects, but the latter are not really readily reusable. $\endgroup$
    – Vorac
    Oct 24, 2012 at 15:11
  • $\begingroup$ I wonder whether this question isn't more suited to the StackOverflow site or the Electronics StackExchange, than Robotics? $\endgroup$ Oct 24, 2012 at 15:46
  • $\begingroup$ It's still a list question, in my opinion, and making it community wiki doesn't solve that. I vote to close $\endgroup$
    – ThomasH
    Oct 29, 2012 at 22:58
  • $\begingroup$ I agree that this is a list question. $\endgroup$
    – Ian
    Nov 13, 2012 at 15:39

2 Answers 2


I can say from my own experience three libraries are awesome to use with 8-bit AVR microcontrollers:

  1. AVR Libc is the standard C library for AVR programming. It is very low-level in the sense that you really need to know your hardware down to the register level, but it gives you great freedom to do exactly what you want.

    Even if you don't want to dive so deep, you should become somewhat familiar with it since every now and then Arduino users end up using bits of it to surpass the capabilities of the standard Arduino API. An interesting fact is that you can use AVR Libc snippets within your Arduino code since the Arduino API is based on the AVR GNU Toolchain.

  2. AVR Liberty is currently my favorite library to develop with. It is both very straightforward and very powerful, so I feel I get the best of both worlds: I don't have to reinvent the wheel as with AVR Libc, but I also don't have to be agnostic of everything that goes on with the hardware as with the Arduino API. I strongly recommend it.

  3. The Arduino API can be used in the Arduino boards, in breadboard versions[1][2] of the Arduino board, or even in standalone microcontrollers using a programmer such as the USBasp.

    I like to use Arduino boards for quick prototyping, but I find its API to be somewhat limiting at times. However, they have many specific libraries that extend the standard API's functionality.

    The Arduino board can also be used with any other AVR library as long as you understand how to upload your code (either through the bootloader or a programmer), so it is definitely a dev board worth buying to get started.

  • Lightweight USB Framework for AVRs — this seems to be a giant in its field. I have not used it, however, and cannot comment on it.
  • Atmel's PID implementation — I can't seem to find the source files at the moment. This is a small and fast integer-arithmetic module, really simple to use. However, choosing the P, I and D coefficients is the real challenge.
  • Modules from this project can be used for USART and for Dallas one-wire communication. I am not sure about the license — the authors do not apper to claim anything.
  • libavrutil — haven't used this. Copileft license. Covers all basic hardware: ADC-s, PWM-s, USART etc. C and C++ interface.
  • Arduino libraries for RC servos
  • openBMS Lithium ion Battery Management System for Electric Vehicle
  • The RepRap project has a bunch of open-source stepper-motor-control code that runs on an AVR
  • 1
    $\begingroup$ Try to give more than just a link in the answer, include a summary as well, since links can get broken over time. $\endgroup$
    – Crake
    Oct 24, 2012 at 14:56
  • $\begingroup$ I'm expanding it - give me some time. Thanks for the pointer! $\endgroup$
    – Vorac
    Oct 24, 2012 at 14:58
  • $\begingroup$ Sorry - didn't see it was a community wiki answer :) $\endgroup$
    – Crake
    Oct 24, 2012 at 16:20
  • $\begingroup$ Does arduino code run on a bare avr cpu, or is the whole board required? $\endgroup$
    – Vorac
    Nov 1, 2012 at 11:05

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