Archive for August, 2008

Very long-term backup fabbed with a reprap ?

Tuesday, August 26th, 2008

How will your personal data be readable 2.000 years from now ? The Long Now Foundation blogs about a nickel-based 3 inches-large disk that can reliably hold high amount of printed data for at least 2.000 years. Data is printed on it in small font : a 750-power optical microscope is required to read the pages !

On the other side of the blogosphere, the reprap community considers adding an ElectroChemical Milling (ECM) tool head to their home DIY 3D printers :

With this tool head, it could machine any conductive material, regardless of how hard it is or how high its melting point.

Maybe someday, personal very-long term backups will be printed at home ?

At the moment, industrial ECM/EDM machines can “achieve a one micron positional accuracy and wire EDM walls as thin as 0.010” (.254mm)” or (ECM) make holes/traces  as small as 0.2 mm large. I guess some progress is required before 750-power optical microscopes are required for reading data printed with this technology. But maybe that before 2.000 years from now, ultra-precision will be achieved by fabbers ? Id be curious of knowing which technique was used by the Long Now Foundation project and how difficult it would be to port this technique to the wonderful world of fabbers.

Rapid prototyping with microcontrollers ?

Monday, August 25th, 2008

I have no clue about micro-electronics and embedded systems. I am a Web application architect and developer, working with very high-level programming languages such as Python (or Perl or Java). I hardly remember assembly language from my childhood experiments with an Apple IIe and almost never touched C or C++. But I have been dreaming lately of rapid-prototyping some advanced non-Web application in an embedded system using my programming skills. So I thought I could share bits of my ignorance here. Please bear with me and give me some hints in order for me to best get out of darkness ! :)

Microcontrollers are now gaining capabilities that are comparable to microprocessors of early personal computers. The two most popular microcontroller (uC) series are Microchip PIC uCs and Atmel AVR uCs. For instance the PIC18F25J10-I/SO costs around 3 or 5 euros per unit at Radio Spares (I am in France: think RS in the UK or Allied Electronics in the USA). It has the following characteristics: 40 MHz, RS-232 capabilities (serial port), a “C compiler optimized architecture”, 48 kB of program memory (Flash mem) and around 4 or 5 kB of data memory (SRAM + EEPROM).

There are nice peripherals available, too. For instance this Texas Instrument CC2500 2.4GHz RF data transceiver (= transmitter + receiver) at around 2 to 3 euros per unit or current sensors approximately at the same price. In fact, periphals possibilities are limitless…

For free software hackers, there was a linux version for such chips : uCLinux. But is it still an active project ? I think I read that the comon linux kernel now includes everything that is required for it to run in embedded sytems. What about GNU utilities ? I know there are things like busybox on bigger but still embedded processors (phones). Anything equivalent on microcontrollers ?

There are simulators that will… let you pretend your desktop computer has a microcontroller inside, or sort of. :)

There is at least one C library for microcontrollers. C is considered as a “high-level programming language” in the embeddeds world ! That is to say that assembly language has been the norm. Some higher-levels languages can be used with microcontrollers, including some exotic-to-me Pascal-like languages like XPlo or PMP or Java-like but living dead things like Virgil and… what about my beloved Python ?

There are at least 2 projects aiming at allowing Python-programming on microcontrollers. pyastra is a “Python assembler translator” that can be used with some PIC12, PIC14 and PIC16 uCs. But it looks dead. Pymite looks sexier but not much more active :

PyMite is a flyweight Python interpreter written from scratch to execute on 8-bit and larger microcontrollers with resources as limited as 64 KiB of program memory (flash) and 4 KiB of RAM. PyMite supports a subset of the Python 2.5 syntax and can execute a subset of the Python 2.5 bytecodes. PyMite can also be compiled, tested and executed on a desktop computer.

At the moment, it seems like Python programming on microcontrollers is a dead end. Nothing worth investing time and efforts unless you want to also have to maintain a Python compiler… Same may be true for Java, not mentioning Perl. In fact, it seems to me that the object-oriented crowds are too far from microcontrollers applications to generate enough interest in initiatives such as Pymite, at the moment. Oh, and I am knowingly ignoring C++ which I did not investigate, having no experience in C++.

