Difference between revisions of "Leapster Explorer How To Extract Files"

From eLinux.org
Jump to: navigation, search
(ac)
 
(2 intermediate revisions by one other user not shown)
Line 106: Line 106:
  
 
/temp$
 
/temp$
 +
</code>
 +
 +
Here are all the abovementioned commands in a shell script (run it via sudo)
 +
 +
<code>
 +
 +
  #!/bin/bash
 +
  modprobe nandsim first_id_byte=0x20 second_id_byte=0xaa third_id_byte=0x00 fourth_id_byte=0x15
 +
  modprobe ubi mtd=0
 +
  ubidetach /dev/ubi_ctrl -m 0
 +
  ubiformat /dev/mtd0 -f erootfs.ubi
 +
  ubiattach /dev/ubi_ctrl -m 0
 +
  mount -t ubifs ubi0 temp
 +
 
</code>
 
</code>
  
  
 
Happy 'Exploring'!
 
Happy 'Exploring'!
 +
 +
[[Category:Leapster Explorer]]

Latest revision as of 03:01, 27 October 2011

These instructions explain how to mount, in Linux (tested on Ubuntu Lucid), the Leapster Explorer firmware found in the lfp files typically handled by LFConnect.

You may need to install mtd-utils.

$sudo apt-get install mtd-utils

Download the lfp file that contains the Leapster Explorer firmware from LF: http://lfccontent.leapfrog.com/lexplorer/downloads/packages/LST3-0x00170029-000000.lfp

This file can be read using any file archiving package (zip format).

When you open it, you will find a number of files to extract.

We will focus on the largest one, called 10485760,688,erootfs.ubi

Rename this to erootfs.ubi

$mv 10485760,688,erootfs.ubi erootfs.ubi

The file is in the ubifs format, so a number of steps are required to mount it.

(There may be better ways to do this, but the method below is what worked for me.)


First create a simulated NAND device (this one is 256MB):

$ sudo modprobe nandsim first_id_byte=0x20 second_id_byte=0xaa third_id_byte=0x00 fourth_id_byte=0x15

$ cat /proc/mtd

dev: size erasesize name mtd0: 10000000 00020000 "NAND simulator partition 0"


Next, attach it to a mtd device:

$ sudo modprobe ubi mtd=0


I had to detach it prior to formatting it:

$ sudo ubidetach /dev/ubi_ctrl -m 0

If that ubidetach step fails when you enter it, just proceed to the next step to format the mtd device.

$ sudo ubiformat /dev/mtd0 -f erootfs.ubi

ubiformat: mtd0 (nand), size 268435456 bytes (256.0 MiB), 2048 eraseblocks of 131072 bytes (128.0 KiB), min. I/O size 2048 bytes

libscan: scanning eraseblock 2047 -- 100 % complete

ubiformat: 2048 eraseblocks have valid erase counter, mean value is 1

ubiformat: flashing eraseblock 455 -- 100 % complete

ubiformat: formatting eraseblock 2047 -- 100 % complete


Then, attach it.

$ sudo ubiattach /dev/ubi_ctrl -m 0

UBI device number 0, total 2048 LEBs (264241152 bytes, 252.0 MiB), available 0 LEBs (0 bytes), LEB size 129024 bytes (126.0 KiB)


Make a target directory, and mount the device.

$ mkdir temp

$ sudo mount -t ubifs ubi0 temp

$ cd temp

/temp$ ls

bin erootfs.md5 flags linuxrc mnt2 sbin test var

boot etc LF mfgdata opt srv tmp www

dev Firmware lib mnt proc sys usr

/temp$

Here are all the abovementioned commands in a shell script (run it via sudo)

  #!/bin/bash
  modprobe nandsim first_id_byte=0x20 second_id_byte=0xaa third_id_byte=0x00 fourth_id_byte=0x15
  modprobe ubi mtd=0
  ubidetach /dev/ubi_ctrl -m 0
  ubiformat /dev/mtd0 -f erootfs.ubi
  ubiattach /dev/ubi_ctrl -m 0
  mount -t ubifs ubi0 temp


Happy 'Exploring'!