Friday 28 September 2012

Go Rebel

The inferior performance of the previous LED lighting system meant that it was unusable under high magnification. Straight after that first attempt I ordered a new set of LEDs that have a significantly higher rating.

The Philips Luxeon Rebel series of LEDs come in various wavelengths and third parties offer lenses and baseboards for them. To recap: I need my light system to fulfill three requirements:
a) small size so it fits into the system
b) bright enough to allow working under high magnification 
c) narrow light beam so that the bright light doesn't disturb the animal

So for the next generation of my light system I picked what is technically an RGB mixer lens which produces a  +/- 6° beam + baseplate that doubles as breakout board for the LED contacts and a heat-sink mounting point. Instead of Red, Green and Blue I just put in 3 high-power white LEDs.

a) Small Size so it Fits into the System

When the LEDs arrived it became clear that size won't be an issue. In fact, one problem with the LEDs is how small they are. Don't be fooled by the amount of light they are producing, they are about 2 x 5 mm. On that space are 3 contacts: cathode, anode and heatsink. All of which are in the same plane on the underside. This means, arranging 3 LEDs so that they are connected in series AND have good contact with the heat sink becomes next to impossible. Luckily there are also baseplates available which break out the contacts and allow to easily to attach a heatsink to its bottom.

Luxeon Rebel Tri-LED breakout board. Apart from the insulated contacts this is made of aluminium for good heat transfer to the heat sink that goes on the underside.

One LED on a tape measure to see the size of them. In the bottom picture you can see the three contacts.

While it is possible to put solder on all of the contacts, heating the contacts all up again to solder them down is next to impossible because they need to sit flat on the baseboard and there is no way to access to contacts with a standard soldering iron once they are in place.

A technique called reflow soldering was the best way to deal with this problem. In brief, you apply a paste that contains solder to the contacts and stick the components together. This is followed by applying heat until the paste melts and turns solid. I haven't used this technique before, but it seemed straightforward enough and there is a great tutorial on the Sparkfun website how to do this with a skillet (or any hot surface for that matter). 

After finding a workshop that had some soldering paste (easier said than done) and finding a hotplate (which we usually use to gently heat and stir delicate solutions...) I carefully applied paste to the contacts and popped the LEDs on it (see pictures below). After that I slid it on the hot-plate and waited a few seconds until the solder melted and made contact with the LED.

Apply solder paste
Pop LEDs on, push them down a little bit but make sure that paste on cathode and anode doesn't make contact 
The hotplate. Exciting, I know.
Put on hotplate for a brief period to melt solder paste. Also, in this picture you can see that I simply connected the breakout contacts of the LEDs in series. And of course the cable will be soldered onto the last two contacts.

Instead of building my own circuit to drive the LEDs I decided to invest into a LED driver. Very conveniently it takes 24V DC input and produces 3 - 33V output (depending on how many LEDs are connected in series) at 1000mA max. current. It has a an analogue and digital dimmer pin to adjust brightness. 

One problem with such powerful LEDs is thermal management. The LEDs have a maximum temperature of 135°C, which means you can run them at full power without a heat sink for about 5 seconds before they blow (or melt?). The baseplate provides a small amount of cooling, but far too little. While one can go into long and complicated calculations how much heat-dissipation is required I simply picked a generously sized heat sink, some heat-transfer tape and stuck it to the baseplate. Well... it wasn't enough. I ended up combining two heat sinks until I felt comfortable with the amount of dissipated heat (which I professionally assessed by touching the heat sink every minute or so and checked how hot it is). There is a heat sink calculator on this excellent website but I ended up not using it as I had the heat sinks ordered before I discovered it.

LEDs on double heat-sink. Between baseplate and heat sink is thermal transfer tape.
The lens for the LEDs fits perfectly and slots into the baseplate. I've used some superglue to fix it, hoping that the LEDs stick to their promise of lasting for the next 9001 (or so) years.

Lens that goes over the LEDs.

b) Bright Enough to Allow Working Under High Magnification   

The brightness of this assembly is really quite remarkable. I've made the mistake of looking straight at the LEDs without the lens on when I turned it on for the first time. It took a while until I regained full vision. Each of these LEDs at full power (i.e. at 1000mA (!!) ) produces 310 lumens according to the manufacturer. These LEDs are rated in lumen rather than microcandela (mcd) which makes it hard to compare to the previous set of LEDs I had and it is difficult to convert between these units so I won't try. According to the internet, a 60W incandescent light bulb has about 800 lumens. Keep in mind that a 60W bulb can light up an entire room quite easily. My LEDs with the lens focus ~85% of its 930lm in a +/-6° beam. Here is a comparison between the two systems I've made:

The old system: seven "super bright" LEDs, at 2.5 cm, focused in one point.
The lightcano.

c) Narrow Light Beam so that the Bright Light Doesn't Disturb the Animal 

