Welcome! Log In Create A New Profile


Uboot for other devices

Posted by gnexus 
Uboot for other devices
June 20, 2012 06:24PM
This post was on another thread. It ended up mainly being about getting Uboot going on an Allwinner A10 tablet.
It is a bit off topic, since it is not about Uboot on a plug device. This is a Uboot forum, however, so some people may find it useful. So I moved it to this separate thread. There currently are no plug computers using the A10. Bu there are many tablets available and other devices such as the Mele STB mentioned below. There is also the MK802 USB key computer and the Gooseberry board which is similar to the Raspberry Pi in price, but is actually available and much much faster.

My goal for compiling uboot for the Dockstar wasn't so it could be permanently installed on it. The uboot from here works perfectly and I will keep using it. I just bought the awesome new Android Tablet that uses the Allwinner A10 ARM SoC. A10 devices will also run Debian or any other ARM Linux distro. Kernel sources are now available. Like most Android devices they use uBoot as the bootloader. I need to get multi-boot enabled for the SD card. So a new uBoot needs to be compiled. Native Linux is already running on these devices. The A10 processor and MALI400MP GPU support up to 2160p (quad HD!) playback. The tablet plays back 1080p HD streams flawlessly. So a device using the A10 would make the ideal MythTV or XBMC frontend!

I don't have a lot of time to spend getting Uboot working properly on the Dockstar. I just want to be able to compile it from source to see that it works and loads the kernel. Then I can concentrate on building a uBoot for my tablet. The A10 in the Eken has 8 serial ports available! But you either need to disassemble it or use an SD card adapter to get to them. I don't really want to do either of those yet, although I will probably be ordering the adapter. I would like to be certain my uboot compilation works on the Dockstar, and that I can add/remove things like the HUSH shell before bricking my tablet (actually the A10 can't be bricked as they will always boot from USB and can then load a ROM) and needing to reflash the Android image.

My Dockstar Uboot works!!!

From the Dockstar:
U-Boot 2012.04.01-07800-g613913f (Jun 17 2012 - 13:48:38)

I can reload my previous environment as follows with the new " env import" command that is also in Davy's Uboot:
mw 0x800000 0xffff 0x40000
tftpboot 0x800000 dockstar.uboot.environment
Filename 'dockstar.uboot.environment'.
Load address: 0x800000
Loading: #
Bytes transferred = 2710 (a96 hex)
env import 0x800000 0xa96
Boots again as normal. But there is a problem:
Unknown command 'usb_scan_done=0' - try 'help'
Unknown command 'for' - try 'help'
Unknown command 'do' - try 'help'
Unknown command 'if' - try 'help'
Unknown command 'then' - try 'help'
Unknown command 'if' - try 'help'
Unknown command 'then' - try 'help'
Unknown command 'else' - try 'help'
Whoops! No HUSH shell yet. . .

The source is the latest from the u-boot-marvell tree. No patches or HUSH yet . Compiled natively on the device.
I'm just happy I don't need to pull out my JTAG board. . .

Now that I know my build environment is okay I can enable HUSH and try pulling down and building the A10 uboot. The good thing with it is that you don't need to flash the Uboot on the A10. It actually resides in a FAT partition! You must still reflash if the Uboot fails. But Uboot can also reside on the SD card from what I understand! Makes life a LOT easier, huh?

It would be nice to have Jeff's relocatable code.

Added the HUSH shell to default u-boot-marvell config. Boots the Dockstar fine now from USB. So I started on the A10. Following instructions from Uboot Allwinner wiki. The default config compiles so I will try to write it to SD and maybe boot Debian on an Android tablet!. I'm looking forward to getting the Mele box as a low-power Debian MythTV frontend to complement my 2 GoFlex Net MythTV backends. I could use a tablet with an HDMI cable. But the Mele has a remote, SPDIF, and SATA. It looks nicer and would be more suitable as a STB. Looks like they could use help getting A10 Uboot tweaked.

Another Update:
Sorry if this post is too long and getting off topic. But, for anybody else that is interested using the Dockstar, etc. as a low-power MythTV backend, they should know that an A10-based tablet or box makes the ideal low-power MythTV frontend for it (I originally had planned to try a Raspi, but very happy I didn't waste money on the delayed, low-powered, closed source PoC), and that compiling U boot works for it and Uboot can reside on the SD card without flashing it to the NAND:

I finally got my mini-HDMI cable for my tablet, and it is flawlessly playing a 1080p HD stream on my TV from the GoFlex backend! It is still using Android, unfortunately. But I have a Mele box coming and am working on getting native Debian going on the tablet. So far the Uboot works on the SD card, but then it hangs at the Android kernel because I have not yet compiled a new kernel. The Dockstar Git sync was too slow, so I had to reinstall an ARM toolchain on my PC to build.

The kernel is finally compiled now. If you are compiling a kernel to be booted by Uboot please be aware that you MUST have the mkimage utility installed on the build host. The package you need is uboot-mkimage on Debian and u-boot-tools on some other distros like Fedora. I forgot it was missing on my Fedora system and ended up without uImage.

Even with the kernel built I can't get the tablet to boot. The display is black and I don't want to disassemble the tablet just to get a serial console. You can also use a micro-SD card adapter to get a Uboot console. But I need the SD to boot from. Most likely there is a problem with the Uboot environment. You can add a Uboot script to the Uboot partition to add extra boot parameters. That will be my next step. But I may need to wait to get the Mele box, which has an accessible serial port, to finally make a bootable SD card. In the meantime there are almost 40 pages about the A10 on the XBMC forum if you want to get more info about the A10. From the XBMC thread it seems that this Ubuntu SD card image will boot on any A10 device. From this post it seems that the A10 kernel is now fully GPL'd.

Guess what? It works!!

I was fighting with the tablet trying to get something other than a black screen. I downloaded the SD card image above and tried mounting it and copying over the files to my partitions and using my Uboot. Nothing. So I cloned the entire image to my card. Still nothing. That was strange as it is supposed to work. But then I had an idea. Both the Mele and the MK802 use the HDMI output for the display. What if there are no LCD drivers for the touchscreen on the Eken tablet? No display. . .

Connected it to a monitor and there was an Ubuntu desktop right there!

If nothing else, it makes for a small Android tablet that, when connected to a display, gives you a full GNU/LInux PC!

Now to see if my Uboot works. . . and get Debian with Trinity Desktop (KDE 3) back on the SD card again.

One of these cheap tablets, or a MK802, or a Gooseberry board, makes a cheaper and better alternative to the Guru Plug Display, and a faster and more available alternative to the Raspberry Pi. Plus they can also double as a tablet or a STB. The A10 is getting more popular every day. There will soon be a large community working to get a good Linux version.

Edited 3 time(s). Last edit at 07/17/2012 09:12AM by gnexus.

Your Email:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.