So what is left in terms of (open source) programming languages that would be of higher level than C ? The best guess I can make is Great Cow Basic, which is a free software Basic (procedural) language. Example programs look nice to me. It has been active recently. And it supports most of the chips I would consider experimenting with.

Next steps for me, I guess, would be to pick a PIC simulator and an IDE for Great Cow Basic (any eclipse plugin ?). Then I will probably have to figure out how a Basic program can be executed on a simulated PIC. And how a PIC simulator can be useful without all of the electronics that would surround it in any real setup. I’ll see that. When I have time to pursue my investigations and experiments in this micro-world.

And piclist is a great site for beginners.

3D scannerless scanning for fabbers

Monday, August 25th, 2008

For several weeks (or more), I have been dreaming of the day I’ll get my hands on a Reprap (self-parts-printing 3D desktop printer, a DIY fabber). I have been lucky enough to have a good friend promise me he would give his free time for assembling such a printer for me as long as I pay for the parts. 3 days of work are required to assemble the parts which you can order via the web in case you don’t already have access to such a reprap, which is my case. I will try to wait for the next major release of Reprap, namely Mendel 2.0 (current version = Darwin 1.0) unless I can’t resist temptation long enough…

Anyway, I have mainly been dreaming of possible applications of fabbers. Their use is extremely competitive (and disruptively innovative) as soon as you want to print customized 3D shapes which can’t be bought from the mass-manufacturing market. For instance, a reprap is cool when you want to print a chocolate 3D version of your face (see the Fab@Home project) or a miniature plastic representation of your home or anything that has a shape which is very specific to your case (not to mention the future goal of printing 90% of complex systems such as robots, portable electronic devices including phones and… fabber-assembling robots…). And this is where 3D scanning is a must : with a 3D scanner, you can scan an existing object and build a 3D model from it which you can then modify and print at the scale you want.

So my dreams lead me to this question : I could get a fabber some time soon but how to also get a desktop 3D scanner ? Some people have already started hacking home 3D scanners. But I had also heard of techniques that allow users to build 3D models from existing objects using either a single picture of the object, 2 pictures, several images or even a small movie. Some techniques require that the parameters of the camera(s) are known (position, angles, distance, …). Some techniques require 2 cameras in a fixed and known setup (stereophotography). Some techniques require that the camera is fixed and the object lies on a turntable. I really know nothing about computer vision and the world of 3D techniques so I was happy to learn new words such as “close-range photogrammetry“, “videogrammetry“, “structure from motion“, “matchmoving“, “motion tracking” (which is the same as matchmoving) or “3D reconstruction“. After some Web wandering, I identified several open source (of course) software packages that could offer some workable path from existing physical objects to 3D models of them using plain cameras or video cameras.

The idea would be the following :

  1. you take an existing, very personal object, for instance your head !
  2. with a common digital camera, you take pictures of your head from several angles
  3. you load these pictures into your favorite 3D reconstruction free software package
  4. it creates a 3D model of your head which you can then export to a 3D editor for possible adjustments (think Blender)
  5. you export your corrected 3D model into the reprap software stuff
  6. your reprap fabs your head out of plastic (or chocolate ?)

Here are the software projects I identified :

  • From a single image :
    • jSVR, Single View Reconstruction, a semi-automatic process for identifying and exporting three-dimensional information from a single un-calibrated image, dead project ?
  • Using a turntable :
  • From stereo images :
  • From a movie or a sequence of pictures :
    • e-Foto, a free GNU/GPL educational digital photogrammetric workstation, but is it suitable for close-range photogrammetry ?
    • Voodoo Camera Tracker, a tool for the integration of virtual and real scenes, estimates camera parameters and reconstructs a 3D scene from image sequences ; oops, this is not free software but freeware only
    • Octave vision, Algorithms for the recovery of structure and motion, using Octave, a one-shot development, no future…
    • Tracking / Structure from Motion, another piece of student homework
    • libmv, a structure from motion library, which plans to one day take raw video footage or photographs, and produce full camera calibration information and dense 3D models, very promising but being rewritten at the moment (August 2008)
    • GPU KLT a high-performance research implementation
  • Using the shadow of a stick (!) :
    • Scanning with Shadows (see also this site), wave a stick in front of a light source to cast a shadow on the object of interest, and figure out its 3D shape by observing the distortion of the shadow
  • Don’t know which technique is used :
    • OpenCV (see also this site), Intel’s Open Computer Vision library may some day contain some 3D reconstruction capabilities
    • Voxelization, a .NET based framework, designed for helping in development of different volume reconstruction, 3D voxel visualization and color consistency algorithms in multi view dynamic scenes, dead project ?

