Monthly Archives: June 2008

Converting a 3-Wire Bi-Colour LED into a 2-Wire Bi-Colour LED

I recently noticed that when one of my computers entered a sleep state its power LED went off, leaving no way of telling if the computer was asleep or off. When my other computer enters an S3 sleep state, its power LED flashes to let me know. I pulled out the motherboard manual to see if I could find an answer. It turned out that the motherboard supported a dual-colour power LED, which would switch colours when the computer entered a sleep state. If only a single colour LED was present, as in my case, it would go off when the computer went to sleep.

What was required was a bi-colour LED with two leads. Such an LED contains two LEDs of different colours, which are wired cathode to anode and visa versa. If the current flows one way, one LED will light, and if the current is reversed, the other LED will light. I didn’t have such an LED, and a search of my local electronics store’s web site showed that they didn’t either. What I did have in my box-of-tricks was a fancy three-colour RGB LED with four leads; a cathode lead for each colour LED, and a common anode lead. Sometimes a similar arrangement is used for bi-colour LEDs, i.e. they have three leads, one of which is a common anode or possibly a common cathode. What I needed to do was convert my common anode LED into a bi-colour, two wire type suitable for the motherboard. This can be done with couple of normal diodes, as per the circuits illustrated below.

In this circuit, a 3-wire, common anode red/green LED is converted into a 2-wire red/green LED.

Here’s the equivalent circuit for a common cathode 3-wire LED.

With the circuit worked out, I went out and bought two 1N4004 diodes and wired them up to my RGB LED (using only the red and green cathode leads, as they were the colours I wanted).

The end result. The diodes are wired into the cable and covered with heat-shrink tubing (the bulge at upper right). So did it work?

At top, the computer awake with both the new green power LED and blue hard disk activity LED on, and at bottom, the computer asleep with the power LED switched to red!

Building a Windows Home Server – Craftsman Style, Part 3

Setting Up the Server

When I left off in Part 2, the cabinet was built, and the server had been assembled. The next step was to move it inside and install the Windows Home Server operating system.

In this photo, the cabinet is in place next to its existing buddy. Now my two desktop computers, along with the ADSL modem and gigabit router, are located on a desk on the opposite side of this office area. Since WHS must be wired to the network, and I didn’t want an ethernet cable running across the floor, I had to run a cable through the wall. Luckily the exterior of this wall has removable corrugated iron cladding. Removing and replacing it was a slightly stressful job, but worth it for the end result. I used Cat 5e cable for the run, as it was all I could buy by the metre. For some reason, Cat 6 cable was only available in 300m drums, slightly more than I required. Cat 5e is rated for gigabit ethernet, so no problem.

To install WHS, I put the drawer assembly on my computer desk and connected it to one of my monitors, and a borrowed keyboard and mouse. I attached a spare DVD drive I had in the cupboard with an IDE cable, and connected up the power supply. Now it was time for that magic moment that only happens once in a new computer build, first power up. I pushed the button. My blue power light came on, the drive spun up, the fans started and the monitor came to life. I pressed the DEL key to enter the BIOS to set up some initial parameters, ensured that the DVD and hard drive were recognized, and set the DVD drive as the first boot device. With every thing looking good, I put in the WHS installation DVD and rebooted. Then a problem. The Windows installer would start to load files, then quit with a read error. I checked the settings, checked the DVD drive setup, but still the same result. So I ripped a DVD burner out of one of my desktops and hooked that up. Installation proceeded normally, phew. But wait, what’s this, another error? This time, after its first reboot it gave a hard drive error. I had noticed the “press F6 to install third party drivers” message, and realized straight away what was wrong. Having been spoiled by Windows Vista, I had set the hard drive controller to run in AHCI mode and just expected the operating system to install. But WHS is based on Server 2003, and like Windows XP, requires AHCI drivers to be installed from a floppy disk at the F6 prompt (Note: I never checked it out at the time, but if your motherboard supports it, you may be able to set the BIOS to emulate a floppy using a flash drive). I considered just setting it to IDE emulation in the BIOS, but decided that was too easy (and requires foregoing hot swapping, NCQ and SATA 3Gb/s interface). I had a floppy drive, used perhaps twice in its life for the XP installations, so I plugged it in and hunted around for a disk. The only disks I could find were two I had used as “F6” disks before. I downloaded the F6 floppy utility from the Intel website, plugged the drive into one of my desktops and made a new F6 floppy. Then back to the server, which promptly gave a floppy read error. Anyway, to cut a long story short, both disks turned out to be dodgy (just too old). I eventually found one that worked at my wife’s work place. Once these problems were sorted, the installation proceeded smoothly.

