Micro-cam or Web-croscope

Here you can discuss DIY adaptations to the microscope.
Post Reply
Message
Author
Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Micro-cam or Web-croscope

#1 Post by Joel_U » Mon Feb 22, 2021 7:51 am

Hello,
As Hobby Brewers, we use an old microscope to check our yeast. It works well but the brewery is not "microscope friendly" because of the moisture, dust, vibrations. Something simple, robuste and cheap could be a good solution. On the web I found this :
https://hackteria.org/wiki/DIY_microscopy
A webcam, just reverse the lens, 3 threaded rods, 3 springs, 3 screws, 2 pieces of wood and you get this :
Cam-croscope201.jpg
Cam-croscope201.jpg (25.76 KiB) Viewed 5993 times
You add a lamp, a Neubauer cell, a drop of yeast suspension and you get this :
comptage_levures_webcam.jpg
comptage_levures_webcam.jpg (38.77 KiB) Viewed 5993 times
We can easily count the yeast even if the light is far from perfect.
Counting is the first step but we also need to test the viability adding some methylene blue. Dead cells turn blue and the alive one stay translucent.
Probleme : I can only get pictures in gray levels, no colour. I changed the light, dimm, add a kind of diaphragme, check that the webcam is not a black and white. Whenn I put the lens the right way on the cam I get some colour meaning that the driver I use is ok.
Any idea how to get some colour ? Why I loose the colours just reversing the lens ?
I could go that way :
https://www.osapublishing.org/boe/fullt ... &id=429869
Using a webcam with a real microscope objective and an additional lens... But it is much more expensive than just reversing a lens.
Joël UGHETTO

Placozoa
Posts: 92
Joined: Tue Jan 05, 2021 10:41 am

Re: Micro-cam or Web-croscope

#2 Post by Placozoa » Mon Feb 22, 2021 8:26 am

My guess would be that you are shining the light through the colored (grey) plastic causing it to act as a filter. Did you try adding an additional top light? Maybe a little flashlight or something above shining down?

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#3 Post by MichaelG. » Mon Feb 22, 2021 8:41 am

.

I can’t guarantee it, Joel ... but

I think you would get much better results by adding a reversed lens to the the front of the existing lens.
This has been demonstrated very successfully [using iPhone] in the literature
... if I can find the link, I will post it here.

The loss of colour is probably because light is now reaching the sensor at the wrong angle.

Great project !

MichaelG.
.
.
Edit: __ Found it quicker than I expected
https://journals.plos.org/plosone/artic ... ne.0095330
Last edited by MichaelG. on Mon Feb 22, 2021 8:46 am, edited 1 time in total.
Too many 'projects'

MicroBob
Posts: 3154
Joined: Sun Dec 25, 2016 9:11 am
Location: Northern Germany

Re: Micro-cam or Web-croscope

#4 Post by MicroBob » Mon Feb 22, 2021 8:45 am

Hi Joël,
interesting setup!
The colours depend on the illumination beam. Then using weak objectives and removes the condenser from a normal biological microscope to illuminate the full image the colours become quite subdued while sharpness is still good. So you might need a better illumination with a focussed beam. This could be had when using a condenser lens e.g. a fat plano-convex lens. The light source musn't be point-like but an evenly lit surface of e.g. 40mm diameter. This could be an LED panel with a diffuser on top. The "objective" of the camera might also contribute. By not being achromatic it might lead to washed out colours. Perhaps you can use an objective from an old analog pocket camera or film camera?

Bob

Scarodactyl
Posts: 2775
Joined: Sat Mar 03, 2018 9:09 pm

Re: Micro-cam or Web-croscope

#5 Post by Scarodactyl » Mon Feb 22, 2021 8:42 pm

If you're getting no color at all I'd guess you hsve a hardware failure, either a bad cable or something inside the camera.

hans
Posts: 986
Joined: Thu May 28, 2020 11:10 pm
Location: Southern California

Re: Micro-cam or Web-croscope

#6 Post by hans » Tue Feb 23, 2021 4:45 am

Joel_U wrote:
Mon Feb 22, 2021 7:51 am
...check that the webcam is not a black and white. Whenn I put the lens the right way on the cam I get some colour meaning that the driver I use is ok.
Strange, ImageMagick indicates the image is greyscale:

