The Midlife Geek

Ramblings of a middle aged engineer, runner and open source enthusiast

Tag: Android

Remove Facebook’s app from Galaxy S7

I recently gave up Facebook and wanted to remove Facebook’s app. For me Facebook has become too much of a trade for privacy. Given that change in trust, it annoys me not having the option to remove the app on Samsung.

Enable Android debugging and install Android Debug Bridge (ADB) tools:

1
sudo apt-get install android-tools-adb

ADB lets you issue commands to the device’s shell, such as pm the package manager. You need to find the app you want to remove:

1
2
pm list packages | grep [packagename]
pm uninstall -k --user 0 [packagename]
Remove Facebook

Success!

Flashing Nexus 9 factory image

This tablet was super fast when I got it but now it lags and drives me nuts. I’d seen someone post on Reddit that flashing the factory image helped so I gave it a go.

Factory images are available here along with good, clear instructions. One caveat, Arch needs super user for fastboot otherwise you get “< Waiting for device >”. For the same reason run flash-all.sh with sudo too.

As to whether or not it helped, it is hard to say but I feel it has. How do you measure something that is entirely subjective?

Edit. Its been a few days now and it is faster. Much faster and without lag. I’m unclear why though. I’m not completely familiar with Android’s architecture but wonder if it’s a combination of multiple updates being applied (this was I think Android 5.0 when bought) and accumulated futz.

What a weight off my shoulders!

 

I haven’t posted in a long time. I’ve been busy with the final part of my Open University studies – TM470 (The Computing and IT Project). But I submitted it in the early hours of this morning!

My project was an Android application, the development of which I have enjoyed. Over the next few months I intend to develop another application and post here on the process.

Secure Android Development, project preparation, a cold and a new year

It’s been a mixed start to the new year. Watching what I eat for the rest of January, damn you Christmas. Back at work after three weeks off, achieved nothing and left by eleven. My ego got the better of me and I went for a run despite having a cold, so am now suffering. Need to shift it with the first cross country league race on Wednesday. I can’t help wondering why generic medicines are so much cheaper than brand names.

Finally got around to ordering a replacement Acer V3-112P screen. Replacement was straight forward. Like most avionics technicians, I breathed a sigh of relief when the LED panel lit up proving the fault. The old girl is now sitting running a million updates courtesy of Microsoft.

While many Linux advocates eschew Microsoft, I prefer Office (Home Use Program). Like current, I take the path of least resistance and I use Word and Excel so often I know them inside out. Linux is an outstanding development platform, I’m using it for TM470.

TM470 project preparation continues, reviewing both TM353 and TM354. FutureLearn is a fantastic resource with a course on Secure Android Development. Delivered by the University of Southampton, it started last week. I haven’t decided the tool chain yet, particularly versioning. I have used SVN and Bazaar, which I prefer as it integrates well with Launch Pad. I won’t be using LP though so should investigate Mercurial and Git.

Read Original Sin too – best Marvel I’ve read in ages. Like Murder She Wrote in space. A real page turner, I read it in one sitting.

Something that didn’t grip me was the Assassin’s Creed movie. It starts off quite well, with a similar story to the games. It suffers the same problem as earlier games though – the present interrupts more interesting stories in the past. What I don’t get though is why option a game as a property then try not to appeal to that market?

What I haven’t made time for though is the Nintendo Classic Mini. I played a little Ghosts ‘n Goblins – damn I forgot how hard games were then. I always thought as a kid that I’d somehow be better at them as an adult but I guess I didn’t factor in reactions.

[Insert project title here]

An Android fitness tracker application. Feedback from the preparation forum was positive, there is enough scope to expand or contract the project as needed. Importantly, it is “substantially within the sphere of information technology”.

Taking approaches from IT Systems Planning for Success (TM353) and an Agile approach from Software Engineering (TM354) meets the requirements. There is a substantial part of the application that needs synchronise with a server, utilising another level 3 module Developing Concurrent Distributed Systems (M362).

What I haven’t decided is the title!

Install Android Studio on Ubuntu