I was pleased to find that powered up, the server was very quiet, and inaudible once inside the cupboard with the door shut.

All powered up and running. The drawer is pulled out to access the power switch on the right hand side.

Installing and setting up the Connector software on my two PC’s was straightforward, and I soon had both computers backed up to the server for the first time. This first backup can take a while, but the daily incremental backups are fast.

Initially, because I was having a problem with a computer that would not sleep properly (see my post on “The Computer that Wouldn’t Sleep), and because I didn’t want to leave the computer on all night, I would turn the server on first thing in the morning, then turn the computers on and let the server back them up. This prompted me to finally solve the computer sleep problem. Now I leave the computers in an S3 sleep state over night, and let the server wake them early in the morning for a backup. To save even more power, I turn the server when I’m finished for the night, and have it turn itself on at 6am using the Wake on RTC Alarm function in the BIOS (as an aside, I really liked the Gigabyte board’s BIOS, it has much better explanations of the settings than the ASUS motherboards I’ve used).

So my overall impression of WHS so far? Well, I think it’s an excellent and very useful product. It’s a great shame its reputation was tarnished by that tricky data corruption bug, but hopefully Power Pack 1 will finally see an end to that. I was never as diligent as I should have been about backing up data, but now it’s automatically taken care of. And when we wanted to share a file between computers, we’d often copy it to a flash drive and hand it over! Now we just save it to the server, which feels just as fast as reading or writing to a different partition on your own hard drive, that’s how well it works over a gigabit network. And then there are the cool remote access features…but that’s enough from me.

I hope you’ve enjoyed reading about my experience, and maybe will be inspired to build your own server, if you haven’t already.

UPDATE: I’ve taken the final step and added the second hard drive, a Western Digital SE16 500GB model, and the installed Power Pack 2 release candidate. It’s all working well so far. To make room and keep things tidy I removed some of the unused cables from the power supply, terminating the cut ends with a 9-pin nylon connector so that I can used them in the future if necessary (d.i.y. cable management!).

Building a Windows Home Server – Craftsman Style, Part 2.

In part one of this series I described how my need for a new office cabinet, and my desire to build a Windows Home Server came together in a single project, the craftsman style home server.

With a cabinet design roughly sketched out on a piece of A4 refill, it was time to start cutting some wood. I’m not going to go into detail about the woodworking and cabinet building process, as this blog is mainly about the server. Suffice it to say that there wasn’t a lot of mortise an tenon jointing going on as I have neither a dado stack, nor a mortising chisel. The cabinet was largely constructed using concealed screws, with through dowels to strengthen the face and door frame. The following pictures will give you an idea.

Now my Belkin N1 Vision router might have a nice LCD display, but it doesn’t have a cutter head that spins at 24,000 rpm! In this shot the venerable De Walt 621 makes short work of cutting slots in the sides for the shelves. My wife’s doing the work here while I take the photo. Computers leave her cold, but she loves those power tools.

In this photo, the sides (pre-stained on the inside to make life easier) are attached to a face frame by screwing through concealed blocks into both the side and frame. Note that I have also attached strips under each shelf slot to both strengthen the shelves, and make ensure that the the sides, which are made from two edge glued boards, are held firmly together.

Here’s the frame for the door, waiting to have a plywood panel fitted. Around this time I also cut out the shelves from both 17 and 12mm plywood, and applied a 5mm pine veneer on the visible front edge of each shelf. The thicker ply was for the base, and lower two shelves (including the server shelf).

