Raspberry Pi For Dummies. McManus Sean. Читать онлайн. Newlib. NEWLIB.NET

Автор: McManus Sean
Издательство: John Wiley & Sons Limited
Серия:
Жанр произведения: Зарубежная образовательная литература
Год издания: 0
isbn: 9781119412021
Скачать книгу
card, and you can’t just copy the file across. (See the section on flashing your card at the end of this chapter.)

Downloading NOOBS

      In your web browser, visit www.raspberrypi.org/downloads/noobs. Two versions of NOOBS are available: The main version of NOOBS includes Raspbian, the officially supported operating system, so you can use it even if you don't have a network connection on your Raspberry Pi; NOOBS also includes a menu for choosing other operating systems to download and install from the Raspberry Pi, if you have a network connection. We recommend you download NOOBS for your first operating system.

      NOOBS Lite leaves out the Raspbian software download and includes a menu to download whichever operating system you want to use. It's a smaller initial download, and it's ideal if you don't plan to use Raspbian. It needs a network connection on your Raspberry Pi to download an operating system, though.

Formatting the SD card

      For best results, you need to format the SD or MicroSD card. You can use a program, available from the SD Association, called SD Card Formatter on Mac and Windows, and you can find it at www.sdcard.org/downloads/formatter_4. You need to read and accept the license agreement before you can download.

      If you’re using Linux, you can use GParted to format the card, as we will show you.

      Earlier models of the Pi used a physically larger SD card, but later ones use a MicroSD card. Make sure you have the right sort. The MicroSD cards often come with a holder to make them look and work like SD cards. (Refer to Figure 1-3, in Chapter 1.) You might have to plug the MicroSD card into this holder to format it on your desktop or laptop computer.

      warning Whichever computer you’re using, you need to be extremely careful in doing this. When you format an SD or MicroSD card, its previous contents are completely erased, so make copies of any files or photos you might need from the card before you begin. Make sure you have a backup of your hard drive, and disconnect any removable disks before you start, to minimize the potential damage from accidentally formatting the wrong disk.

       Using Windows

      The Windows SD Card Formatter software downloads as an executable (.exe) file, so double-click it to run the installation program. Click Next to work through the steps. The program suggests where to install SD Card Formatter, but you can change this location if you want. Finally, click the Install button. You may receive an alert from Windows telling you that a program is trying to make changes to your computer and asking whether this is allowed.

      After installing SD Card Formatter, you can use the Windows Search feature to find it and run it. On Windows 10, click in the box on the taskbar in the bottom left of the screen to start the search. If you’re using Windows 8.1, move the mouse to the top-right corner and click the magnifying glass to open the search. In either version of Windows, type SD and then click the program name when it appears. (On older versions of Windows, run SD Card Formatter from the Start menu in the bottom left of the screen.) When you run the program you might be prompted to confirm it is allowed to make changes to your computer.

Figure 2-1 shows the SD Card Formatter software on Windows. Where it says Select card, select the drive that contains the SD or MicroSD card. If no drive is shown, try clicking Refresh. Check the drive displayed here, and double-check it as often as you need to, because SD Card Formatter erases everything on this drive. It’s a sensible precaution to disconnect USB drives and any other removable storage devices, to protect them from accidental deletion before you go any further.

       FIGURE 2-1: SD Card Formatter, used to format the SD or MicroSD card, on Windows.

      The Quick Format option is fast but not secure, so you’ll receive a warning that data might still be recoverable after formatting. (Don’t count on being able to do so, though!) Click OK to start the formatting. On Sean’s computer, this took a few seconds.

       Using a Mac

      The Mac version of SD Card Formatter downloads as an installation package. Double-click this package to install the software. The software installs by default into the Applications folder. Note: You will need to enter your Mac’s password to do this, and also every time you run this utility.

Insert the SD or MicroSD card into your Mac’s slot, or into a card reader connected to your Mac, and then double-click the SD Card Formatter icon in the Applications folder. When the software opens, the main screen looks like Figure 2-2.

       FIGURE 2-2: SD Card Formatter, used to format the SD or MicroSD card, on a Mac.

      Make sure the Select Card drop-down menu shows the SD or MicroSD card you want to use. This is the drive that will be wiped, so check this as often as you need to for you to be certain. If the right card isn’t shown, use the drop-down menu to choose the right one.

      Next, click the Overwrite Format option to select it. Click the Format button, and SD Card Formatter starts to format the card. Note that there is no need to enter anything into the Volume Label box. That will be completed automatically.

      This is a great time to have a cup of tea, because the card takes about half an hour to format. You can still use your Mac while the process is running, although it might take a bit longer to format if you do. When the formatter is finished, you see the icon of the SD or MicroSD card on the desktop. Note that if the SD card has been formatted before or comes preformatted, clicking the Quick Format option will save you some time.

       Using Linux

      We’re using Ubuntu, the most popular desktop distribution, so you might see some variations if you prefer a different distribution. These steps should give you the guidance you need in any case.

      warning Because this process involves completely erasing a disk (the SD card), make sure you have a recent backup of your computer before you proceed, just in case you accidentally wipe the wrong disk.

      Follow these steps:

      1. You use a utility called GParted to set up the SD card on Ubuntu. If you don't already have it installed, start by installing it from the terminal. Enter the following commands:

      sudo apt-get update

      sudo apt-get install gparted

      You can open a terminal window by using Dash Home in Ubuntu, the applications menu in your distribution, or a keyboard shortcut (Ctrl+Alt+T in Ubuntu).

      2. You use a utility called GParted to set up the SD card on Ubuntu. It needs to be run with root permissions, so start it by issuing a command from the terminal. Enter the following:

      sudo gparted

Figure 2-3 shows GParted running on the desktop.

      3. Click in the top right to choose the correct disk, the SD card.

      Take particular care here. You can cause serious damage to your hard drive if you choose the wrong disk. We know this is our SD card because it’s showing a capacity of 7.4GB and our hard drive has a capacity of 500GB.

      4. The main window shows the partitions on the card. You want to delete them, so click them in turn and then click the Delete icon on the toolbar.

      The Delete icon looks like a No Entry sign, or the