PC Interfacing a GameBoy Camera

 by Technoshaman
Featured
GL.jpg
top.jpg
3D2.gif
Here's another past project of mine from a couple of years ago. At that time I was looking for a low-res camera for simple robotics image processing, and all I had experience with was PIC (12, 16, and 18) microcontrollers. So I didn't really get to work on the images real time (not enough RAM or speed, and I could not find any suitable SRAM around at that time). I think I'll revisit this project later on using my new TI Stellaris Board.

The system consists of a GameBoy Camera (Mitsubishi M64282FP Image Sensor with hardware image processing), an ADC0820 high-speed ADC to convert analog pixel values to digital (the sensor outputs pixels as 2.0V p-p analog values), a LM385-2V5 2.5V micropower voltage reference IC, a PIC18F4620 for processing the digital values to send them later on to a PC via the serial port (or USB with a RS-232 - USB converter).

The PC part of the project is a program (uses OpenGL to display the received image, the height of the pixels change according to brightness to have a fake 3D effect = Depth Mapping) written on Borland C++  Builder. I also still have the simple test programs written in Processing (brightness tracking, etc.). All will be attached.
 
Remove these adsRemove these ads by Signing Up

Step 1:

flow.jpg
b_track_2.gif
gbcam_pinout.jpg
Since the code and the schematics are self explanatory, and the datasheet for the MCU and the image sensor are rather informative, I'm not going to get into much theory here (as always, questions are answered). Here's the flowchart of the system, which explains what's going on.  Ignore the USART part (old version), registers are set up from the MCU :) And an animated GIF image showing brightness tracking done with this camera in Processing.

The first thing to do before you start is to create a suitable connector for the camera (after opening the cartridge structured box with a tri-wing screwdriver and disconnecting / removing the camera from the main structure). I attached a picture of the pinout, so many people used this image, so I don't know who to give the credit (here's one http://www.seattlerobotics.org/encoder/200205/gbcam.html). I used an IDC-10 connector to connect it to my old PIC board (from another project). 

In the next step we'll be looking at the schematics and how the system actually functions.
chipper35 says: Dec 30, 2012. 7:17 PM
Man, I haven't seen a good old programming logic flowchart in a while!! Nice, old skool!
Technoshaman (author) in reply to chipper35Dec 30, 2012. 11:04 PM
Thanks a lot :)
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!