After fitting the server shelf to the cabinet, I was able to finally construct the server drawer. The slot in the upper left of the drawer front is for an acrylic insert, which will serve as a diffuser for the server power LED.

This picture shows the LED in place below the acrylic. The LED is a 3mm high intensity blue type. After I cut the slot for the acrylic, I drilled a 3mm hole down through the center of the bottom of the slot. I then drilled a larger hole into the back side of the drawer front, just below the slot, and far enough in so that I could access the 3mm hole (I squared the hole out with a chisel to allow flush fit of the LED into the 3mm hole). I fitted the LED to a lead, bent it at a right angle and fitted it up into the 3mm hole as can be seen above. The acrylic itself has roughly sanded edges to better diffuse the light.

This is the power switch, hidden just behind the front of the drawer and easily reached by opening the drawer a few centimeters. I didn’t bother with a reset switch, and so far I haven’t needed one.

Once the drawer was finished I was free to start setting up the server hardware. Here I have placed and screwed down the motherboard, after fitting the RAM and CPU. To mount the board I started by placing the board on the wood, then marking through the mounting holes with a pencil. I removed the board and drilled small guide holes for the screws. At first I wondered how I was going to give the underside of the board clearance from the drawer base, then, whilst browsing my local electronics shop (probably for switches or LEDs) I found a packet of small rubber grommets, about 8mm high with a 6mm hole in the middle. Perfect! I placed them over the holes I’d drilled, then sat the motherboard on them and screwed it down with stainless screws. This also met my requirement of mounting any part that could possibly transmit vibrations through to the woodwork on a rubber washer or pad.

You’ll also notice in the above photo, that I’ve used the stock CPU cooler. Early on I spent some time puzzling over CPU cooling, as I wanted the server to be as quiet as possible, and my previous experience with stock Intel coolers for higher end processors was that they were quite noisy, especially when running flat out. I thought I was going to need to buy an after-market low noise cooler, and went to some trouble considering the options and whether they’d fit into the drawer space available. Luckily I waited until the CPU turned up. I’d never bought a low power processor before, and when I opened it I was amused by the small cooler, about half the height of those I was used to. I plugged it into a spare 12V supply and was pleasantly surprised to find that even at full speed it was almost inaudible. Problem solved.

In this photo I’m test fitting the drawer to the cabinet in order to mark on the back where the cutouts for the power supply, LAN cable, and a drawer ventilation fan should go. The power supply is a 480W Enermax that I had spare. I would have rather had a lower rated supply with plug in cables, but I couldn’t justify the expense since this supply was available. What this supply does have is fans that can be turned down to run very quietly. As with all the parts, the supply is mounted on foam rubber pads.

I fitted a fan to the inside of the back board (mounted on foam rubber of course) to blow air into the drawer. The fan in the photo was my first attempt, a high volume Delta fan I had spare. I fitted a resistor in order to run it at 6V and reduce its noise. Once the server was running, I realized that this was still by far the noisiest component, and replaced it with a new silent Sythe 500rpm fan (I had also determined that only minimal ventilation was required).

The server build was completed by fitting the Samsung hard drive behind the power supply. I made some mounting brackets out of right angled metal brackets I found at the hardware store (they are actually “concealed perlin cleats”). They allow enough height for me to eventually add a second hard drive underneath the first, although at this stage that space is filled with the surplus power supply cables. I may have to eventually remove some cables from the power supply. The metal brackets are screwed through foam pads into the drawer base.

At this time I don’t intend to use the server with more than two drives (apart from perhaps an external drive used as a shared folder backup). By my calculation, two large drives will give me backup redundancy, plus plenty of storage, whilst keeping the noise, heat and power consumption to a minimum. If I did ever want to add more drives I would have to build them into the shelf above.

The cabinet and server are finally finished.

At the back of the cabinet, I added a filter holder over the fan inlet to reduce dust ingress. The hole next to the filter is for the LAN cable.

