Fancy microscope autofocusing using offset LEDs

This seems like a neat addition that could be made to many microscopes here. You have an array of LEDs shining through a sample, take a photo lit by one led and then another, combine the photos with some fancy math that gives an interference pattern, then measure the interference pattern to get an offset for optimal focus!

https://phys.org/news/2026-04-hidden-stripe-pattern-microscopes-auto.html#google_vignette

1 Like

Amazing find!

This would combine perfectly with the similarly implemented microscope showcased in Applied Science.

It blew my mind.

Add.: actually it looks like they were already doing Fourier ptychography and came across this autofocus method. Nice :stuck_out_tongue:

Funny that you saw that, as today I was looking at the white LEDs disposition on the Mothbox pro PCB and I think you can do some fancy Photometric stereo pictures by turning only one or a few LED at the time, and then combine the pictures to make a 3D surface map of the insects ( Photometric stereo - Wikipedia and https://pages.cs.wisc.edu/\~csverma/CS766_09/Stereo/stereo.html ). Maybe it could even possible to increase the sharpness of the pictures.
Talking about LEDs, I’m pretty sure that the 365 is quite useless, as the plexiglass will block 99.99% of its transmission.

We tested our plexi with a cheap photospectrometer, and it seemed to let 365 through fine. The cutoff seemed to be more around 330

We tested our plexi with a cheap photospectrometer, and it seemed to let 365 through fine. The cutoff seemed to be more around 330

I believe it varies depending on the specific UV stabilizers/blockers added to the PMMA by the manufacturer. It might be a good idea to tell people making their own to use those cheap UV-B phosphor cardboard test cards to check if they light up through the acrylic they plan to use :slight_smile:
Edit: If you want an even lower tech method then very dry starchy foods (which yes, I know is a challenge where you live) like crackers or possibly papadam (or other things that swell up when cooked in oil) will fluoresce at around 365 nm so should work too but will need better darkness. Their glow will actually persist for a second or two after turning off the UV source as well if the UV is bright enough.

If there’s ever a need to do more precise (fluoro)spectrophotometric testing then let me know as I have a some decent equipment for this purpose in my Oakland lab.

Also, super interesting technique in the original post!

1 Like

330? that’s an amazing plexiglass. the stuff we buy here is more or less on the standards of PMMA https://cds.cern.ch/record/1214725/files/PH-EP-Tech-Note-2009-003.pdf

I tattooed a built in tester to my hand for this reason

2 Likes

Amaaaaaziiing!

btw, I looked at the repo and it’s vibe-coded in matlab :S