I just finished my Smiley-O-Mat - it's a tin-box with 3 turning knobs that allows you to controll the appearence of a smiley. With 3 simple turns I can now tell your co-workers, familymembers, ... how you feel at the moment and if it is wise to talk to me right now :-)
The controllerbox is made with an arduino, the smiley generator is written in processing, and the turning knobs are printed on my makerbot
This is what the controller looks like
and here are some smileys i generated
read more ...
I always considered barcode scanners as a pice of rocketscience that mere mortals like me aren't able to build. But this weekend megalomania hit me and i wrote one in processing. I didn't use any libraries beside GSVideo (on my linux box) or processing.video (wherever quicktime is available)
My barcodescanner is able to decode a subset of the code128 barcode. it shows all printable characters and it supports all three charsets, but i didn't include all those Bell, Stx, Enq, .. character. feel free to add support for them if you need it :-)
The program assumes that the barcode is placed in the middle of the camera image. It takes the middle row of pixels and converts it to black and white. then it calculates the width of the black and white bars and searches for a barcode startsequence. if it finds one it tries to match the next six bars with the code128 patterns and adds the value of the character that has the highest match to a stringbuffer.
when a stop character is found it calculates the checksum and if that matches it returns the found string (minus the checksum char).
sounds a lot more complicated than it actually is. the hardest part was turning the row of pixels into an array of black and white values.
The code is not really beautifull and it is a bit long because of the big char tables.
click here to download the code.read more ...
i have used processing to access map materials from geoserver. but i have noticed that the earth is not flat and that processing is making 3d animations really easy :-)
so i have coded a rotating sphere and project the GIS data from geoserver on the surface
flat map from my last sketch
spherical map from the new sketchread more ...