Wednesday, September 19, 2012


Through reading science-blogs like BoingBoing and Wired I got to know about Arduino, a tiny Amel AVR-Microcontroller based prototyping platform and got  an idea of how it could be possible to build  a kind of light-absorption meter for measurements in analytical chemistry without spending much money. Here I will explain the development of my idea.


The Idea.

At first I thought about a device for the measurement of visible light absorption in suspention- simplified turbidimetry. A simple photoresistor and a cuvette with a light source would do the job- the more concentrated  the suspension is, the less light comes to the photoresistor; but I did not have access to the laboratory to build the device and start the tests. A year later I was lucky to meet Sebastian Hermes, a PhD student at the university where I studied who liked the idea and told me that he could use something similar in his work. In the laboratory of the university they have a flash device for liquid chromatography which can not only separate substances, but also measure their UV-absorption and show it as diagram in function of time.  So the idea was not just to build a simple device for the measurement of the color intensity of liquids- it is necessary to separate mixtures of substances, measure the amount of ultraviolet radiation and get in real-time results. A  simple lamp and a photoresistor (considering that they change resistance only in visible light according to the data sheets) were not enough- the fascinating process of finding solutions begun.

Tuesday, September 18, 2012


First steps.

At first I needed to know, if it is possible to make quantitative measurements with Arduino. For that purpose I decided to build a device similar to what I had it in mind at the beginning: a photoresistor connected to Arduino, a cuvette and a calibration curve made of colored solutions with different concentrations.


In order to collect data, I used the program- PLX-DAQ. It transferes data directly to MS Excel in real-time (apart from MS Excel all programs that I used to work with Arduino are avaliable on the Internet for free).

I tested that “device” with KMnO4- and Malachite green- solutions in different concentrations, different light intensity and LED-color. Measurements show that a pretty precise correlation –the correlation coefficient R2 was always between 0,9961 and 0,9977- really exists and it is possible to use such a simple “device” as a turbidimeter (or something similar). Here I need to notice, that the exact placement of the cuvette is very important, a difference in one millimeter can result in big difference in the measurements; also it is necessary to exclude the influence of external light- I used a box and a measure cell made of cardboard:

Monday, September 17, 2012


Flowcell.

The Next step was to measure ultraviolet light absorption. I found a ready-to-use UV-measuring cell on eBay, which had a UV-lamp (uses a 12V battery) and an UV-sensor, which was able to work at 3,3V- voltage, that Arduino can provide- and measures at 280nm. Sadly enough, I did not had enough time to build a measuring cell by myself- however, it is possible to assemble one with a simple UV disinfection lamp and UV sensors (these can be found on the internet). 

Together with Sebastian we have built a device that creates flow through the cell and is able to inject samples through the septum. I have run many tests with different substances that are UV-active in different concentrations and mixtures.



Here is an example of the separation of Furfural, Triphenylphosphine and Acetonaphthone (I injected 200μl of 1% mixture): The y-axis represents the signal intensity and the x- the number of measurements. Arduino sent measurements every 500 milliseconds, so the whole separation lasted almost 30 minutes and you can see all 3 peaks:

Those tests have shown that it is possible to detect different substances and it is possible to separate them but it had some issues. In order to move solvent through the system we used a vacuum pump, which worked fine until we connected the device to a separating column (stuffed with silica gel). The vacuum was so high, that the gas bubbles developed inside the column and went through the measuring cell. Moreover, the cables and Arduino were not shielded.  As a result the signal had a strong noise and the measurements were not very reliable.

Sunday, September 16, 2012

Noise reduction.


After I knew, that the device worked, I started to think of what can reduce noise and improve the performance. Obviously, the vacuum pump was not suitable. The mobile phase must be pressed through the system, not sucked. Luckily Sebastian found an old peristaltic pump which was not used in the laboratory, it was not the perfect solution because an HPLC-Pump would be better, but it was what we had at the moment.


Anyway, after the “new” version of the device was built I noticed a strong increase of noise, it basically showed a sinus-function, as it can be seen in the basis-line:


and an injection of 200μl 1% 4-Methoxybenzaldehyde solution gave this chart:

It is possible to recognize the substance-peak but the noise is too high. To solve that problem I have connected Arduino directly, without the breadboard to the sensor and isolated Arduino in a box warped in aluminium foil (what I actually needed to do at the beginning). I also noticed, that moving the cable, which goes from the sensor, results in big signal fluctuations:



Even opening and closing the box in which Arduino was placed had a very big influence. Here is an example of changes in the signal after opening and closing the cover of the box:

Shielding made the signal better but it was not enough, so I decided to use a “Smoothing filter”- it collects readings, calculates the average of the last M readings and sends it to the computer. In my case, I found out that with a 50-millisecond delay between readings and M=50, you get the best results.


This chromatogram shows the separation of 50μl 150μmol/ml Triphenylphosphine + Dihydroxyacetophenone  (flow rate 9ml/min) mixture with smoothing filter:

And this one shows the separation of the same mixture with the same conditions but without the filter:


Obviously, it was better- the curves looked much more reliable but it was still not exactly the same as in the commercially available chromatographs. In the next step, the filter was improved by temporarily saving readings as floats (the first version used integers- which gave not so accurate results) - thanks, Aleks! Now the signal had good strength and the basis line had “noise” of just ±0,25.


This chromatogram shows the separation of 40μl 150μmol/ml Triphenylphosphine + Acetophenone + Furfural (flow rate 9ml/min):

All 3 peaks are recognizable and it looks almost like it needs to be.


Update

The final version of the  code can be found here




Saturday, September 15, 2012

End and conclusions.


Sadly enough I was not able to continue the project because of the lack of time. It the end the signal had a good strength, the noise was minimized and we had a qualitative separation of low amounts of substances. I think that with a higher flow rate than our peristaltic pump could produce (maximum 9 ml/min, while normal flash chromatograph works by ca 35ml/min) it would be able to get a better separation and the chromatogram would look like it does on commercial devices. This project shows that it is possible to build a cheap scientific device based on Arduino that can give reliable data and can be used in chemical /pharmaceutical or other type of research.


Special thanks:         Sebastian Hermes- for Interest on the project, many advices, ideas and help
                                 Leire Urriolabeitia- for making this blog readable
                                 Aleksandr Mattal- for improving the noise filter