Code: Select all

hans@uganik ~/Downloads identify -verbose comptage_levures_webcam.jpg 
Image:
  Filename: comptage_levures_webcam.jpg
  Format: JPEG (Joint Photographic Experts Group JFIF format)
  Mime type: image/jpeg
  Class: DirectClass
  Geometry: 640x480+0+0
  Units: Undefined
  Colorspace: sRGB
  Type: Grayscale
...
  Colors: 209
  Histogram:
    1: (36,36,36) #242424 grey14
    1: (44,44,44) #2C2C2C srgb(44,44,44)
    1: (45,45,45) #2D2D2D srgb(45,45,45)
    1: (48,48,48) #303030 grey19
    1: (50,50,50) #323232 srgb(50,50,50)
    2: (51,51,51) #333333 grey20
    1: (52,52,52) #343434 srgb(52,52,52)
    1: (53,53,53) #353535 srgb(53,53,53)
    2: (54,54,54) #363636 grey21
    4: (56,56,56) #383838 grey22
    1: (57,57,57) #393939 srgb(57,57,57)
What camera is it, exactly? Seems unlikely, but is there any possible way the camera could sense that the lens is removed, affecting the behavior of the software?

Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Re: Micro-cam or Web-croscope

#7 Post by Joel_U » Tue Feb 23, 2021 7:30 am

Thank you for all those comments.
This was an old project 2019, I haven't got the cam anymore BUT, I will soon scavenge/slaughter a new one :twisted:
To do : add a light condenser and an iris diaphragme.
Check the positionning of the reverse objective which has to be as perpendicular to the sensor as possible (I hope you understand what I mean).
Use a real microscope objective instead of the cam reversed one.
Come back and give you a full account of my actions.
Joël UGHETTO

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#8 Post by MichaelG. » Tue Feb 23, 2021 10:48 pm

MichaelG. wrote:
Mon Feb 22, 2021 8:41 am
.

I can’t guarantee it, Joel ... but

I think you would get much better results by adding a reversed lens to the the front of the existing lens.

[ etc. ]
.

I’m glad I didn’t offer that guarantee !!

Although the idea demonstrably works with the iPhone lens, my quick & dirty attempt [today] with a cheap little webcam was a miserable failure. ... I suspect that the ‘beauty ring’ on the front of each lens means the front elements are too far apart.

[ further butchery is required; I will report back if I have any success ]

MichaelG.
Too many 'projects'

Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Re: Micro-cam or Web-croscope

#9 Post by Joel_U » Wed Feb 24, 2021 7:20 am

Thank you very much for this report Michael.
Last year I tried the Smartphone + reverse smartphone lens proposed in the publication. I have not been able to obtain any good result. I probably failed positioning correctly the 2 lenses + the sample + a good illumination at the same time.
Obtaining the first picture (Neubauer cell and Yeast) was really easy and I could reproduce it. In the publication, they show well stained cheek cells. We would like to see yeast... Very different stuff (size, color, contrast) :oops:
Feel free to report your attemps in this post. Negative results are as important as positive one ... And in my case much more numerous.
Joël

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#10 Post by MichaelG. » Wed Feb 24, 2021 9:38 am

.

Here’s a useful description of what Joel is doing:
https://www.whitelabs.com/beer/cell-cou ... ty-testing

MichaelG.
.

P.S. this is an interesting model of Yeast: https://youtu.be/OWiZU_DZzAU
Too many 'projects'

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#11 Post by MichaelG. » Wed Feb 24, 2021 11:20 pm

This is a VERY crude first step ... but I think it's one in the right direction

I removed the 'beauty rings' from two lenses [one for the webcam, and a spare] ...
This enabled them to be mounted face-to-face; closer together than before, but obviously still not close enough.

The lens on the camera is screwed fully home, so is maybe focussed on infinity
... and the supplementary lens then converts it into a 1:1 'macro' lens.

Hopefully, if I can trim the 'hoods' and get the front elements closer together; the vignetting will be dramatically reduced

Meanwhile: Here's an image of my iPad screen [264 pixels per inch = approx 96 micron pitch]
.
Crude 640x480 webcam experiment
Crude 640x480 webcam experiment
Photo on 24-02-2021 at 22.40.jpg (55.75 KiB) Viewed 5818 times
.
... and, for comparison, a link to a much better one:
https://www.anandtech.com/show/5689/the ... analysis/2
[click the third image for a full picture, with scale-bar]

