First off, I'd like to welcome you to this title. By the end of this book, you will be able to set up a comprehensive media center that will serve you well for years to come. Each chapter will guide you through the basics so that by the end of the book we will have gone from a basic system to a comprehensive and complex one that meets your needs.
In this chapter, we will cover the following:
Why Raspberry Pi is a good hardware choice to be used as a media center
The equipment needed to build a Raspberry Pi based media center
What Raspbmc is, and what it can do
Installing Raspbmc onto an SD card using Windows, Mac OS X, or Linux
Booting up Raspberry Pi to complete the installation
The Raspberry Pi is a small, credit card sized computer launched in 2012 for the purpose of rekindling a dwindling interest in Computer Science. The device therefore had to be affordable, have a low power consumption, and a small form factor. These characteristics are also what make the Raspberry Pi such an appealing solution as a media center. The Raspberry Pi is silent, and a quiet system is essential for an ideal media center experience. The Raspberry Pi may seem like a low performance device for education, however it has HDMI output. Its Ethernet capabilities and powerful GPU capable of decoding full HD videos has attracted much attention. Furthermore, as the operating system runs on an external SD card, a type of memory card, the device itself cannot be bricked, and can always be restored to a working state by reinstalling Raspbmc.
You will need some equipment to use your Raspberry Pi as a media center; you may or may not have some of these components already. These components can be obtained from most retailers and are relatively inexpensive:
Power supply: The Raspberry Pi requires a micro USB power supply capable of providing 700 mA at 5 volts. As a media center, this supply needs to be reliable, so it is worth picking up a charger capable of at least 1 mA. You can even pickup a charger that is 2 A, but you should ensure that the charger does not exceed 5 volts. It should be noted that not every power adapter will work on Raspberry Pi, mainly because many chargers' output specifications are printed by the manufacturer, rather than regulated independently. A list of good power supplies can be viewed at http://elinux.org/RPi_VerifiedPeripherals#Power_adapters.
SD card: This is the card that the media center operating system will run from. Not much space is needed, even in library mode, so an 8 GB card would suffice. It is strongly recommended that you use a Class 6 or Class 10 SD card. This is usually denoted on the card with a number that is encompassed in a circle. Sandisk Ultra cards are reliable, and recommended. The following screenshot shows a Sandisk Ultra card:
Card reader: You may already have this on your computer, but if you do not, you'll need a card reader to install Raspbmc onto your SD card. These can be obtained from most electrical retailers as they are commonly used for digital cameras.
Network cable: An Ethernet can be used to connect and install the software on your device. You may also use this later for streaming media. You can also use a supported Wi-Fi adapter with Raspbmc. Refer to Appendix C, Supported Peripherals, for a list of supported adapters. However, it should be noted that installation is possible without a network connection.
HDMI cable: If you wish to use CEC support (discussed later in this book), which allows you to use your TV or AV receiver's remote to control Raspberry Pi, you will need an HDMI 1.3 or later compliant cable.
Remote: This is entirely optional, as controlling the Raspberry Pi via other means is possible. For a full list of supported remotes, please visit http://www.raspbmc.com/wiki/user/configuring-remotes.
Raspbmc is a highly optimized and dedicated media center for Raspberry Pi. It brings XBMC to Raspberry Pi in a fast and self updating package in an easy-to-use manner. This is because Raspbmc has been built specifically for the purpose of running XBMC. Raspbmc is flexible and allows expansion via the Debian packaging system. For example, it is possible to utilize GPIO (general purpose input output) to configure a custom infrared receiver.
XBMC is an open source media center that runs on all major platforms. It began as a project for playing back media on the original Microsoft game console, and it now runs on many platforms. XBMC is not limited to just media playback, and sports a lot of functionality, such as plugins, add-ons, and media scraping. XBMC's existence on the Raspberry Pi can be greatly attributed to the work of Edgar Huceke and Scott Davilla. You can learn more about XBMC at www.xbmc.org.
Hardware playback of HD (up to 1080p) content in formats H264, MPEG2, and VC1, and MPEG2 and VC1 codecs must be purchased separately
Playback of multiple music formats (MP3, AAC, FLAC, and more)
Streaming content from a computer over a variety of streaming protocols
Support for different looks via skins
Streaming content from attached hard drives via USB
AirPlay support (with compatible iOS devices)
Watch and record TV on your device
Raspbmc can be controlled via a USB remote, a CEC-compatible device, or via a smartphone
Using various plugins, you can use online video and music services such as YouTube, Spotify, and iPlayer
Ability to create a media library that automatically downloads TV shows, film information, and FanArt
Ability to share this media library across multiple devices, including Windows, Linux, and Mac OSX systems
Automatic updating means that Raspbmc is always running at optimum performance and has the latest version of XBMC
Raspbmc can be easily installed from Windows, Linux, or Mac OS X. With the help of a computer, you can install the Raspbmc installer on to the card. You will need an Internet connection on your computer for this. This installer will then configure the Raspberry Pi by grabbing the latest version of Raspbmc. The part where the user installs Raspbmc onto the SD card using a computer card can also be referred to as imaging.
The installer for Raspbmc can be obtained from http://www.raspbmc.com/download. As instructions for downloading and running the installer are already available on this page, the instructions given in this chapter will be condensed.
You should double-check you are installing Raspbmc to the right device before imaging. You can reduce the likelihood of imaging the wrong device by temporarily removing devices that you do not want to image, such as USB sticks.
If your SD card is not already listed in the grid, verify whether it is inserted and click on the refresh icon. If you wish to configure advanced options, such as installing to a USB drive, or wireless networking settings, tick the appropriate boxes.
Simply check the SD card that you would like to image, accept the license agreement, and click on the Install button. This process will take up to five minutes, as your computer downloads the latest Raspbmc setup image and writes it to your SD card.
The installer for Mac OS X and Linux is written in Python, and running it as per the instructions on the web page should lead you to a screen similar to the one shown in the following screenshot:
Simply follow the instructions to select the correct device to image. The script will then download the setup image and write this to your SD card. When this is done, the device will be safely removed, so it is safe to remove it. Similar to the Windows installer, there will be an option to configure network settings or USB/NFS installs.
In the rare instance that the installers do not work on your system, this web page also has an image that can be downloaded if the user wishes to image the card with their own software. Select the Network Image option for downloading. If you do not have a network connection on your Raspberry Pi, you should choose the Standalone Image option.
For Windows, an alternative to the Raspbmc installer is Win32DiskImager or the USB Image tool. For UNIX systems, the following command would suffice, assuming that the filename of the compressed image was
gunzip âc installer.img.gz | sudo dd of=/dev/sdb
Now that we have imaged the card, we need to prepare Pi for its first boot:
Attach a network cable or your USB wireless dongle to the Raspberry Pi's Ethernet port and the Ethernet port of a switch or router (note that this is not necessary if you have used the Standalone Image option).
Attach the power supply and connect either the composite or HDMI video connection so we can view the installation's progress on a display.
The connection to the Raspberry Pi should now look similar to the following screenshot:
With everything connected, plug in the charger. You may need to change the input on your display device if this does not automatically change for you.
Unless you installed using the Standalone Image option, Raspbmc will now connect to the update server and install. This usually takes around 20-30 minutes on a home broadband connection, as Raspbmc must download the latest version onto your device. This process is entirely automatic, so feel free to take a break and come back later.
For a few seconds, you may see a rainbow colored screen. This is to be expected and will disappear a few moments later.
In this chapter, we covered what makes the Pi appealing as a media center device, what Raspbmc is and what it brings to the tablet, how to connect your Pi, and how to install Raspbmc. This chapter makes an ideal reference to revisit if you need to reinstall or configure another device at a later date.
In the next chapter, we'll look at how to control Raspbmc, how to navigate Raspbmc's menus, how to change important system settings, installing plugins in Raspbmc (such as iPlayer or TVCatchup), and installing additional codec support (such as MPEG2 and VC1).