This week, Brad wrote in with an interesting question: Can you program the ATtiny25 on one of our ‘tiny2313 target boards? And the answer is yes: you can, with just a trivial modification.
Okay, back up– a little context here. The ATtiny25 and the ATtiny2313 are examples of AVR microcontrollers, the little brains that power many of our projects.
Some good stuff for the AVR freaks up in here, Alastair writes in…
Here’s a replacement for WinAVR with up-to-date tools (since WinAVR has been abandoned, and nothing has yet been released from Atmel) & an efficiency oriented runtime library for AVR microcontrollers, for those ready to graduate from the Arduino environment.
Developing software – or better firmware – for the Atmel AVR can be quite easy or quite complicated. A lot of people like to just use vi, some source files and a make file. Here at Interactive Matter we are a tad lazy and want a fully fledged IDE, with code completion, one click building, no make files and buttons to flash the AVR. The easiest was is to achieve this with Open Source Software, using avr-gcc, avrdude and avr-eclipse. This guide explains how to install and use it.
TL;DR – In order to get raw parsed data out of a magstripe reader, we first experimented with a MAGTEK Centurion Keyboard Encoder (PN-21073062). We found that although we could get all 3 tracks of data, it was not possible to have it parsed out. We then purchased a raw magstripe decoder head with track 1 reading, the Omron V3A-6. By writing some parity checking code, we were able to read the raw data off of the magstripe, and parse it into output that would be ‘typed out’ as an emulated keyboard using a USB-enabled Teensy. An Arduino can also be used, and the data would be output as Serial which may also be useful.
We also suggest checking out StripeSnoop which despite being a couple years old, was extremely useful!
This project can only be used for card reading, not writing. There is no way to convert a card reader into a card writer.
So there I was, 5 days before HOPE (Hackers on Planet Earth) conference – getting ready for our booth that would be running all weekend. We had a similar booth at the previous HOPE, and it was pretty successful, one of the only things that hung us up was that we couldn’t easily accept credit cards and the ATM had run out of money. We could take credit cards but it took a long time and was typo-ridden because everything had to be entered into a website. See, instead of a boxy terminal, we were using a Virtual Terminal – a website that allows you to enter in all the important data (card number, expiration, name, amount, etc).
An ATTiny2313 powers this night light, driving multicolor LEDs diffused by ping-pong balls. nuumio writes:
Geir’s RGB night light was such an inspiration I just had to make my own. Instead of Picaxes I decided to use ATTiny 2313. At first I tried to program it with C but I ran to some “differences of opinions” with gcc when I tried to assign dedicated registers to variables holding duty cycle values (for speed optimizations). After some struggling I gave up and coded the whole thing in AVR assembly. I was quite surprised how easy it was after all. It took me about one weekend and I got first versions running nicely.
My speedo cable snapped. Boo. The speedo was never very accurate anyway, so rather than replace the cable I figured it’d be fun to try making a digital speedo – plus it’s an opportunity to try using surface mount components rather than the bigger through-hole ones I’ve used so far. A bit of an ambitious design this time round – separate display and control boards, bigger and more complicated than anything I’ve done to date
V-USB is a software-only implementation of a low-speed USB device for Atmel’s AVR® microcontrollers, making it possible to build USB hardware with almost any AVR® microcontroller, not requiring any additional chip.
My goodness. Thank you *so* much for making the USBTiny ISP kit!… Thank you for sharing the fruits of your talents and work with those of us at home trying to learn how these things work. Without people like you and Windell & Lenore over at EMSL, I would never have started down this path. I’m having a great time, and my 9yo son is as well. He’s thoroughly intrigued by electronics and programming, and the tools you offer are an enormous help for us!
simavr is a new AVR simulator for linux, or any platform that uses avr-gcc. It uses avr-gcc own register definition to simplify creating new targets for supported AVR devices. The core was made to be small and compact, and hackable so allow quick prototyping of an AVR project. The AVR core works more or less perfectly now. The simulator loads ELF files directly, and there is even a way to specify simulation parameters directly in the emulated code using an .elf section.
Building the AVR toolchain by hand also thwarted me somewhere in the building of the avr-binutils package — it doesn’t want to build on my Mac. As soon as I entered the dependency hell of installing an upgraded gcc to build binutils and that didn’t work either, I got pretty fed up with that line of attack. Finally, I tried installing the AVR toolchain from the Fink project. Success! Here are the steps it took to get it up and running…
To program the ATtiny13 or other AVR tiny microcontrollers I use the USBtinyISP. It is a diy build programmer, you can buy a package and you only need to solder. The nice thing is that it works with USB and can power the circuit directly. More information about the programmer can be found here: http://www.ladyada.net/make/usbtinyisp/ I use Windows Vista for programming. USBtinyISP uses an USB driver to work under Windows. This works good on 32 bit Vista system, but on 64 bit system you need to disable Windows check of unsigned drivers. This can be done by pressing F8 during boot and selecting a boot option at the bottom. This needs to be done every time you want to program the microcontroller. Perhaps a reader knows a solution to that? Please post in the comments. The USBtinyISP is cheap and works great…
The Chameleon uses an Atmel AVR ATMega 328P as the main master processor (client) and Parallax multicore Propeller chip, includes the Arduino bootloader too -
The Chameleon(TM) AVR 8-Bit is the evolution of the high performance, small footprint, application development board. Similar to the BASIC Stamp(TM) and Arduino(TM) in concept, the Chameleon takes these products to the next level with a huge leap in computational performance as well as I/O interfaces. Simply put, the Chameleon is a credit card sized computer with (2) processors, (9) processing cores, 1 MByte of on board FLASH, 64K of EEPROM, and over 170 MIPS of processing power! If that wasn’t enough, the numerous I/O interfaces include composite video for NTSC/PAL generation, VGA, audio out, PS/2 for keyboards and mice. Additionally, the Chameleon has a number of digital I/Os and Analog inputs making the Chameleon perfect for industrial controllers, experimentation, education, wearable computing, or hobbyist use.
Experiments in RFID, continued… Last time, I posted an ultra-simple “from scratch” RFID reader, which uses no application-specific components: just a Propeller microcontroller and a few passive components. This time, I tried the opposite: building an RFID tag using no application-specific parts. Well, my solution is full of dirty tricks, but the results aren’t half bad. I used an Atmel AVR microcontroller (the ATtiny85) and a coil. That’s it. You can optionally add a couple of capacitors to improve performance with some types of coils, but with this method it’s possible to build a working RFID tag just by soldering a small inductor to an AVR chip…