Android Studio is a great development environment and is available on Ubuntu. I’m using Ubuntu Mate 16.10 “Yakkety Yak”.
 
First install a Java Development Kit (JDK). OpenJDK is pre-installed or you can use Oracle Java 8 (there is a great guide here). I don’t wish to argue over your choice – I need to use the latter (my tutor does). Download Android Studio here. – I extracted it to /opt; ran the installer; and used my home folder for the SDK. If you are using 64 bit, you need the 32 bit GNU standard C++ library:
sudo apt install lib32stdc++6

For Arch you need to enable “multilib” repository:

<code><span class="pln">sudo pacman </span><span class="pun">-</span><span class="typ">Syu</span> <span class="pun">&amp;&amp;</span><span class="pln"> sudo pacman </span><span class="pun">-</span><span class="pln">S multilib</span><span class="pun">/</span><span class="pln">lib32</span><span class="pun">-</span><span class="pln">libstdc</span><span class="pun">++</span><span class="lit">5</span><span class="pln"> multilib</span><span class="pun">/</span><span class="pln">lib32</span><span class="pun">-</span><span class="pln">zlib</span></code>

Virtualisation support is interesting. I read two tutorial and Google’s guide. The former makes reference to command line options not in version 2.2.2. These posts suggest this is a bug, but it may now be default behaviour. First enable that virtualisation in BIOS (check if enabled using “kvm-ok”).

sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils
sudo adduser dougie kvm
sudo adduser dougie libvirtd

This results in an error.
screenshot-at-2016-11-25-21-16-19

Using the system version of libstdc++.so.6 works. Add the following to /etc/environment:

ANDROID_EMULATOR_USE_SYSTEM_LIBS=1

It seems snappy but with no feedback I’m unsure if accelerated.

So I now have a development environment set up for my project. The next hurdle is to choose a title. So far it is a: development project; distributed application; and uses Android.

Progress

Well I haven’t posted in ages but I’m down to a single TMA and two exams before I start the computing and IT project (TM470).

I’ve got what I think is a sound idea that builds on TT284, M362, TM353 and TM354 so fingers crossed. Its an integrated system developing an Android app, web app and a hardware solution that utilises near field communication (NFC) and is built on a Raspberry Pi B+.

So far my main issue has been getting back on top of Python. I haven’t used it since M269.

Install Android 5.0 (Lollipop) on Nexus 7

Update: Lollipop is now available OTA on Nexus 7!

Why? Why not? This will remove any custom boot loader and wipe the tablet. I did this from Windows 7 – in Linux its pretty much the same but doesn’t require the Google USB driver and you can obviously extract the image using tar from the command line.

Download the Android SDK, run the Android SDK Manager and install Google USB Driver (from Extras) and Android SDK Platform-tools (from Tools). The former are installed to AppData\Local\Android\android-sdk\extras\google\usb_driver by default. If you’re unfamiliar with USB drivers Google have a guide.

Your device’s boot loader needs to be unlocked then boot in to the boot loader (hold down power and volume down button when turning on).

Download the image for your device (I have a 2012 WiFi – codename “nakasi”). Uncompress the tgz file and then the resulting tar file – 7-zip will do the trick on Windows.

Add the location of the Android SDK platform tools to your path will speed up the command line part. Open a command prompt and go to the folder you extracted the image to.

Check that the device is recognised by typing fastboot devices – if there is an output then all is well. Now run flash-all.bat – this takes a while (159.617 seconds on my Samsung RV511), when it is complete it will reboot the tablet. Rebooting took around five minutes on the first boot.

Thoughts on Web Technologies (TT284)

TT284 Web Technologies is a level two Open University module now in its second year of presentation and compulsory on the solutions development pathway of BSc (Hons) Computing and IT (B62). From the module description:

This course will give you an insight into architectures, protocols, standards, languages, tools and techniques; an understanding of approaches to more dynamic and mobile content; and demonstrate how you can analyse requirements, plan, design, implement and test a range of web applications.

Continue reading

© 2018 The Midlife Geek

Theme by Anders NorenUp ↑