Difference between revisions of "Boot setup" - Pandora Wiki

m (In the case of a broken R button: typos)
 
(21 intermediate revisions by 5 users not shown)
Line 1: Line 1:
==Introduction==
+
The uBoot bootloader normally boots the OS from NAND, but it can be inhibited by pressing R while starting up to for example pick SD-card booting. This can also be set up with text-files, making it the default behaviour.
  
== Booting the Pandora OS from SD ==
+
==Set up your boot.txt==
 
 
The hardware is capable of booting entirely from SD (as is used for the section above); if the device is bricked or otherwise has a blank [[NAND]], this could be an option. Furthermore you're able to try out alternative operating systems without needing to reinstall your primary operating system and boot your system regularly from one of the SD cards.
 
 
 
There are several possible approaches:
 
 
 
* Boot entirely from SD card, with a single partition (which must support linux permissions, [[ext2]], [[ext3]] etc)
 
* Boot from SD, but with multiple partitions for boot, root and even swap. It used to be the case that this was necessary, to permit a FAT32 boot partition to exist.
 
* Setting things up to boot from [[NAND]], but use the SD as a root partition
 
* More complex mounting strategies, extending a single filesystem across SD and NAND.
 
 
 
Some strategies will require that you keep one SD permanently mounted, and could result in a non-functioning setup if that card is lost. [[PND]] files make it easier to swap in and out applications, but any permanent storage required by the application will generally be kept in a separate location.
 
 
 
As described in the [[Ångström]] page, the Pandora is able to boot from an SD card.
 
This tutorial explains the steps necessary to create an SD card with a copy of the Angstrom operating system which you can boot.
 
