CMOS imaging chips have been steadily improving, their cost and performance being driven by the highly competitive smartphone industry. As CMOS sensors get better and cheaper, they get more interesting for hacker lab projects. In this post I’m going to demonstrate a few applications of the high-resolution sensor that you’ve already got in your pocket — or wherever you store your cell phone.
CMOS vs CCD
First lets quickly review image sensors. You’ve probably head of CMOS and CCD sensors, but what’s the difference exactly?
As the figure above shows, CCD and CMOS sensors are both basically photodiode arrays. Photons that hit regions on the chip are converted into a charge by a photodiode. The difference is in how this charge in shoved around. CCD sensors are analogue devices, the charge is shifted through the chip and out to a single amplifier. CMOS sensors have amplifiers embedded in each cell and also generally include on-chip analogue to digital conversion allowing complete “camera-on-a-chip” solutions.
Because CMOS sensors amplify and move the signal into the digital domain sooner, they can use cheaper manufacturing processes allowing lower-cost imaging chips to be developed. Traditionally they’ve also had a number of disadvantages however, because more circuitry is included in each cell, less space is left to collect light. And because multiple amplifiers are used, it’s harder to get consistent images due to slight fabrication differences between the amplifiers in each cell. Until recently CMOS sensors were considered a low-end option. While CCD sensors (and usually large cooled CCD sensors) are still often preferred for scientific applications with big budgets, CMOS sensors have now however gained in-roads in high performance DSLRs.
It’s always interesting to see how much can be done with CMOS sensors though. A recent article described the imaging of single molecules of DNA stretched on a surface using a mobile phone camera. These results are pretty impressive when you consider that each fragment is only 10 microns long (0.01mm). The researchers 3D printed an attachment for the phone which included a blue excitation laser. This laser was used to illuminate DNA which had been stretched out on a surface and stained with a fluorescent dye. When illuminated the dye lights up green and passes through a filter and magnifying lens where it is detected by the phones camera.
While this is one extreme, others have suggested using cheap mobile phone based microscopes for pathogen detection, and a cheap mobile phone based fluorescent microscope would make a neat hacker tool (I know a number of people are considering kickstarting just such a project, so if you’re interested leave a comment below!).
However, if you’re less interested in fluorescence and more interested in a general purpose cheap microscope, a number of other options are available. Inspired by Kurt’s post of his Echolabs phone microscope, I’ve been playing with his and other phone based microscopes.
I believe the Echolabs microscope was originally a freebie given away at tradeshows. However it’s now available from their site for $10. The microscope comes as a flat packed laser cut kit. While it can be a little fiddly to assemble there’s a great assembly video available and it shouldn’t take more than 15 minutes or so.
The project is great fun, and definitely and interesting project, but how good is its performance as a microscope. In order to investigate this, Kurt introduces the USAF1951 resolution target. The USAF1951 target is a slide on which is marked with features of ever decreasing size. I got mine from Thorlabs.
This target allows you to determine the smallest feature that you can resolve with your microscope. Somewhat ironically the target will cost you many times more than the Echolabs microscope, but if your interested in these things it’s a useful calibration standard to have around.
The image I acquired using the wooden microscope is shown below on the left. This is the inner set of targets from the USAF1951, the first level down. Like Kurt I was able to just about resolve group 5 element 2. Each line here is 36 microns thick (0.036mm). That’s not bad for $10!
On a whim, and hoping to have a small inspection loupe which I could carry around, I also picked up an Olloclip macro pro lens. While I can faintly hear muffled cries of “that’s not a hack”, a good inspection loupe is an invaluable hacker tool. I also thought it would be interested to see how it performed with the USAF1951.
The image above right shows the USAF1951 target captured with this lens on the iPhone 6S. While significantly more expensive than the Echolabs microscope, the Olloclip shows that the iPhone optics can be pushed a bit further. All of group 5 is clearly visible and if you zoom in, group 6 element 2 can clearly be discerned. This is a linewidth of about 7 microns (0.007mm). Both the better illumination possible with the Olloclip, and the improved optics probably help.
Capturing Images from Your Traditional Microscope
While imaging micron-scale features is great fun, the microscope I use most often is a general purpose inspection microscope for inspecting components and SMD rework. Often I want to take a quick snap of a piece of work too, either to document my progress or highlight a fault. In the past I’ve struggled to jam mobile phones against the eye piece lens in order to take a picture. Surprisingly this kind of works, but it’s a fiddly and awkward process.
While I’ve used eyepiece C-mount adapters and cheap CCD imagers from Shenzhen. The results were less than ideal, and I often just want to take a quick snap and upload it. Surprisingly there are clamps which make the jam phone against eye piece process a little more robust (though they are surprisingly expensive). There has to be a 3D-printed alternative for this one.
Still, after some fiddling the clamp can produce quite reasonable images. The picture below shows 0.8mm pitch pins on a TQFP IC.
Hopefully this short review of phone based microscopy has given you some inspiration. I’d love to hear about more optics based hacker projects. How have you put your old cell phone’s camera to use? If you know of any cool projects, or are planning one, please comment below!