166Views5Replies

Author Options:

Need help with DIY spectrophotometer. Data not what was expected. Answered

Hi All,

I am interested in spectrophotometry and made several colourimeters, however I am busy making my first true polychromatic spectrophotometer. I have built a decent working prototype using a incandescent bulb, a photodiode with transimpedance op-amp, a diffraction grating, and a stepper motor inside an enclosure. The arduino steps or scans the sensor across the spectrum and finishes just after the zero order light (see graph 'blank' spectral response, the small bump is the fringe pattern and the big peak is the zero order light). I am testing red, blue, and green filters with very specific wavelengths to calibrate it, but the data is not what I have expected. I even tried scanning some KMnO4 (which has a distinctive double peak) but the pattern doesn't quite match.

What I expect to see when I use each filter is three distinct and separate peaks which are clearly spaced apart from each other, however the green and the blue overlap significantly. The red seems to match the transmission spectra from the datasheet. Why do the blue and green peaks overlap? I have done some analysis and I have determined;

  • The fringe separaton is scanning correctly, I replaced the photodiode with an AC726X 6-colour sensor (the grey graph) and the peaks occur at the correct points in the graph. Granted, the light is not truely polychromatic and the intensity of red wavelengths is greater than blues or violets but that should not matter if the result is a ratio beween input and output intensity.
  • The measurements are repeatable and the spread of the data is about 10% of the mean values. This indicates that I am missing something in regards to the construction. Is it the angle of the light? Is the entrance slit too wide?

If anyone has and ideas please let me know. I would love to finish this project and put it on instructables. I have had an amazing learning experience with this and I would like to share it when I am done.


Comments

The forums are retiring in 2021 and are now closed for new topics and comments.
0
smooth_jamie
smooth_jamie

10 months ago

For anyone interested here is the setup. The entire assembly is contained in this 3d printed box. A 90W halogen bulb is contained in the small aluminium box at the top, which has a small hole in the bottom to let out a narrow beam of light. The light is focused usnig a convex lens onto the diffraction grating. The grating then splits the spectrum and projects it onto the bottom where the stepper, curvette holder, and sensor is mounted. The curvette is mounted in front of the sensor and slit (I have tried putting the slit in front of the sample with the sensor behind it but this gives worse results). This is slightly different from most other spectrometers in the fact the the sample, sensor, and slit is moved together over the spectrum.

I am quite sure that this is working to some degree. I intend to change the diffraction grating to see if I can elongate the rainbow pattern. It is currently about 20 mm long, but if I use 1000 lines/mm grating instead of 500 then my calculations suggest the pattern should be twice as long.

20200521_094115_HDR.jpg20200521_094136_HDR.jpg20200521_094213_HDR.jpg20200521_094224_HDR.jpg
0
smooth_jamie
smooth_jamie

Reply 10 months ago

Hello Dr H! I have seen your excellent instructables for the ACS Photometer before deciding to make my own. Some very useful information there! I agree this is a good idea. I have in fact already purchased the attached LED's from Roithner Lasertechnik. These 12 LED's span the spectrum from 420 nm to 700 nm. I intend to use these to test the slit and diode together.

LEDS.JPG
0
smooth_jamie
smooth_jamie

10 months ago

I appreciate the time you took to make a very comprehensive response thank you. You're right about some sensors having filters (some have IR filters for example). I have given very careful selection to what photodiode I should use. Unfortunately for the DIY maker community the selection of diodes available is almost exclusively restricted to 400-700 nm wavelengths, all with maximum sensitivity centred on 530 - 560 nm. I've written an instructable evaluating most of the breakouts available for some of the common one's and decided that a the photodiode would probably offer the most interesting (if not the best) result. I have evaluated the following:

- SFH 2701 (tested, works fine but SMD is harder to solder than through hole)
- S1223-01 Hamamatsu (not tested yet but the datasheet looks promising)
- BPW34 (tested and works good)

I decided on the BPW34 since it is thruogh hole, plus the datasheet shows a very linear trend between 350-950 nm, and in theory I could calibrate the sensor with a simple linear trendline formula y=mx+c. However you can see from the results that datasheets are just as much marketing literature as technical data. Real world result may vary!

I am indeed doing as you suggested only with calibrated filters rather than calibrated LED's. I have selected ROSCO E106, E120, and E139 (datasheets attached). You will see a good correspondence between the RED filter spectra and the result from my device, however there is poor correspondence with blue and green.

E106_red.PNGE120_blue.PNGE139_green.PNG
0
Jack A Lopez
Jack A Lopez

11 months ago

This hypothesis that the entrance slit is too wide, or that somehow the sensor is looking at too wide a band of wavelengths, is a good guess.

But can you test this guess? I mean, can you make the scan work with a really narrow slit?

Can you compensate for really low amounts of light by scanning more slowly? I am not sure how the samples, as numbers, are arriving at the Arduino, but I am guessing if it were done more slowly, then you would get more numbers in that longer time, and add them all together and average them.

But I am not sure if that will give good numbers. It might be if the sensor is too dark, you are just looking at noise.

By the way, I have never built anything like this, and I am impressed by what you have got so far.

0
smooth_jamie
smooth_jamie

Reply 10 months ago

Thanks for the compliment. It has taken some hard work to get this far!

Yes the raw data from the sensor is very noisy. That is probably due to the LM358 being a poor choice of op-amp but I'm using what I have for now. The solution was to take 1000 samples per second and take the average which gives me a nice curve of absolute ADC values, which is also a good match against the datasheet's spectral response (see attached datasheet, a graph before averaging, and after averaging).

It already take 5 minutes to complete a full scan (about a second per 10 steps which I think is about a millimeter). You are correct about the light intensity, if I make the slit narrower the resolution increases but the intensity reduces. There are other options to solve this though (second op-amp stages, increasing the gain in stage one etc) but maybe I should investigate the slit size first.

BPW34_spectral_response.JPGno_averaging.PNGwith_averaging.PNG
0
Downunder35m
Downunder35m

11 months ago

I have no real clue about how to build a spectrometer, however, I do have a clue about photodiodes ;)

From my repairs and experiments I noticed that these diodes are very far away from being even and equal.
For example:
Had to fix one inside a laser distance sensor.
Worked as planned with no problems.
Reason was simple: Red laser, red filter and most photodiodes are by default quite sensitive in the red-orange area.
My personal nightmare was a diode system for an industrial line follow robot.
No filters, instead a weired plastic lens similar to a fresnel system covering the entire array.
Tried about 10 different diodes until I found one that worked half decent.
Later when there was time for a real tech to have a lok he explained the diodes provide different values for different light colors.
The lens causes the strip on the floor to apprear in a gradient from red to blue on either side.
So instead of creating a complicated PWM control to drive the motors it was solved by providing a variable sensor input.

Since you already have the equippment at hand:
Take the diode and use a red, green and (proper) blue LED for the testing.
With that you can quite easy check if the diode's sensitivity to a fixed wavelenght is linear or not ny simply adjusting the brightness.
It could also be a case of "filter" within the photodiode itself.
Often the lens or cover material is not fully linear with all light colors - intentionally I must add.

Last but not least: selection...
Just to give you and idea about quality control:
When I worked for a sensor producer we had dedicated testing machines for our photo and laser diodes.
Usually about 5000 each arrved in bulk.
These were then tested and sorted based on their real world performance and overall properties.
In the end we had 10 different containers each.
And for each photodiode container there was a matching laser diode container.
Still about 800 to 100 diodes were discarded every time due to the tolerance outside acceptable parameters....

Sorry, but I have to ask this anyway:
I assume you made sure that the diode only gets the intended light color with no chance for stray light getting in?