2008-12-21

Christmas, Winter Solstice and Chili pepper

Christmas is coming soon! Yesterday were spent the afternoon baking cookies and looking for some last minute presents. Every present is now wrapped and ready to pack. I still have some important things to do in the run up, like cleaning and a major overhaul of the bike(s), packing, cleaning the house etc., but with decent planning we'll be fine!
Today is the winter solstice, the shortest day (daylight) of the year! It is time to celebrate... From now on the days can only get bigger, although it can still get colder... brrr.... It is also the start of the Winter season! We already had the first snow fall in late November, but with only two centimeters of snow... maybe later it gets more interesting.
And now for something completely different...
Our indoor "three vase garden" has been going on. We planted parsley, basil and chili peppers in three vases before this spring. This year, Spring was actually quite warm but Summer was pretty lame, and although our plants grew and some flourished (basil and chili peppers) they did it quite late in the summer. Mid September I had to take the vases indoor as the conditions outside deteriorated. When inside I tried some hand pollination (as I have no bees or flying insects at home) with a cotton bud and as a result I managed to get some basil seeds and to my surprise, one chili!

This week it changed color! it has gone red! I have some projects to extend the light time and control the moisture in the earth, something similar to the garduino project ... but more autonomous and without a full blown arduino and minimal feedback to the user.

2008-12-07

Creating a PCB with gEDA

I always wanted to try out the gEDA tools for producing PCBs and schematics in the Linux environment.
The ongoing mini85 (8085) project is to big for a first try, there are many packages that are not standard in gEDA, many schematic symbols that also do not come standard, there are many ICs in the schematic, these are too many variables to control for a first time.
I needed something smaller, where I could fully test the tools. I decided to use my USBHID Flight simulator control for this project. I would also try out other things like adding a MACH131SP because it is a SMD component, programmable via a ISP connector (also test the software) and test the package outline of a DB9 connector, the power connector and USB B connector.
I want to send the board for fabrication, most of the PCB fabrication houses need a gerber file (none accepts pcb format), but not many details appear in the official tutorial.

The schematic editor has a reasonable sized library, but if a symbol is needed the procedure is quite fast, I used tragesym and the tutorial is here. I redesigned the symbol for the Atmel AVR AT90S2313 (also ATtiny2313), because I prefer to have direct access to the VCC and GND pins and I don't like the crystal oscillator and the reset input in the bottom. Here is the first page of the schematic.


For converting to PCB I downloaded a library from jluciani, it seems very complete... I still have to understand how to use it properly and in conjunction standard libraries. It needs a small modification of the command line of gsch2pcb.
gsch2pcb --use-files --elements-dir ~/footprints SCHEMATIC_NAME


For now I think the footprints provided are suficient, but I'll probably need to draw new footprints for some older PGA microprocessors (when the time comes)...
Another way will be to try the same system with kicad, it also appears to be a good (free) design tool for linux. It has an extra that for now I don't really need which is the 3D view, but who knows latter...

2008-11-18

USB keyboard - Flight simulator control

I wanted to help friend building control panel for a flight simulator "on the cheap". I'm not much into gaming scene but it sounded a fun project, and I could use it for other projects.
The first idea that came to mind was to "hack" or "cannibalize" keyboard controller and connect it to switches. Guilherme also mentioned some sort of visual feedback when the switch is activated. For switches I thought of rocker switches, they look like made to be "air borne" all the time. I passed the "word" that I needed a keyboard to all my friends, and waited... Alex had a folding keyboard that wasn't working anymore, he gave it to me to be "sacrificed"... "may God have mercy on its soul"...

I opened the keyboard and separated the membrane, I marked lines and columns with letters and numbers respectively.
Then I wrote and identified all the keys in the membrane, so I could build a list of correspondence between key and of column, line.

Then I identified one line and one particular column, line is marked black and column is marked red. I marked the key "Q".
Then I wired a switch to the keyboard on the "Q" contacts, the second contact would be used to power the LED when the switch was activated.
Well, it didn't worked out exactly as expected... I toggled the switch and "W" appeared... connected the black wire on the wrong line...
There was another problem, once the switch is activated it keeps writing Ws, not what I intended. I would need some more electronics to translate a toggle of the switch to a single key press...
Then I decided to try another alternative, build my own USB keyboard controller. I knew of a firmware only implementation with AVR micro controllers here, since I had some AVRs in the components box I decided to give it a try.
I started with the HIDKeys project, but since I didn't have a ATmega8 I had to change the project for the ATtiny2313. I started with a breadboard version of the project once the software started running OK (being recognized by the PC), I build a small prototype board.


Development was done on the PC (SUSE linux platform) with avr-gcc and for the programming I used the AVR-ISP mk 2 USB programmer. The source is not final and there are still no switches and output indicators, as soon as I finish something I'll publish it.

2008-11-02

Formating a floppy in Mini85

My list of softwear and hardware tasks is becomming shorter by the day. That is the number of new tasks added during the week is less than the tasks I finish during the weekend...
This weekend I finished the formating function and the display help function. On the hardware I changed the regulated power supply by a home build switching power supply, I've also changed the Motor on timer to 30 seconds to reduce wear on the floppies.
I've also created a task lisk on the blog's front page so it's easy to keep track of the TO DO list on the Mini85. I think it is a good idea, to keep a todo list for each project while it is running.I'll keep a list alive and maintained until a new project comes along, then I'll do a new one.
The format routine had a few details, the interrupt routine had to be changed to support the read/write operations and format operations.

Two pictures of the switching power supply, pretty standard. An LM2575-5.0 simple switcher, a RENCO 330uH inductor with IRMS 3 Amp capability (an old sample I had) and a schottky diode 1N5819 (here the diode is only capable of IRMS 1A)...