My personal conclusion :

I haven’t tested any of these packages. At the moment, there seems to be no easy-to-use free software package that would compare to commercial stuff such as Photomodeler or ImageModeler or research works such as Microsoft Photosynth. However these techniques and algorithms seem to be mature enough to become present as open source package soon, especially given the emerging interest in 3D scanning for fabbers ! Most promising free packages for scannerless 3D scanning for fabbers are probably Stereo and libmv.

What do you think ?

L’ANPE et les nouvelles technologies

Tuesday, August 12th, 2008

Pour créer ma petite entreprise avec une subvention ASSEDIC, je me suis inscrit comme chercheur d’emploi. Du coup, je reçois de temps à autre des mails de l’ANPE qui me recommande des offres d’emploi. Rien d’étonnant jusque là. J’ai été plus surpris cet été de recevoir un appel automatisé de l’ANPE sur mon répondeur téléphonique (en plus d’un mail). Ecoutez plutôt.

Ce que j’en pense : bravo à l’ANPE pour sa volonté d’utiliser au mieux les nouvelles technologies ; en l’occurence les appels téléphoniques automatisés me semblent une bonne idée pour tous ceux qui ne sont pas mail-dépendants ; par contre, il y a un réglage à faire pour ralentir le débit de la voix qui vous annonce la référence de l’offre d’emploi ! Essayez d’écrire cette référence sous la dictée de l’ordinateur de l’ANPE et vous comprendrez ! Ah, oui, encore un truc pour l’ANPE : prenez des leçons d’usabilité auprès de vos amis des ASSEDIC (vous êtes de la même maison, maintenant, non ?), car leur site est franchement mieux fait que

Alitheia core de SQO-OSS pour mesurer la qualité du code

Monday, August 4th, 2008

Un projet de recherche financé par la commission européenne (SQO-OSS) distribue, sous licence open source bien entendu, un logiciel qui analyse la qualité du code source d’un logiciel. Ce logiciel s’appelle Alitheia.

Alitheia parcourt des dépôts de code du style subversion/CVS (et notamment ceux de sourceforge). Des plugins fournissent des mesures du code (nombre de lignes de code, nombre de lignes de commentaires, etc.). Des modules d’Alitheia effectuent des statistiques à partir de ces mesures afin d’estimer la qualité globale du produit analysé. Alitheia se présente soit sous forme d’une application Web, soit, bientôt, sous forme d’un plugin pour Eclipse.

L’intérêt pratique d’Alitheia me semble actuellement limité: il y a peu de mesures disponibles dans la version de démo en ligne, la version pour Eclipse n’est pas encore disponible, les mesures sont effectuées au niveau de chaque fichier source et ne semblent pas encore agrégées au niveau du projet en lui-même (on peut savoir combien de lignes de commentaires il y a dans tel fichier mais pas dans le projet complet). Actuellement, la fonction la plus amusante semble être la mesure de la “productivité” de chaque développeur.

A terme, ce logiciel me semble très prometteur. Son intérêt dépendra essentiellement de la richesse des plugins de mesure disponibles, de l’existence d’un site public permettant de comparer entre eux les projets phare de sourceforge et tigris par exemple, et de la capacité d’Alitheia à produire des indicateurs agrégés significatifs. En ce qui concerne les plugins de mesure, j’espère qu’on va non seulement avoir des plugins mesurant des caractéristiques du code mais aussi (voire même surtout), des plugins mesurant la qualité de la communauté du projet: fréquence et délai des réponses sur les mailing lists, fréquentation du canal IRC de support, nombre et qualité des plugins et modules additionnels, durée de vie d’une version, etc. A suivre !

(via Le Monde Informatique)