open the pod bay door HAL

I'll probably never buy myself the Mindstorms sets, especially after a very kind person donated theirs to me. However, the idea of actually building my own computer LEGO brick does appeal. Robotic LEGO is nothing new. Years ago, back in 1985 a book called "Make and program your own robots" by William Clark was published. I expect this is long since out of print. It used LEGO and the good old Sinclair ZX-Spectrum computer. Since then others have used a variety of different methods to control their LEGO models.
My first attempt was simply an array of 16 relays that plugged into the parallel port and controlled via QBASIC. The circuit was based on that given in the book I mentioned above Needless to say, it was only useful for stationary models and I never managed to successfully take the result of an input such as a switch event back to the controlling program. This was either something to do with interfacing via QBASIC or more likely a dodgy piece of wiring on my part.
Technology moves on and now you can get groovy microprocessors for next to nothing. So it's back to the drawing board. The computer brick I want to build will have 6 inputs and 6 outputs and, all being well, will be able to use existing Mindstorms sensors. At the moment the plans are no further than a drawings-on-paper stage, but one of these days a prototype will get built, It will replace the parallel port interface I designed and built a few years ago.
The "brains" of the brick will be the Basic Stamp module. This is based on the Pic microprocessor, but has the added advantage that it has an in-built basic language interpreter, making programming it much simpler. Unfortunately the chips don't come cheap and are around 40 pounds sterling. I anticipate that the total cost of building my own RCX will be around 80 pounds, still half the price of Mindstorms though.
I plan to put the electronic "brains" inside one of the old 4.5V battery boxes. Whilst I have a couple of my own they are often available on Ebay.
Using the LEGO wire connectors, it will be possible to put 6 inputs and 6 outputs on top of the battery box. The positions of these are shown by the white and grey 2x2 plates.
The wire connectors can be opened. The two metal strips allow a soldered connection to be made, should you need to do this, and for the wire to run straight into the battery box and to the electronics.
The following video shows the 'RCX' in action controlling a train. I used a simple class written in C to control input and output of the parallel port. The track-side switches, when triggered, stop the train for a few seconds and depending on which switch was pushed, the train the either continues in the same direction or reverses.

I've also got a couple of pictures of my first RCX, the circuit schematic and the design ideas for my new (one day) microprocessor RCX, just in case you're interested. I'd forgotten how the wiring inside resembled spaghetti!