ATMEL AVR PROJECTS
- as I started to use microcontrollers at my daily work I kinda liked the thought to do some projects on my own. So what I did first of all was I build myself a little place in my flat that kinda reminds me of an electronic lab, and second I got myself a 8 bit AVR µC from Atmel and started coding. And here are some of the (maybe rathor poor) results:
Table of contents
- ISP interface for programming the atmel
- CD-changer emulation on a pulse-width-modulated bus
- I²C using USI (ported from ATMEL’s appnote 310)
- Using the SAA1064 led driver chip with an AVR
- Clock project
- MYRFM12 – a RFM12 library
- RS232 TTL Level Shifter
- DragonLair
- Links
ISP
This is a schematic of a cheap but very stable parallel port programmer for AVRs. It can be used with ponyprog or AVRdude.
CD-changer emulation on a pulse-width-modulated bus
I own a rather cheap (but very cool) MP3 CD radio which is currently in use in my VW Lupo. And what I always missed was an AUX input. Why not use the CD changer input? Well, the problem of most radios is that you have to have a proper working CD changer connected to use the auxiliary input.
My radio uses the MBUS, a rather slow pulse-width-modulated bus. Found this out I decided to check if I can fake a CD changer (better said it’s communication with the radio) and use my AUX input.
And today it works properly! So if you also own a CD radio you can maybe use this project.
MBUS implementation for ATMEL MCUs
I²C using USI (ported from ATMEL’s appnote 310)
If you want to use chips connected via I²C, you need an implementation of the I²C protocol. This is what I took from the ATMEL page (appnote 310) and used in my project. Grab the files here.
I²C implementation for ATMEL MCUs based on ATMELS APPNOTE 310
Using the SAA1064 led driver chip with an AVR
Whenever you want to drive many LEDs and you don’t want to use each pin of your AVR for that (or you want to drive more LEDs than you’ve got pins) you can use a SAA1064. It’s an LED driver chip connected via I²C. And here’s a small library to use it easily.
SAA1064 LED driver implementation for ATMEL MCUs
My clock project
Now I put everythign I currently learned together and built a clock. You can grab the complete project here (no guarantee for nothing, mates
).
Complete sources for my CLOCK project
MYRFM12
The RFM12 is a nice and priceworthy wireless module, which is rather easy to interface. This is why there are several libraries existing today, most of them working but none did yet meet my expectations in terms of source code readability, code style and documentation (at least not the ones I knew about). This is why I started out creating a new one which you can download here. The help can be found here. As this is version 0.1 there will maybe updates or enhancements in the future. If you have questions about the library don’t hesitate to contact me.
The other libs can be found (at least linked) in the wiki of http://www.mikrocontroller.net. And I just found one more nice site about RFM12, here.
RS232 TTL Level Shifter
I was used to air-wire my MAX232 to µCs and PC. But I often had to pay the price. Sick of having troubles with the serial connection, I created a layout which nicely fits on a half euro sized PCB. Additonally, it’s possible to choose via jumper if either a hardware handshake (via CTS/RTS) is wanted (which normally isn’t), or just a standard RX/TX connection.
Download the complete project including eagle schematics and board here.
It’s easily doable using the toner method (described by Thomas Pfeifer, in englisch here, in german here). Or watch the vid.
DragonLair
This is my “easy-to-etch-and-solder” DragonLair PCB. It is really easy, as the PCB is one-sided and there’s plenty of space to solder. Download the eagle schematics and board here.
It looks like this:
Links
- great german website regarding µC – http://www.mikrocontroller.net/
- ponyprog (AVR programing tool) – http://www.lancos.com/prog.html
- AVRdude (AVR programing tool) – http://savannah.nongnu.org/projects/avrdude/