We're not there yet ... but watch this space

MichaelG.
.

Edit: corrected the micron pitch value
Too many 'projects'

Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Re: Micro-cam or Web-croscope

#12 Post by Joel_U » Thu Feb 25, 2021 5:07 pm

With the last "murdered webcam", just reversed the front lens and moved away 4mm from the sensor . Hand held smartphone, I was able to take this picture of the smartphone screen.
2021-02-25-132638.jpg
2021-02-25-132638.jpg (55.23 KiB) Viewed 5789 times
Image is blurry but with a steady stage it should be better. One hand holding the phone, one hand on the mouse to click just in time when it is focused and one hand for my beer ... Microscopy ? Not an easy job at all !
With the same geometry I also took a picture of my calibration slide and mesuring the distance on the screen I found an enhancement about 600X. I use two washers to move the lens away from the sensor.
20210225_181136bis.jpg
20210225_181136bis.jpg (101.52 KiB) Viewed 5786 times
Give me, please, some time to learn about pixels, resolution and all that stuff . I am highly incompetent but I try to take care of myself. :oops:
My samsung A31 is 6,4" 2340*1080 pixels DPI 430 Super Amoled :lol:
Does that mean that each red, blue or green dot on the picture mesures around 63µm ??? :ugeek:
Joël

Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Re: Micro-cam or Web-croscope

#13 Post by Joel_U » Thu Feb 25, 2021 6:48 pm

With the same setup, some cheek cells (no stain). Always hand held.
Cheek_Cells.jpg
Cheek_Cells.jpg (73.43 KiB) Viewed 5781 times
Joël

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#14 Post by MichaelG. » Thu Feb 25, 2021 7:41 pm

The reason I am playing with the little webcam [aside from me being a cheapskate] is to understand the optical possibilities

The 640x480 pixel sensor on this one is physically small

.
Webcam Sensor : Probably 1/9” format
Webcam Sensor : Probably 1/9” format
BB4AC3F9-BB15-4D2E-92B1-048B0357A357.jpeg (70.32 KiB) Viewed 5772 times
.
I have not identified the chip, or put it under the microscope, but [scaling from the 18mm mount centres] it looks like 1/9” format, which would therefore have pixels at 2.5 micron pitch.
... if I can get the lenses working at 1:1 that would be useful microscopy.

Can’t explore it any further until I machine the ‘lens hoods’ off
[ to get the front elements closer together ]

MichaelG.
Too many 'projects'

MichaelG.
Posts: 3976
Joined: Mon Apr 10, 2017 8:24 am
Location: North Wales

Re: Micro-cam or Web-croscope

#15 Post by MichaelG. » Thu Feb 25, 2021 7:51 pm

Joel_U wrote:
Thu Feb 25, 2021 5:07 pm
Does that mean that each red, blue or green dot on the picture mesures around 63µm ??? :ugeek:
Joël
.
Not quite ... The individual RGB dots are sub-pixels, and your pixel pitch is the distance between the clusters.

Have a good look at the scale bars on that page I linked yesterday.

... or even this:

.
pixel pitch : iPad Pro 9.7”
pixel pitch : iPad Pro 9.7”
69569229-4FFE-4D1F-AD79-B06F4CBD468A.jpeg (33.59 KiB) Viewed 5769 times
.

MichaelG.
Too many 'projects'

Joel_U
Posts: 13
Joined: Wed Feb 10, 2021 2:25 pm

Re: Micro-cam or Web-croscope

#16 Post by Joel_U » Mon Mar 01, 2021 4:58 pm

With my last setup, this camera :
https://fr.aliexpress.com/item/40006315 ... 6c37iMEsLn
I reverse the objective and I get some colours :D
Yeast_MB01.jpg
Yeast_MB01.jpg (56.2 KiB) Viewed 5738 times
It is some yeast dead and alive and methylene blue...
Problem, lack of contrast, poor definition and some "round artefacts" the same size as the yeast :evil:
The lenses in the objective I use are probably crappy plastic stuff, I would like to find the same kind of objective but with a better quality.
Any idea ?
Joël

Post Reply