Jump to content


Photo

Ubuntu Linux 11.04 (natty) on Vega (update 13/4)


  • Please log in to reply
208 replies to this topic

#1
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts
Update 13/4:
* Working unity-2d

Update 31/3:
* Replaced onboard virtual keyboard with florence
* Fixed wifi to work more consistently

Here is an updated photo of ubuntu running on the vega:
Posted Image

Update: Sample root, kernel and initrd image now available from http://www.adebenham.com/vega/
To use
* first download linux-kern.img and vega_root.tgz from the above site
* Partition your microSD so that there is a partition set aside for the linux install. Make sure to format this partition as ext3
* Extract the vega_root.tgz to this new partition - this needs to be done as root so that the permissions can be set correctly
* The prebuilt kernel image assumes that root in on the second partition of the SD card - if this is not so then you will need to rebuild the linux-kern.img (see instructions below)
* Put the microsd into your vega ready to use
* Boot the vega into nvflash mode (via back+power button)
* Flash the created boot.img via "./nvflash -w --bl ./bootloader.bin --download 7 linux-kern.img --go"
* You should now be able to boot the vega into ubuntu!

Note: gdm can take a long time to login - you can skip the wait by logging into the console as root and running 'service gdm start' or you can just wait a moment until udev finishes its work.
The default user is 'ubuntu' with password 'ubuntu' and the root user has the password 'root'
There is a problem with libc6 2.13 so if you accidentally update libc you can re-install the 2.12 version by running 'dpkg -i /root/glibc/*' as I have saved a copy of the package in there

Working: Wifi, graphics (via tegra drivers), touchscreen (single-point), usb host (for keyboard etc)
Non-working: Sound, bluetooth


How to manually rebuild the linux-kern.img:
* To do this download initrd.img-2.6.32-custom and zImage from the above site
* Create a suitable boot.img via (that should all be on one line)

mkbootimg --kernel zImage --ramdisk initrd.img-2.6.32-custom --cmdline "root=/dev/mmcblk3p2 rootdelay=5 rw mem=448M@0Mnvmem=64M@448M vmalloc=192M init=/sbin/init video=tegrafb console=tty0,115200n8 usbcore.old_scheme_first=1 mtdparts=tegra_nand:2048K@6784K(misc),5120K@9344K(recovery),8192K@14976K(boot),1496K@23680K(system),32768K@146688K(cache),4096K@179968K(staging),339200K@184576(serdata)"-o linux-kern.img

* This will create a linux-kern.img file suitable for flashing. It assumes the root filesystem is on /dev/mmcblk3p2 (which is the second partition on your microSD card) but you can change it as needed.


----
I have ubuntu 11.04 mostly working on my vega now but there were a few issues on the way.
Here is a basic/general guide on how to get it working (note: this is not for the faint of heart as yet)
It's more of a brain dump of how I got things working and probably not easy to follow.
Once I'm happy with things I'll work on uploading a copy of the root filesystem and kernel I am using to make it easier for others to try it

* Download natty-arm minimal root image from http://elinux.org/Be....04_Development
* Partition microsd card to have a ext3 partition of at least 2g
* Extract the rootfs from downloaded natty-arm minimal image to that partition
* Copy /system/lib/hw/wlan from existing/working android system (this contains the pre-compiled wireless LAN kernel module)
* Grab vega kernel source from git and apply kmsg patch from https://bugs.launchp...-syscalls.patch
* Next recompile the kernel with CONFIG_SIGNALFD enabled and CONFIG_ANDROID_PARANOID_NETWORK disabled
* Flash that kernel with the initrd from the minimal image via (Change the 'root=/dev/mmcblk3p2' to whichever partition the root filesystem is on):
mkbootimg --kernel android_kernel_advent_vega/arch/arm/boot/zImage --ramdisk initrd.img-2.6.32-custom --cmdline "root=/dev/mmcblk3p2 rootdelay=5 rw mem=448M@0M nvmem=64M@448M vmalloc=192M init=/sbin/init video=tegrafb console=tty0,115200n8 usbcore.old_scheme_first=1 mtdparts=tegra_nand:2048K@6784K(misc),5120K@9344K(recovery),8192K@14976K(boot),1
2496K@23680K(system),32768K@146688K(cache),4096K@179968K(staging),339200K@184576
(userdata) " -o linux-kern.img

