site  contact  subhomenews

LineageOS with microG on Nexus 5

March 26, 2018 — BarryK

Wow, on a roll here!

I have been very concerned about the old version of Android (4.4.4) on my Mlais M52 Red Note phone. I bought this from China some years ago. Yes, 2015, here is a blog post:

http://bkhome.org/news/201504/mlais-m52-smartphone.html

And posted a short first-impressions:

http://bkhome.org/news/201504/mlais-m52-first-impressions.html

As with most of these non-Google phones, Android doesn't get updated. There were some updates, then it stopped.

Hence, now looking at Unlegacy-Android and LineagOS, using my Nexus 5 to experiment on. I bought the Nexus 5 new, quite cheap as it is "old technology". It is a nice phone though. That was mid-2016:

http://bkhome.org/news/201606/nexus-5-phone-ordered.html

Firstly tried Unlegacy-Android:

http://bkhome.org/news/201803/nexus-5-updated-to-android-810.html

Then moved on to LineagOS:

http://bkhome.org/news/201803/lineageos-141-installed-on-nexus-5.html

Googling around, made a discovery. LineageOS is also available with microG. Now, microG is very interesting. It provides the Google infrastructure, but without any actual Google apps. Find out more:

https://lineage.microg.org/

And yep, it has the nexus 5 Hammerhead images, oh goody. Downloaded it and went through the same steps as in previous post (for LineageOS). One thing, the zip file was very difficult to download. I used 'wget -c' to continue download when it stopped (ctrl-c to kill wget, then rerun to continue download.

Safe In Cloud app

Now it gets extremely interesting. LineageOS with microG is installed on the Nexus 5, but I don't have, nor want, access to the Google Play Store. There is F-Droid, pre-installed, store for completely free apps only.

One of the most important apps for me is Safe In Cloud, a password manager, well, much more than that, stores anything, such as website logins. Even has its own web browser.

It is a paid-for product, and I have it on my Mlais M52. Android packages are .apk files, and all installed apk files of installed apps are kept in the phone. So, I want to get the Safe In Cloud apk out of the Mlais and install it in the Nexus 5.

Seems like a difficult task, however, I discovered the power of that 'adb' utility. This is how I did it:

good info here:
https://stackoverflow.com/questions/2507960/does-android-keep-the-apk-files-if-so-where

List all .apk files (Mlais connected to computer):
# ./adb shell pm list packages
...
package:com.safeincloud
...
Find where an .apk is:
# ./adb shell pm path com.safeincloud
package:/data/app/com.safeincloud-1.apk
Copy it to computer:
# ./adb pull /data/app/com.safeincloud-1.apk
In the mlais m52 phone, used file-manager to locate where have locally backed up safe-in-cloud. Copied database to computer:
# ./adb pull /storage/sdcard0/SafeInCloud_2018-03-26.db
610 KB/s (29655 bytes in 0.047s)
Now for the Nexus 5:
# ./adb kill-server
plugin nexus 5
# ./adb devices
Make sure Settings --> Security --> Unknown sources
is turned on.
# ./adb install com.safeincloud-1.apk
4198 KB/s (5023776 bytes in 1.168s)
Success
Find out where most likely place to push the database file to:
# ./adb shell "ls /sdcard"
Alarms   DCIM       Download  Music          Pictures  Ringtones 
Android  Documents  Movies    Notifications  Podcasts  TWRP

# ./adb push SafeInCloud_2018-03-26.db /sdcard/
520 KB/s (29655 bytes in 0.055s)
However, Safe In Cloud syncs the database online as well. In my case on Google Drive. I pressed the "SafeInCloud" icon in the Nexus, and choose to sync with Google Drive ...we are about to see if microG works!

Yep, logged into Google Drive, safe In Cloud synced. and now running. Superb!

EDIT 20180328
I realised that one thing I do not want, is for the phone to access my main google account. Therefore, I created a new Google account, wiped all of the 'data' partition on the phone using TWRP, then re-installed Safe-In-Cloud and other apps.
Running Safe-In-Cloud, loaded the local database 'SafeInCloud_2018-03-26.db' (see above), then synced it to Google Drive on my new Google account.


I am very pleased about this. My Nexus is now good for years ahead, very secure and as Google-free as I can get it.

Oh, one extra thing. I have installed Firefox. F-Droid has 'FFUdater' app, which, apart from updating, will also do a first-time install.

Tags: tech

LineageOS 14.1 installed on Nexus 5

March 25, 2018 — BarryK

Yesterday I posted about installing Unlegacy-Android 8.1.0 on my Nexus 5 phone:

http://bkhome.org/news/201803/nexus-5-updated-to-android-810.html

It's a bit buggy. Also, being stock Google Android, it has some limitations. For example, my wi-fi did not appear, it requires "country localization" to be set to Australia, which it seems there is no option to do. However, LineageOS does have that option.

I also tried Unlegacy-Android 7.1.2, same wi-fi problem.

So, downloaded LineageOS for the nexus 5:

https://download.lineageos.org/hammerhead

Note, version 14.1 equates to Android 7.1.2 (Nougat).

My phone has TWRP installed, and USB-Debugging enable, so good to go. With USB cable connected to computer, typed on computer:

# ./adb reboot recovery

The phone rebooted and TWRP started. Saw the "Advanced" button, but when I pressed that and proceeded with a sideload, got an error message:

"Can't install this package on top of incompatible data"

So, pressed the "Back" button, and on the same screen that showed "Advanced" button, there is also "Wipe" button. Press "Wipe", then "Format data".

Then, went back until the "Advanced" button is on the screen, pressed it, then "ADB sideloading" then slide to start it, and over on the computer type:

# ./adb sideload lineage-14.1-20180322-nightly-hammerhead-signed.zip
This works well. Most importantly, wi-fi works. generally, there are more configure options than with stock Google Android.

LineageOS is actually a fork of CyanogenMod, after it fell to pieces:

https://en.wikipedia.org/wiki/LineageOS

First time that I am using it.

Tags: tech

Nexus 5 updated to Android 8.1.0

March 24, 2018 — BarryK

I originally purchased the Nexus 5 to be able to play with MaruOS:

http://bkhome.org/news/201606/nexus-5-phone-ordered.html

The most recent version of MaruOS is 0.4.1. This evening, decided to install a recent vanilla-flavoured Android. This is how it was done...

Download MaruOS image, to get the 'adb' and 'fastboot' binaries:

https://github.com/maruos/maruos/releases

...get them out of the zip file.

Download Android 8.1.0 image for Nexus 5:

https://builds.unlegacy-android.org/aosp-8.1/hammerhead/

Download TWRP for Nexus 5:

https://twrp.me/lg/lgnexus5.html

https://dl.twrp.me/hammerhead/

How to install TWRP:

https://github.com/maruos/maruos/wiki/TWRP

Place 'adb', 'fastboot', 'twrp.img' and the Android zip file in the same folder, open a terminal.

Plug USB cable from computer to phone. On the phone, turn on "USB debugging", as explained here:

https://github.com/maruos/maruos/wiki/USB-Debugging

Type "lsusb" in terminal to verify that computer sees phone.

What I did to install TWRP, in computer terminal:

# ./adb reboot bootloader
# ./fastboot flash recovery twrp.img

On phone, press Up-Volume physical button, until "Recovery" appears on phone screen, then press Power physical button.

On computer, reboot the phone in Recovery mode:

# ./adb reboot recovery

On phone, press "Advanced" button, then "ADB Sideload" button. There are a couple of checkboxes, "Wipe Dalvik cache" and "Wipe cache", tick those. Then there is a slider to start the sideload.

Back on the computer, type:

# ./adb sideload ua_hammerhead-8.1.0-EXPERIMENTAL-20180207-0816.zip

This will install the Android image file from the computer to the phone. Then there will be a button on phone to reboot. TWRP will then display "Swipe to install TWRP app", do it (not sure if necessary). Yay, it worked!

Tags: tech

Cheap Be 16GB USB3 Flash drive is very fast

January 29, 2018 — BarryK

Putting this info out there, for anyone in Australia who is interested. Right now, Bigw is selling some USB Flash drives for half-price.

This includes the Be 16GB USB3 stick, at AU$11:

https://www.bigw.com.au/product/be-16-gb-usb-3-0-w313-16/p/5138/

image

Be is Bigw's internal brand.

I bought one of these yesterday, and this morning used the 'easydd' utility to write an image file to the drive. This utility reports the write speed, and I got 27.8MB/s.

This is phenomenal. Another well-known brand cheap 16GB USB3 Flash drive that I bought a little while ago, gave only about 9MB/s.

Then there's some cheap USB2 drives that are as low as 3 - 5MB/s.

The reason that this is important is that if you are going to run Linux from a USB Flash drive, if the drive gives less than about 7MB/s write speed, you will have very unsatisfactory user experience, very sluggish.

Another important point, that I have reported many times, is that the theoretical read/write speeds of USB2 interfaces is above what these Flash drives are giving, so my Be 16GB USB3 drive will have almost the same speed in a USB2 socket.

Note, this Be drive has an Innostor chip. I have reported on these before. They are very fast, made in Taiwan.

Tags: tech

Totolink A2004NS fast wireless/ethernet router

December 20, 2017 — BarryK

A few days ago, I posted about setting up a local network, using an old-ish router:

http://bkhome.org/news/201712/toto-link-wifiethernet-routerrepeater.html

The Totolink N100R+ has 150mb/s wi-fi and 100mb/s ethernet. OK, but these days we can do a lot better.

I don't recall the price of that N100R+, but I think that it was well under US$30, a few years ago.

I looked around local suppliers, and routers with "ac" class wi-fi and gigabit ethernet are not cheap.

I looked up Totolink online, and found that they sell through Aliexpress. The a2004NS looks great:

https://www.aliexpress.com/item/A2004NS-AC1200-Wireless-Dual-Band-Gigabit-Router-with-VPN-and-USB-function/32539330540.html

image
Fast wi-fi and ethernet. The usb port is only usb2 though.

It cost US$41.15 including delivery to Australia by "Aliexpress Standard Delivery", and they also have an AU (Australian) Power plug. I opted for the "full package", would have saved a couple of dollars without (the full package would be the retail box).

As I am embracing local networking, and getting into using Samba, looking forward to using this router.

Tags: tech

Toto Link wifi/ethernet router/repeater

December 11, 2017 — BarryK

In the Puppy Forum thread where we are testing Quirky Pyro64 0.6, it was reported that Samba is not working. I wasn't much help, as I had to admit that I have never used Samba. A bit embarrassing really, considering what I "do".

Yesterday, decided that the time has finally arrived when I would setup Samba. First though, I need a little local network. I access the Internet via my mobile phone, no land line. So, wifi tethering turned on in my Android phone, no problem connecting to the Internet for any of my PCs.

I did wonder whether the phone itself could be used as a local wifi network. That is, each of the PCs connected to the phone being able to share files between each other. I have read conflicting reports about whether that is possible.

Anyway, I have an old router, have put it back in service. This is a Toto Link N100R+ V2, picture here:

image

This is old technology, 150mb/s wifi, 100mb/s ethernet, but OK for now. My model is no longer sold, the latest is N100RE:

http://www.totolink.net/sub/product/detail.asp?product_num=100079

On my desk there are two PCs, my midi-tower and Mele mini-PC. The latter dual-boots Linux and Windows 10, so I plugged it into "LAN1" on the N100R and powered up, then went to the "http://192.168.0.1" in my browser. Default login is "admin", "admin".

I clicked "Operation Mode" then the "Wireless ISP" radiobutton. Then clicked "Wireless" from left side, then "Basic Settings" and the "ScanAP" button. It detected my phone SSID and chose "WPA2-PSK" and "CCMP", and entered the password. That's it, had Internet access!

On the Win10 mini-PC, was now connected to the Internet via ethernet. In the "Setup", looked around a bit, but basically just enabled "Turn on network discovery" and "Turn on file and printer sharing".

For the midi-tower, plugged an ethernet cable into "LAN2" on the N100R, and fired up Quirky Xerus64. Fiddled around a bit, but essentially just ran 01micko's Samba Simple Management.

Over on the Win10 machine, in the file manager, there is "Network" on the left side. Clicked that, then right-clicked on the right-side and chose "Refresh". Yay, got "PUPPYPC11067", which is my midi-tower. Clicking on that, it asked for username and password, which is "root" and "woofwoof".

Next step is to get it going on Quirky Pyro64...

Tags: tech, quirky

Optus Prepaid Ultimate Plus

November 07, 2017 — BarryK

I have been lamenting how quickly I churn through my AU$40 6GB prepaid data. However, I discovered that I am on an old prepaid plan, "Prepaid Ultimate", whereas Optus is now touting "Prepaid Ultimate Plus". I found that I had to manually upgrade.

Here are the details:

http://www.optus.com.au/shop/mobile/prepaid/plans#datatab1

I probably don't qualify as a "new customer", so don't get that one-time bonus data. But, for AU$50 get 10GB per 28 days. I can manage with that.

Data rollover too, that is nice, for those months when I use less data.

Hey, I wonder what they will call the next one? "Prepaid Ultimate Plus Extreme"?

Tags: tech

Mele PCG35 Apo works well

September 27, 2017 — BarryK

I purchased this mini-PC recently, and I am pleased to report that everything works. I am pleasantly surprised how fast it is -- Windows 10 also is very snappy. I am running Easy Linux, and all interfaces work.

I purchased it for US$179 including international postage, from the Mele store:

https://www.aliexpress.com/store/product/Fanless-Windows-10-Mini-PC-Desktop-MeLE-PCG35-Apo-4GB-32GB-Intel-Apollo-Lake-Celeron-J3455/715968_32822268228.html

it has the Intel J3455 CPU, which is the fastest of the Apollo Lake series, power dissipation rating is 10W. I notice competitors using a slower CPU and yet costing more.

image

The chap at CNX Software has done an unboxing review:

https://www.cnx-software.com/2017/09/18/mele-pcg35-apo-mini-pc-review-part-1-unboxing-teardown-and-m-2-ssd-sata-hdd-installation/

So far, I have written two tutorials on installing Linux, especially Easy Linux, on a PC, using the PCG35 as a case study:

http://bkhome.org/linux/prepare-your-computer-for-booting-linux.html

http://bkhome.org/easy/how-to-install-easy-os-on-your-hard-drive.html

Everything works. I tested wifi, ethernet, SD-card, sound, all OK. Wifi was missing firmware, which I got from here:

https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/iwlwifi-7265D-29.ucode

I haven't tested bluetooth, but I see from dmesg that the firmware loaded ok.

I am running Easy on it right now. There is an error message in /tmp/bootsysinit.log, about a syntax error:

/etc/init.d/start_cpu_freq: line 14: [: too many arguments

Line 14 runs dmidecode, which returns the requested BIOS/UEFI release date, but also appends an error message. Testing in a terminal:

# dmidecode -s "bios-release-date" 2>/dev/null
08/08/2017
Invalid entry length (0). DMI table is broken! Stop.

I have fixed the script to ignore that error message.

It is great to have a silent PC. I usually run my middy-tower, with fans all over it, and it sounds like an aircraft taking off. Right now, I can hear a noise, it is the 3.5 inch 4TB USB drive that is plugged into the Mele -- surprising how noisy that is.

So, very pleased with the Mele. If I have to make any negative comment, it would be my initial disappointment that the fins are plastic! From the advertising blurb and pictures, I expected them to be alloy. There is, however, a large metal-plate heatsink kind of under the fins, which works ok -- not putting the CPU to much work right now, and it is reading 32 degrees C, which is fine. Room air temp is lowish today, probably a tad under 20. It will be interesting to give the CPU chip a heavy workload and observe the temperature rise.

Tags: tech