Step by Step - Booting and running the Android OS from the SD card

Downloads

Archive android-install-kit-mini2440.tar.gz 39.41MB

Note the md5 checksum for the archive should be:  a742e3e60b27925efb98ae4c01a3fe73

Additional note, please do not use the comments at the bottom of the page as a support forum.  You will receive much better support by joining this group:  http://groups.google.com/group/mini2440?lnk=srg

Overview

The goal is to install the Android OS (version 1.5) on the mini2440 so that it boots and runs off of a SD card. 

In this configuration the NAND flash is only used to start the boot loader, u-boot.  The SD card contains the kernel and the root file system.  The primary advantage of this configuration is that it avoids unnecessary writes to the NAND flash, which in my experience leads to file-system corruption.  A secondary benefit is that the SD card can be mounted on a PC and changes can be easily made to the system.

All of the files needed are included in the tarball which is available at the top of the page.

Credit

Everything on this site has been compiled from online resources.  My contribution is to bring them together in a cohesive fashion.   I wil begin the process of working backward and identifying the origional sources soon.  Most of the difficult work has been performed by others, and they diserve the lion's share of the credit.

Feedback

Please leave feedback if you use these instructions.  I would love to have a rough idea of how many people succeeded or failed because of these instructions.

Assumptions

You are assumed to have a moderate degree of Linux skill, and comfort at the command line.  You should understand how to mount, unmount and prepare filesystems on a removeable SD card.  You should also have a SD card reader on your linux machine. 

We assume you have formatted the SD card with three partitions, the 2nd partition has an ext2 file system containing the uImage file, the 3rd partition has a ext3 file system containing the contents of the file system.  The first partition contains swap space.  You are assumed to be running Linux and have minicom installed.  You have minicom configured to communicate to the mini2440 at 155200 baud.  

It is also assumed that your mini2440 has a 128M flash.  As the included boot-loaders are specific to this memory size.  Otherwise you should substitute the provided u-boot boot loader with a suitable one compiled for your memory configuration.

Finally you should have 30 - 60 minutes of time available to complete the install.

TODO: provide instructions for SD card prep. 

Starting

With the power off, insert the SD card into the mini2440.  It must be formatted and contain the root filesystem  and kernel.

Boot using supervivi off of the NOR flash (switch toward near edge). 

Connect the USB transfer cable between the unix machine and the mini2440.

You will need to have two terminals open. On the first terminal you will have started minicom and are communicating with the mini2440. 

The second terminal should contain a unix shell.  Create a directory to contain the contents of the tarball ( android-install-kit-mini2440.tar.gz).  Change to that directory and extract the contents.  This terminal will be used to initiate USB transfers of files to supervivi.

At the supervivi menu, press "q" to drop into the shell.

Load u-boot into ram

Supervivi> load ram  0x31000000 0x0003b29c u 

On the 2nd terminal, run

# ./s3c2410_boot_usb u-boot-128MB.bin  

On the first terminal verify that the file transfered.  (You will see an error on the 2nd terminal, ignore it).

execute u-boot

Supervivi> go 0x31000000 

You should be rewarded with the u-boot prompt

 MINI2440 # 

Prep the NAND

 MINI2440 # nand info
 MINI2440 # nand bad
 MINI2440 # nand scrub 
 MINI2240 # nand createbbt
 MINI2440 # mtdparts
 MINI2440 # set ethaddr 08:00:2f:00:00:06
 MINI2440 # dynenv set 40000
 MINI2440 # saveenv

There are two options, A and B, only perform one of them!

Why two methods?  U-boot is already loaded in memory, we can write the memory to the NAND and be finished (Option A).  However, uboot has a seldom documented ability to receive files using ymodem.  This option does not require a USB data transfer cable.  I include Ymodem transfer instructions to highlight this capability of u-boot.

Use Option A if you are in a hurry or are happy with the USB transfer method.  Use Option B if you would like to learn to use Ymodem to transfer files to uboot using the serial port.

Option A, write the copy of u-boot in RAM onto the NAND

 nand write.e 31000000 0  0x0003b29c

End of Option A

Option B, reload u-boot into ram using YMODEM and minicom.

Read ahead and be prepared to act quickly (old-school ymodem upload).

 MINI2440 # loady 0x32000000 

 Press [CTL]+[a] then [s]

An ASCII pop-up should appear, choose ymodem

And ASCII file browser should appear, choose the file using the space key (u-boot-128MEG.bin) then press enter.

You should see the file upload progress screen, with luck your transfer will complete.

 Write the file to the NAND

nand write.e 32000000 0  0x0003b29c

End of Option B

 Power the board off

Move the NAND/NOR switch away from the near edge

Power the board on

You should see the u-boot menu

Set the environment to boot off of SD

MINI2440 # setenv bootargs console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3 mini2440=1tb rootdelay=3 init=/linuxrc
MINI2440 # setenv bootcmd mmcinit \; ext2load mmc 0:2 0x31000000 uImage \; bootm 0x31000000
MINI2440 # saveenv

Reboot

Success! ?

You should be rewarded with the Android OS. 

There is only one issue that I am aware of, one of the Android services (settings) will issue several errors when the machine boots.  This does not occure when the same filesystem is loaded directly on NAND flash.  So I suspect it is caused by the SD device not being available for media (since we booted off of it).  If anyone solves this, please let me know and I will incorporate the changes into the install kit.

Once you get this far you will want to change your network settings, language preferences and remove the sdcard entry in mountd.  This is covered in more detail here: http://mini2440.spaceopera.org/site/developmentenviroment/configuration/ 


 

Comments and suggestions are welcome!

sunitha

Hi

 

  I did the exact steps and I hit an open file errer as it boots up . I have pasted the lines below.

 

Any ideas / clues. I am using a dev board from developemntboard.net

Thanks

Sunitha

 

mmc0: new SD card at address fd52
mmcblk0: mmc0:fd52 SD02G 1921024KiB
 mmcblk0: p1 p2 p3
kjournald starting.  Commit interval 5 seconds
EXT3-fs warning: checktime reached, running e2fsck is recommended
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
open file errer!
xres = 240, yres = 320

Shannon Haworth

Sunitha,

First, the good news is that the bootloader ran correctly, the kernel loaded and even mounted the root filesystem.  So, you are VERY close.

It looks like (the logs are not very specific) a filesystem error.  Since the kernel loaded and mounted the filesystem a lot of causes are eliminated. However there are many potential causes remaining.

My instinct is that the filesystem wasn't correctly written to the filesystem.

First I would re-write the SD card, making sure I ran "sync" to ensure the contents of the SD card were written before unmounting the SD card from your linux PC.

Let me know if that works, if not I'll look into another solution.  Also, I'll add a MD5 sum for the file.  That should provide some assurance that the tarball is correct.

Bill Sargent

Hi,

Why do you re-upload u-boot to the RAM after executing it from supervivi? It¨s already in RAM, you can simply copy it from RAM to the NAND without using Ymodem to reupload it.

Would it be possible for you to outline your filesystem creation for Android? For a lot of us, writing images to the board isnt a problem, its creating the Android image and compiling it that are the problem.

Shannon Haworth

Bill,

You make a very good point.  My motivation for re-loading was to show how to use Ymodem rather than the dual connection with a USB transfer cable method.   I find it easier to use minicom for everything than using the USB transfer script.