* The first seen on booting is that the libc that comes with natty causes a bunch of instruction alignment errors.
I worked around this by grabbing an older version from ports.ubuntu.com
The files needed were:
- libc6_2.12.1-0ubuntu10.2_armel.deb
- libc6-dev_2.12.1-0ubuntu10.2_armel.deb
- libc-bin_2.12.1-0ubuntu10.2_armel.deb
- libc-dev-bin_2.12.1-0ubuntu10.2_armel.deb
- libnih1_1.0.2-1ubuntu2_armel.deb
- libnih-dbus1_1.0.2-1ubuntu2_armel.deb
- upstart_0.6.6-4_armel.deb

They were downloaded on a separate machine, copied to the rootfs so that they could be installed manually later

* Once these were installed the machine was able to boot into gdm and work correctly

Update: Found how to recompile the wlan module so now can make more changes to kernel - such as swap and sysv ipc support
See http://armin762.word...s-6002-working/

Update: If you are getting compile errors about "undefined reference to `__aeabi_uldivmod'" then apply the following patch : http://www.linux-arm...c0f9d243359d5f8

Edited by hybr1d, 13 April 2011 - 06:00 AM.

  • 0

#2
High Flyer

High Flyer

    Newbie

  • Members
  • Pip
  • 23 posts
You're a god man - You really are.

Is it fast?

  • 0

#3
Jisonga

Jisonga

    Regular

  • Members
  • PipPip
  • 141 posts
  • Gender:Male
  • Location:South East England
  • Interests:I am a big fan of tech gadgets, Motor Sport and sim racing.
  • Devices:Gallaxy S2 & ASUS TF 101.
This all sounds very interesting mate.

Please keep us updated on how things go and once its usable and the install procedue is little easier to follow i would be looking forward to giving it a go.

Thanks for all your hard and effort in bringing us something else to play with on our vegas.

Jason.

  • 0

Posted By Jason a rooted Galaxy S2 & Asus TF 101 user.


#4
IndyUK

IndyUK

    Newbie

  • Members
  • Pip
  • 13 posts
I'm liking the sound of this. I'd love to see Ubuntu running on this. What os did you use to perform the install?

  • 0

#5
Nemes1s

Nemes1s

    Regular

  • Members
  • PipPip
  • 83 posts
  • Location:Berkshire, UK
  • Devices:Vega (1.09 + mcr8)
  • Twitter:@FredTrigg
As a massive Ubuntu fan I would be very interested in this if you get it going. Excellent work!!

  • 0

#6
vurrut

vurrut

    Newbie

  • Members
  • Pip
  • 4 posts
Can you please explain a little more detail these three paragraphs.

Copy /system/lib/hw/wlan from existing/working android system (this contains the pre-compiled wireless LAN kernel module)
* Grab vega kernel source from git and apply kmsg patch from https://bugs.launchp...-syscalls.patch
* Next recompile the kernel with CONFIG_SIGNALFD enabled and CONFIG_ANDROID_PARANOID_NETWORK disabled

I jam on how to compile the kernel. kernel to use? MoDaCo?

thanks in advance.

  • 0

#7
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

Can you please explain a little more detail these three paragraphs.

Copy /system/lib/hw/wlan from existing/working android system (this contains the pre-compiled wireless LAN kernel module)
* Grab vega kernel source from git and apply kmsg patch from https://bugs.launchp...-syscalls.patch
* Next recompile the kernel with CONFIG_SIGNALFD enabled and CONFIG_ANDROID_PARANOID_NETWORK disabled

I jam on how to compile the kernel. kernel to use? MoDaCo?

thanks in advance.


