Telecnatron

radio, electronics, computing, telecnology.

rss icon
twitter icon

Support This Site.

Please consider helping to support this site by making a contribution.

avr_lib C Library For AVR MCUs

Author: Stephen Stebbing

ATmega328 Chip

A utility library for various AVR microcontrollers using the avr-gcc compiler and AVR Libc c-library. Has been developed for use with ATmega32, ATmega328, ATmega168, ATmega88 and ATmega8 microprocessors, as well as ATtiny2313, ATtiny85 and ATtiny13. It is likely to be also useful with other AVR processors.

The library is a constant work-in-progress with functionallity being added as required by new projects.

Current features include:

  • Tasks a simple co-operative multitasking (co-routine) system.
  • Interrupt driven UART routines including printf functionallity and a logging system.
  • Simple messaging protocol including synchronous and asynchronous communications between two MCUs or a MCU and a PC host. Python implementation for PC host.
  • Bootloader allows sharing of bootloader code with the application, including global variables and interrupt service routine code. Currently implement using UART, but can be easily ported to other communication channels such as SPI, for example.
  • Utility function to simplify use of timers and watchdog, a sysclk and RTC system support. Currently supports ds1302 and ds1307 RTC devices.
  • Dallas Semicondutor onewire support. Driver for DS18B20 temperature sensor device.
  • Interrupt driven routines for interfacing to rotary encoder devices, including velocity detection.


1. References


2. Tutorials and Examples.

Examples and descriptions on how to use the various parts of the library. The list below will be updated as the tutorials are written. Please check back here regularly.

  • Tasks a simple co-operative multitasking (co-routine) system.

Copyright 2012 - 2019 Telecnatron CSS | Login | Privacy | Sitemap Web software by Stephen Stebbing.