I completed my review of PCG02U Ubuntu TV stick a few days ago, and I was quite satisfied with the device, but since Ubuntu 16.04 was released last month, I thought it might be fun to upgrade to the latest version of Ubuntu. I’m go through the complete steps including building a new kernel for HDMI audio, and the drivers for WiFi, but you should be able to install Ubuntu 16.04 for Bay Trail and Cherry Trail processor with the image made by Linuxium and a USB stick.
Star Cloud PCG02U OS Support and Warranty
Before I go through the instructions, you may want to read the conditions on MeLE’s Aliexpress PCG02U page.
They meant Ubuntu 14.04 instead of 14.0.4, but the important part is that if something goes wrong trying alternative OS, you may lose your warranty.
Upgrade Ubuntu 14.04 to Ubuntu 16.04
Upgrading from one LTS version to the next should be easy using the update manager…
1 2 3 |
sudo apt update sudo apt dist-upgrade sudo update-manager -d |
… or doing it through the terminal entirely:
1 2 3 |
sudo apt update sudo apt dist-upgrade sudo do-release-update -d |
However, it did not work for me, as it quickly ended with the message:
1 |
The required dependency 'apt (>= 1.0.1ubuntu2.13)' is not installed. |
I noticed that PCG02U was still stuck on Ubuntu 14.04.3 LTS, despite running dist-upgrade:
1 2 |
cat /etc/issue Ubuntu 14.04.3 LTS \n \l |
After trying several solutions, I eventually changed the Ubuntu mirror, and the steps above completed successfully with Ubuntu 16.04 running.

