Wednesday, April 26, 2017

How to install Kubuntu on a Chuwi Hi13


I've always dreamed to have an ubuntu-tablet. Chuwi promises official support for Ubuntu for this device. I think this Chuwi can cause a revolution: If installing ubuntu would be just as easy as insert a usb-stick and hit OK, this can be a great succes, and a way to bring ubuntu to a larger community of users.



I ordered mine by Chuwi QH store. Good store: very helpfull and correct:
https://nl.aliexpress.com/item/Presale-Tablet-PC-Chuwi-Hi13-13-Intel-Apollo-Lake-N3450-4GB-RAM-64GB-ROM-10000mAh-Windows/32793418065.html?spm=2114.13010608.0.0.ABpuji

Finally, after some problems with declaration by DHL, it arrives! What a nice device: very premium-feel aluminium finish.

So I couldn't wait to install ubuntu on it. Made an ubuntu USB-live-stick, and inserted it. You guess what: nothing happened...



I googled and studies for hours and hours, and now I have Ubuntu for Gnome successfully installed on the Chuwi HI13.
Nearly everything is working out-of-the-box, except grub. You have to replace it by Refind.

DETAILED HOWTO


First we are going to update the bios of the Chuwi HI13. Because newest version has more options to boot from USB.
Go to:
http://forum.chuwi.com/forum.php?mod=forumdisplay&fid=83&filter=typeid&typeid=62
and download bios:
http://www.mediafire.com/file/uqdbirvp7r1mlb1/Chuwi_Hi13_Bios_AP1V114_X64_BIOSEC.rar

Use your old windows computer once more... Download and install rufus on your windows computer:
https://rufus.akeo.ie/downloads/rufus-2.14.exe

Insert your first USB-stick, and copy the files to it, using Rufus.

Now we are going to make a bootable USB-stick with ubuntu.
Download Ubuntu for gnome live ISO.
http://cdimage.ubuntu.com/ubuntu-gnome/releases/17.04/release/ubuntu-gnome-17.04-desktop-amd64.iso.torrent

Insert you second USB-stick, and burn the ubuntu iso to it, using Rufus.
Open your USB-stick with windows file browser.
Go to: Efi/Boot.
There you see 2 files:
BootX64.efi and:
GrubX64.efi
Delete them and replace them with the Refind version I prepared for you:
https://drive.google.com/drive/folders/0B3FtVY6JAiGAV2d0Z1hzMDBQQ0U?usp=sharing
In the directory Boot, you find the two needed files:
bootx64.efi
refind.conf

Notice I added a menu entry at the bottom of refind.conf.
The options i have copied from boot/grub/grub.cfg:
menuentry "Try Ubuntu GNOME" {
    loader  /casper/vmlinuz.efi
    options "file=/cdrom/preseed/ubuntu-gnome.seed boot=casper quiet splash ---"
    initrd    /casper/initrd.lz
}
Then: copy the second dir on my google-drive:
refind
to the root of your usb-stick. We will need it later.

Oke, your life stick is ready.

Now we are going to update the bios of your Chuwi HI13.
Take your chuwi HI13. Insert  your first usb-stick with bios update.
Be sure battery is 50% or more.

Please make sure windows is properly shutted down, and not in fastboot mode.
You can disable it in windows menu structure (goodluck to find it, i can not find anything in windows menu...) or use restart in stead of shutdown.
Then hit continuously F2 during boot, you will enter the UEFI-BOOT-screen.
Go to boot, and change the order so your usb-stick is first.

Now you can restart, and can succesfully update your UEFI-BOOT.

Now we are going to install ubuntu.
After updating your UEFI-Boot, insert the second USB-stick, and boot again.
Maybe you have to visit again the UEFI-BOOT and change the boot order.
Finally you should be able to startup refind on your USB-stick, you get some very small letters, I need my glasses to read them!
Choose:  Try Ubuntu GNOME
Now you get a fully working ubuntu from live ISO.
Choose install, after choosing language you can login to your WIFI-network, and check extra repositories. Note that WIFI is wqorking out-of-the-box!
Finally, you get a menu with several choices of installation.
install nearby windows, replace windows, and so on, choose the last one:
"something else"
Now you get an inserted version of gparted diskeditor.
Choose the secund ntfs-partition (It is the windows C-partotion) and shrink it with about 20 Gb.
Make a new partition with EXT4 in this empty space of about 17 Gb, choos "/ "as mount point.
Make a secund partition of about 3 Gb, and choose: swap memory.
I bought myself a sd-card of 128 Gb as my home-partition. It costed me 50 €.
So choose the Sd-card, delete the fat32 partition, and make a new one of EXT4, and mountpoint "/home"
now go on with installation.

After install, choose restart.
But you can not boot into ubuntu, because your ubuntu install used Grub, and grub is not working.

But you can boot from life-stick. It wil start Refind, and refind will automatically find your new ubuntu install.
So you tablet is fully working, but for booting you have to insert the usb-life-stick, after boot you can remove it again.

This is not an elegant solution, but we can fix it!


You have to add refind to the ESP windows bootloader.
I figured out a bit complex way in 4 steps. Hold on for 15 minutes.


step 1: mount the GPT-boot-partotion
Once booted into your fresh installed ubuntu,
install gparted:
sudo apt-get install gparted
look at the name and mountpoint of the GPT boot-partition.
Something like:
/dev/mcmlbk1p1

now you know the name, open terminal and type:
sudo mount /dev/mcmlbk1p1 /mnt

