View Single Post
Posts: 116 | Thanked: 643 times | Joined on May 2016
#1
I got pretty much inspired by https://jolla.comes.today/jolla-tablet-on-taobao-china/ article and firmware from http://talk.maemo.org/showthread.php?t=96474. In a nutshell, official Jolla Tablet is a device based around Intel Atom Z3735F SoC (Bay Trail) and can work both with Sailfish OS and Android (by the way, Android device tree it's based on is called "anzhen4_mrd8_w").

There have been a lot of cheap Chinese tablet using the same SoC, and usually they come with Android/Windows dualboot. So what's preventing us from running Sailfish OS on them? Android firmware can often be easily ported between such devices, but kernel is device-specific, so custom ROM makers just use the stock kernel from their device unmodified.

For Sailfish OS, we can't, since systemd requires some kernel options which are most of time turned off in Android kernels. Enabling them and recompiling kernel would be easy if Chinese manufacturers didn't violate GPL and actually provided kernel sources, but that's not the case. Thankfully, since most of hardware is similar, it's possible to base custom kernel on other device source.

I have Sailfish OS running on Onda V820w tablet. It's not perfect yet, but the hardware itself (touchscreen, audio, Wi-Fi, Bluetooth, front and back cameras) works. Many thanks to Stskeeps for providing modules folders which were missing from Jolla Tablet kernel sources. The biggest problem was getting kernel working with camera sensors. Even though the needed drivers are present, PMIC regs and GPIO pin meanings turned out to be different. Just a few values to change, but it was very troublesome to debug and I had to disassemble Onda stock Android kernel to understand what's wrong.

Below is a guide to installing Sailfish OS on Onda V820w (tested with V3, see serial number to understand what revision is yours if you happen to have it). Hope community will be interested in running Sailfish OS on other similar devices and we can have more supported. I'm happy to help with what I can either here or at #sailfishos-porters on IRC.

Onda V820w (V3) manual install guide
Make sure you have USB keyboard and OTG cable, it's required for navigating in UEFI setup.

1. Make ext4 partition at least 2 GiB large on your microSD card. GParted is your friend in this. It's also possible to use internal NAND, but this would require booting Linux LiveCD on tablet for partitioning, using microSD is easier and safer for testing.

2. You can either download Jolla Tablet firmware yourself and extract root/home partition. On Jolla Tablet LVM is used with separate partitions for root, /home and /fimage (recovery images). I didn't use this structure since it complicates testing and amount of available space on tablet is pretty low, and instead moved /home contents on root partition. /fimage is not needed since we don't have recovery images anyway. Then overwrite the contents of root partition with the contents of "root" folder from https://github.com/NotKit/sailfishos-onda-v820w-overlay.

Or you can use the rootfs tarball I prepared (Sailfish OS updated to the latest version): https://mega.nz/#!cBZ2XZ6L!P3EIFFQze...6lNcJnyOvjsArA

3. Now you need to adjust the contents of grub.cfg in /boot.
root= should to point to the right partition, /dev/mmcblk1p2 by default for second partition on microSD card.
Since the tablet can't boot from SD card, we need to copy bzImage, grubia32.efi and grub.cfg from /boot to the root of internal NAND ESP partition. If you have root access in Android, you can mount it like this:
Code:
su
mkdir /data/local/esp
mount -t vfat /dev/mmcblk0p1 /data/local/esp
4. Connect USB keyboard and reboot the tablet, holding Esc key. It should go to the boot menu. Select "Boot From File" option and chose ESP partition in the list, then launch grubia32.efi.

The first option in GRUB should normally boot Sailfish OS. First boot is going to take around a minute, but If you have black screen for too long, try pressing power button.

The second (init-debug) enables USB networking and telnet daemon as specified in 9.2 of HADK porting guide. It halts booting until you connect via telnet and tell it to continue, so don't expect anything but black screen until then.

Here are some photos how it looks like if you get it running: http://imgur.com/a/2CIVo
Update: automatic installer (all data is going to be erased!) image for ONDA V820W V3: https://mega.nz/#!8FZRiBwB!FBBD8CUMa...Qp713VqT-FoAhM. Unpack it to the root of FAT32 formatted USB drive and boot tablet from USB drive.

Last edited by TheKit; 2016-12-10 at 17:28.
 

The Following 39 Users Say Thank You to TheKit For This Useful Post: