Step 4: Paint, Putty, & Install

Step 5: Assemble & Enjoy

Plug in your SD Card and all your wires into the Pi & Hub. Attach the Ethernet, HDMI, and USB panel connectors with the screws that came with them. ...

I travel a lot and I like to take my media with me. However, I'm rarely end up at places with a strong internet connection and I don't like having to hook up my laptop to the TV. So a couple months ago I decided to build a portable media computer, and as a result, Mjölnir was born.

Mjölnir (so named because it looked like Thor's hammer before I painted it), is essentially a Raspberry Pi, a powered USB hub, and a portable HDD tucked inside an electronic enclosure.

The Raspberry Pi is great, especially when it's tucked away behind a monitor. However, it isn't perfect as a something to carry around with in your travels. To make it as small as possible the connections are all on different sides of the board. Plus, once you've found them all, you have to hook up the pi to a hub, the the hub back to the pi to power it, and then your portable HDD into the hub, then plug in power to the hub, HDMI into the pi, and ethernet. . . . on and on. And a crow's nest of wires does not look very good.

Mjölnir was born out of a need for simplicity. I wanted it to be just like a tiny computer, all the ports at the back, just plug things in and go.

If you follow these instructions you too can have a portable media computer for around $215.

POST NOTES:

Wow, the feedback and response to this has been incredible. Thank you to everyone that has viewed it and commented. I'm glad the majority of you like it. After recieving some feedback I'll try to clarify some points I failed to make in my instructable:

Orientation - The removeable plate is actually the bottom. I attached bits of Sugru to that for feet, and after I closed the lid I flipped it over and that's the bottom. Showing pictures of the internal configuration made it confusing, because when you see inside the case with the panel removed, you're actually looking at it upside down.

WiFi - Originally i had one of the ports on the USB hub for a WiFi Dongle; however that thick aluminum blocks all WiFi. I don't need WiFi (like I said I use this mostly in places where there isn't internet); but if you' need one I'd recommend buying another USB panel connector and mounting it just above the first one. There should be an open port since I have my fan plugged into the Pi directly.

Fan & Temp - Yes, that is a 12V fan, and yes USB only puts out 5V. It doesn't run at full speed (or even half speed), but it moves enough air for the little heat my HDD makes and it's super quiet. I watched many hours of full 1080p content over the weekend and the Pi's CPU never got above 54C.

The OS - I'm running RaspBMC (http://www.raspbmc.com/) which is a custom Linux kernel based on Rasbian which in turn is based on Debian Wheezy. Once installed it boots directly into XBMC which is all you can use. This was a big plus for me, because this makes it very user friendly for my friends. If you're looking for a full fledged computer with a browser, games, etc. this probably isn't for you.

The Pi will also support OpenElec (XBMC) and RasPlex (Plex) as OSes.

Control - So one of the reasons I choose the Pi is because it supports CEC over HDMI. This means that MOST newer TV's can control the pi using their factory remote. This was a big plus for me, because this makes it very user friendly for my friends.

Cost - Yes, as mentioned at $215 you're almost into NUC territory. However, remember that includes 2TB of storage, memory , and remote control (through CEC). Additionally, I, like so many of us, already had a Pi, an external HDD, Sugru, many of these cables lying around. So the cost ended up only being less than $100. I included the TOTAL cost for someone wanting to start from scratch. Just so they know what they'll be getting into.

Step 2: Create your cables & reset switch

You need to make 3 custom cables for Mjölnir, and they will all come from that random USB cable you found.

USB to Fan

The USB to Fan cable is very easy.

Cut the cable about 4 inches from the USB plug.

Remove about 1/2 an inch of the outside rubber.

Pull back the metal sheeth and insulation and remove it.

Clip back all the inside wires except the red and black ones.

Take the fan wires and the USB cable and match red to red and black to black.

Solder or twist together and cover in tape.

Power Cable

You need something to go from the panel adapter to the USB hub. What I ended up using was a couple more inches off the USB cable you just chopped up. Here is the panel adapter that you'll be using. Basically, we're making a coupling from the outside of the case to the USB hub. The two pieces match the female and male plugs of the hub perfectly.

Cut the cable about 4-6 inches long.

Remove 1/2 inch of the outside rubber from both sides of the cable.

Pull back the metal shet and insulation and remove it.

Clip back all the inside wires except the red and black ones.

Using your voltmeter work out which connector goes to the barrel and which connector goes to the pin.

Solder the wires and cover in tape.

**NOTES**

I couldn't use the little plastic cover on the male part that goes into the hub inside the case. It just didn't fit, so I went without and covered it in a little sugru.

I also would recommend either putting in some connectors into your power cable or waiting until the end to put it in and finish the connector because the male piece will not fit through hole you drill for the female piece that attaches to the panel.

Reset Switch

The reset switch is a bit of a two-parter.

First you need to solder the headers onto Pi, then you create the cable/switch for the panel.

I didn't end up using a panel mounted switch and a custom wire for my reset switch because I had this switch left over from a previous project.

Step 3: Drill some holes

Panel Holes

You will need holes for the power adapter, HDMI plug, Ethernet, USB, & reset switch.

Fit all the components into the box and take measurements of where your panel holes need to be cut on the inside of your case.

Using your measurements put your cables on a piece of paper and trace where they should be.

Cut out the holes of the paper and transfer the layout to the outside of the case.

Using a dremel or rotary tool cut out the holes & then drill out the screw holes.

Vent Holes

I drew up a pattern for drilling that would fit my 40mmX40mm fan nicely. I put one vent on the front left (looking at the case and assuming the panel connections would be rear) and one on the rear right side to get as much cross ventilation as possible. I used a Rigid drill bit that was recommended to me at Home Depot for metal drilling and it made it through all the holes. Almost 200!

To be honest having a drill press to do this would have been nice. My holes aren't exactly in straight lines. . . but it's not terrible.

I printed off my pattern and taped it to the case where I wanted it then simply drilled through the paper, as shown in the photo.

Step 4: Paint, Putty, & Install

Paint the case whatever color you want and while it's drying install your choice of XBMC on your SD Card.

After the paint has dried attach the fan to one of the vents (the front one fit best for me). I had no desire to use bolts so I stuck it to the vent with a bit of Sugru in each corner.

Then, since my reset switch wasn't designed for panel use, I attached it to it's proper hole using Sugru as well.

I added 3 pieces of Sugru to the bottom of the Pi so it doesn't rest on it's pins.

Finally, I put 4 pieces of Sugru on the bottom of case to act as little rubbery feet.

All in all I used two mini packs (5g each) of Sugru.

Step 5: Assemble & Enjoy

Plug in your SD Card and all your wires into the Pi & Hub.

Attach the Ethernet, HDMI, and USB panel connectors with the screws that came with them.

Put your HDD on top and close up the case.

Plug in your HDMI & Ethernet, set your TV to the right input, and plug in your power to watch the magic happen.

The bending of cables was the biggest space waster. I think ribbon wires are a great idea, but cost & getting them to mount easy into the panel was the problem.

I think the next version I'll look into putting together all the connections into one plate. . . and having the whole thing mount into the box; then using thinner ribbon cables for connections to that.

I finished it! It's amazing! A couple of things I did different: I added a power button to the front (mostly because I liked the blue LED) and added a second USB port to the front as well to either: add an IR remote later down the line (important when traveling as hotels' wi-fi will not allow pass through for XBMC remote app), or [more importantly] to have easy access to a game pad in order to load emulators on it. For the rear one I've plugged in Adafruit's $19 wi-fi antenna which gives me great reception even on my upstairs TV. Also, I added 1 Channel to XBMC which will allow me to cancel my Netflix and Hulu subscriptions.

The problems I faced were:

-adding those things to the front took up a LOT of space (you weren't kidding when you said it's tight!), and so no matter how I tried (including taking the hard drive out of the enclosure) I couldn't get the hard drive to fit, so when using that I need to use one of the USB ports

-That die-cast aluminum project box was an absolute [enter expletive of your choice] to work with. Extremely stable with a good weight, so I can see why you chose it, but without all of the right tools it's a nightmare. I destroyed the back when the the drill bit got stuck on the box and kept spinning.

I'm going to create a couple more for my other TV and one for the road. Version 2.0 will have some minor changes:

Well, when you flip it over that's how everything sits. Because the way the thing is shapped and the screw holes on the bottom; I made that plate that comes off the bottom so everything from the assembly stages is flipped upside down. Sorry, that was pretty unclear in the instructions.

