Thursday 13 September 2018

It's really not about the ducks

I received some very strange looks from my colleagues when I stated that I was no longer going to allow students to put their hands up in my IT workshops to ask for help. Nope, not even once.

What is this nonsense you might ask, or in terms of the name given to the initiative, What the Duck?

Let's make one thing very clear at the outset, students can ask for help during my classes, but they have to do it in a specific way. I will elaborate but first some background.

There is a very successful initiative for improving the programming and data management of primarily postgraduate and postdoctoral scientists who are not computing specialists. This initiative, Software Carpentry (and it's allied friends) takes a strongly evidence based pedagogy and uses some smart methods in the classroom. One of those is the application of red and green post-it notes. When a student requires help they put the red sticky up on their monitor. When they have completed the task at hand the green sticky is used to indicate visually to the instructor that they are ready to move on.  This is an effective method for those classes which are high intensity with highly motivated and high calibre participants.

I have translated this to my classes. I don't use stickies (though they are usable in this context) but instead simplify the approach to this:
If you want help, talk to the duck!
The duck is anything that you can stick on the top of your monitor. It is surprisingly easy to detect any perturbation in the smooth flat line of a monitor from across the classroom.

Whilst the duck is there, explain the problem, talk it through. Often the student solves the problem and takes down the duck before the instructor can reach them.  But while the duck is doing the attracting, the student can concentrate on the task, eyes are on the screen, hands are on the keyboard.

How well does it work? It is only the start of semester and only one class in but the students got the idea very quickly and really liked the ducks/sheep/penguins/swans/hedgehogs etc. I distributed. This is a small class in an elective module - the large classes will have to earn their ducks through interaction in lectures/workshops. The response was great - I could see that ducks that had been up were taken down before I could attend to that student. And while students had ducks up on their monitors they were actively engaged in attempting to solve the problems rather than being engaged in attracting the instructor's attention.

So a positive response so far from the students and the desired behaviour in the classroom. We'll see how  it plays out through the rest of semester and larger classes.
Yes, all of these are ducks, in the right context.
Edit: We are now three weeks in and the ducks are extremely popular. The class is less stressed and students are keen to bring in their own personal ducks (or win some for answering questions in class). It is surprising how easy it is to see almost anything on top of a monitor screen, even in a room of 150 (our largest IT lab).

Has this inspired you to try ducks in your classroom? If so, please let me know how you get on via a comment or email.

How hard can it be? Part one of a saga.

It started, as do many things, with an idle conversation in front of a white board. (I'm starting to realise that white boards are dangerous places). One of my colleagues, a talented immunologist who spearheads our undergraduate cell culture modules, had seen the laser pen microscope and commented 'It would be great to adapt this to use as a cell counter'. She has been trying to get one into the lab but it isn't economically viable at the moment. How hard can it be to build a fluorescent cell counter/analyser on a minimalist budget (ie  a few £10s )?

Lasers

We have lasers. For a few pounds you can buy a laser pen that gives a reasonably coherent light. I bought several for a fiver from eBay and now have wavelengths of 405nm, 535nm and 620nm (blue, green and red respectively). So we have a source of light.

Filters

Filters for a commercial system are typically precision optical glass, carefully manufactured and a premium price. Way more than we could afford on the shoestring budget allocated (I rummaged down the back of the sofa and found a few bits of spare change, a button and some random electronic components). However, there is a very cheap source of filters. The theater industry use many colours on lightweight plastic filters. Rosco provide spectrograms for all their filters so we can spend many hours scanning their web site to identify filters that will act as high-pass (to capture the excitation wavelength but exclude the incident) and a low-pass to capture the incident light without any contribution from the emitted light.

 This gets us two components - the challenge now is leveraging these in a way where we can work with it. One of those aspects is detecting and measuring the light, the other is scaling this to a level where we are working on just a single cell. The former of these will be dealt with later.

Optics
To focus a laser beam requires a lens. Identifying suitable lenses (ie very cheap) is challenging so it is time to think creatively. An acrylic rod that is optically clear will focus the light to a line from the round dot of the laser pen. A quick google identifies a suitable equation for calculating the focal length of a cylinder of known refractive index and diameter. In short, this tells us that a laser beam will be focused to a point 7.6 mm from the centre of a 10mm acrylic rod.

Having now obtained a suitable rod, a quick play around indicates that this will be about right. So this problem is solved. We can put a disc from the rod before, to focus the light, after to gather the transmitted light, and at right angles to catch the emitted fluorescent light. In principle we could use two different discs, one on each side to capture two different incident lights but that proves difficult to easily design. So we will stick with one fluorescent label.

Electronics

This is not too difficult (I always seem to say that at the start of a project). Phototransistors are cheap and have a broad sensitivity. Light causes the resistance they exhibit to drop. We can wire this in to a voltage divider and turn the change in resistance to a change in voltage. In order to boost detection we can feed this voltage into an op-amp in differential mode, the other input being a voltage that can be adjusted to set a zero. We are then measuring the change in voltage rather than absolute voltage (signals can go up and down. You may not get back the electrons you invest).

This signal can then be fed into a second op-amp that is used as an amplifier, so a second variable resistor can be used to adjust the gain. The output from this is then read through an Analogue to Digital Converter and read by a Raspberry Pi. That at least seems a sensible plan to start with.

 And now the big challenge.

The Flow Cell 

How big are the cells we want to look at? Different cells give different sizes. Ultimately our flow cell size will be determined by what it is feasible to manufacture. The narrowest hole I think I can drill is 0.3 mm so the plan is to take a 4mm square perspex bar and drill a 0.3 mm diameter hole down the absolute centre, then to glue some larger tube to each end of the cell. I can find 5mm OD, 3mm ID clear perspex tube that should do the trick. I had considered using a laser to make the channel in a triangular piece and then construct the flow cell from two pieces, but the width of the laser cut is probably in the order of 0.5-0.6mm and any interface will have optical challenges, so careful use of a drill press it will be. There is a plan B if this doesn't work which gives us the potential to do even smaller holes but more on that later if it is needed.

This should give us a cell of 0.3 mm diameter. To limit the effective flow cell size, the laser can be pointed through a narrow (0.1-0.2) slit across the flow cell so we have a maximum size of about 0.2 * 0.3mm. If a cell is 25 micron diameter then we are looking for a maximum pertubation of the signal of about 1% for a single cell. That should be detectable if we use differential signal analysis with a suitable gain.

Other considerations

Holding a 4 mm rod in a vice under a drill press will be challenging. Instead of holding it directly I will make a jig with a 3D print that has a 4mm receptacle in the centre. The jig can be tightly clamped in the right position and then multiple flow cells drilled without having to constantly reset alignment. Likewise, gluing 5mm and 4mm pieces together end on will be challenging. A jig will be 3D printed to allow pieces to be held in place without risk of gluing them to the substrate.

Enabling flow in the optical cell is the final challenge. We have thought to use a peristalsic pump, or just a hand held syringe but one of my colleagues has instead suggested a venturi pump on the outflow (a water pump to those used to school chemistry lessons). This will keep a constant pressure differential without overstressing the components.

Design in CAD

 I've used TinkerCad (from Autodesk) to design the pieces. It is freely available and cloud based.



The blue element is the main part. The laser pen comes in to the right hand side, firing through the first lens and the slit. The flow cell (clear) will be inserted in the slot and run front to back (or back to front, there is no real difference.)
The green element locks the lenses in place. There is a slight gap between the lenses and the flow cell of about 0.6mm which allows for the insertion of a sliver of filter gel.
The yellow element locks the flow cell in place.
The purple element is the jig for constructing the flow cell.
The red element is the jig to hold the central part of the flow cell for drilling.

Overall size is about 60x40x40mm.

These parts have now been 3D printed, perspex has arrived and needs cutting to size and drilling. Electronics components are ready and waiting.
Testing - the laser pen fits. Other parts require a bit of finishing.
The 3D print straight off the machine. The flow cell dummy is to the left.

Parts ready to play. A phototransistor sits on the right hand foreground.


Perspex (acrylic) bar and tube ready to turn into finished parts.

Will this actually work as intended? I don't know but I'm going to have fun finding out. More posts will follow detailing construction, testing, coding and more.