Yes, use the kernel source from modaco (http://android.modac...-now-available/)
For the kernel config you can use the config file attached to this post (just uncompress, rename to .config, place in the kernel source directory and then run 'make oldconfig')
In relation to the wlan modules - I've actually found the source code for this so there is no longer a need to copy from a running android install.
(see the first post)

Attached Files


  • 0

#8
simonta

simonta

    Hardcore

  • Members
  • PipPipPipPipPipPip
  • 1,298 posts
  • Gender:Male
  • Location:Southampton
  • Devices:Vega. HTC Desire
Sweet work mate. Thanks. Will watch this with great interest. How's the touch screen support in Ubuntu? I'm still running Fiesty Fawn on my main machine and haven't really tinkered with it lately. Are you using Unity?

I know how to make a boot image, but not a lot about initrd and the bootloader. Do you know a bit about them? I'm wondering if there's a possibility of getting GRUB or similar running?

Anyway, thanks for the contribution. Can see a geekfest weekend coming up!

  • 0
If I've helped you, you want to say "thanks" and you do not use Dropbox (it's enormously useful, especially with mobile devices), please consider signing up for it using my reference. You'll get 2GB of disk space for files available anywhere, any time on any device. They give us both an extra 250MB if you do sign up!

Sign up for Dropbox

Apple? I'd rather eat my own kidneys!

#9
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

Sweet work mate. Thanks. Will watch this with great interest. How's the touch screen support in Ubuntu? I'm still running Fiesty Fawn on my main machine and haven't really tinkered with it lately. Are you using Unity?

I know how to make a boot image, but not a lot about initrd and the bootloader. Do you know a bit about them? I'm wondering if there's a possibility of getting GRUB or similar running?

Anyway, thanks for the contribution. Can see a geekfest weekend coming up!


Touch screen works fine (but only single-point at this stage - will look at it more once I fix up the eglibc issues)
The eglibc problems are also causing unity to fail so I'm just running a normal gnome desktop
In relation to the boot image - have a look at the 'kernel source released' thread as it is described in there and also check out http://wiki.cyanogen...nel_from_source
I don't think grub will be possible (never heard of grub working on arm) but my curiosity has been raised so I might look into that :huh:

  • 0

#10
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

Touch screen works fine (but only single-point at this stage - will look at it more once I fix up the eglibc issues)
The eglibc problems are also causing unity to fail so I'm just running a normal gnome desktop
In relation to the boot image - have a look at the 'kernel source released' thread as it is described in there and also check out http://wiki.cyanogen...nel_from_source
I don't think grub will be possible (never heard of grub working on arm) but my curiosity has been raised so I might look into that :huh:


Grub doesn't look possible (relies on firmware/MBR capabilities not available on arm) but u-boot may be do-able

  • 0

#11
warriorscot

warriorscot

    Addict

  • MoDaCo Silver
  • PipPipPipPipPip
  • 724 posts
  • Location:Scotland
  • Devices:Advent Vega
Have you got a gui up and running with it or is it just the backend command line interface you have up.

  • 0

#12
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

Have you got a gui up and running with it or is it just the backend command line interface you have up.


Full gui up and running - even firefox/openoffice works
Just not that fast as yet due to non-accelerated X drivers

  • 0

#13
warriorscot

warriorscot

    Addict

  • MoDaCo Silver
  • PipPipPipPipPip
  • 724 posts
  • Location:Scotland
  • Devices:Advent Vega
Take it you are using Gnome for the GUI, have you given XFCE a go its less resource intensive. I used to use it on an older system that I couldn't get drivers for the graphics card for so I needed the extra performance boost and it's actually just as good as gnome.

Have you tried the current release 10.10 netbook edition in the arm flavour it has some tablet based tools? Or is there something changed in 11.04 that is necessary? Just seems to me it might be easier with the stable version rather than the beta that way you can distinguish beta problems from vega/Tegra problems.

  • 0

#14
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

Take it you are using Gnome for the GUI, have you given XFCE a go its less resource intensive. I used to use it on an older system that I couldn't get drivers for the graphics card for so I needed the extra performance boost and it's actually just as good as gnome.

Have you tried the current release 10.10 netbook edition in the arm flavour it has some tablet based tools? Or is there something changed in 11.04 that is necessary? Just seems to me it might be easier with the stable version rather than the beta that way you can distinguish beta problems from vega/Tegra problems.