I would like to better mounting solutions for both the pi and the HDD so they're not just kinda in limbo in there. The stiff cables really keep everything from moving; but having dedicated standoffs for the pi and something for the HDD would make me feel better.

Alright! All my parts have come in - hopefully I'll get a chance to build this weekend! One more question for you - what voltage/amperage worked for you to power it all so I can find an adequate transformer?

I think that I'll build a variant of your project. The main differences will be that (1) I need the RCA composite video connection to be available and (2) I need it in a plastic case so that the WiFi module can work.

Why composite video? Both our cars have flip-down screens and dvd players, but they also will accept RCA composite video inputs. On a long trip, the kids can have the entire family video library available without having to mess with physical dvds.

Why plastic? So that the WiFi will work. I will need to be able to control XBMC via a remote control app (Yatse) on a phone/tablet so the Mjölnir has to be able to join the car's WiFi environment. As soon as I can find the right plastic case, I'm off and running. In your searching, did you come across any plastic cases that would have worked?

You could definitely find a plastic case about the same size doing a little bit of googleing. Something like polycase.com might have what you're looking for. If you wanted the ruggedness of the metal you could simply plug your WiFi dongle into the exterior USB port on the current plan. If you needed to you could run a second USB panel mount.

As far as the amps of the power supply I'm not sure. I'd have to manually check the output of that hub's USB ports to see what they're pushing. Whatever it is; my pi runs very stable even with having a fan hooked up to it and using a preconfigured overclocked profile.

I just used RaspBMC because it's what I first installed. I know it's an easy install, and I know it works. I have done an OpenElec install, and it works just as well. It's kinda just personal preference.

If you want a full rundown on various XBMC Pi Installs check out Lifehacker's article here.

Brilliant! I just ordered all of the parts and looking forward to making this for our vacations!Doing that, any way you can think of to control to xbmc without being in my home wireless? Do you know if it can broadcast a point to point so I can join with a phone to control it?

1) If you are lucky, your fancy new flatscreen TV will support CEC and you will be able to control the Pi via the remote your TV came with. I have been able to control my Pi with every TV I have plugged it into, but I have friends that claim otherwise. I think a lot of it depends on how old the TV is and how many other CEC devices are plugged into the TV at the same time.

You have definitely encouraged me to reconsider my case for my pi! I currently use a lego case that I built using LDD. I might even redesign so as to allow it to be even more portable. My suggestion regarding the WIFI issue, why not extend a USB port just to the outside of case to plug the wifi card into? Maybe like a right angle USB port?

You can definitely do that. The plans already include one USB port extended to outside the case that could be used for a WiFi dongle. That's currently what I use it for. I'd extend a second one if I ever needed it.

I have not done any custom overclocking of my pi. However, in RaspBMC there are "Performance Profiles" that have pre-configured overclocking profiles for you to select from. I have mine running on the medium one (Fast) WHILE pulling power from the Pi to the fan and it works perfect.

Compared to some, my CD collection is not all that big, just a few hundred disks, but I don't look forward to ripping them all even the first time. The thought of doing it a second time if anything happens to the drive makes me cringe. Is there any way to set this up as a raid array?

Its nice because you can hold it lengthwise like a remote and use the arrows to navigate, or turn it horizontal to use the keyboard. It also has a lighted keypad. I use it with my google tv all the time.

A question: if I used a plastic box and put a wi-fi dongle in there, would this work as a media center for my home that could be stuck behind the TV and taken with to our vacation home for favorite movies on rainy nights or as a music source for hanging around on the back deck?

Will it work as a media center for your home & for the road? Yes. Perfectly actually. That's pretty much what I use it for. I have it hooked up at home right now, and this weekend when I'm on the road again it will be coming with me.

However, I am not sure that the wifi signal will pass through a plastic case if that is what you're asking. Someone with a better understand of 2.4Ghz or 5Ghz wireless signals and polymers might need to take this one. I'm going to guess that it would pass through alright, but I know it will have to do with the density and thickness of the material you end up using. I do know that if it is blocked you'd need about a 5 inch hole to let those waves pass through uninterrupted.

What you could do (and what I do); is plug in a Wifi dongle into the USB port on the back when I'm at home (or utilize the Ethernet jack); then I just take it with my when I travel and I don't need internet.

You need internet for the initial set up. But once you're running you don't (assuming your files are on your external HDD like my setup shows).