After getting waaay ahead of myself in pondering what software my project will eventually run, I thought about using an RTOS on the main microcontroller. After finding out that installing FreeRTOS on an ATMega328p will leave me with 320-odd bytes of usable memory, I swiftly abandoned that idea :).
I'm trying to have fun while learning something at the same time, and that's just one of the options I can rule out along the way.
Thursday, 26 April 2012
Wednesday, 25 April 2012
What's Next?
Question is now what to work on adding to the project next. About a year ago I had a bash at making a pong machine, based solely on my Duemilanove with a circuit to output composite video and potentiometers connected to two inputs - another partial success ensued. I couldn't get a stable synced output due to the demands of running everything at the same time which made the game unplayable due to screen corruption.
Having tested the breadboarded Tellymate circuit with my Duemilanove, I'm happy that I can get a stable video signal as this is what was bothering me most - now I can concentrate on adding other stuff, although using a huge tv to test the results seems a bit like putting an elephant on rollerskates.
Having tested the breadboarded Tellymate circuit with my Duemilanove, I'm happy that I can get a stable video signal as this is what was bothering me most - now I can concentrate on adding other stuff, although using a huge tv to test the results seems a bit like putting an elephant on rollerskates.
Video Hardware
First up, the video hardware, not just because it's the most straightforward to get a quick result out of, but also because it's where my first tv-out experiment fell down. The Humane-PC's video output is based on the Tellymate from Batsocks, it too is open source as well as being a very clever idea, so that's where I headed and started studying the schematics.
If you've scavenged an ATMega328p from somewhere else, then the Arduino bootloader needs to be overwritten by the Tellymate firmware. My first try resulted in failure but I had negated to alter the ATMega's fuse bit settings as necessary before programming the firmware.
I'm using an external crystal and caps for the oscillator, so I executed the following to set the bits:
If you've scavenged an ATMega328p from somewhere else, then the Arduino bootloader needs to be overwritten by the Tellymate firmware. My first try resulted in failure but I had negated to alter the ATMega's fuse bit settings as necessary before programming the firmware.
I'm using an external crystal and caps for the oscillator, so I executed the following to set the bits:
avrdude -p m328p -c avrisp -P /dev/ttyUSB0 -b 19200 -v -e -U lfuse:w:0xff:m -U hfuse:w:0xd9:m -U efuse:w:0x07:mThen flashed the firmware with:
avrdude -p atmega328p -P /dev/ttyUSB0 -c avrisp -b 19200 -U flash:w:TellyMate_M328p.hex
![]() |
| Programming an ATMega328p with the Tellymate firmware using my home-made AVRISP programmer atop my trusty Duemilanove. |
![]() | |||
| Insert a finger in each ear and connect the battery :). Ready to test... |
![]() |
| Nice and sharp too, I put the 2x 100nf caps that Batsocks specify between pins 7 & 8 and pins 20 & 22 on the ATMega, dunno if they make any difference - guess I'll find out when I remove them. |
Tuesday, 24 April 2012
Inhuman PC
By no means my first project (and hopefully not my last :), more of which I'll detail later if I can summon up the gusto. Inhuman-PC is a play on words with a project by Humane Informatics that aims to bring minimal computing to the developing world. It consists of 3x ATMega328p's all working in together to implement such features as composite video, PS2 Keyboard interface, USB, an SD card slot, PWM audio output as well as compatibility with Arduino shields, along with a host of other features in an Open Source design.
And so it begins
A year or two ago I purchased an Arduino kit on a whim from Fleabay, it arrived surprisingly quickly and not having touched hobby electronics for years (before the internet was invented, at least), I set about doing some experimenting. The kit consisted of a Chinese Duemilanove, breadboard, LCD Module and various leds, resistors, switches a potentiometer and an IR led, IR receiver and a dodgy hand-held IR remote.
I did all the experiments on Arduino.cc, that I had the bits for, built an IR device to trigger my Nikon D40, cloned the tv remote and annoyed my wife by switching the tv off :) and numerous other odds and sods. I even got it to control some RC servos and an ESC without blowing them to smithereens, quite good, I thought - but now I was bored...
The answer... I bought a pre-programmed ATMega328p chip, complete with 16mhz crystal, caps and the other bare minimum of components required to make a 'Breadboarduino' along with a shiny new breadboard and set out in search of more fun.
Subscribe to:
Comments (Atom)