I haven't tried xfce as yet because the aim is to get unity working on it (due to unity being more finger-friendly)
I am just using gnome at the moment because it was already there :huh: Also, I have customized my gnome install to use less cpu memory (I'm pretty much just running the panel+metacity)

The desire to get unity working is also why I am using 11.04 instead of 10.10 (also when I had 10.10 running it did not support the touchscreen)

  • 0

#15
HunteronX

HunteronX

    Diehard

  • Members
  • PipPipPipPip
  • 319 posts
  • Gender:Male
  • Location:UK
  • Devices:Xperia X10; Advent Vega

I haven't tried xfce as yet because the aim is to get unity working on it (due to unity being more finger-friendly)
I am just using gnome at the moment because it was already there :) Also, I have customized my gnome install to use less cpu memory (I'm pretty much just running the panel+metacity)

The desire to get unity working is also why I am using 11.04 instead of 10.10 (also when I had 10.10 running it did not support the touchscreen)


Nice work! I don't really know much about the underlying workings of linux - I've just installed modules, messed around with terminals, and compiled some code before, but I'm not sure if I could help to fix things for you.

I would love to test it though. :huh:

  • 0

#16
High Flyer

High Flyer

    Newbie

  • Members
  • Pip
  • 23 posts

I haven't tried xfce as yet because the aim is to get unity working on it (due to unity being more finger-friendly)
I am just using gnome at the moment because it was already there :) Also, I have customized my gnome install to use less cpu memory (I'm pretty much just running the panel+metacity)

The desire to get unity working is also why I am using 11.04 instead of 10.10 (also when I had 10.10 running it did not support the touchscreen)


There is a unity 2d version for 10.10, I'm currently running it on my netbook, http://www.webupd8.o...in-ppa-for.html

This might be less processor intensive on our lovely wee devices :huh:

  • 0

#17
fromWinland

fromWinland

    Newbie

  • Members
  • Pip
  • 8 posts
How about virtual keyboard? It has one or you have to install( it's possible, right)?

  • 0

#18
hybr1d

hybr1d

    Newbie

  • Members
  • Pip
  • 43 posts

How about virtual keyboard? It has one or you have to install( it's possible, right)?


Here is a photo of the current status http://twitpic.com/456ypz
'onboard' is the virtual keyboard seen

  • 0

#19
vurrut

vurrut

    Newbie

  • Members
  • Pip
  • 4 posts
Sorry to bother you but I can not compile the kernel, I have taken the following steps:

1.Download natty image and transfer to partiotion ext3 on my SD. (OK)

2.Download Kernel MODACO to git and extract in a folder android_kernel_advent_vega(OK)

3.i copy modules wlan of android rom ,but I do not know where to put them.

4.copy patch in folder of kernel an aplly the patch with the command:

patch -p0 < (file name).patch

(and the output is 4 FAILS)

5.Copy .config in the kernel

6.make oldconfig

ask me lot of things! spend all the enter.
I see that many things are answered by default.
(surely this is my big mistake)


Thanks in advance.

PS: I saw the picture with virtual keyboard and I can not endure more ...

  • 0

#20
Zebrahead

Zebrahead

    Diehard

  • Members
  • PipPipPipPip
  • 317 posts

4.copy patch in folder of kernel an aplly the patch with the command:

patch -p0 < (file name).patch

(and the output is 4 FAILS)



Not used patch before, but a quick man patch told me that doesn't look quite right.

diff --git a/fs/proc/kmsg.c b/fs/proc/kmsg.c

The -p(NUMBER) flag strips characters from the start of the parameters. Directories a and b, do not exist. So the files
you're patching, wont be found.

Try :

patch -p2 < filename.patch

Good luck :huh:



PS, Whole thread is awesome btw, thanks for all of your work! WRT Kernel options, did you just compile with default
options except the ones specified in OP?


Zeb

  • 0

My new website - check it out for various VEGA dev stuffs and tools


I'm running out of space to host things! More space for both of us if you don't already have Dropbox! : Free Dropbox Space!!
@ZebraDroid





6 user(s) are reading this topic

0 members, 6 guests, 0 anonymous users