Author Topic: Qemu Zaurus Emulation, With Cacko/sharp Rom  (Read 4289 times)

matthis

  • Full Member
  • ***
  • Posts: 217
    • View Profile
    • http://badaboum.bidibom.free.fr/mat/
Qemu Zaurus Emulation, With Cacko/sharp Rom
« on: June 14, 2008, 11:00:44 pm »
The latest version of Qemu (0.9.1) adds support for Xscale emulation and specific zaurus emulation.

I have used this successfully for roms which do not use nand, like debian.

But I would love to get sharp-rom going under emulation.
Here are the steps needed to get going, from what I have gathered up until now.

1. Get sharp/cacko kernel
http://tetsu.homelinux.org/zaurus/kernel/v...-v18j-C3200.bin  (this is for 3200 --> terrier in qemu)

2. From the emergency menu of your zaurus, do a full NAND backup (I get a SYST320.DBK) file. (I have an sl-c3200)

3. extract the necessary bit from this backup file: use this script: http://web.mita.keio.ac.jp/~mh070504/nand-ripper.sh

As explained in the script, you may have to modify two parameters:

[div class=\'codetop\']CODE[/div][div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']YOU MAY NEED TO ADJUST THE TWO PARAMETERS BELOW.

Run the indicated commands on the zaurus to find your values.  It is unlikely
that ROMFS needs changing - I think this is fixed in the firmware at 7Mb,
i.e., 7 x 8 = 56 128kb blocks.  ROOTFS on the other hand will depend on how
you have divided up the remaining 121Mb between the root and user partitions.

EOC

ROMFS=56        # Use 'wc -c </dev/mtdblock1' and divide result by 128x1024.
ROOTFS=344      # Use 'df' to find the 1k-blocks for /dev/root and divide by 128.[/div]

Then run the script like this: ./nand-ripper.sh ripped_nand all SYST320.DBK

4. Get going with qemu:

qemu-system-arm -M terrier -kernerl sharp_kernel.bin -mtdblock ripped_nand -portrait


THIS FAILS AT THIS POINT: the kernel complains endlessly about reading nand error.
I suppose the script to rip has to be adjusted or something.

Anyone knowledgeable in this area?? Thanks! I think this is quite an exciting project.
« Last Edit: June 14, 2008, 11:01:52 pm by matthis »

malik

  • Full Member
  • ***
  • Posts: 149
    • View Profile
Qemu Zaurus Emulation, With Cacko/sharp Rom
« Reply #1 on: June 15, 2008, 03:46:13 am »
Quote from: matthis
The latest version of Qemu (0.9.1) adds support for Xscale emulation and specific zaurus emulation.

I have used this successfully for roms which do not use nand, like debian.

But I would love to get sharp-rom going under emulation.
Here are the steps needed to get going, from what I have gathered up until now.

1. Get sharp/cacko kernel
http://tetsu.homelinux.org/zaurus/kernel/v...-v18j-C3200.bin  (this is for 3200 --> terrier in qemu)

2. From the emergency menu of your zaurus, do a full NAND backup (I get a SYST320.DBK) file. (I have an sl-c3200)

3. extract the necessary bit from this backup file: use this script: http://web.mita.keio.ac.jp/~mh070504/nand-ripper.sh

As explained in the script, you may have to modify two parameters:

[div class=\'codetop\']CODE[/div][div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']YOU MAY NEED TO ADJUST THE TWO PARAMETERS BELOW.

Run the indicated commands on the zaurus to find your values.  It is unlikely
that ROMFS needs changing - I think this is fixed in the firmware at 7Mb,
i.e., 7 x 8 = 56 128kb blocks.  ROOTFS on the other hand will depend on how
you have divided up the remaining 121Mb between the root and user partitions.

EOC

ROMFS=56        # Use 'wc -c </dev/mtdblock1' and divide result by 128x1024.
ROOTFS=344      # Use 'df' to find the 1k-blocks for /dev/root and divide by 128.[/div]

Then run the script like this: ./nand-ripper.sh ripped_nand all SYST320.DBK

4. Get going with qemu:

qemu-system-arm -M terrier -kernerl sharp_kernel.bin -mtdblock ripped_nand -portrait


THIS FAILS AT THIS POINT: the kernel complains endlessly about reading nand error.
I suppose the script to rip has to be adjusted or something.

Anyone knowledgeable in this area?? Thanks! I think this is quite an exciting project.


hello matthis,

two remarks on your approach:
1. in many cases the original source code of qemu-arm has to be patched to work well,
have a look at the poky and neo homepages, maybe you can use their versions and
find some information there.
2. i am not sure, but i think that the zaurus expects a hd, at least in my case.
3. the emulation stops at "IrCOMM protocol (Dag Brattli)"


malik
borzoi, cacko 1.23 lite, 1gb kingston cf, 512mb toshiba sd.. suse 10.0