spectralworkbench.org diy spectrophotometer

141 views
Skip to first unread message

Mac Cowell

unread,
Feb 4, 2013, 3:49:23 PM2/4/13
to diy...@googlegroups.com
What do you all think about the Public Laboratory for Open Technology and Science (PLOTS) spectrophotometer design?

They have developed instructions for building a basic spectrophotometer from a low-cost webcam, electrical-conduit housing, and a fragment of a DVD as a diffraction grating.  Seems like the devil is in the details for something like this and they have paid a fair amount of attention to the details.

Build instructions: http://publiclaboratory.org/wiki/dsk

What about calibration?  I think I missed that step in their instructions...

Mac Cowell

unread,
Feb 4, 2013, 3:52:45 PM2/4/13
to diy...@googlegroups.com
Ah ha, calibration instructions! http://publiclaboratory.org/wiki/spectral-workbench-calibration

Well I'm interested in building one of these to play with.  Will let you all know how it goes.

Simon Quellen Field

unread,
Feb 4, 2013, 4:12:53 PM2/4/13
to diy...@googlegroups.com
This may well be sufficient for most DIYBio applications.
It has low resolution (5 to 10 nm) so applications that need sub-nanometer resolution are out of the question (doppler astronomy, etc.).
The low resolution masks focus problems (different wavelengths focus at different distances, so one usually tilts the camera with respect to the grating, while this design has the image plane parallel to the grating).
It could easily be made self-calibrating by imaging mercury vapor lines in the top half of the image, and the sample in the bottom half, and adding a little software.
Since it is video, there is no way to let the sensor integrate a faint image over several seconds as there is when using a still camera, so the brightness of the sample could become a problem. Longer exposures are often useful when doing long range spectroscopy (to identify pollutants in smokestacks, e.g.).

Quite a nice project for $15.


-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



--
-- You received this message because you are subscribed to the Google Groups DIYbio group. To post to this group, send email to diy...@googlegroups.com. To unsubscribe from this group, send email to diybio+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/diybio?hl=en
Learn more at www.diybio.org
---
You received this message because you are subscribed to the Google Groups "DIYbio" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diybio+un...@googlegroups.com.
To post to this group, send email to diy...@googlegroups.com.
Visit this group at http://groups.google.com/group/diybio?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Josiah Zayner

unread,
Feb 4, 2013, 5:17:42 PM2/4/13
to diy...@googlegroups.com
One major issue is the lack of data on the spectral response of the camera/cameras. CCDs respond to different wavelengths of light differently. Difficult to analyze any data obtained using diffraction grating because of that unless a spectral response curve is measured.

Simon Quellen Field

unread,
Feb 4, 2013, 7:31:56 PM2/4/13
to diy...@googlegroups.com
That's what calibration is for.

But for DIYBio purposes, often what you want is simply a ratio of the values at two different wavelengths, and even that can be plus or minus 10 percent and you are still happy.

Identifying certain dye molecules like the chlorophylls is a matter of looking for peaks at certain wavelengths. The same goes for emission or absorption lines for chemical elements and simple compounds. For that, calibrating using mercury vapor lines is pretty easy, and the device under discussion has calibration procedures and software designed for that (the one on my web site self-calibrates automatically). As you can see from the spectrograms on that site, my design gets sub-nanometer resolution on the peaks for things like sharp emission lines. And it is similarly inexpensive, at the cost of some inconvenience. The device under discussion is more compact, and plugs nicely into your USB port for automatic analysis. Replacing the DVD with some high resolution diffraction grating (and tilting the grating to get better focus at different wavelengths) might go a long way to increase its resolution.

-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



--
-- You received this message because you are subscribed to the Google Groups DIYbio group. To post to this group, send email to diy...@googlegroups.com. To unsubscribe from this group, send email to diybio+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/diybio?hl=en
Learn more at www.diybio.org
---
You received this message because you are subscribed to the Google Groups "DIYbio" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diybio+un...@googlegroups.com.
To post to this group, send email to diy...@googlegroups.com.
Visit this group at http://groups.google.com/group/diybio?hl=en.
To view this discussion on the web visit https://groups.google.com/d/msg/diybio/-/XtihuLWK_fcJ.

Dakota Hamill

unread,
Feb 4, 2013, 7:41:31 PM2/4/13
to diy...@googlegroups.com
Could this be used to measure turbidity for optical density measurement?

Josiah Zayner

unread,
Feb 4, 2013, 8:35:33 PM2/4/13
to diy...@googlegroups.com
Simon that is wavelength calibration I am talking about intensity/amplitude calibration. The fact that CCDs used in cameras do not have a linear response to light across the spectrum makes it even more difficult. See: http://www.maxmax.com/spectral_response.htm for an example of what I am talking about.

Simon Quellen Field

unread,
Feb 4, 2013, 8:40:48 PM2/4/13
to diy...@googlegroups.com
Easily.