I have gone back and reworked that portion of the instructions with your feedback in mind.  Thanks for pointing that out.

I wish I had a filesystem creation process for Android.  I've tried, and failed so far.  If anyone can provide instructions (even screen shots, I'll write the process up from a complete set of screen shots) and would like to share, please contact me.  I'll be happy to host them.

Filesystem creation for the Android is, in theory, a rather simple process.  You pull the repository down, which includes a cross-compiler tool chain for x86 linux, make a few configuration and enviroment settings.  And then run make.

Once make is finished (which takes quite a while) you should have all of the Android OS and framework (other than the kernel) built.  

And that is as far as I've gotten since since I encounter compile errors very deep into the compile. 

The filesystem I provided was extracted from a tarball I found in Japan.  The contents are identical to the yaffs that appeared in China late last year.

My goal is to have complete compile instructions for building the Android OS / framework and the matching kernel from source.  My long term goal is to put together a continuous integration server, with functionl black-box testing and full build reports online for the community to pull builds from.  Assistance in this arena is very welcome.

Shannon

Bill Sargent

Hi,

Were you able to actually run this smoothly on the Mini2440? I ran the one from developmentboard.net (The yaffs2 one) and it was incredibly slow. I ran it from NAND so maybe that was the problem. It was totally unusable for me taking sometimes as long as 5 minutes to acknowledge I'd even tapped the screen. 

I've been able to completely get Android to compile however that was only in Debian and Ubuntu. If you are running something else, maybe its wrong versions of packages etc. 

I'm going to keep your page here bookmarked. You have some good stuff here.

I'll also keep trying to figure out the filesystem and keep checking back here. Thanks so much!

Bill

Shannon Haworth

Bill,

This is based on the developmentboard.net version, and it is very responsive on my machine.  Five minutes!  That is insane.  Having only 64M of memory it can be slow, but even web pages (google image search for instance) only take a few seconds to load.  Something else is at play other than the mini and Android.

I have been trying to cross-compile using Fedora Core 11.  Which may be the root of my issues.   My todo list includes installing and trying Ubuntu - free time permitting.

I'm glad to hear this is useful for you.  

Take care,

Shannon

 

Shannon Haworth

A bit of advice, don't plug a 12V power supply into your mini.  It will release the magic smoke, all of it.   :)

I should be back in business in a couple of weeks.  Until then I'll have to make do with the emulator.

 

Soohong

Hi, thanks for this great info.

I exactly followed your instruction and everything went well. After the reboot, I get this "Permission denied" message and can't pass this point.

I partitioned the 512M Sandisk SD card as follows. 128MB swap, 128MB ext2, rest of the space - ext3.

