Saturday, April 24, 2010

Thermometer version 5

I added backlight functionality to my thermometer.
A menu system was added too (as well as an annoying bug...).

I noticed that the button response is getting worse with time and the number of button clicks. Perhaps they are just to cheap? It is not a software fault.
The possibility to calibrate the clock for higher accuracy is still missing.

Gameport to PS/2 converter




Finally! My gameport project is finished!
With this little circuit it is possible to emulate a ps/2 keyboard with your gamepad.
I designed the circuit for a game that could not be played with that gamepad. But it worked well with a keyboard - so this evil mad idea was born. ;)
I used my old repaired gravis gamepad (repair report) for that project. Other gamepads could be wired internal in a different way.
The circuit is designed for digital gamepads only - no analog sticks or joysticks are supported (yet)!
But such a functionality could be implemented too. Because i used an old ATMEGA8, there are a lot of free pins for further experiments and hacks.
The buttons are "hard wired" in the code to keys. I used the ALT, SPACE, ENTER and CNTRL keys for the buttons. A function to define new key bindings without hacking them into the code and reporogram the controller could be implemented - but i was to lazy to write it. ^.^

Another impressive project that shows how easy and yet powerfull a µC circuit can be.
THX to the KISS guidelines.

The circuit in the red box does all the magic.












Feel free to use or improve this circuit.


The code can be found here:
http://sites.google.com/site/species0x2118/hive
http://sites.google.com/site/species0x2118/hive/gamepad.c?attredirects=0&d=1 (direct link)
I changed the fuses to run the controller with 8 MHz to have enough speed reserves. But a lower frequency could work as well.

As a goody i made a video of the gameplay with the gamepad connected to the converter:


Wednesday, April 21, 2010

Gamepad fixed


Last week i repaired my old Gravis gamepad. It had a broken cable. To fix it, i bought a joystick extension cable as replacement. Because the new cable was a bit thicker, i had to modify the casing of the gamepad. The modifications are not visible from the outside.


Monday, April 5, 2010

Watching the truck in action

video

Some new stuff

Today i have a bunch of new stuff. First of all: i made a six channel logic analyzer. The hardware was designed in about five minutes. The software in perhaps six minutes...

Here is the code:
#include <avr/io.h>
#include
<avr/interrupt.h>
#include "uart.h"

#ifndef F_CPU
#define F_CPU 11059200
#endif

#define UART_BAUD_RATE     115200

int main(void)
{
    uart_init( UART_BAUD_SELECT(UART_BAUD_RATE,F_CPU) );
    sei();
    uart_puts("Starting low cost logic analyzer.\n");
   
    while (1)
    {
        uart_putc( PINB + '0' );
        uart_putc( '\r' );
    }
 }
You need the UART library from Peter Fleury (http://jump.to/fleury).
Unfortunatly i have no software for the data analysis. I saved the data with HTERM as text file so far.

Next project was the modification of my good old LEGO Technic truck.
He needs a huge amount of AA batteries - more than i had. But i wanted to make it work

And it worked. With my old self made power supply it was a joy to play with the truck. ; )


























And finally if finished the case for my thermometer. I found some transparent plasic in the cellar. Now only a calibration function for the clock is left.