Powering the Router and Illuminator
By Patrick Wigmore, , published: , updated
Having decided to put a BT Home Hub 5a in the garden to record videos of hedgehogs, I needed a way to power it.
I didn’t want to spend money on a massive battery or solar panel. The most obvious strategy, then, seemed to be to extend the router’s DC power cable, so that the power adapter could be plugged in indoors and a long cable run outdoors to the router.
Unfortunately, the router uses a DC barrel jack with non-standard dimensions. I couldn’t find a matching plug or socket for sale anywhere online, let alone an extension cable fitted with them.
Instead, I made do with cutting the router’s power cord in two and fitting a standard DC barrel plug and socket to the cut ends. I bought a DC power extension cable, marketed for CCTV purposes, which could then be connected between the two ends of the modified power cord.
Router USB current limit
On the page about the IR illuminator, I mentioned that the IR illuminator breaks the rules, because it doesn’t ask the USB host for permission before pulling its full 380mA current.
Well, it turns out that one of the shortcomings of the BT Home Hub 5 Type A is that its USB port can’t supply very much power. In fact it can’t even supply 100mA reliably, as required by the standard, so it, too, breaks the rules!
To solve this problem, I bought a small DC to DC buck converter module and installed it inside the router. I rewired the USB port to take its 5V supply from the new converter instead of from the main board.
With hindsight, supergluing the buck converter to the side of the WAN port was a mistake. I thought I’d been clever and found a nice neat space to fit it into, but then I realised it was too big and it proved impossible to unglue it without damaging anything. I had to cut a hole in the case to get it to fit back together again.
The buck converter is powered directly from the incoming 12V supply. The router only uses about two thirds of the supply’s capacity, so there was plenty of headroom to power the IR illuminator.
It’s a bit ironic that I went out of my way to build a 5V IR illuminator and then ended up having to convert 12V to 5V in order to run it.
Voltage drop in the supply cable
It is difficult to determine the resistance of random DC barrel jack extension cables from eBay, prior to purchase. Mine turned out to have a resistance of 1.2Ω per wire, for a 2.4Ω round trip.
The resistance of a cable causes voltage drop when a current is drawn through it. This is just Ohm’s Law. If the load draws I amps, and the cable has resistance R, then the voltage drop in the cable is V=IR. So, if 1 amp is drawn through cable having a total resistance of 2.4Ω, the voltage drop in the cable will be 2.4 volts. If the supply voltage is 12V, this means that the load at the end of the cable will only see 9.6V.
Voltage drop under constant power
The router, with the camera and the IR illuminator plugged into it, takes something in the region of 4 to 6 watts. Let’s say it’s 6 watts.
But the router has what’s known as a “constant power” characteristic, and that changes the calculations. As the external supply voltage reduces, the router ends up pulling more current to compensate, consuming the same total power overall. This is caused by the use of switching converters to generate the router’s internal voltage rails.
In practice, the basic method assuming constant resistance is fine if you just want rough idea of whether or not the cable is going to melt, and whether the router has any chance of running on the remaining voltage at the other end. At the end of the day, I was still going to have to plug it in and see what happened, to find out what kind of voltage range the router would tolerate.
But I thought it would be interesting to calculate the voltage drop under constant power, so I had a go anyway.
Calculating voltage drop under constant power: recursive solution
One way to work out the voltage drop under constant power is to apply the basic Ohm’s Law method recursively. Work out the current, work out the voltage drop, work out the current, work out the voltage drop, and so on. Eventually it’ll converge on a value you can use.
Calculating voltage drop under constant power: algebraic solution
It’s also possible to reach a solution algebraically:
Formula for current:
Formula for voltage seen at the load:
Substitute the formula for I into the formula for the voltage at the load:
Multiply both sides by V~load~:
Subtract from both sides, giving:
This equation is recognisable as a quadratic in the form where , , and , which can be solved using the quadratic formula:
This gives two solutions, which turn out to correspond to the voltage drop in the cable and the voltage at the load.
and
Substituting in the known values
, and
Gives
and
In other words, I could expect the router to see about 10.7V for its supply when it is connected to the end of the long cable.
This voltage drop wastes about 0.8 watts of power in the cable.
Practical consequences of voltage drop
In this case, it turned out that the router worked perfectly well on what was indeed about 10.7V, so there was no real problem.
0.8 watts over the length of the cable is not a major issue, especially given that it’s used outdoors and not coiled up.
Had the router not enjoyed running on a reduced voltage, I probably would have installed a boost converter at the router end of the cable, to bring the voltage back up to 12V, rather than trying to find a different cable with a known, lower resistance.