If you are trying to reproduce an experiment by following a protocol in a published journal, they might be specifying something like an optical density at 600 nanometers of 2.
That would mean the sample blocked 99% of the light (optical density is measured in log 10 of the ratio of light in to light out). An optical density of 3 means 99.9% of the light is blocked. Basically, you count the number of nines.

So you put your broth containing no bacteria in the spectrophotometer, and take a reading, noting the value at 600 nanometers (deep red). Then you put your sample of bugs and broth in the light path and take another reading.

Divide the second reading by the first.

Now a spectrophotometer such as the one under discussion has no way of delivering RAW images -- web cams only give you JPEGs. So you will only have 256 levels to work with. If your sample is OD 2, and your blank gave you a reading of 250, your sample will give you a reading of 2. As you can see, using the webcam device will not be able to tell you much about higher densities.

A device like the one on my website could be modified to use RAW images, giving you 14 bits per pixel. So the blank might give you a reading of 16,300, and the sample would read 163 for OD 2, and 16 for OD 3.

You can extend the range if you have a dimmer on the light source, and you have calibrated the dimmer with the spectrophotometer, so you know what settings give you 100% of the light, 10% of the light, and 1% of the light. A red LED and some resistors on a rotary switch would do the trick. Now you take a reading of the blank using 1% of the light, and a reading of the sample using 100% of the light, and you get to OD 4 using the simple webcam version of the device.

Generally you might be looking for the log growth stage of your sample. In that case, anything in the 600 nm to 650 nm range will do nicely, and you don't need to bother with a spectrophotometer. Use a cheap red laser and the resistors, and a cadmium sulfide photocell and a cheap multimeter. The red laser has a nice sharp spectrum peak and little else, and it is probably much sharper than the spectrophotometer is (sub-nanometer).

You could build a probe out of some plastic optical fiber. The laser goes into one bit of fiber, and exits into the sample. A millimeter from the exit is another fiber end, conducting the light up to the photosensor. You dunk the probe into the beaker of bugs and broth, and let a microcontroller monitor the optical density and look for logarithmic change, whereupon it beeps or lights an LED. You can run the laser (or a red LED) from different output pins on the microprocessor, each one giving you 10 times more light than the last one, through the use of different resistors attached to each one. A microcontroller like the Ti430 Launchpad (cost is $4.30 for the USB enabled development board) has a 10 bit analog to digital converter, and 16 output pins, giving you a possible accuracy of 26 bits, assuming you can control the brightness of the LED using the 16 bits and get all of the range. That gets you to OD 7, where 99.99999% of the light is blocked.
But if you only need OD 2 or 3, the 10 bit ADC and maybe three output pins will easily get you there. And it could send the data back to your laptop computer for graphing or recording by printing to the USB port in humanly readable ASCII.

-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



On Mon, Feb 4, 2013 at 4:41 PM, Dakota Hamill <dko...@gmail.com> wrote:
Could this be used to measure turbidity for optical density measurement?
--
-- You received this message because you are subscribed to the Google Groups DIYbio group. To post to this group, send email to diy...@googlegroups.com. To unsubscribe from this group, send email to diybio+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/diybio?hl=en
Learn more at www.diybio.org
---
You received this message because you are subscribed to the Google Groups "DIYbio" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diybio+un...@googlegroups.com.
To post to this group, send email to diy...@googlegroups.com.
Visit this group at http://groups.google.com/group/diybio?hl=en.

Simon Quellen Field

unread,
Feb 4, 2013, 9:02:52 PM2/4/13
to diy...@googlegroups.com
Not as much as you might think.
The camera already compensates for that in software.
Otherwise, photos would look wrong.

But generally two wavelength measurements are taken at fairly small wavelength differences, where the spectral response does not differ much. To assess the purity of a DNA/RNA sample, for example, the ratio of 260 nm absorbance to 280 nm absorbance is used. If that ratio is 180:100, the sample is pure DNA, and if it is 200:100, the sample is pure RNA. In a 20 nm range, the spectral response is the same to a fraction of a percent, and what we are looking for is a 20% difference. But even that 20% is just a rule of thumb. It is based on the absorbance of the individual nucleotides:
Guanine:  1.15
Adenine:  4.50
Cytosine: 1.51
Uracil:   4.00
Thymine:  1.47
So if your DNA strand had a lot of A and your RNA had a lot of G, you could be just plain out of luck. The rule of thumb assumes a random distribution of nucleotides.

The way you use your home-built spectrophotometer is by calibration. If you had samples of pure nucleotides, you would do the 260/280 reading, and find out what multiplier gave you 4.5 for adenine and 1.15 for guanine, and you are all set -- that automatically controls for the spectral response of your sensor.

-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



Simon Quellen Field

unread,
Feb 4, 2013, 9:28:06 PM2/4/13
to diy...@googlegroups.com
Another fun thing for DIYBio hackers to build might be a Lambda integrator:

It looks to me like a pH meter and a syringe pump full of HCl connected to a microcontroller should do the trick.

And if we wanted to build an optical density meter, it occurred to me that the two optical fiber method I described earlier could be modified by adding a micrometer to adjust the separation between the two fibers. The difference between absorbance with a millimeter distance and with a 25 millimeter distance is enormous. A stepper motor turning the micrometer knob could get you highly accurate readings from OD 1 through OD 10 or higher. And it still just dips into the beaker, and is easy to clean and sterilize. No cuvettes or spectrophotometers needed. Just a cheap red LED and a photodetector, and a bit of plastic optical fiber, and a micrometer you can get at the hardware store for a couple bucks. Salvage a stepper motor from an old printer. Do the whole project for maybe $20, microcontroller included.

Each time you double the distance, you get another bit of accuracy. Each revolution of the micrometer in my hand at the moment gives me one millimeter. If the stepper motor has 180 steps per revolution, that gives us 5.555 microns per step. The micrometer range is 25 rotations, giving us 4500 steps. That's 12 doublings, or 3.65 OD steps. Add to that the 10 bits from the A to D converter in the Ti430 Launchpad, and we get 22 bits of range. That gets us to OD 6.62, or better than 99.9999% of the light blocked. With an error less than 1 in 4 million.

-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



Dakota Hamill

unread,
Feb 4, 2013, 9:59:58 PM2/4/13
to diy...@googlegroups.com
You could build a probe out of some plastic optical fiber. The laser goes into one bit of fiber, and exits into the sample. A millimeter from the exit is another fiber end, conducting the light up to the photosensor. You dunk the probe into the beaker of bugs and broth, and let a microcontroller monitor the optical density and look for logarithmic change, whereupon it beeps or lights an LED. You can run the laser (or a red LED) from different output pins on the microprocessor, each one giving you 10 times more light than the last one, through the use of different resistors attached to each one. A microcontroller like the Ti430 Launchpad (cost is $4.30 for the USB enabled development board) has a 10 bit analog to digital converter, and 16 output pins, giving you a possible accuracy of 26 bits, assuming you can control the brightness of the LED using the 16 bits and get all of the range. That gets you to OD 7, where 99.99999% of the light is blocked.
But if you only need OD 2 or 3, the 10 bit ADC and maybe three output pins will easily get you there. And it could send the data back to your laptop computer for graphing or recording by printing to the USB port in humanly readable ASCII.

Thanks for all that, plus the stuff above!  You are a physics wizard.

I guess I need to do some more reading on exactly what would be needed but, I have a photo-resistor + a red laser laying around doing nothing so maybe that'll be the start.

Jonathan Cline

unread,
Feb 15, 2013, 10:53:35 PM2/15/13
to diy...@googlegroups.com, jcline


On Monday, February 4, 2013 1:12:53 PM UTC-8, Simon Field wrote:
This may well be sufficient for most DIYBio applications.

Using a DVD.
Why not use a real grating?
As in:
   http://www.asdlib.org/onlineArticles/elabware/Scheeline_Kelly_Spectrophotometer/index.html


## Jonathan Cline
## jcl...@ieee.org
## Mobile: +1-805-617-0223
########################

Simon Quellen Field

unread,
Feb 16, 2013, 11:29:11 AM2/16/13
to diy...@googlegroups.com
Or here: "http://sci-toys.com/scitoys/scitoys/light/spectrograph/spectrograph.html".
:-)

-----
Get a free science project every week! "http://scitoys.com/newsletter.html"



--
-- You received this message because you are subscribed to the Google Groups DIYbio group. To post to this group, send email to diy...@googlegroups.com. To unsubscribe from this group, send email to diybio+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/diybio?hl=en
Learn more at www.diybio.org
---
You received this message because you are subscribed to the Google Groups "DIYbio" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diybio+un...@googlegroups.com.
To post to this group, send email to diy...@googlegroups.com.
Visit this group at http://groups.google.com/group/diybio?hl=en.
To view this discussion on the web visit https://groups.google.com/d/msg/diybio/-/upJgZinHin8J.

Jonathan Cline

unread,
Feb 16, 2013, 2:41:50 PM2/16/13
to diy...@googlegroups.com

On 2/16/13 8:29 AM, Simon Quellen Field wrote:
Or here: "http://sci-toys.com/scitoys/scitoys/light/spectrograph/spectrograph.html".
:-)

I wonder if html5 with opengl would allow you do to the picture analysis on the local PC rather than the server side, anyone with knowledge of the latest html5 api's want to pipe up?  The other example from spectralworkbench also required a server side web app which is also an electronic leash.

I like yours, compared to this $$$ one $$$
http://www.orbeco.com/water/products/spectrophotometer-sp600
Reply all
Reply to author
Forward
0 new messages