And here it is, ready to take its place inside. The next task will be setting up the Windows Home Server, but more about that in Part 3.

Building a Windows Home Server – Craftsman Style

PART 1: A Plan Comes Together.

I told myself that there weren’t going to be any major computer builds/rebuilds this year. I was going to give my wallet a year off. But previous builds and upgrades had left a legacy of unused parts, and I began to consider “throwing a few together” to build a Windows Home Server, just to see what it could do. A server, I thought, doesn’t need a monitor, keyboard, mouse or fancy video card, so it shouldn’t be too expensive. What it would need is something to house it in. I kept the idea in the back of my mind, and then last month when I was thinking about building a new storage cabinet for my home office area, I had an idea to combine it with the server project. I would build the server into the cabinet. A beautiful symphony of woodworking and computing all in one project.

Cabinet Design

My preferred style of furniture is American craftsman style, and I already had a vaguely craftsman style music cabinet in the office area that I wanted to match. To fill the space available, I decided that the cabinet should be about 1.2m high, about 0.6m wide, and about 0.35m deep. I sketched it out with a single door, and five shelves, the bottom shelf being quite deep to accommodate box files. The next shelf up is where the server would be, built into a removable drawer so that it could be easily serviced. As I do not have ready access to a supply of quarter-sawn white oak, and I didn’t want to spend a fortune, I decided to build the cabinet out of plain old pine, stained to a nice deep craftsman brown. My wife and I had previously built a cabinet like this, and it looked fine. And so it was off to the lumber yard.

Selection of Server Parts.

Early on I thought about using a spare ASUS 915P based motherboard I had in storage. It turned there were two problems with this, firstly it was a full ATX board and my available drawer space was limited, and critically, when I tested it I found it was broken. This wasn’t entirely unexpected as I had used this board with an after-market air cooler which used a stick-on back plate. When I removed the board from service, I tried to remove the back plate and ended up damaging the board (I learned my lesson, and next time I came across one of these back plates I left the paper on the adhesive and secured it with the bolts alone).

I considered that my key requirements for the server were very quiet operation, as I didn’t want an annoying noise coming from the cupboard, and low power consumption, as I anticipated leaving it on all day. I also had a spare CPU, but it was a hot Prescott core P4 540. I decided that it would be best to sell that and buy a new low powered processor. Next I considered an important part of any server, the storage. I have a couple of spare 160GB Seagate SATA drives, but I also discounted these on account of their loud seek noise and limited size. I wanted to start with a nice fast, quiet, large drive for the primary partition. Just one drive to begin with, especially considering the data corruption bug in Windows Home Server (power pack 1 beta had not been released). So much for my plans to use left over parts. In the end, after much research I chose the following parts that I thought met the bill:

Motherboard: Gigabyte GA-G33M-GS2R
CPU: Intel Pentium Dual Core E2180, 2GHz
Hard Drive: Samsung HD753LJ, 750GB

The one part I could recycle was the RAM, as I had a spare 2GB Corsair DDR2 1066MHz kit, massive overkill, but otherwise sitting on the shelf unused.

The reasonably priced G33M-GS2R features an unusual mix, for a micro-ATX board, of integrated video (required for easy server setup) and quality components like all solid capacitors, 1Gbps LAN (also essential) and six SATA ports fed by an ICH9R southbridge. In fact one reviewer on the internet wondered exactly who Gigabyte were aiming the board at for this reason: well server builders of course! By the way, the fancy copper northbridge heatsink shown in the photo does not come with the board. After initially examining the board, I did what you shouldn’t, and held the board in one hand by its edge and northbridge heatsink to put it back in the bag. I felt the heatsink give, and knew that I’d broken the thermal material interface. Since I had to remove it and replace the TIM, I took the opportunity to fit a spare Swiftech heatsink (minus its little fan to minimize noise) I had left over from a previous upgrade.

With the parts sorted, it was time to get on with the cabinet build. More about that and making the server in Part 2.