Now your GPT-boot-partition is mounted under /mnt

step 2: copy the refind-files to the GPT-boot-partition.
open terminal and type: sudo nautilus
now filebrowser opens with admin rights.
Be carefull what you are doing. Don't delete any windows files.
Go to /mnt/EFI/boot
In this dir, you copy the complete content of the dir: "refind" you copied earlier to the root of you USB-stick.
you must have:
drivers_x64
icons
tools_x64
bootx64.efi
refind.conf-sample (it is not necessary to change it)

If you want, you can delete the grub bootloader. Delete directory: "Ubuntu". It removes a  not-working ubuntu-button in you refind bootscreen

Then it is not working alraedy. You can try:
sudo efibootmgr
It does not see the new boot entry...

Step 3:
restart and boot into windows .
download and install the app: EasyUEFI.
start it, choose the left button.
Choose add entry
search for the REFIND you have just installed.
give it a name: "Refind"

Step 4:

Now restart into the UEFI-bootloader (continuously hit F2).
goto boot, at bottom of page you see: BBS priorities.
You see normally tree entries now:
windows
ubuntu grub
refind
change it so refind is first.
reboot.
and you get a nice graphical refind loginscreen.


Further experiences with ubuntu.

I tried ubuntu unity, kubuntu, ubuntu gnome, mint mate, elementaryos, debian gnome and fedora gnome.

Mint and debian: no touchscreen support, you need the latest linux kernel to have it.
Kubuntu: definitely faster respons, the best working distro on this device.
But no onscreen keyboard at login, no support for rotating screen.
Ubuntu unity: no support for rotating, there is an onscreen keyboard, but it is half hidden under de screen corner, so useless. i don' t like the unity startmenu. And it is less faster responding then kubuntu.

I tested Ubuntu Gnome for a very long time.
Everything is supported: WIFI, bluetooth and touchscreen are working out-of-the-box.
Screen keyboard at login, working after you switch it on in: "settings --> universal acces"

Rotating screen automatically, works ! But in landscape mode, your screen is upside down. You have to turn it around, untill it is normal again, you hold you tablet flat, and you can lock the automatic turning from the taskbar. so, i can live with it for the moment... I figured out it is a bug in iio-sensor-proxy.
If you enter command: sudo monitor-sensor, you can see it is always 180 degree wrong...

I tried the: "dash to dock" gnome extension, but then gnome becomes very slow. And it opens all application two times. Don't use it!


The right-mouse-button menu, by tap-and-hold is working sometimes, only in gnome itself, not in other apps. So you need to hold your physical keyboard standby.
Firefox does not support touch-scrolling , but i found a firefox extension: "Grab and drag" . then it supports touch scrolling. Firefox is slow and not very responsive. But to be honest: I have more then 20 extensions and 400 favourites, and this all is synced between all my devices... Maybe an empty firefox is working well... Chromium is working very much better and faster.

The onscreen keyboard does not show up always: only in gnome itself, not in other applications, but i found a gnome extension: "onscreen keyboard button" that shows an icon on the taskbar to activate the keyboard:
https://extensions.gnome.org/extension/1061/on-screen-keyboard-button
Simply draw the onscreen button from off to on.

The onscreen keyboard is  sometimes covering your workspace. There is a handy gnome extension to solve it: Caribou-resize-workspace:
https://extensions.gnome.org/extension/1024/caribou-resize-workspace/
Simply draw the onscreen button from off to on.

I could succesfully connect my bluetooth speaker, but it did not show up as audio device. There was a simple solution:
Adding read permissions for the gdm user on the pulseaudio bin. Open terminal (CTRL-ALT-T) and type:
sudo setfacl -m u:gdm:r /usr/bin/pulseaudio
And restart the system.

Working speed is extremely slow and un-responsive. It seems to me my Chuwi is suffering under lack of support by the graphical drivers. Touch support is not everywhere on the screen, or is not good all the time. Sometimes it works, sometimes not. 
- double tap a folder in nautilus is only working after 10 times trying.
- the "back" button of firefox in the upper left corner is only responding after 10 hits.
- in: "Gparted" you can not switch from drive in the upper right corner, only with mouse, impossible with touch.
- and many more...

Therefore, I definitely moved away from Ubuntu for Gnome, and installed Kubuntu.


Here is the refind.conf menu entry:
menuentry "Try Kubuntu" {
    loader  /casper/vmlinuz.efi 
    options "file=/cdrom/preseed/ubuntu-gnome.seed boot=casper quiet splash ---"
    initrd    /casper/initrd.lz
}
- the touch problems I mentioned above aren't there in Kubuntu. It's all working fine.
- no onscreen keyboard at login: I set the Chuwi to automatically login, without asking password. Solved...
- the same with suspend mode: disable password asking. Done...
- Bluetooth is working out-of-the-box. Just have to switch your audio device manually.
- I played around with KDE: it is nice: you can change nearly everything. You can brake a lot. But there is always that very handy linux-method to restore a default desktop: open your Dolphin, make hidden files visible. Delete everything in your home-map that are not data-files. And then restart. Now you have your default desktop again.
- no rotating mode: you can set rotation in the settings menu manually, but no auto-rotate support. I will try to make some button in the taskbar by myself. Keep you in touch!


Joostvdw from Belgium
joostvanderwulp@gmail.com


















How to install Android on a Chuwi HI13

I succesfully installed Android X86 7.1rc1 on my Chuwi HI13. After all my experiences with ubuntu, it was quite easey. Here we go: Step...