Friday, July 26, 2013

Miscellaneous Mechanics

I apologize for anyone reading this, I haven't updated in almost a month. Yikes! Well I'm gonna change that put down some good news, a little bad news but altogether some cool things happening.

First, the bad news. The Linux board has taken a lot longer to realize than initially planned. We're still in a development phase of the board and until that happens it's difficult to integrate the computer with the electronics on the spectrometer. On the other side, the prototype of the spectrometer works just fine, I've been working on getting an idea of how accurate it is and how much loss there is due to mirrors and such. Overall, it looks quite promising. Also, I have apparently not uploaded any of my schematics, designs, or materials to the repo, so I am going to do that as soon as I have the chance. Now, onto some new cool and exciting news.

We're always cooking up plenty of different things to work on, and currently we are designing and producing a fairly affordable manual pick and place machine. We're using standard chromed linear rail, and aluminum plate for the base and armature, with CNC'd plastic brackets holding everything together. We don't have a great estimate on price, since most of the base materials were from scrap (we've only bought the rails and bearings, which along with some other pick and place equiment ran ~$240). The base plate and armature could reasonable be built with some reasonably dense wood material like MDF or the like. I'll post pictures tomorrow, it looks reall cool.

The other thing we've been working on is a complete rework of the electronics for servo drivers in a machine we have at Lib3. The original servo interface was for IBM PC's ISA (obsolete) so that was disappointing. However, we opened up its casing to find 3 AMC 10A8 servo ampilifiers, and after fiddling with them for a bit and reading the data sheet, decided they were more than salvagable. So, the next step is to write firmware for the Stellaris to control the motor controllers using some external op amp setup to get the proper signal. The servo amps take a reference, and then a + or - to determine speed and direction. A microcontroller can do stop and one direction, or both directions, but cannot do all forms of motion needed to drive the motors by themselves. I'll have more details when we finish designing the external circuitry, but basically we are going to turn the machine into a big USB peripheral that will be able to do some serious macaroni art (if you'd like). And now a couple pictures. This is the test circuit I'm using to debug the motors. There is an Arduino nano pictured, but not used, although that would be simpler than an ARM chip.


This is an Astrodyne DC-DC converter. They're really cool devices if you ever need to do anything that needs a differential supply.