At least two little problems though: I lost HDMI audio with only Dummy Output available, and while Ethernet was still working after the update, WiFi support was gone… But if you don’t need either you’re good to go.
Enabling HDMI audio in PCG02U
Luckily we already have the instructions to enable HDMI audio for Bay Trail and Cherry Trail processors, all we need is a Linux 4.5 kernel and patch it. I’ll do everything inside PCG02U, and I have not used a separate build machine, which would likely be faster. Tip: you’ll need gcc 4.9 or greater. I used the instruction here and there.
First let’s build the dependencies required to build the kernel in Ubuntu.
1 |
sudo apt-get build-dep linux-image-$(uname -r) |
Now let’s get the patches in a working directory
1 2 3 4 5 |
mkdir linux wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.5.1-wily/0001-base-packaging.patch wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.5.1-wily/0002-debian-changelog.patch wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.5.1-wily/0003-configs-based-on-Ubuntu-4.4.0-19.35.patch wget http://pastebin.com/raw/kZyiZMR5 -O hdmi_audio.patch |
as well as the Linux 4.5.1 kernel patched for Ubuntu and the Intel Atom HDMI audio support:
1 2 3 4 5 6 7 |
git clone git://git.launchpad.net/~ubuntu-kernel-test/ubuntu/+source/linux/+git/mainline-crack v4.5.1 cd v4.5.1 git checkout v4.5.1 patch -p1 < ../0001-base-packaging.patch patch -p1 < ../0002-debian-changelog.patch patch -p1 < ../0003-configs-based-on-Ubuntu-4.4.0-19.35.patch patch -p1 < ../hdmi_audio.patch |
Now we can configure the build:
1 2 3 4 5 |
chmod a+x debian/scripts/* chmod a+x debian/scripts/misc/* chmod a+x debian/rules fakeroot debian/rules clean fakeroot debian/rules editconfigs |
This will ask which config files to configure for AMD64, i386, ARM and so on. We only need to edit the first one (AMD64). Once you are in the config menu, use menuconfig search function to locate SUPPORT_HDMI option and enable it. Exit and save.
Before starting the build add something like “+some_string” to the end of the first version number in the debian.master/changelog> file. I added +hdmi_audio string:
1 |
linux (4.5.1-040501.201604121331+hdmi_audio) unstable; urgency=low |
You can now start the build with:
1 |
fakeroot debian/rules binary-headers binary-generic |
However, the build did not complete for me, with the error:
1 2 3 4 5 6 7 8 9 10 11 |
# # SPL/ZFS wants a fully built kernel before you can configure and build. # It seems to be impossible to tease out the application configuration # from the modules, but at least one can build just the modules. # install -d /home/jaufranc/linux/v4.5.1/debian/build/build-generic/spl rsync -a --exclude=dkms.conf --delete spl/ /home/jaufranc/linux/v4.5.1/debian/build/build-generic/spl/ rsync: change_dir "/home/jaufranc/linux/v4.5.1//spl" failed: No such file or directory (2) rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1183) [sender=3.1.1] debian/rules.d/2-binary-arch.mk:70: recipe for target '/home/jaufranc/linux/v4.5.1/debian/stamps/stamp-build-generic' failed make: *** [/home/jaufranc/linux/v4.5.1/debian/stamps/stamp-build-generic] Error 23 |
I followed the instructions on askubuntu, and disabled set do_zfs = false
in debian.master/rules.d/amd64.mk, and completed the build with the same command line. It took around 2 to 3 to complete the build on PCG02U, and I had a bunch of deb packages…
1 2 3 4 5 6 7 8 9 10 |
cd.. ls *.deb linux-cloud-tools-4.5.1-040501_4.5.1-040501.201604121331_amd64.deb linux-cloud-tools-4.5.1-040501-generic_4.5.1-040501.201604121331_amd64.deb linux-headers-4.5.1-040501_4.5.1-040501.201604121331_all.deb linux-headers-4.5.1-040501-generic_4.5.1-040501.201604121331_amd64.deb linux-image-4.5.1-040501-generic_4.5.1-040501.201604121331_amd64.deb linux-image-extra-4.5.1-040501-generic_4.5.1-040501.201604121331_amd64.deb linux-tools-4.5.1-040501_4.5.1-040501.201604121331_amd64.deb linux-tools-4.5.1-040501-generic_4.5.1-040501.201604121331_amd64.deb |
.. and I installed the headers and image:
1 2 |
sudo dpkg -i linux-headers-*.deb sudo dpkg -i linux-image-*.deb |
Rebooted the system, which booted successfully, and I could confirm HDMI audio was back. Yes!

But still no WiFi… and space was running now, so I did some cleaning which gave me a few gigabytes to play with:
1 2 |
sudo apt autoremove sudo apt clean |
Building Realtek RTL8723BS WiFi Driver in Ubuntu/Linux
Star Cloud PCG02U uses a WiFi and Bluetooth module with the common Realtek RTL8723BS chip, but the driver is not currently in mainline, so it needs to be compiled separately. That part is straightforward, and only take 2 minutes or less:
1 2 3 4 5 |
git clone https://github.com/hadess/rtl8723bs cd rtl8723bs make -j4 sudo make install sudo modprobe r8723bs |
That’s all and now the Wireless network is enabled:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
sudo lshw -C network *-network:0 description: Ethernet interface physical id: 1 logical name: eth0 serial: 00:ce:39:ca:20:36 size: 100Mbit/s capacity: 100Mbit/s capabilities: ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=asix driverversion=22-Dec-2011 duplex=full firmware=ASIX AX88772B USB 2.0 Ethernet ip=192.168.0.113 link=yes multicast=yes port=MII speed=100Mbit/s *-network:1 description: Wireless interface physical id: 2 logical name: wlan0 serial: cc:79:cf:71:8a:bb capabilities: ethernet physical wireless configuration: broadcast=yes driver=rtl8723bs multicast=yes wireless=IEEE 802.11bgn |
I had no problems connecting to my wireless router, and the module is automatically loaded at boot time. So now we have the same level of support as in Ubuntu 14.04 with HDMI audio and WiFi.
Realtek RTL8732BS Bluetooth in Linux
However, the hardware also supports Bluetooth, so it would be nice to have this enabled too, and again RTL8723BS Linux Bluetooth driver is available thanks to one independent developer (lwfinger).
In theory, it’s pretty easy:
1 2 3 4 5 6 |
git clone https://github.com/lwfinger/rtl8723bs_bt cd rtl8723bs_bt/ make sudo make install sudo ~/rtl8723bs_bt/start_bt.sh Using device /dev/ttyS4 for Bluetooth |
But this did not work for me, despite Bluetooth apparently being located on /dev/ttyS4:
1 2 3 4 5 6 |
dmesg | grep tty [ 0.000000] console [tty0] enabled [ 1.831625] 00:02: ttyS0 at I/O 0x3f8 (irq = 4, base_baud = 115200) is a 16550A [ 5.440955] systemd[1]: Created slice system-getty.slice. [ 6.004920] 80860F0A:00: ttyS4 at MMIO 0x90941000 (irq = 39, base_baud = 2764800) is a 16550A [ 6.020676] 80860F0A:01: ttyS5 at MMIO 0x90947000 (irq = 40, base_baud = 2764800) is a 16550A |
But the log would show a connection timeout:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
cat hciattach.txt Realtek Bluetooth init uart with init speed:115200, final_speed:115200, type:HCI UART H5 Realtek Bluetooth :Realtek hciattach version 2.5 Realtek Bluetooth :3-wire sync pattern resend : 1, len: 8 Realtek Bluetooth :3-wire sync pattern resend : 2, len: 8 Realtek Bluetooth :3-wire sync pattern resend : 3, len: 8 .... Realtek Bluetooth :3-wire sync pattern resend : 38, len: 8 Realtek Bluetooth :3-wire sync pattern resend : 39, len: 8 Realtek Bluetooth :3-wire sync pattern resend : 40, len: 8 Realtek Bluetooth ERROR: H5 sync timed out |
Sadly, I haven’t been able to find a solution in a reasonable amount of time, and changing the baudrate from 115200 in the script to 2764800 (as shown in dmesg) does not help.
Of course everything would be so much easier if HDMI audio Cherry Trial and Bay Trial and RTL8723BS drivers would be in mainline linux, as all you would have to do would be to install Mainline linux in Ubuntu, and everything would just work. This does require some work however, but if you are motivated, lwfinger is ready to submit the RTL8723BS WiFi code to mainline if somebody takes care of all the errors and warnings generated by checkpatch.pl.

Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011.
Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress