Pi On The Wall – wall mounted home server – Part 4: Putting it together

This is part 4 of the Pi On The Wall build log, concerning modifications to the enclosure and how everything comes together into its final form factor. Part 3 was about power consumption, and optimizing it for low-power and ultimately low-temperature running. Previous parts can be found at Part 2 and Part 1.

41zJZupMBKLThe choice to use a standard (for the UK, anyway) footprint for the Pi On The Wall was made very early on. Ease of mounting to the wall (compatibility with existing wall-fixtures) and a wide range of cheap thermostats to choose from for simply utilising their outer shell.

thecaseAfter removing the guts of the £12 wall thermostat I purchased, the inside was what you’d expect – mounting posts for the PCB, guides for the LCD panel, and a PSU block behind it.

Internally, all I was planning on doing was removing as much of the PCB and LCD supports as possible – there was quite a few and they really restricted the usable space inside the case. A hobby drill and knife were enough to completely re-engineer the inside to suit my needs for maximum possible space (whilst still keeping some of the LCD guides, for the new panel). The following image shows the sort of supports that existed.

front_rear_unmodified On the rear panel, I removed the PSU block and smoothed the pcb supports whilst removing a notch for the flush USB connector.

case_modificationThe front panel ended up looking as follows after installation of the front TFT, after many hours of making sure it was perfectly straight, and holding it down with glue.

front_screen_buttonguidesNote the hole bottom right, for the PIR sensor/lens. It was countersunk to make it ‘neat’ and I messed it up. Which it why there is now a grommet on the opposite side, as the hole is too large for the sensor.

Also of note are the red straw tubes hot-glued into locations around the buttons. The straws are actually cut from the one provided with a can of WD-40, as I didn’t have anything else the correct size. The reason for these straws are made clear with the next image.

button_pcb_guidesThey form the guide for the small off-cut of PCB from the original thermostat which housed the tactile switches for the front buttons. The top one is flush with the PiTFT circuit board giving it a good fit.

frontpcb_wiringThe traces on that board were cut and the switches were directly connected to the 4 GPIO buttons on the PiTFT. There is not much else on this half of the enclosure, the main components (minus the actual panel itself) are laid out below.

raw_front_pcbsThe PIR motion sensor module was rather annoying in that it took 5v input and provided a 4.4v logic level signal when movement was detected. This is voltage divided through to 3v3 for a Pi GPIO input and is designed to switch on the back light of the PiTFT when movement is detected in front of the unit and works well. You can see some foam underneath the tactile switches, there is some on the other side as well when the case is fully closed to keep the pressure correct for the panel buttons. The PIR unit itself was deconstructed for ease of positioning the components, with 0.2mm enamelled wire being used to connect the sensor to the control board, as normal wire was too thick to also allow for the USB connector to fit snug above it.

heatsink_clampSomething I failed to write up well was the heatsink I designed for the Pi On The Wall. It needed to be incredibly low-profile due to the fact the PiTFT board was only 4mm above the Broadcom SoC. Using some very thin metal I cut out a strip which I moulded into a clip-like shape, which would clip either side of the PCB and provide some feedback into the top of the SoC whilst giving enough clearance to other components on the board.

heatsink_sinkAfter that some copper wire was soldered to the metal and arranged so the top of the SoC conducted thermally with the copper, with the help of some paste. The wires were routed to what would be the top side of the board, where the case has ventilation holes. I cut a small aluminium heatsink into two strips and then soldered the wire to those sinks, very poorly. Aluminium does not solder well and I only managed a very weak bond using the oil+scrape method. Soldering a heatsink really is as stupid as it sounds.

Amazingly, however, the heatsink works. It averaged 2 degrees Celsius of a saving over a days worth of burn-in testing. On a very hot day (for UK standards) the SoC was reporting after several hours of burn in that it was 42 degrees Celsius. This was using the ondemand governor with a 350-500MHz working range. I actually don’t think underclocking from 700 to 500 made a massive difference, but I’ve kept it at that value.

BujMHAACcAE0g93The last item is the power supply block. The AC-DC adaptor I choose fit nicely into the case and had enough room to fit the MP2307 5v->3v3 converter, as well as some required capacitors. The capacitors I eventually settled on are different from part 3, as I went from a phone charger 5v rail to this and it had different characteristics. A switch is included to hard-restart the Pi when required. 200uF is provided on the 5v rail mainly to allow for USB hot plugging, which the Pi is spectacularly terrible at.

power_sch_latest powerpsu_cableFinally, I made a video which goes into further detail about how the components all fit together. This was released a few weeks ago, but compliments this part of the build log well, so it is below.

The last part will be on the software running on the PiOnTheWall. Thanks very much for reading, I hope it was interesting!

As always, you can reach me on twitter @domipheus.