If you do not want to run these steps manually, there also exists a utility (as a standard [[PND]] package) which can guide you through that process: [http://www.pandorabits.org/?page=sd-installer Pandora SD installer]
 
 
 
{{hint
 
|Note: This tutorial assumes you are using Linux, and gives examples which should run on your Pandora.
 
}}
 
 
 
==Get a copy of the firmware==
 
 
 
There are methods you can use to get the data off your Pandora's [[NAND]], [http://www.gp32x.com/board/index.php?/topic/54290-up-to-date-firmware-tarball this topic] discusses them. It is easier, however, to just extract a tar file.
 
 
 
*Take a look [http://openpandora.org/firmware/ here] (pandora-rootfs.tar.bz2 is what you want) and get the latest version from the official Open Pandora site. Note that this firmware version may be unstable and comes untested!
 
 
 
*Download [http://pandora.digital52.com/downloads/Angstrom-pandora-xfce-image-glibc-ipk-2010.4-test-20100614-omap3-pandora.rootfs.tar.bz2 this old reference image] if you are having trouble with the first link.
 
 
 
*If the two above don't work, you can download an [http://www.codejedi.com/pandora/libpnd/pandora-xfce-image-omap3-pandora-20101705-image-for-checking-fixes.tar.bz2 even older image].
 
 
 
*You can also copy your running firmware on the NAND to the SD partition. This is shown in its own section below.
 
 
 
 
 
==Option 1: Use the GUI-driven SD installer tool==
 
 
 
Instead of installing the firmware manually on the SD card (as described further below under "Option 2"), you may use the '''GUI-driven tool sd_installer.pnd by David Boucher''', which automates the entire process.
 
http://repo.openpandora.org/?page=detail&app=sd-install-2011-03-10
 
 
 
You only need the downloaded firmware tarball, the sd_installer.pnd and a suitable SD card.
 
 
 
 
 
==Option 2: Manually install the OS on the SD card==
 
 
 
===Partition your SD card===
 
 
 
This is an optional step.
 
 
 
If you want to slice your SD card into several partitions (see [[#Setting_up_mutliple-partition_SD_cards_for_booting|Setting up mutliple-partition SD cards]]), you can use the ''cfdisk'' command-line tool on the Pandora to create a partition table. Note that - as of Zaxxon HF5 - the Pandora firmware doesn't have a command to format FAT partitions, so if you want to use the FAT/ext2/swap - scheme, you'll have to format the first partition on another system later on (under Windows, use the Disk Management tool).
 
 
 
Assuming your card is in the left slot:
 
 
 
<source lang="bash">sudo cfdisk -z /dev/mmcblk0</source>
 
 
 
'''WARNING: mmcblk0 will [http://bugs.openpandora.org/index.php?do=details&task_id=237 not necessarily be the left slot]. It's the first card that the system recognizes, which is ''usually'' the left slot (but not if you inserted an SD into the left slot after you had one in the right slot, for example). Please make sure before you do anything dangerous.'''
 
 
 
cfdisk -z starts off with a clean partition table - if you want to see what's set up currently, use ''cfdisk /dev/mmcblk0''.
 
 
 
Use only primary partitions (so you're limited to four slices).
 
 
 
===Format SD card to ext2===
 
 
 
You need to format your SD card to have a single ext2 partition; ext3 also works<sup>[http://www.gp32x.com/board/index.php?/topic/54928-64gb-sdxc-cards/]</sup> and is more reliable<sup>[http://www.gp32x.com/board/index.php?/topic/54928-64gb-sdxc-cards/page__view__findpost__p__901072]</sup>. You can have a second, swap partition, as well if you like. There are command line tools you can use as well as GUI tools.
 
 
 
====Using the command line====
 
Take care with using these command line tools, to be certain you are accessing the correct device. They will not ask you and will DESTROY any data on the device. This command will replace an existing partition with an empty EXT2 formatted filesystem (this includes the single FAT partition most SD cards come shipped with). Assuming ''/dev/mmcblk0p1'' for your SD device (left slot, first partition), ''LABELNAME'' for the partition:
 
<source lang="bash">
 
mkfs.ext2 -L LABELNAME /dev/mmcblk0p1
 
</source>
 
If you run into problems with formatting the SD card, try unmounting it first:
 
<source lang="bash">
 
sudo umount /media/[LABELNAME of SD card]
 
</source>
 
 
 
====Using a GUI tool====
 
The GUI tools are simple enough that you shouldn't need someone to tell you how to use them. For now this is left as an exercise left for the reader (until someone wants to write up how to do it).
 
 
 
===Copy and boot===
 
 
 
====Copy the files to your SD card====
 
Navigate (cd) to the directory with the .tar.bz2 file you just downloaded (or made) and do:
 
 
 
<source lang="bash">
 
sudo tar -xvjf <tarfile>.tar.bz2 -C <SD card>
 
</source>
 
 
 
If you're doing this on your Pandora, <SD card> is something like /media/mmcblk0p1 (first SD card slot on Pandora). On Ubuntu it would be something like /media/disk if it has no label. You can also try using GUI tools for this, but I didn't have very good luck with them.
 
 
 
====OR copy your firmware from the NAND to the SD card====
 
 
 
The following will ask for your password. All the operations need root permissions so I thought it would be wasteful to sprinkle sudo to everything.
 
We will bind mount the root fs to an alternative location ("/mp"), under which other filesystems mounted under root (like the kernel virtual filesystems /proc and /sys, and your SD card.) wont be visible. This allows us to take a live copy of the NAND contents to the SD filesystem. 
 
 
 
<source lang="bash">
 
sudo su
 
mkdir /mp
 
mount --bind / /mp
 
cp -va /mp/* /media/<SD card>
 
umount /mp
 
rmdir /mp
 
exit
 
</source>
 
 
 
====Set up your boot.txt====
 
  
 
Create a new file called boot.txt (or autoboot.txt if you want to boot automatically) and copy and paste the text below. Copy that file to the root of the root of the SD card.
 
Create a new file called boot.txt (or autoboot.txt if you want to boot automatically) and copy and paste the text below. Copy that file to the root of the root of the SD card.
Line 110: Line 7:
 
{{warning
 
{{warning
 
|If you edit the file on Windows, use an advanced text editor like [http://notepad-plus-plus.org/ Notepad++] and be sure to convert to UNIX format (in NP++: Edit -> EOL Conversion -> UNIX format). If you have DOS linebreaks, ext2load will fail with an error like "file not found" as it appends an hidden character to the uImage file name.
 
|If you edit the file on Windows, use an advanced text editor like [http://notepad-plus-plus.org/ Notepad++] and be sure to convert to UNIX format (in NP++: Edit -> EOL Conversion -> UNIX format). If you have DOS linebreaks, ext2load will fail with an error like "file not found" as it appends an hidden character to the uImage file name.
}}
+
}}boot.txt (from the [http://openpandora.org/firmware/README.txt official firmware site])
 
 
boot.txt (from the [http://openpandora.org/firmware/README.txt official firmware site])
 
 
<source lang="bash">
 
<source lang="bash">
 
setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
 
setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
ext2load mmc 0 0x80300000 /boot/uImage-3
+
ext2load mmc 0 0x80300000 /boot/uImage
 
bootm 0x80300000
 
bootm 0x80300000
 
</source>
 
</source>
 +
Note: If you chose ext3 instead of ext2 for the partition containing the kernel, the second line still starts with ext2load. There is no ext3load.
 +
 
Note: depending on firmware version kernels might be at several, sometimes multiple locations, so you have to choose one:
 
Note: depending on firmware version kernels might be at several, sometimes multiple locations, so you have to choose one:
 
* /boot/uImage-3 - the default 3.2 kernel (recommended)
 
* /boot/uImage-3 - the default 3.2 kernel (recommended)
 
* /lib/boot/uImage - alternative location of 3.2 kernel on certain older firmwares
 
* /lib/boot/uImage - alternative location of 3.2 kernel on certain older firmwares
* /boot/uImage - the old 2.6 kernel
+
* /boot/uImage - mostly a symlink to the latest kernel on recent firmwares
  
Be aware though that this boot.txt assumes you have formatted your card with ext2 and loads the kernel off the SD card. It is possible to boot the kernel from NAND with following boot.txt
+
Be aware though that this boot.txt assumes you have formatted your card with ext2 and loads the kernel off the SD card. It is technically possible to boot the kernel from NAND but still run the rest of the file system from your SD card with following boot.txt
 
<source lang="bash">
 
<source lang="bash">
 
setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
 
setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
Line 131: Line 28:
  
 
Both boot.txt's assume you are booting from the left SD card slot, first partition. You can change "mmcblk0p1" to "mmcblk1p1" if you want to boot from the right slot (but boot.txt must still be on a card on the left slot).
 
Both boot.txt's assume you are booting from the left SD card slot, first partition. You can change "mmcblk0p1" to "mmcblk1p1" if you want to boot from the right slot (but boot.txt must still be on a card on the left slot).
Note: If you chose ext3 instead of ext2, the second line still starts with ext2load. There is no ext3load.
 
  
====Setting up mutliple-partition SD cards for booting====
+
===Rescue console boot===
 +
If you have a problem booting, and need to rescue data from the [[NAND]]) you can boot into a console by doing the following: Make a file named boot.txt in root of SD with this[http://www.gp32x.com/board/index.php?/topic/54918-unbricking-my-pandora/page__view__findpost__p__885362]:
 +
<pre>
 +
setenv bootargs ubi.mtd=4 ubi.mtd=3 root=ubi0:rootfs rootfstype=ubifs rw rootflags=bulk_read console=tty0 vram=6272K omapfb.vram=0:3000K init=/bin/bash
 +
ubi part boot && ubifsmount boot && ubifsload 0x80300000 uImage && bootm 0x80300000 && boot
 +
</pre>
 +
then hold down the right shoulder button on boot and booting from the SD card. (It doesn't require an operating system on the SD card, but it will use the boot configuration specified there). This is a text mode boot to the shell, using the kernel from the [[NAND]].
 +
This should provide a way of bypassing any broken startup scripts, adding in logging for a normal boot, etc. It does not start the full OS, just a basic shell.
 +
 
 +
 
 +
===Setting up multiple-partition SD cards for booting===
  
 
It is possible to have several partitions on the SD card and boot from one of them.
 
It is possible to have several partitions on the SD card and boot from one of them.
Line 171: Line 77:
 
'''Note: '''
 
'''Note: '''
  
For "root=" kernel argument, slot numbering begins at 0 (0 is left SD slot, 1 is right SD slot) and partition numbering begins at 1!
+
For both the "root=" kernel argument and the "mmc x:y" argument of the fatload/ext2load commands, slot numbering begins at 0 (0 is left SD slot, 1 is right SD slot) and partition numbering begins at 1!
 
 
For "mmc x:y" agrument of the fatload/ext2load commands, x is the card number (0 is left slot, 1 is right slot), y is the partition number, beginning at 1(!).
 
 
 
  
 
'''Recommendation:'''
 
'''Recommendation:'''
Line 181: Line 84:
 
Reason: In case the root FS partition is flagged "inconsistent" after a system crash or sudden SD card removal, uBoot won't be able to boot from that partition anymore. But the file system cleanup routines can only be run, once the kernel has been booted. Hence it's safer to put the kernel on a different partition.
 
Reason: In case the root FS partition is flagged "inconsistent" after a system crash or sudden SD card removal, uBoot won't be able to boot from that partition anymore. But the file system cleanup routines can only be run, once the kernel has been booted. Hence it's safer to put the kernel on a different partition.
  
 +
If you want to use ext4 for the root FS, it is necessary to put the kernel on a different partition.
 +
 +
'''Options Summary'''
 +
 +
{|class="wikitable" border="1" cellpadding="1" cellspacing="0" style="font-size: 90%; border:1px solid gray; border-collapse: collapse; text-align: center; width: 100%;"
 +
|- style="background: #ececec"
 +
! Files
 +
! File System Options
 +
! Location
 +
|-
 +
| boot.txt/autoboot.txt
 +
| FAT, ext2, ext3
 +
| first partition of left SD card
 +
|-
 +
| kernel
 +
| FAT, ext2, ext3
 +
| parameters of '''fatload''' or '''ext2load'''
 +
|-
 +
| rootfs
 +
| ext2, ext3, ext4
 +
| "root" parameter of '''setenv'''
 +
|}
  
 
==Boot the system==
 
==Boot the system==
Line 194: Line 119:
 
</source>
 
</source>
  
==Other information==
+
==Extending intall environment==
 
An alternative approach to using an SD card to increase the space accessible to the system is [[Extend_Utils#OS_Extends | OS Extend]]. This allows the root filesystem to exist on more than one physical device.
 
An alternative approach to using an SD card to increase the space accessible to the system is [[Extend_Utils#OS_Extends | OS Extend]]. This allows the root filesystem to exist on more than one physical device.
  
 
==References==
 
==References==
*[http://www.rjmitchell.ca/~jeff/blog2009/2010/06/07/pandora-running-firmware-from-sd-card-instead-of-nand-flash/ Skeezix's blog]
 
*[http://www.gp32x.com/board/index.php?/topic/54290-up-to-date-firmware-tarball GP32x Forum Topic, "Up to date firmware tarball"]
 
 
*[http://openpandora.org/firmware/ Official firmware page]
 
*[http://openpandora.org/firmware/ Official firmware page]
 
*[http://repo.openpandora.org/?page=detail&app=sd-install-2011-03-10 The GUI-driven SD installer by David Boucher]
 
*[http://repo.openpandora.org/?page=detail&app=sd-install-2011-03-10 The GUI-driven SD installer by David Boucher]
  
 +
=Copy the files to your SD card=
 +
Navigate (cd) to the directory with the .tar.bz2 file you just downloaded (or made) and do:
 +
 +
<source lang="bash">
 +
sudo tar -xvjf <tarfile>.tar.bz2 -C <SD card>
 +
</source>
 +
 +
If you're doing this on your Pandora, <SD card> is something like /media/mmcblk0p1 (first SD card slot on Pandora). On Ubuntu it would be something like /media/disk if it has no label. You can also try using GUI tools for this, but I didn't have very good luck with them.
 +
 +
===OR copy your firmware from the NAND to the SD card===
 +
 +
The following will ask for your password. All the operations need root permissions so I thought it would be wasteful to sprinkle sudo to everything.
 +
We will bind mount the root fs to an alternative location ("/mp"), under which other filesystems mounted under root (like the kernel virtual filesystems /proc and /sys, and your SD card.) wont be visible. This allows us to take a live copy of the NAND contents to the SD filesystem. 
 +
 +
<source lang="bash">
 +
sudo su
 +
mkdir /mp
 +
mount --bind / /mp
 +
cp -va /mp/* /media/<SD card>
 +
umount /mp
 +
rmdir /mp
 +
exit
 +
</source>
 +
 +
== serial port ==
 +
In an unlikely event that you can get serial output from EXT port, be aware that serial device has changed several times (due to the driver and port configuration changes in the kernel):
 +
* openpandora.org 2.6.27: ttyS0
 +
* mainline upto 2.6.36: ttyS2
 +
* mainline/openpandora.org 2.6.37 and up: ttyO2
 +
This is relevant for console= bootarg.
 +
 +
== MLO bootloader ==
 +
Holding START while switching it on will only work if you have a bootable SD Card with a special MLO bootloader in the left SD slot, as this forces the Pandora to boot from SD.
 +
 +
== In the case of a broken R button ==
 +
The file that kicks things off is boot.scr.
 +
Place an autoboot.txt file on the SD card to trigger an automatic boot off the SD card without having to use the right shoulder button.
 +
Create autoboot.txt file that would load the boot.scr file and start the reflash :
 +
setenv bootcmd  ’mmc init;fatload mmc 0 0x82000000 boot.scr; source 0x82000000’
 +
 +
Thanks to user limxr [http://boards.openpandora.org/topic/18416-how-to-reflash-when-right-shoulder-button-is-broken-solved/#entry396356]
 +
 +
== SEE ALSO ==
 +
[https://github.com/urjaman/pandora-u-boot urjaman github u-boot]
 +
[http://blogs.distant-earth.com/wp/?p=79 DjWillis distant earth boot documentation]
 +
 +
[[Category:Documentation]]
 
[[Category:Tutorials]]
 
[[Category:Tutorials]]
 
[[Category:Booting]]
 
[[Category:Booting]]
 
[[Category:Storage card]]
 
[[Category:Storage card]]
 
[[Category:Operating system]]
 
[[Category:Operating system]]

Latest revision as of 12:51, 18 October 2016

The uBoot bootloader normally boots the OS from NAND, but it can be inhibited by pressing R while starting up to for example pick SD-card booting. This can also be set up with text-files, making it the default behaviour.

Set up your boot.txt

Create a new file called boot.txt (or autoboot.txt if you want to boot automatically) and copy and paste the text below. Copy that file to the root of the root of the SD card.


boot.txt (from the official firmware site)

setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
ext2load mmc 0 0x80300000 /boot/uImage
bootm 0x80300000

Note: If you chose ext3 instead of ext2 for the partition containing the kernel, the second line still starts with ext2load. There is no ext3load.

Note: depending on firmware version kernels might be at several, sometimes multiple locations, so you have to choose one:

  • /boot/uImage-3 - the default 3.2 kernel (recommended)
  • /lib/boot/uImage - alternative location of 3.2 kernel on certain older firmwares
  • /boot/uImage - mostly a symlink to the latest kernel on recent firmwares

Be aware though that this boot.txt assumes you have formatted your card with ext2 and loads the kernel off the SD card. It is technically possible to boot the kernel from NAND but still run the rest of the file system from your SD card with following boot.txt

setenv bootargs root=/dev/mmcblk0p1 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
ubi part boot && ubifsmount boot && ubifsload ${loadaddr} uImage && bootm ${loadaddr} && boot

However this is not recommended because kernel modules on SD card will likely be not compatible with kernel on NAND.

Both boot.txt's assume you are booting from the left SD card slot, first partition. You can change "mmcblk0p1" to "mmcblk1p1" if you want to boot from the right slot (but boot.txt must still be on a card on the left slot).

Rescue console boot

If you have a problem booting, and need to rescue data from the NAND) you can boot into a console by doing the following: Make a file named boot.txt in root of SD with this[1]:

setenv bootargs ubi.mtd=4 ubi.mtd=3 root=ubi0:rootfs rootfstype=ubifs rw rootflags=bulk_read console=tty0 vram=6272K omapfb.vram=0:3000K init=/bin/bash
ubi part boot && ubifsmount boot && ubifsload 0x80300000 uImage && bootm 0x80300000 && boot

then hold down the right shoulder button on boot and booting from the SD card. (It doesn't require an operating system on the SD card, but it will use the boot configuration specified there). This is a text mode boot to the shell, using the kernel from the NAND. This should provide a way of bypassing any broken startup scripts, adding in logging for a normal boot, etc. It does not start the full OS, just a basic shell.


Setting up multiple-partition SD cards for booting

It is possible to have several partitions on the SD card and boot from one of them. E.g. if you have three partitions on the card like this:

  • Partition 1: FAT
  • Partition 2: ext2 (where the rootfs should be placed)
  • Partition 3: swap


How it's done:

1. Put uBoot's boot control files "boot.txt" and/or "autoboot.txt" into the root of the first partition of the card (FAT partition in this example)

2. Make "boot.txt" and "autoboot.txt" point U-Boot to the partition, which holds the root file system of your Linux system. This would be parition 2 in this example (ext2 FS). This is done using the "root" parameter of setenv.

3. Make "boot.txt" and "autoboot.txt" point U-Boot to the correct location to boot your kernel from. This kernel location can be any FAT or ext2/3/4 partition on the SD card. The uBoot commands "fatload" and "ext2load" with their parameter "mmc x:y" are repsonsible for loading the kernel. Choose the command, which addresses the file system the kernel is located on and make sure to correctly adapt the values x and y.

This common example boots the kernel from the FAT partition (then this is a "boot partition"), and uses the ext2 file system as root FS:

setenv bootargs root=/dev/mmcblk0p2 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
fatload mmc 0:1 0x80300000 uimage
bootm 0x80300000

If you put the kernel into the root file system's /boot directory, the second line would be different:

setenv bootargs root=/dev/mmcblk0p2 rw rootwait vram=6272K omapfb.vram=0:3000K mmc_core.removable=0
ext2load mmc 0:2 0x80300000 /boot/uImage
bootm 0x80300000

Note:

For both the "root=" kernel argument and the "mmc x:y" argument of the fatload/ext2load commands, slot numbering begins at 0 (0 is left SD slot, 1 is right SD slot) and partition numbering begins at 1!

Recommendation:

Put the kernel into another partition than the root FS is located. Reason: In case the root FS partition is flagged "inconsistent" after a system crash or sudden SD card removal, uBoot won't be able to boot from that partition anymore. But the file system cleanup routines can only be run, once the kernel has been booted. Hence it's safer to put the kernel on a different partition.

If you want to use ext4 for the root FS, it is necessary to put the kernel on a different partition.

Options Summary

Files File System Options Location
boot.txt/autoboot.txt FAT, ext2, ext3 first partition of left SD card
kernel FAT, ext2, ext3 parameters of fatload or ext2load
rootfs ext2, ext3, ext4 "root" parameter of setenv

Boot the system

As you power up the Pandora, hold the shoulder button R. A menu should appear, allowing you to boot from the SD card. (this step isn't necessary if you chose to create an autoboot.txt instead of boot.txt). Remember that this will be an un-configured image, taking a little while longer to boot, and giving the first-run dialogue.

Access the NAND

Once you're booted into the system from SD, you may want access to the NAND rootfs. The following will let you do that.

sudo mkdir /mnt/nand
sudo ubiattach /dev/ubi_ctrl -m 4
sudo mount -t ubifs ubi0:rootfs /mnt/nand

Extending intall environment

An alternative approach to using an SD card to increase the space accessible to the system is OS Extend. This allows the root filesystem to exist on more than one physical device.

References

Copy the files to your SD card

Navigate (cd) to the directory with the .tar.bz2 file you just downloaded (or made) and do:

sudo tar -xvjf <tarfile>.tar.bz2 -C <SD card>

If you're doing this on your Pandora, <SD card> is something like /media/mmcblk0p1 (first SD card slot on Pandora). On Ubuntu it would be something like /media/disk if it has no label. You can also try using GUI tools for this, but I didn't have very good luck with them.

OR copy your firmware from the NAND to the SD card

The following will ask for your password. All the operations need root permissions so I thought it would be wasteful to sprinkle sudo to everything. We will bind mount the root fs to an alternative location ("/mp"), under which other filesystems mounted under root (like the kernel virtual filesystems /proc and /sys, and your SD card.) wont be visible. This allows us to take a live copy of the NAND contents to the SD filesystem.

sudo su
mkdir /mp
mount --bind / /mp
cp -va /mp/* /media/<SD card>
umount /mp
rmdir /mp
exit

serial port

In an unlikely event that you can get serial output from EXT port, be aware that serial device has changed several times (due to the driver and port configuration changes in the kernel):

  • openpandora.org 2.6.27: ttyS0
  • mainline upto 2.6.36: ttyS2
  • mainline/openpandora.org 2.6.37 and up: ttyO2

This is relevant for console= bootarg.

MLO bootloader

Holding START while switching it on will only work if you have a bootable SD Card with a special MLO bootloader in the left SD slot, as this forces the Pandora to boot from SD.

In the case of a broken R button

The file that kicks things off is boot.scr. Place an autoboot.txt file on the SD card to trigger an automatic boot off the SD card without having to use the right shoulder button. Create autoboot.txt file that would load the boot.scr file and start the reflash :

setenv bootcmd  ’mmc init;fatload mmc 0 0x82000000 boot.scr; source 0x82000000’

Thanks to user limxr [2]

SEE ALSO

urjaman github u-boot DjWillis distant earth boot documentation

Top