2010-01-31

Hackerfruehstueck

It is really my version of the German Bauernfruehstueck, yesterday the local hackerspace had their new year's party and "official opening event", shame on me but I could not go.... hope I'll be able to meet some of the guys there.
I hope this helps recovering from last night's party... I know it helps after long nights of kernel compilation and cross-toolchain building...(geek thought, sorry)

Start by peeling the potatoes and cut them in slices of about 1cm thick, it is better if you use a type of potato that stays firm after cooking. I usually add in some vegetables, green beans are my favourite but other vegetable that cooks firm is fine (broccoli in small pieces). I usually steam them for about 15 minutes before going for the rest of the recipe.
Start by frying the bacon for a few minutes, turn the bacon slices over, and let it cook for one minute. Add the potatoes and vegetables (and some onion if you want), some pepper and salt and mix gently, let the potatoes cook until they are golden, add some sliced parsley and remove from the fry pan.
Do some scrambled eggs on the same pan (keeping some of the bacon's fat) and serve.
et voilà...
A few after-thoughts:
- remember your cholesterol bacon and eggs are your enemies, "but it tastes so good..";
- the fruit juice is important, use orange or carrot juice, helps digestion :-)

2010-01-30

Thinkpad X40 and openSUSE 11.2

Note to self... and anyone interested... Installing openSUSE 11.2 in a IBM thinkpad X40:
- edit partitions yourself (don't trust a computer to do a man's job), create primary partition, don't format as ext4 use ext3 instead(see update notes below), mount root; create primary partition, format as swap - size must be at least half the memory (just used for hibernating);
- install the languages you want (for OpenOffice dictionaries);
- disable firewall (avoids frustration when playing with toys);
- install development in C and KDE;
- remove Games (although some bastards are hard to kill);
- remove AppArmor, Beagle (optional, but if I don't know what they do, I don' t want them);
- install minicom (to play with serial toys);
- install kate (resonable window editor);
- install zip and other utils;
let it install for an good hour...
let it auto-update... let it fail...reboot...
let it auto-update again... now everything looks green... (the SUSE updater icon);
search for "opensuse 11.2 restricted formats", don't read any warnings and go directly to the one-click install... click yes, accept import keys and "deny any wrong doing" regarding the dvd-read library.
When finished reboot and have some food/coffee. Your system is ready to work... but for curious minds continue....
Search "opensuse 11.2 science" click on opensuse_11.2 and copy the URL, open YAST and add a repository using the URL that you cutted, add and import key...
In YAST go to software management and search for the following:
- gEDA (install all programs);pcb (install pcb); gerbv; ngspice, gspiceui, gwave2;
- AVR (install binutils,gcc, libc, avrdude);
Search "OpenOffice updates stable", install repository as above.
Open Yast and then Software Management, select All in "package groups", in the programs window select "all in this list -> update if newer version is available"
That's it, your laptop is a electronics design workstation and avr cross development computer.
Some things of opensuse need some extra work like SUSPEND and HIBERNATE, I also didn't managed to get dual head working "out of the box" and I'm reluctant to change the Xorg.conf... something I did when I had my first thinkpad a second-hand 340...

And all this because I had a Sony reader for a week and then decided to return it (takes to long to render some PDFs with pictures, and sometimes it hangs), wanting to un-install calibre... I found out there is no such thing... damn!
Update: my old backup software failed first to copy the ext4 partition and then failed to install grub for booting. After battling with it for some time I decided to do a fresh install with ext3. It is a pain in the butt! I hate myself for it, I should have known better, you should never be an early adopter!

SolarLight (4) - gEDA, PCB and first corrections

It has been a while since my last post, but I've been busy... not so much on electronics projects, but projects of other kind... Nevertheless I've been working a bit on SolarLight.
The prototype was working to light the LED but some other bits of the code were not working. Although the "light-on" function was working, the function checking the battery and checking the charging were not.
After wake-up from reset (power-up or watchdog), the micro checks if the current Solar Panel voltage is >200mV than the battery (a safe assumption it is charging) and if so increments a "charging timer", if this timer is less than 3hours, don't turn the light on. This is to be sure that there is some charging before a discharge. These and other checks were not working.
De-evolution from C to Assembler is always a mess if you have to re-learn the mechanics of each architecture. It is not only the instructions, its how the micro "thinks", only then you really control the machine.
On the hardware side I also had some problems, due to the limited number of pins I had to share some pins with the in circuit programmer, one of them is the MOSFET gate. I forgot to add a gate resistor to the source, in common MOSFETs with 10V gate threshold that is still asking for trouble, I guess that with LL (logic level) gate thresholds of 2V it is just "waiting to happen"... although it did take a couple of weeks...
I guess what hapened was, after programming the AVR-ISP left the pin floating and probably before that the level was high... the MOSFET kept on and finally burned.. I saw smoke coming out...
Here the new schematic with revisions on the lower corner.I also started the PCB design (with PCB part of gEDA suite) and I've now finished the board. It is not as packed as it could be because it has the size of a 3xAA pack. It is marked version 1.1 because I had finished the version 1.0 when the MOSFET blew up. I've mostly followed the tutorials available at the gEDA Documentation site:
- this one for the drawing of schematic and creating the netlist;
- this one for drawing footprints and getting to know PCB;
- and this one for the simulation;
- I also used this one for creating large "box symbols" (cpu, uart, etc)
I used gschem directly to create the new MOSFET symbol (IRLD024), since the original MOSFET symbol was graphic I though it would be better to use it instead of having a 4 pin box. I also wanted to keep both Drain connections separated if needed to use them in separate nets (although they are connected).
Using gEDA is still far from trivial as components, footprints, schematics symbols are all your responsibility, but still, I'm starting to like it. PCB also has a nice feature, you can print "photo mode" version of your PCB (yes, I know other software produces 3D views), here's mine top side.

2010-01-01

Happy New Year

A year has gone by, another year has arrived, hoppefully it will bring more posts and projects.
Happy New Year to all the readers and friends.