This is the only point in which the new LEDs lack behind the previous system. The lenses are not focusing the light well enough. That said, I could build a shield to focus the light in a narrower beam. However, I've found it easier to make a little cover that blocks the light from shining directly into the mouse's eyes without blocking the its view onto the virtual reality screen. While the mouse can still see the entire environment lighting up, none of the intense light is frying its retina.


Having tested the new lighting system in an experiment and compared it to the old I can say that the difference is like day and night - literally. A key disadvantage of the new system is that the light is less focused and therefore I can't avoid the eyes of the mice but with a small shield this problem is easily circumvented. An upside of the light intensity is the fact that I can place it further away, and therefore its even less in the way. The fantastic brightness means that whatever worries I had about illuminating the brain surface are now gone.

Friday 7 September 2012

The Good, the Bad and the Ugly

A key consideration if one wants to do electrophysiology on a virtual reality rig is space for all the required equipment. One such thing is the light source. Ideally it only lights up a small area so that the animal won't be stressed or disturbed by the sudden bright light. To get an ideal solution for this I decided to make a frame for LEDs that would allow me to shield stray light and place it just where I needed it using a snake-arm on a magnetic base.

The Good

The light-source, like all other bits of equipment for this project, will be used in a clean facility. That means no loose cables or half-done jobs. However, to drive the LEDs a small circuit was required that would provide the right current and voltage. Further, being able to dim the LEDs might be beneficial. Less light means less disturbance for the animal. And of course, a nice enclosure makes everything look a bit more professional.

Box and frame. No electrical safety test was required as only 24V DC is going into the housing.

The top of the box features an on/off switch and a knob that dims the LEDs. Of course the knob is just a potentiometer underneath. The box is made of plastic, but the quality is good and it comes with anti-slip pads so that it sits on any surface quite firmly. Drilling the holes to fit switch and potentiometer through was even easier than drilling the aluminium frame for the heating mad system.

The second part of the system was the holder for the LEDs. I decided that using 7 "super bright" white LEDs will be sufficient. The description on the seller website said they are so bright that looking into them directly would hurt your eyes. Well, I thought, if one hurts your eyes, seven must burn your brain. And falling short of that, still enough to illuminate a work surface.

These LEDs are designed to emit light at a 20 degree angle, accompanied by some stray light, suiting my application quite well. While using a convex lens would have been the more elegant solution to focus the light I opted for the cheap and easy way of just shielding any unwanted light. With so many lumens at my disposal, shielding some won't be a problem, or so I thought.

The Bad 

Unfortunately, it turned out that the "super bright" white LEDs are not as bright after all. While it is true that they are unpleasant to look into, it's nowhere near bright enough to light up an area to look at it under high magnification. Even when 7 of them are focusing on point only 4cm away from the LEDs it didn't produce enough illumination. While in the picture below it certainly looks like the LEDs almost burn a whole into the table, it really wasn't that bright. Add the fact that they can't be placed at the ideal angle to shine onto the surface of the brain and it becomes rather useless.

~4cm distance from LEDs. While the light is nicely concentrated in one spot it didn't produce enough illumination, the picture is quite misleading.

One problem with using a simple potentiometer to alter the voltage on the LED for dimming is that LED have an exponential voltage response. That means that low voltages for large parts produce almost the same (low) amount of light, and only the last few hundred mV approaching the LEDs max. voltage rating produce a huge change in response. However, LEDs are very sensitive to applying too much voltage, which means if you turn the pot too far you will fry the LEDs. That is also the reason why proper LED drivers are a bit more sophisticated.

Luckily, in the process of soldering up the LEDs a friend from the workshop showed me some real LEDs. These are industry-grade, not some hobby-project components. They hurt your eyes even when standing on the other side of the room. Exactly the kind of thing I needed. On top of that a real LED driver (which can be bought for <£20.-) will be used instead of just a potentiometer, allowing dimming the LEDs linearly.

The Ugly

Approaching the halfway point of my PhD at an alarming pace I decided that time is becoming a currency ever-increasing in value. It makes a lot of sense, therefore, to save time where possible, even at the risk that one of my contraptions won't last for the next 50 years. While some soldering couldn't be circumvented, I decided to use a mini-breadboard and some jumper-wires to assemble the circuitry inside the box. With hindsight, it didn't save an awful lot of time, but at least it made it a lot easier to assemble and take apart again in case there were any mistakes in the circuitry.

This might fall to pieces the first time someone knocks it but until then it will do the job. If I can find a glue-gun I'll just glue it all down.

Instead of using a double-stranded wire I used two single-stranded ones (blue and red) to connect the LEDs. That was purely for the reason that I didn't have a double-stranded one available and I needed to get this up and running.


Arguably it is a viable option to simply buy an off-the shelf lightsource with some gooseneck light-guides. However, designing your own lighting system guarantees that it will fit exactly where you want it and only illuminate the area required. While my current solution is suboptimal due to low light output, the next generation will hopefully do the job.