This is a closeup of our servo amplifiers. They're a little pricey, and we're lucky to have them, but they are industry grade amplifiers. I think that having an available interface to them would be useful in cases like ours, where people get secondhand equipment where most of the parts are perfect, but there are logistical issues preventing them from being easily used (e.g. you can't you its control interface because it was obsolete in 1993). But once again, they seem pretty solid.

That's all the news I have for now. We're continuing to work hard to bring open electronics to the world, whether its through the spectrometer, motors, or even mechanical devices to aid in the construction of electronics. Have fun, feel free to ask us any questions, things you might like to see, or even just your favorite color.

Saturday, June 29, 2013

Mirror, Mirror on the Wall

This week has been relatively quiet. I got some super nice mirrors from Thor Labs, so now I am thinking of ways to mount it in an enclosure. I don't have any aluminum thick enough to take a 1" mirror, but everything is theoretically working physically, so I am going to look back into the state of the linear detector, see what progress has been made on it by the past group, and go from there, because I have all the parts of a working spectrometer, I just need to start thinking about things like radiometric calibration, and correction for the nonlinear response of the mirrors, gratings, stuff, like that.

Progress on the board's brain has been going well. Gordon's schematics are coming together nicely, and an initial prototype should be done fairly soon, so eat your heart out, raspi. On a side note, I noticed that Gordon's commit logs never seem very large, but Git simply can't capture the effort that goes into making such a large schematic (curse you efficient representation!). It will definitely give the spectrometer some serious power when it comes to processing and display.

Also, we will be outlining our progress further at the next RCOS meeting. I believe Nick will also be joining us to detail his progress on the embedded GUI framework to complement our embedded Linux board. He has made some amazing progress, along with excellent documentation, although dashboard refuses to recognize his subversion repo. We have recently run into some irreconcilable differences at the kernel level which require us to get a new dev board, so things have been quite on that front as well. Nevertheless, Nick has made stunning leaps in helping us cultivate a complete system for this board, and we're happy as clams to have him on board.

That's all for this week, once again, we'll be detailing progress next Tuesday at RCOS, so look forward to the live presentation or the recorded video from Ben Vreeland. Thanks for reading.

Sunday, June 23, 2013

Big Changes and Important Progress

There have been exciting changes and big news since the last post. I might break it into several posts to cover everything.

First, let us start with the brain. The initial plan was to use a TI ARM microcontroller to control the spectrometer, run the lcd screen, and talk to the computer. Upon further consideration and careful thought, we have been working with a small, ARM-based SoC from Allwinner, the A13. This will allow everything we need plus more: digital and analog GPIO, native LCD driver, plus all the good bits that a full linux distribution would have (sans X server). I'll detail plans for this subsystem as they come along, but the plan is that this control system will be its own device, that will be embedded in the spectrometer, but be a neat board all by its lonesome. On the software side, this opens up entirely new worlds. With the decision to move to a full embedded linux system, we have also opted to use the QT application framework, streamlining the process for making a fluid and intuitive experience using one of the stablest open source projects in the game.

Next, let's talk about progress on the actual spectrometer. So far it's been really promising. After several iterations of machining the spectrometer profile into polycarbonate, I have arrived at a prototype that I'm very comfortable with milling into aluminum. Compared to theoretical design and calculation, it's at least as accurate as a pair of calipers can confirm, using two separate laser sources (532nm and 650nm). Right now my process involves cutting the curvature into the material and then pasting a strip of mirror film onto the curvature to prototype expensive mirrors, which works for proof-of-concept, but won't cut it at the calibration stage. Anyway, the next step of the game is to get optical mirrors to go with the diffraction grating, and start to contact suppliers in China to source components for prototypes in the near future.this breakthrough has been huge from my perspective, and I'll provide pictures of the prototype later in the week. 

That's all for now, be sure to check out the repo for any updates on circuit diagrams, cad diagrams, and code, and comment if you have any questions.

Sunday, April 14, 2013

More Progress


We now have a sensor that talks to a microcontroller!

Yellow=sensor output (200mV/div)
Green=ROG (TTL, Basically starts the sensor reading when low)
Blue=Clock(TTL, makes the sensor spit out a value on the output for each pixel sequentially)

The first image shows the 33 dummy pixels. The second image(IMGP2879) shows the entire sensor output. The large blip is due to the light from a piece of black card with a small hole punched in it, and shows that the addressing is working correctly. Due to the slowness of Arduinos, the integration time is still way too large, and the sensor reading clips. This won't be an issue once we move to the ARM processor, which is a good order of magnitude faster.


Tuesday, February 26, 2013

Progress So Far

Over the course of the past few weeks, much progress has been made on the Open Source Spectrometer, although the name is still up for debate. 

Using TI sample code the following has been made to work:

  • The microcontroller running code accepts a buffer of 255 bytes and flips the case of any alphabetic characters received over serial.
  • The driver allows a windows application to interface with the hardware over USB2.0
  • A demo application, written in C++, now allows the sending of buffers to the microcontroller and receives the processed data back. This is a very fast process, since USB can be thoeretically 480 megabits/s. Currently, we are transferring small buffers, so most of the overhead is in dealing with the individual buffers, but high speed will allow us to easily transfer greater than 4kb buffers many times a second. 4kb is the smallest a buffer could be, since we are using 12 bit ADCS (12 bits per pixel), and we have 2048 pixels.

A CAD design of the Open Source Spectrometer has been drafted and is being further revised.


And Tim Cantwell made a pretty cool visualizer program that displays a spectrum on a grid, which will be able to be added into the interface functionality to show data from the spectrometer once the hardware is more complete. His program is written in C++, using open frameworks and openGL for rendering/GUI.

Sunday, February 3, 2013

Project Overview

Open Source Spectrometer (OSS)
RCOS Spring 2013

The Team: Jorel Lalicki, Monica Kosciuk, Justin Jones, Jonah Gruber, Andy Lynch, Brian Barnes

Why:
Physics education in High School and College covers light (and other electromagnetic waves). While there are a variety of hands on experiments that demonstrate, for example, that white light is composed of many wavelengths of light, there are few that can quantify the results in a cost effective and accurate manner. Spectrometers are most practical way of taking measurements of a light source. A spectrometer takes input light and measures the relative power present across a large array of discrete detectors. The data is then processed, and visualized as a graph of energy vs. wavelength. Spectrometers can be incredibly versatilethe following are a few examples of how such a device could be used in High School education to supplement and enhance the student learning experience.

Chemistry: 

A spectrometer can be used to measure absorbance of different wavelengths of light. A student could identify molecules present in a solution by first taking a reference measurement of a high CRI source such as an incandescent bulb, and then subtracting a measurement of the same light source after passing through the sample. The peaks give a unique ‘fingerprint’ for the compounds absorbing the light.

Physics: 

When teaching about the electromagnetic spectrum and color mixing, a hands on lab could be used to demonstrate how different colored filters/light sources combing. The spectrometer can be used to prove that, even though our eyes perceive the combination of Red, Green, and Blue light sources as white, they are still separate wavelengths.

Ecology/Environmental Science/Biology:

One common use of spectrometers is to identify and detect chemical pollutants in water samples. A low cost, durable, portable spectrometer would enable students to perform measurements and experiments in the field, and analyze the results in the classroom later.

The OSS Spectrometer project aims to make low cost OSHW spectrometers available to educators. A modular design will allow the OSS.S to be used in a variety of applications, including existing optical equipment with fiber optic connections, as well as direct light apertures for use with lighting fixtures/LEDs. Simple open source software will allow for basic use without a steep learning curve. The goal is a 10 second setup, where the spectrometer gets plugged in via USB, you start the spectrum visualizer, and adjust vertical scaling (a function of sample integration time).

Existing Products:
There currently exist several commercial, portable, visible light spectrometer solutions, such as those produced by Ocean Optics, Spectral Evolution, or ASDI. The main problem with these products is the prohibitive cost. For example, the Ocean Optics USB2000+, the spectrometer used by the Undergraduate Optics Lab classes at RPI, costs $2771 for the unit. The proprietary software needed to run the spectrometer (and only usable for spectrometers made by this company) costs an additional $209. However, the markup on these devices is ridiculously high. Even if you get the optics involved manufactured in a high end US optics lab, the cost is still only around $100. The sensor involved is in fact a Sony ILX511B, which was designed for use in barcode scanners. The software does little other than visualize real time data from the sensor on a graph. The Open Source Spectrometer will leverage low cost optics and components to produce a quality device that is capable of being used for analytical measurements in a High School/College classroom.

There have been several attempts to bring a low cost open source spectrometer to market. These have either failed due to funding shortcomings (there was a Kickstarter for a project in 2011 that failed to raise adequate funds to begin development), or due to hardware limitations (the mySpectral Spectruino is actually in production/available, however, due to bandwidth limitations of transferring the data over serial, it is unable to compete with native USB solutions). The mySpectral Spectruino has developed open source control software that we hope to be able to port to our new hardware platform.

Technology:
The spectrometer hardware consists of a opaque enclosure that houses a holographic diffraction grating (reflective) or transmission grating, and a linear B/W CCD or CMOS detector. These detectors are commonly used in barcode scanners, and consist of a single row of pixels, with no focusing lenses or coatings. There is then a interface circuit that reads the detector and sends the raw data to the computer for processing and display. That is it...the hardware itself is pretty straightforward. Of these components, the interface circuit is by far the most complex, and consists of a microprocessor, as well as high speed, high resolution A/D converters.

Name:
It got called a few things throughout the project description; the name is still being decided, although it will most likely have ‘Open Source’, and ‘Spectrometer’ in it.