Difference between revisions of "PB:Download a suitable Image"

From Klaus' wiki
Jump to: navigation, search
 
Line 7: Line 7:
 
Once the image has downloaded to you development host find you 4++ GB SD card and a USB device that the card can be inserted into. The reason for using a USB MultiMediaCard (MMC) reader is that it can be very hard to route the built-in MMC card reader, that many laptops are fitted with, from the host operating system to the guest, i.e. to the Centos.  
 
Once the image has downloaded to you development host find you 4++ GB SD card and a USB device that the card can be inserted into. The reason for using a USB MultiMediaCard (MMC) reader is that it can be very hard to route the built-in MMC card reader, that many laptops are fitted with, from the host operating system to the guest, i.e. to the Centos.  
  
Attach the USB card reader with the SD card inserted to your laptop.  
+
Attach the USB card reader with the SD card inserted to your laptop.
 +
 
 +
'''''(NOTE: If you run into a "medium not found" error message at some point it may be your card reader that not supports the type of SD-card you're providing. I ran into this problem with a SDHC card, that one card reader couldn't handle, but another could.)'''''
  
 
In your virtual machine menu find something like this picture:
 
In your virtual machine menu find something like this picture:

Latest revision as of 16:06, 9 November 2020

The PcoketBeagle (PB) does not come with a built-in flash memory, so in order to make it run a suitable image must be downloaded and burnt onto a SD-card.

Jump over to BeagleBoard's download section and get one of the headless images. A headless image is a complete Linux operating system without any graphics support - and therefore also a fair bit smaller than the images with graphics support. At time of writing the "Debian 9.3 2018-01-28 4GB SD IoT" is the most current. It contains a 4.9.78 kernel - a fairly new kernel.

All work here is described using the Centos development host running as a virtual computer. If you prefer to work in Windows there is a description over at [1].

Once the image has downloaded to you development host find you 4++ GB SD card and a USB device that the card can be inserted into. The reason for using a USB MultiMediaCard (MMC) reader is that it can be very hard to route the built-in MMC card reader, that many laptops are fitted with, from the host operating system to the guest, i.e. to the Centos.

Attach the USB card reader with the SD card inserted to your laptop.

(NOTE: If you run into a "medium not found" error message at some point it may be your card reader that not supports the type of SD-card you're providing. I ran into this problem with a SDHC card, that one card reader couldn't handle, but another could.)

In your virtual machine menu find something like this picture:

Screenshot 20180221 155309.png

Navigate to the point where you downloaded the image, typically in ~/Downloads

] $ cd Downloads
] $ ll
total 6.1G
drwxr-xr-x.  2 klaus klaus 4.0K Feb 21 16:02 .
drwx------. 44 klaus klaus 4.0K Feb 21 11:14 ..
-rwxrwx---.  1 klaus klaus 3.4G Feb 20 14:56 bone-debian-9.3-iot-armhf-2018-01-28-4gb.img.xz
...

Next thing is to unpack the image as it comes hard compressed.

] $ unxz bone-debian-9.3-iot-armhf-2018-01-28-4gb.img.xz

after a few minutes, depending on you computers speed you'll end up with a .img file around 3.4 GB.

The .img file contains a fulle disk layout with a boot partition and a root (/) partition with all the Linux utilities.

Transfering the image to the SD card is a matter of locating the correct device. Try

] $ ls -lart /dev/sd*
brw-rw----. 1 root disk 8,  0 Feb 21 16:24 /dev/sda
brw-rw----. 1 root disk 8,  2 Feb 21 16:24 /dev/sda2
brw-rw----. 1 root disk 8,  1 Feb 21 16:24 /dev/sda1
brw-rw----. 1 root disk 8, 16 Feb 21 16:24 /dev/sdb
brw-rw----. 1 root disk 8, 17 Feb 21 16:24 /dev/sdb1

The -lart sorts the output in reverse order so the newest device will be presented in the bottom of the list. If you just inserted the USB-reader the newest device is typical sdb or sdc.

NOTE: NEVER try to use the sda devices. It is your harddisk for the Centos operating system.

Now in order to transfer the image to the SD disk issue

] $ sudo dd if=./bone-debian-9.3-iot-armhf-2018-01-28-4gb.img of=/dev/sdb bs=1M

and wait. Wait even longer. It may take several tens of minutes. Keep an eye on your USB writer - many has a LED built-in and while it blinks everything is working as expected.

After waiting for many, many minutes you'll eventually get something similar to this.

] $  sudo dd if=./bone-debian-9.3-iot-armhf-2018-01-28-4gb.img of=/dev/sdb bs=1M
3400+0 records in
3400+0 records out
3565158400 bytes (3.6 GB) copied, 9276.85 s, 384 kB/s

NOTICE: I've ran into problems with a kernel of this version 4.14.67-ti-r73. The PocketBone does not show up in the network. Find the kernel version by mounting the SD on an other computer, e.g. your laptop, and look into /boot, where you'll find three files with the same version number at the end.