I changed the permission setting of /system/bin/* to 777 but still get the same message.

Any help would be greatly appreciated!

Soohong

*************************************************
U-Boot 1.3.2-mini2440 (Oct  6 2009 - 12:51:09)

I2C:   ready
DRAM:  64 MB
Flash:  2 MB
NAND:  128 MiB
Found Environment offset in OOB..
USB:   S3C2410 USB Deviced
In:    serial
Out:   serial
Err:   serial
MAC: 08:00:2f:00:00:06
Hit any key to stop autoboot:  0
trying to detect SD Card...
Manufacturer:       0x03, OEM "SD"
Product name:       "SD512", revision 5.7
Serial number:      809672491
Manufacturing date: 8/2004
CRC:                0x0d, b0 = 1
READ_BL_LEN=15, C_SIZE_MULT=7, C_SIZE=3197
size = 4208984064

2060420 bytes read
## Booting kernel from Legacy Image at 31000000 ...
   Image Name:
   Created:      2010-03-26   5:54:15 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2060356 Bytes =  2 MB
   Load Address: 30008000
   Entry Point:  30008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux.............................................................
........................................................................ done, b
ooting the kernel.
Linux version 2.6.27 (root@tom) (gcc version 4.3.2 (Sourcery G++ Lite 2008q3-72)
 ) #1 PREEMPT Mon Aug 24 17:01:35 CST 2009
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177
Machine: FriendlyARM Mini2440 development board
Memory policy: ECC disabled, Data cache writeback
CPU S3C2440A (id 0x32440001)
MM: CPU does not support supersection mapping for 0x55000000000 at 0xf0d00000
S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz
S3C24XX Clocks, (c) 2004 Simtec Electronics
CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
Kernel command line: console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3
mini2440=1tb rootdelay=3 init=/linuxrc
irq: clearing pending status 02000000
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 1024 bytes)
timer tcon=00500000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57
Console: colour dummy device 80x30
console [ttySAC0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 64MB = 64MB total
Memory: 60188KB available (3896K code, 636K data, 116K init)
SLUB: Genslabs=12, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Calibrating delay loop... 201.93 BogoMIPS (lpj=504832)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
net_namespace: 288 bytes
NET: Registered protocol family 16
S3C2440: Initialising architecture
S3C2440: IRQ Support
S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics
DMA channel 0 at c4800000, irq 33
DMA channel 1 at c4800040, irq 34
DMA channel 2 at c4800080, irq 35
DMA channel 3 at c48000c0, irq 36
S3C244X: Clock Support, DVS off
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 2048 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 2048 bind 2048)
TCP reno registered
NET: Registered protocol family 1
NetWinder Floating Point Emulator V0.97 (double precision)
ashmem: initialized
NTFS driver 2.1.29 [Flags: R/W DEBUG].
yaffs Aug 24 2009 16:57:57 Installing.
msgmni has been set to 117
io scheduler noop registered (default)
Console: switching to colour frame buffer device 30x20
fb0: s3c2410fb frame buffer device
adc     initialized
input: buttons as /class/input/input0
buttons initialized
leds    initialized
s3c2440-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2440
s3c2440-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2440
s3c2440-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2440
brd: module loaded
loop: module loaded
nbd: registered device at major 43
logger: created 64K log 'log_main'
logger: created 256K log 'log_events'
logger: created 64K log 'log_radio'
dm9000 Ethernet Driver, V1.31
Now use the default MAC address: 08:90:90:90:90:90
eth0: dm9000e at c4804000,c4806004 IRQ 51 MAC: c3908934 (friendly-arm)
usbcore: registered new interface driver zd1211rw
usbcore: registered new interface driver zd1201
Linux video capture interface: v2.00
ovcamchip: v2.27 for Linux 2.6 : OV camera chip I2C driver
usbcore: registered new interface driver ov511
ov511: v1.64 for Linux 2.5 : ov511 USB Camera Driver
Driver 'sd' needs updating - please use bus_type methods
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c2440-nand s3c2440-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns
NAND device: Manufacturer ID: 0xec, Chip ID: 0xf1 (Samsung NAND 128MiB 3,3V 8-bi
t)
NAND_ECC_NONE selected by board driver. This is not recommended !!
Scanning device for bad blocks
Creating 4 MTD partitions on "NAND 128MiB 3,3V 8-bit":
0x00000000-0x00060000 : "supervivi"
0x00060000-0x00260000 : "Kernel"
0x00260000-0x40260000 : "root"
mtd: partition "root" extends beyond the end of device "NAND 128MiB 3,3V 8-bit"
-- size truncated to 0x7da0000
0x00000000-0x40000000 : "nand"
mtd: partition "nand" extends beyond the end of device "NAND 128MiB 3,3V 8-bit"
-- size truncated to 0x8000000
s3c2410-ohci s3c2410-ohci: S3C24XX OHCI
s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1
s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
s3c2440-usbgadget s3c2440-usbgadget: S3C2440: increasing FIFO to 128 bytes
mice: PS/2 mouse device common for all mice
usbcore: registered new interface driver appletouch
input: s3c2410 TouchScreen as /class/input/input1
s3c2410 TouchScreen successfully loaded
S3C24XX RTC, (c) 2004,2006 Simtec Electronics
s3c2410-rtc s3c2410-rtc: rtc disabled, re-enabling
s3c2410-rtc s3c2410-rtc: rtc core: registered s3c as rtc0
i2c /dev entries driver
s3c2440-i2c s3c2440-i2c: slave address 0x10
s3c2440-i2c s3c2440-i2c: bus frequency set to 98 KHz
s3c2440-i2c s3c2440-i2c: i2c-0: S3C I2C adapter
mapped channel 0 to 0
s3c2440-sdi s3c2440-sdi: powered down.
s3c2440-sdi s3c2440-sdi: initialisation done.
s3c2440-sdi s3c2440-sdi: running at 0kHz (requested: 0kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
usbcore: registered new interface driver hiddev
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
UDA1341 audio driver initialized
failed to get memory region resouce
s3c2410-iis: probe of s3c2410-iis.0 failed with error -2
TCP cubic registered
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2410-rtc s3c2410-rtc: setting system clock to 2005-06-23 11:34:37 UTC (111952
6477)
Waiting 3sec before mounting root device...
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
mmc0: new SD card at address a95c
mmcblk0: mmc0:a95c SD512 495488KiB
 mmcblk0: p1 p2 p3
EXT3-fs warning: maximal mount count reached, running e2fsck is recommended
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
Warning: unable to open an initial console.
ts_control_open!
ts_control_release!
init: cannot open '/initlogo.rle'
sh: can't access tty; job control turned off
/ # init: cannot find '/system/bin/playmp3', disabling 'bootsound'
init: cannot execve('/system/bin/dbus-daemon'): Permission denied
init: cannot execve('/system/bin/mediaserver'): Permission denied
FAT: bogus number of reserved sectors
VFS: Can't find a valid FAT filesystem on dev mmcblk0p1.
warning: `rild' uses 32-bit capabilities (legacy support in use)
eth0: link down
init: cannot execve('/system/bin/mediaserver'): Permission denied
init: cannot execve('/system/bin/dbus-daemon'): Permission denied
init: cannot execve('/system/bin/mediaserver'): Permission denied
init: cannot execve('/system/bin/dbus-daemon'): Permission denied
init: cannot execve('/system/bin/mediaserver'): Permission denied
init: cannot execve('/system/bin/dbus-daemon'): Permission denied
init: cannot execve('/system/bin/mediaserver'): Permission denied
...

Shannon Haworth

Dear Soohong,

Very Interesting.

I am very curious what the enviroment for uboot is.  Please interrupt uboot and at the uboot prompt enter the command "printenv". 

Also, mount the SD card on a linux box, and as root enter the command "fdisk -l"

Please post the results of both commands.  I suspect this will be trivial to fix.

Regards,

Shannon

Soohong

Shannon,

Thanks so much for the quick reply. Below is the message I got.
Let me know if you see anything odd.

Thanks again,
Soohong 

***********************************

MINI2440 # printenv
bootdelay=3
baudrate=115200
ipaddr=10.0.0.111
serverip=10.0.0.4
netmask=255.255.255.0
usbtty=cdc_acm
mtdparts=mtdparts=mini2440-nand:256k@0(u-boot),128k(env),5m(kernel),-(root)
mini2440=mini2440=0tb
bootargs_base=console=ttySAC0,115200 noinitrd
bootargs_init=init=/sbin/init
root_nand=root=/dev/mtdblock3 rootfstype=jffs2
root_mmc=root=/dev/mmcblk0p2 rootdelay=2
root_nfs=/mnt/nfs
set_root_nfs=setenv root_nfs root=/dev/nfs rw nfsroot=${serverip}:${root_nfs}
ifconfig_static=run setenv ifconfig ip=${ipaddr}:${serverip}::${netmask}:mini244
0:eth0
ifconfig_dhcp=run setenv ifconfig ip=dhcp
ifconfig=ip=dhcp
set_bootargs_mmc=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440} $
{root_mmc}
set_bootargs_nand=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440}
${root_nand}
set_bootargs_nfs=run set_root_nfs; setenv bootargs ${bootargs_base} ${bootargs_i
nit} ${mini2440} ${root_nfs} ${ifconfig}
mtdids=nand0=mini2440-nand
ethaddr=08:00:2f:00:00:06
bootargs=console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3 mini2440=1tb
 rootdelay=3 init=/linuxrc
bootcmd=mmcinit ; ext2load mmc 0:2 0x31000000 uImage ; bootm 0x31000000
partition=nand0,0
mtddevnum=0
mtddevname=u-boot

Environment size: 1190/131068 bytes
MINI2440 #

****************************************

 vadmin@ubuntu:/$ fdisk -l /dev/sdd
Cannot open /dev/sdd
vadmin@ubuntu:/$ fdisk -l /dev/sdd2
Cannot open /dev/sdd2
vadmin@ubuntu:/$ fdisk -l /dev/sdd3
Cannot open /dev/sdd3
vadmin@ubuntu:/$

I'm not sure I understood what you wanted but I'm getting "Cannot open..."

 

Shannon Haworth

Soohong,

You will have to run the fdisk comand as root.

Shannon

Soohong

Oh, thanks..

vadmin@ubuntu:/$ sudo fdisk -l /dev/sdd
[sudo] password for vadmin:

Disk /dev/sdd: 507 MB, 507379712 bytes
16 heads, 61 sectors/track, 1015 cylinders
Units = cylinders of 976 * 512 = 499712 bytes
Disk identifier: 0x000d93bb

   Device Boot      Start         End      Blocks   Id  System
/dev/sdd1               1         129       62921+  82  Linux swap / Solaris
/dev/sdd2             130         190       29768   83  Linux
/dev/sdd3             191         697      247416   83  Linux

********************************

Any clue??

 

Shannon Haworth

Well, I see two potential issues (my mini2440 is dead right now so I can't compare what you are seeing with what mine does on boot). 

The first is a permissions problem on the root file system.  

My advice is to re-create the root filesystem as root.

The second is that the system is trying to mount the first partition as a FAT filesystem, which fails.  I have no idea if this is normal for this image.  I don't think it is the cause of your problems, but it might be something to look into.

Please advise when this is resolved, I want to update the instructions if needed.

Soohong

Dear Shannon,

Awesome, it's working!!! (sort of..)

"My advice is to re-create the root filesystem as root." <<-- That was it!!

I was using different user name and after login as root, then re-created the SD file system -> Now I see the Android robot blinking... Then after a short while, I get an error message in Chinese (!@#%!@#21% 'com.android.settings !@#%)  If I press the left button, message disappears and Android screen show up but all menus are Chinese...

This is the booting time message *************
...
mmc0: new SD card at address a95c
mmcblk0: mmc0:a95c SD512 495488KiB
 mmcblk0: p1 p2 p3
s3c2410-rtc s3c2410-rtc: setting system clock to 2005-06-24 15:24:07 UTC (111962
6647)
Waiting 3sec before mounting root device...
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
Warning: unable to open an initial console.
ts_control_open!
ts_control_release!
init: cannot open '/initlogo.rle'
sh: can't access tty; job control turned off
/ # init: cannot find '/system/bin/playmp3', disabling 'bootsound'
eth0: link down
FAT: bogus number of reserved sectors
VFS: Can't find a valid FAT filesystem on dev mmcblk0p1.
warning: `rild' uses 32-bit capabilities (legacy support in use)
*********************************

Am I supposed to see Chinese menu or something is still broken?
I also noticed that it's a bit slow.

Anyway, thank you so much for your help!!

Soohong

 

Shannon Haworth

You are almost there.  You need to make a few adjustments to make the system usable. 

  • Change your language settings.
  • Remove the sdcard from the mountd configuration.
  • Adjust the network settings (wired only right now).

All of thse changs are very obvious.  I outline which files contain these settings on this page:  http://mini2440.spaceopera.org/site/developmentenviroment/configuration/

Regards,

Shannon

Soohong

Dear Shannon,

I changed the language setting to "US" in /default.prop and edited /etc/mountd.conf (isn't this /system/etc/mountd.conf?) to comment out the sdcard reference.

Now there are no more error messages during the bootup and all menus are in English!!

I cannot believe I'm running Android on my Mini2440 board.

I saw your future plans and I totally agree with you. I guess most of the people using mini2440 will need low level hardware access. I will need time to learn Android programming but will check back frequently to see any progress here.

Thank you so much!

Soohong

Fernando

Hello, I cant get android to work.

 

After resetting with the S2 switch in nand mode, I get in the terminal:

 

U-Boot 1.3.2-mini2440 (Oct  6 2009 - 12:51:09)

I2C:   ready
DRAM:  64 MB „à0’P„â0ƒã0‚ådata abort
pc : [<33fa13e4>]          lr : [<33f8121c>]
sp : 33d5ff14  ip : 33f974f6     fp : 7f9213ef
r10: 000001b8  r9 : 4fde7ce7     r8 : 33d5ffdc
r7 : 79af74df  r6 : 00000000     r5 : c7e765f7  r4 : 33fb77f6
r3 : 00bf234b  r2 : 00000020     r1 : 00000000  r0 : 00000000
Flags: nzCv  IRQs off  FIQs off  Mode SVC_32
Resetting CPU ...

 

and never does anything else. cant boot or get prompt... what can be?

Thank you very much

Fernando

Shannon Haworth

Fernando

It looks like uboot is either incompatible with your board or there has been data corruption somewhere along the line (bad NAND block, corrupt data transfer ...).  Difficult to say from afar.  I have a few thoughts.

To eliminate the potential of bad blocks I would follow the procedure I outline here:   http://mini2440.spaceopera.org/site/developmentenviroment/missingbadblocktable/index.html

What is the size of your NAND?  The version of uboot that I provide is specific to the 128M version.

If these ideas don't resolve the problem I would seek assistance on one of the uBoot sites.

Good luck,

Shannon

Bill Sargent

Hello,

 

Have you seen this link about compiling Android and creating a filesystem? 

http://my.opera.com/vinodmunikoti/blog/manual-for-compiling-android-for-mini2440

 Maybe this can help.

Shannon Haworth

Bill,

Nice find.

I will dig into this very soon.  Thanks for the resource!

Shannon

 

badr

hi ...

 i don know if u r still seeing this page any more...but

i managed to run android on mini2440 but it is 64 nand wityh nec3.5''

(on sd card).....but i cannot control it as there is some problem with the back button is not viewed

i think that there might be some problem with compatability with lcd...

should i re configure the kernel or what ... has the file system any effect .... what is the difference bet. a file system for 128 or 64 nand....or its only the kernel????

Shannon Haworth

Badr,

Concerning the back button, it should be one of the buttons on the main board, and it is available via one of the headers.  You need to connect the correct two pins (your manual will indicate which two) to a button and it should work.

I am not using the NEC LED and have no experiance.  It is likely a configuration issues, although it may require adjustments to the kernel or the driver.

My best advice is to post your query on one of the android porting groups.  

 

Shannon

memo

 

 hi shanon

i install android on nand flash but i have problem that it can't read usb and i don't know where i make mount point for usb

 

Shannon Haworth

Memo,

To the best of my knowledge, the Android OS does not have a default mount point for USB storage devices. However the general procedure is no different for Android that most other Linux distros.

The first step is to identify where (and if) the OS exposes the block device. You can use dmesg, however I usually use “fdisk -l” to list all available partitions on all available block devices.

The next step is to actually mount the device. You will need a mount point, which is usually just an empty directory. Then you use the mount command to mount the partition onto the mount point.

Good luck.

 

 

flux000

Hello All,

I followed the instruction above but i encounter the msg below are reset. Also, I attached my env below.

........

.........

s3c2410-rtc s3c2410-rtc: setting system clock to 2010-09-16 04:09:21 UTC (12846)
Root-NFS: No NFS server available, giving up.                                   
VFS: Unable to mount root fs via NFS, trying floppy.                            
VFS: Cannot open root device "mmcblk0p3" or unknown-block(2,0)                  
Please append a correct "root=" boot option; here are the available partitions:
1f00        384 mtdblock0 (driver?)                                             
1f01       2048 mtdblock1 (driver?)                                             
1f02      63104 mtdblock2 (driver?)                                             
1f03      65536 mtdblock3 (driver?)                                             
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)  

 

Environment:

bootdelay=3                                                                    
baudrate=115200                                                                
ethaddr=08:08:11:18:12:27                                                      
ipaddr=10.0.0.111                                                              
serverip=10.0.0.4                                                              
netmask=255.255.255.0                                                          
usbtty=cdc_acm                                                                 
mtdparts=mtdparts=mini2440-nand:256k@0(u-boot),128k(env),5m(kernel),-(root)    
mini2440=mini2440=0tb                                                          
bootargs_base=console=ttySAC0,115200 noinitrd                                  
root_nfs=/mnt/nfs                                                              
set_root_nfs=setenv root_nfs root=/dev/nfs rw nfsroot=${serverip}:${root_nfs}  
ifconfig_static=run setenv ifconfig ip=${ipaddr}:${serverip}::${netmask}:mini240
ifconfig_dhcp=run setenv ifconfig ip=dhcp                                      
ifconfig=ip=dhcp                                                               
set_bootargs_mmc=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440} }
set_bootargs_nand=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440}}
set_bootargs_nfs=run set_root_nfs; setenv bootargs ${bootargs_base} ${bootargs_}
mtdids=nand0=mini2440-nand                                                     
bootargs_init=init=/linuxrc                                                    
filesize=206224                                                                
root_nand=root=/dev/mtdblock3 rootfstype=jffs2                                 
root_mmc=root=/dev/mmcblk0p2 rootdelay=2                                       
bootcmd=mmcinit ; ext2load mmc 0:2 0x31000000 uImage ; bootm 0x31000000        
bootargs=root=/dev/mmcblk0p3 rootfstype=ext3 console=ttySAC0,115200            
partition=nand0,0                                                              
mtddevnum=0                                                                    
mtddevname=u-boot                                                              
                                                                               
Environment size: 1165/65532 bytes                                             

Thanks,

flux000

flux000

Hello All,

I used the uImage provided in the attachment and add mmcinit to bootargs however i am gettig the error msg below.


bootcmd=mmcinit ; ext2load mmc 0:2 0x31000000 uImage ; bootm 0x31000000
bootargs=console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3 mmcinit rootdelay=3 init=/linuxrc

Waiting 3sec before mounting root device...
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
mmc0: new SD card at address cb4f
mmcblk0: mmc0:cb4f SD02G 2011136KiB
 mmcblk0: p1 p2 p3
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
Warning: unable to open an initial console.
Failed to execute /linuxrc.  Attempting defaults...
Kernel panic - not syncing: No init found.  Try passing init= option to kernel.

Thanks,

flux000

Shannon Haworth

flux000

It appears that the root filesystem is not correct.  I suggest you recreate the filesystem on the SD card, being careful to unmount it before removing it.

Good luck

Shannon

 

flux000

Shannon,

I was able to use your post and this site https://sites.google.com/site/belina76/android-booting to sucessfully get the Android working...

Thanks,

flux000

Prakash

Hi,

 I am using Mini2440 with 128MB RAM. I am trying to boot the android from SDCARD. I dowloaded the necessary files (android-install-kit-mini2440.tar.gz) and followed the same steps. But I am getting the kernel panic error exactl what flux000 was getting. The errors are,

 

Warning: unable to open an initial console.

Failed to execute /linuxrc. Attempting defaults... Kernel panic - not syncing: No init found. Try passing init= option to kernel.

 

Unfortunately, flux000 did not mentioned about the tricks he used to fix the same issue.

Help me to resolve the error.

 

-Prakash

Brandon Smith

Hello,

Im so close, but it keeps stopping. Below is the output from the serial link. I dont know what I am missing...

ø


U-Boot 1.3.2-mini2440 (May 25 2010 - 19:15:21)


I2C:   ready

DRAM:  64 MB

Flash:  2 MB

NAND:  1024 MiB

Found Environment offset in OOB..

USB:   S3C2410 USB Deviced

In:    serial

Out:   serial

Err:   serial

MAC: 08:08:11:18:12:27

Hit any key to stop autoboot:  0

mmc: Probing for SDHC ...

mmc: SD 2.0 or later card found

trying to detect SD Card...

Manufacturer:       0x03, OEM "SD"

Product name:       "SU02G", revision 8.0

Serial number:      272022369

Manufacturing date: 10/2007

CRC:                0x36, b0 = 1

READ_BL_LEN=15, C_SIZE_MULT=7, C_SIZE=3453

size = 2329935872

SD Card detected RCA: 0xe624 type: SD


2060420 bytes read

## Booting kernel from Legacy Image at 31000000 ...

   Image Name:  

   Created:      2010-03-26   5:54:15 UTC

   Image Type:   ARM Linux Kernel Image (uncompressed)

   Data Size:    2060356 Bytes =  2 MB

   Load Address: 30008000

   Entry Point:  30008000

   Verifying Checksum ... OK

   Loading Kernel Image ... OK

OK


Starting kernel ...


Uncompressing Linux..................................................................................................................................... done, booting the kernel.
Linux version 2.6.27 (root@tom) (gcc version 4.3.2 (Sourcery G++ Lite 2008q3-72) ) #1 PREEMPT Mon Aug 24 17:01:35 CST 2009
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177
Machine: FriendlyARM Mini2440 development board
Memory policy: ECC disabled, Data cache writeback
CPU S3C2440A (id 0x32440001)
MM: CPU does not support supersection mapping for 0x55000000000 at 0xf0d00000
S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz
S3C24XX Clocks, (c) 2004 Simtec Electronics
CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
Kernel command line: console=ttySAC0,115200 root=/ev/mmcblk0p3 rootfstype=ext3 mini2440=1tb rootdelay=3 init=/linuxrc
irq: clearing pending status 02000000
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 1024 bytes)
timer tcon=00500000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57
Console: colour dummy device 80x30
console [ttySAC0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 64MB = 64MB total
Memory: 60188KB available (3896K code, 636K data, 116K init)
SLUB: Genslabs=12, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Calibrating delay loop... 201.93 BogoMIPS (lpj=504832)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
net_namespace: 288 bytes
NET: Registered protocol family 16
S3C2440: Initialising architecture
S3C2440: IRQ Support
S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics
DMA channel 0 at c4800000, irq 33
DMA channel 1 at c4800040, irq 34
DMA channel 2 at c4800080, irq 35
DMA channel 3 at c48000c0, irq 36
S3C244X: Clock Support, DVS off
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 2048 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 2048 bind 2048)
TCP reno registered
NET: Registered protocol family 1
NetWinder Floating Point Emulator V0.97 (double precision)
ashmem: initialized
NTFS driver 2.1.29 [Flags: R/W DEBUG].
yaffs Aug 24 2009 16:57:57 Installing.
msgmni has been set to 117
io scheduler noop registered (default)
Console: switching to colour frame buffer device 30x20
fb0: s3c2410fb frame buffer device
adc initialized
input: buttons as /class/input/input0
buttons initialized
leds initialized
s3c2440-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2440
s3c2440-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2440
s3c2440-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2440
brd: module loaded
loop: module loaded
nbd: registered device at major 43
logger: created 64K log 'log_main'
logger: created 256K log 'log_events'
logger: created 64K log 'log_radio'
dm9000 Ethernet Driver, V1.31
Now use the default MAC address: 08:90:90:90:90:90
eth0: dm9000e at c4804000,c4806004 IRQ 51 MAC: c3908934 (friendly-arm)
usbcore: registered new interface driver zd1211rw
usbcore: registered new interface driver zd1201
Linux video capture interface: v2.00
ovcamchip: v2.27 for Linux 2.6 : OV camera chip I2C driver
usbcore: registered new interface driver ov511
ov511: v1.64 for Linux 2.5 : ov511 USB Camera Driver
Driver 'sd' needs updating - please use bus_type methods
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c2440-nand s3c2440-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns
NAND device: Manufacturer ID: 0xec, Chip ID: 0xd3 (Samsung NAND 1GiB 3,3V 8-bit)
NAND_ECC_NONE selected by board driver. This is not recommended !!
Scanning device for bad blocks
Bad eraseblock 3641 at 0x1c720000
Bad eraseblock 4309 at 0x21aa0000
Creating 4 MTD partitions on "NAND 1GiB 3,3V 8-bit":
0x00000000-0x00060000 : "supervivi"
0x00060000-0x00260000 : "Kernel"
0x00260000-0x40260000 : "root"
mtd: partition "root" extends beyond the end of device "NAND 1GiB 3,3V 8-bit" -- size truncated to 0x3fda0000
0x00000000-0x40000000 : "nand"
s3c2410-ohci s3c2410-ohci: S3C24XX OHCI
s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1
s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
s3c2440-usbgadget s3c2440-usbgadget: S3C2440: increasing FIFO to 128 bytes
mice: PS/2 mouse device common for all mice
usbcore: registered new interface driver appletouch
input: s3c2410 TouchScreen as /class/input/input1
s3c2410 TouchScreen successfully loaded
S3C24XX RTC, (c) 2004,2006 Simtec Electronics
s3c2410-rtc s3c2410-rtc: rtc disabled, re-enabling
s3c2410-rtc s3c2410-rtc: rtc core: registered s3c as rtc0
i2c /dev entries driver
s3c2440-i2c s3c2440-i2c: slave address 0x10
s3c2440-i2c s3c2440-i2c: bus frequency set to 98 KHz
s3c2440-i2c s3c2440-i2c: i2c-0: S3C I2C adapter
mapped channel 0 to 0
s3c2440-sdi s3c2440-sdi: powered down.
s3c2440-sdi s3c2440-sdi: initialisation done.
s3c2440-sdi s3c2440-sdi: running at 0kHz (requested: 0kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
usbcore: registered new interface driver hiddev
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
UDA1341 audio driver initialized
failed to get memory region resouce
s3c2410-iis: probe of s3c2410-iis.0 failed with error -2
TCP cubic registered
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
mmc0: new SD card at address e624
mmcblk0: mmc0:e624 SU02G 1985024KiB
 mmcblk0: p1 p2 p3
s3c2410-rtc s3c2410-rtc: setting system clock to 2010-05-30 22:58:53 UTC (1275260333)
Waiting 3sec before mounting root device...
Root-NFS: No NFS server available, giving up.
VFS: Unable to mount root fs via NFS, trying floppy.
VFS: Cannot open root device "/ev/mmcblk0p3" or unknown-block(2,0)
Please append a correct "root=" boot option; here are the available partitions:
1f00        384 mtdblock0 (driver?)
1f01       2048 mtdblock1 (driver?)
1f02    1046144 mtdblock2 (driver?)
1f03    1048576 mtdblock3 (driver?)
b300    1985024 mmcblk0 driver: mmcblk
  b301     522081 mmcblk0p1
  b302      24097 mmcblk0p2
  b303    1437817 mmcblk0p3
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Any assistance would be greatly received. please let me know at: brandonsmith@rocketmail.com.

Brandon Smith

Hi again,

With a little more work, I have now got the NFS to start, but not it gives a new error:

Waiting 3sec before mounting root device...
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
Warning: unable to open an initial console.

 any ideas?

Prakash

@Brandon Smith

Either this warning stops your booting process or you just want to know why you are getting this warning message?.

 

 

Brandon Smith

It actually stops my boot.

Brandon Smith
Dont know if this makes any difference but i am also using the 7" touch instead of the 3.5"
max2440

Hi

  I folled  all the steps and i  port Android to my micro2440 with 7'tft but the screen is blank with some colors here and there

need help.

Eureka

Hi 

I need to know. What is terminal 2nd.

Thank for help

Josh Williams

I've been following your outline, but have one problem. I have a 64m and cant find a 64m uboot image anywhere! I actually loaded your uboot image (somehow) - but my next problem is im trying to do this with usb instead of mmc because i dont have a way to format my blasted mmc (im a windows user with no native linux. Virutalbox doesnt port my mmc card through to my ubuntu.

 I get a successfull uboot now on my mini2440, after the first part of your instructions. But my usb device always fails:

 

USB device not responding, giving up (status=2)

 

Maybe you can make some suggestions on ways to format my mmc, or get my usb working?

 

Thanks!

my email is josh.williams@tsma.com

Shannon Haworth

I apologize for the backlog of issues that I have not replied to.  I just finished up a cross-country move and havn't had much free time.  I'll take a look at these issues in the next few days.

 

Carlos M

I actually had the same 'problem' as brandon Smith:

"Waiting 3sec before mounting root device...

kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K

Warning: unable to open an initial console.

But it seems really only a warning for the 7" display (FriendlyARM), because as soon as I hooked up the smaller 3.5" version, the bootprocess continued -with all kind of warnings- but it worked. I actually saw the calibration screen of Android.

This project is really not stable. As soon as I hooked up the 7inch screen again, the bootproces also finish, with some errors which belong to Android I'm sure. 

"Warning: unable to open an initial console.

ts_control_open!

ts_control_release!

init: cannot open '/initlogo.rle'

sh: can't access tty; job control turned off

/ # FAT: bogus number of reserved sectors

VFS: Can't find a valid FAT filesystem on dev mmcblk0p1.

eth0: link down

init: cannot find '/system/bin/playmp3', disabling 'bootsound'

warning: `rild' uses 32-bit capabilities (legacy support in use)" 

I'm guessing this is normal..but the screen delivers real strange images, it's obviously not calibrated or something for a bigger size. I see 3 parts screen, 1 part black, 2 parts: 2blue and 1 white fat vertical stripes.

Any solution for the 7inch problem? I'll keep on switching screens and resetting in the meantime, since it seems to affect this 'living' problem.. 

Carlos M
btw..the version of u-boot that you got here didn't work for me. So I used a newer one, from May 2010. I downloaded it via this person's blog: https://sites.google.com/site/belina76/android-booting
Saravana

Hi Carlos ,

Did you get your 7 inch working. I'm having the exact same issue when I try to do it in my 7 inch mini2440. Any help will be much appreciated.

 

Regards

Saravana 

Mário Henrique

Hello Shannon,
really need your assistance.
I have a 256MB FLASH mini2440 and I use a screen 8".
I followed all his steps and found the problem below:

MINI2440 # boot
mmc: Probing for SDHC ...
mmc: SD 2.0 or later card found
trying to detect SD Card...
Manufacturer:       0x02, OEM "TM"
Product name:       "SD02G", revision 3.8
Serial number:      2732287029
Manufacturing date: 1/2009
CRC:                0x30, b0 = 1
READ_BL_LEN=15, C_SIZE_MULT=7, C_SIZE=365
size = 1642070016
SD Card detected RCA: 0x2df9 type: SD

2060420 bytes read
## Booting kernel from Legacy Image at 31000000 ...
   Image Name:
   Created:      2010-03-26   5:54:15 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2060356 Bytes =  2 MB
   Load Address: 30008000
   Entry Point:  30008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux.............................................................
........................................................................ done, booting the kernel.
Linux version 2.6.27 (root@tom) (gcc version 4.3.2 (Sourcery G++ Lite 2008q3-72)
 ) #1 PREEMPT Mon Aug 24 17:01:35 CST 2009
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177
Machine: FriendlyARM Mini2440 development board
Memory policy: ECC disabled, Data cache writeback
CPU S3C2440A (id 0x32440001)
MM: CPU does not support supersection mapping for 0x55000000000 at 0xf0d00000
S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz
S3C24XX Clocks, (c) 2004 Simtec Electronics
CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
Kernel command line: console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3
mini2440=4tb rootdelay=3 init=/linuxrc
irq: clearing subpending status 00000003
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 1024 bytes)
timer tcon=00500000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57
Console: colour dummy device 80x30
console [ttySAC0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 64MB = 64MB total
Memory: 60188KB available (3896K code, 636K data, 116K init)
SLUB: Genslabs=12, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Calibrating delay loop... 201.93 BogoMIPS (lpj=504832)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
net_namespace: 288 bytes
NET: Registered protocol family 16
S3C2440: Initialising architecture
S3C2440: IRQ Support
S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics
DMA channel 0 at c4800000, irq 33
DMA channel 1 at c4800040, irq 34
DMA channel 2 at c4800080, irq 35
DMA channel 3 at c48000c0, irq 36
S3C244X: Clock Support, DVS off
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 2048 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 2048 bind 2048)
TCP reno registered
NET: Registered protocol family 1
NetWinder Floating Point Emulator V0.97 (double precision)
ashmem: initialized
NTFS driver 2.1.29 [Flags: R/W DEBUG].
yaffs Aug 24 2009 16:57:57 Installing.
msgmni has been set to 117
io scheduler noop registered (default)
Console: switching to colour frame buffer device 30x20
fb0: s3c2410fb frame buffer device
adc     initialized
input: buttons as /class/input/input0
buttons initialized
leds    initialized
s3c2440-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2440
s3c2440-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2440
s3c2440-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2440
brd: module loaded
loop: module loaded
nbd: registered device at major 43
logger: created 64K log 'log_main'
logger: created 256K log 'log_events'
logger: created 64K log 'log_radio'
dm9000 Ethernet Driver, V1.31
Now use the default MAC address: 08:90:90:90:90:90
eth0: dm9000e at c4804000,c4806004 IRQ 51 MAC: c38bc934 (friendly-arm)
usbcore: registered new interface driver zd1211rw
usbcore: registered new interface driver zd1201
Linux video capture interface: v2.00
ovcamchip: v2.27 for Linux 2.6 : OV camera chip I2C driver
usbcore: registered new interface driver ov511
ov511: v1.64 for Linux 2.5 : ov511 USB Camera Driver
Driver 'sd' needs updating - please use bus_type methods
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c2440-nand s3c2440-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns
NAND device: Manufacturer ID: 0xec, Chip ID: 0xda (Samsung NAND 256MiB 3,3V 8-bit)
NAND_ECC_NONE selected by board driver. This is not recommended !!
Scanning device for bad blocks
Bad eraseblock 615 at 0x04ce0000
Bad eraseblock 838 at 0x068c0000
Bad eraseblock 866 at 0x06c40000
Bad eraseblock 1158 at 0x090c0000
Creating 4 MTD partitions on "NAND 256MiB 3,3V 8-bit":
0x00000000-0x00060000 : "supervivi"
0x00060000-0x00260000 : "Kernel"
0x00260000-0x40260000 : "root"
mtd: partition "root" extends beyond the end of device "NAND 256MiB 3,3V 8-bit"
-- size truncated to 0xfda0000
0x00000000-0x40000000 : "nand"
mtd: partition "nand" extends beyond the end of device "NAND 256MiB 3,3V 8-bit"
-- size truncated to 0x10000000
s3c2410-ohci s3c2410-ohci: S3C24XX OHCI
s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1
s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
Initializing USB Mass Storage driver...
usb 1-1: new low speed USB device using s3c2410-ohci and address 2
usb 1-1: configuration #1 chosen from 1 choice
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
s3c2440-usbgadget s3c2440-usbgadget: S3C2440: increasing FIFO to 128 bytes
mice: PS/2 mouse device common for all mice
usbcore: registered new interface driver appletouch
input: s3c2410 TouchScreen as /class/input/input1
s3c2410 TouchScreen successfully loaded
S3C24XX RTC, (c) 2004,2006 Simtec Electronics
s3c2410-rtc s3c2410-rtc: rtc disabled, re-enabling
s3c2410-rtc s3c2410-rtc: rtc core: registered s3c as rtc0
i2c /dev entries driver
s3c2440-i2c s3c2440-i2c: slave address 0x10
s3c2440-i2c s3c2440-i2c: bus frequency set to 98 KHz
s3c2440-i2c s3c2440-i2c: i2c-0: S3C I2C adapter
mapped channel 0 to 0
s3c2440-sdi s3c2440-sdi: powered down.
s3c2440-sdi s3c2440-sdi: initialisation done.
s3c2440-sdi s3c2440-sdi: running at 0kHz (requested: 0kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
usbcore: registered new interface driver hiddev
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
input: Generic USB K/B as /class/input/input2
input,hidraw0: USB HID v1.10 Keyboard [Generic USB K/B] on usb-s3c24xx-1
input: Generic USB K/B as /class/input/input3
s3c2440-sdi s3c2440-sdi: running at 198kHz (requested: 197kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
s3c2440-sdi s3c2440-sdi: running at 16875kHz (requested: 25000kHz).
mmc0: new SD card at address 2df9
mmcblk0: mmc0:2df9 SD02G 1921024KiB
 mmcblk0: p1 p2 p3
input,hidraw1: USB HID v1.10 Mouse [Generic USB K/B] on usb-s3c24xx-1
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
UDA1341 audio driver initialized
failed to get memory region resouce
s3c2410-iis: probe of s3c2410-iis.0 failed with error -2
TCP cubic registered
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
s3c2410-rtc s3c2410-rtc: setting system clock to 2010-07-19 00:37:22 UTC (1279499842)
Waiting 3sec before mounting root device...
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p3, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 116K
Warning: unable to open an initial console

I currently have these settings:

My default.prop

#
# ADDITIONAL_DEFAULT_PROPERTIES
#
ro.secure=0
ro.debuggable=1
persist.service.adb.enable=1
persist.sys.country = US
persist.sys.language = eng
persist.sys.timezone = Asia/Hong_Kong

My mount.conf

## mountd configuration file
## add a mount entry for each mount point to be managed by mountd
mount {
    ## root block device with partition map or raw FAT file system
    block_device    /dev/block/mmcblk0p1
    ## mount point for block device
    ## mount_point     /sdcard
    ## true if this mount point can be shared via USB mass storage
    enable_ums      true
    ## path to the UMS driver file for specifying the block device path
    ## use this for the mass_storage function driver
    driver_store_path   /sys/devices/platform/usb_mass_storage/lun0/file
    ## use this for android_usb composite gadget driver
    ##driver_store_path   /sys/devices/platform/msm_hsusb/gadget/lun0/file
}

My net.conf

NET=eth0
IP=192.168.254.230
GW=192.168.254.254
DNS=192.168.254.254

My SD Card

Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1          66      124775   82  Linux swap / Solaris
/dev/sdb2              67          92       49166   83  Linux (with ext2 - uImage)
/dev/sdb3              93        1015     1745393   83  Linux (with ext3 - fs)

My u-boot 1.3.2 (256MB)

MINI2440 # printenv
bootdelay=3
baudrate=115200
ethaddr=08:08:11:18:12:27
ipaddr=10.0.0.111
serverip=10.0.0.4
netmask=255.255.255.0
usbtty=cdc_acm
mtdparts=mtdparts=mini2440-nand:256k@0(u-boot),128k(env),5m(kernel),-(root)
mini2440=mini2440=0tb
bootargs_base=console=ttySAC0,115200 noinitrd
bootargs_init=init=/sbin/init
root_nand=root=/dev/mtdblock3 rootfstype=jffs2
root_mmc=root=/dev/mmcblk0p2 rootdelay=2
root_nfs=/mnt/nfs
set_root_nfs=setenv root_nfs root=/dev/nfs rw nfsroot=${serverip}:${root_nfs}
ifconfig_static=run setenv ifconfig ip=${ipaddr}:${serverip}::${netmask}:mini2440:eth0
ifconfig_dhcp=run setenv ifconfig ip=dhcp
ifconfig=ip=dhcp
set_bootargs_mmc=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440} ${root_mmc}
set_bootargs_nand=setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440} ${root_nand}
set_bootargs_nfs=run set_root_nfs; setenv bootargs ${bootargs_base} ${bootargs_init} ${mini2440} ${root_nfs} ${ifconfig}
mtdids=nand0=mini2440-nand
bootcmd=mmcinit ; ext2load mmc 0:2 0x31000000 uImage ; bootm 0x31000000
bootargs=console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3 mini2440=4tb rootdelay=3 init=/linuxrc
partition=nand0,0
mtddevnum=0
mtddevname=u-boot

Environment size: 1190/131068 bytes

Please Shannon, I'm doing something wrong.
There is still something to fix?
Can you give me a hand.
Thank you very much.

Saravana

Hi Mário ,

I think you also have the same issue as mine. But I'm trying with 7 Inch. Did you try connecting 3.5 inch to see if it works. I don't have a 3.5 to test this. If that thee case we can work towards fixing the screen.

I will keep working and let you know if it works also let me know if it works for you,

 

Regards

Saravana

Mário Henrique
Hi Saravana,
I also own a boar with screen 7" but have not tested as it is with a friend of mine.
I think the screen settings are made only in the u-boot, I could be wrong.
Unfortunately I do not have a screen test for 3.5".
As soon as I get some progress here and I decided to inform you.
Regards.

Mário Henrique
Saravana

Hi Mario/Carlos,

I guess the issue is we need to setup FrameBuffer device while building android Image. I tried the below command after getting into Linux prompt through serial console. And able to see color changes in the screen. I guess right now Android writes to this Frame buffer which is set fr 3.5 Inch screen.

 

/ #   cat /dev/urandom > /dev/graphics/fb0.

 

Hi Shanon,

Do you know how to rebuild the image for 7inch Screen.

 

Regards

Saravana

 

Mário Henrique
Hi Saravana,
I compiled a new kernel following the footsteps of Vinod. ( You need to install ncurses-devel)

http://my.opera.com/vinodmunikoti/blog/manual-for-compiling-android-for-mini2440

I've used SUSE Linux Enterprise Server 10 SP3. Until then, when I ran the command "make menuconfig", a screen of settings for compiling the kernel is displayed and not found any option related to the type of display.
Take a look, as you may find something, after all I am not expert in linux and I am a beginner with the mini2440.

I believe that the problem does not relate to the display, at least by my case.
One question: You know you need to add in the boot args, parameters, mini2440 = 1tb (For display 7 ") and mini2440 = 4TB (For display 8")?

As the example of our colleague:

MINI2440 # setenv bootargs console=ttySAC0,115200 root=/dev/mmcblk0p3 rootfstype=ext3 mini2440=1tb rootdelay=3 init=/linuxrc

Oh my god! What is this error?

Warning: unable to open an initial console

Somebody help us! ...Please!

Regards

Mário Henrique - Brazil
Joan
Hi

I try to implement Android in NAND flash, not in SD card, but when I reboot says me  "unsopported NAND".

I follow the steps:

-Boot supervivi in NOR mode and in the menu:

(1) input "x" formatting system
(2) and then select the "v" to start the download bootloader, and choose supervivi-128M
(3) and then select "k" to start the download android kernel: zImage
(4) Finally, select the "y" to start the download mini2440T35_android.img

 The files supervivi-128M, zImage and mini2440T35_android.img are from download, not recompiled.

When I switch to NAND and reboot in minicom appears the message

unsupported NAND

Can anybody help me,please?

Thanks.
Mário Henrique

Hi Saravana,
I almost solved my problem.
I found I can not remember where, a tip using mknod.

Mount your root filesystem SD card and give the command mknod.
/# cd /mnt/rootfs
/mnt/rootfs/# mknod dev/console c 5 1

Me think it will work with you because it uses a 7 "screen.
How do I use a screen 8, I found this problem:

mknod: /myDev/ts0: File exists
mknod: /myDev/fb0: File exists
mknod: /myDev/ts_ctl: File exists
open file errer!
xres=240, yres=320

I guess I'll have to compile another resolution and do not know which to use for the screen 8 "

Regards,

Mário Henrique

Mário Henrique

Hi Joan,

I also had this problem was then that I decided to use the SD card.
First try to use the SD after leaving for installation in flash memory.
When I get I'll let you know.
Please, if you get ahead of me, teach me how.

Regards,

Mário Henrique

Joan

Hi Mário and blog friends

I have successfull run Android in the NAND.  I done the same process described in this blog but only using the NAND because I need the SD card to put the files recorded by the mini2440.
I need now configure the language (now is in chinese) and the internet connection.


Best Regards to all

Saravana

Hi Mario,

It doesn't work for me. See this below Video both the Parts, If you closely watch Console not found is just a warning but it still works. Only catch is he is making change in Kernal C source.  But the video is in Japanese I guess.

 

http://www.youtube.com/watch?v=Bfp3H9K2pCE

 

Regards

saravana. 

 

 

Mário Henrique

Hello Joan,
edit  the file /default.prop

persist.sys.country = CN
persist.sys.language = zh
persist.sys.timezone = Asia / Hong_Kong

Change to:

persist.sys.country = U.S.
persist.sys.language = en_US
persist.sys.timezone = Asia / Hong_Kong

I do not know how would the line "persist.sys.timezone".

To configure the Internet edit the file /system/etc/shine/net.conf

How were you able to load the NAND?
Until now I could not do anything!
Do you use a display of 8"?

Reggards,

Mário Henrique

Mário Henrique

Joan!

Sorry!

persist.sys.country = US

not "U.S"

 

Google tranlator ..... OOOOOPS!

 

Mário Henrique

Hi Saravana,
we ask for help from him.

 cheers.

Shannon Haworth

I've been very busy at work (the mini2440 is my hobby) and unable to monitor, much less respond to posts on this page. 

I reccomend that everyone use this resource:  http://groups.google.com/group/mini2440?lnk=srg as it has great community participation.  Your questions may be answered there.  

I apologize to those who have left me messages - I'm unable to respond currently.  In part because I have not even unpacked my mini2440 following my move.

Regards,

Shannon

Saravana

Hi Mario,

  Good news I made 7inch mini2440 work.Its good except it very slow. May be due to screen size ? Mine in 64 MB RAM and 256 NAND version

I will post the working uImage file in my blog shortly and give you link. 

 

 

Regards

Saravan 

Joan
Hi Mario

Sorry for the answer's delay.

At the NOR flash I have the supervivi and in the NAND flash I load the android with Supervivi tools. I don't use SD card.

If you like send me and email to joan060606 gmail.com . I have more questions but Shannon says that is better to use http://groups.google.com/group/mini2440 but in this group there isn't answers about Android and mini2440.

Regards

 

Carlos M

 

Hello everyone, I dont see much activity here. I've been looking for info/support about Android on the 2440 for weeks now. I've seen a few sites talking or blogging about this project but no main community. :(

On the other hand here http://www.friendlyarm.net/forum/0 is a lot of activity but little people are developing in combination with Android I think or at least not commenting about it. I see only people with questions and no people with answers. At Google Groups it's not better, nothin but talk about compiling Android, further only non-Android related stuff.

I'm doing this right now for my internship, but when I get the chance I'll get my own 2440 or 6410 and will be developing. Will be cool if there's a much bigger community at 1 place.

I wonder where everyone is looking or talking about the 2440? And where are the people who actually have a better than average knowledge about this project? 

Another question: Does someone know how to use the camera(cam130) in Android? I can't call it as native android-camera or I'm doing something wrong..

Regards

(I hope there's still some folks left to read this and reply) [sent:September 1]

 

Chris

I used the install from https://sites.google.com/site/belina76/android-booting and the tips for setting the languages andt making the sd-card as root

 works like a charm

  thank all, Chris

captcha

Last modified: Sep 1, 2010

 

Navigation