[Nexus Q General] kornyone:
How to make your Nexus Q awesome with built in Android ICS (using CyanogenMod Trebuchet Launcher per this example).

This is by popular demand on Youtube and other places to demonstrate how I love my Q at the moment, which I obtained from someone who attended IO 2012. I was playing with it to see how capable it is with stock OS and kernel at handling 1080 content. It took me longer to write these instructions than root the device. Much of what is noted here is scattered on the forums and internet, but more than one person told me they didn't see an explanation matching what they saw in the video.

WARNING WARNING WARNING:

If you proceed with these instructions, you will be unlocking your device. If you do not know what "fastboot oem unlock" means, you should research it FIRST and understand you are officially bypassing a disclaimer when running "fastboot oem unlock_accept". If you do not have Jelly Bean and got it off eBay (like me), you will need to hack the actual APK from Google some for core functionality. This document expects advanced understanding of Android, and many assumptions are made. I have tested it locally, but since my Q is already unlocked, I cannot go back to the beginning for complete testing. Proceed at your own caution.

Assumptions:

You have a secksy Nexus Q. Also, if you have an ICS client device without Jelly Bean, or the Google Apps aren't doing enough for you, this document covers these areas. I run with the assumption you do not have a JB client device (I own a Note, Tablet S, and HTC Doubleshot all running ICS builds).

Pre-req:

*SKIP IF RUNNING JELLY BEAN ON CLIENT DEVICE* -- Somehow get the NexusQ client apk. I personally updated my SDK value to 16 in build.prop, and it showed up. Then adb pull the apk, use apktool to decompile it, edit the manifest to use SDK version 15 rather than 16, and use apktool/jarsigner to install it to an ICS client.

*SKIP IF YOU HAVE ENABLED USB DEBUGGING ON NEXUS Q* -- Use the Nexus Q Client app (installed above if in ICS) as owner, enable USB Debugging in Advanced. This (should) magically enable ADB Network mode too (it did for me). Via nmap, I found it listening on port 4321.

fastboot is installed on PC.

adb is installed on PC (and can see the Q).

Sources:

http://droidcloudshare.blogspot.com/2012/07/rooting-and-getting-hid-mouse-to-work.html#more

http://bliny.net/blog/post/How-to-Root-Nexus-Q-(Temporarily).aspx

For kernel (modules): git clone https://android.googlesource.com/kernel/omap. Branch is android-omap-steelhead-3.0-ics-aah.

Steps:

Connect PC to Q via USB.

Run 'adb reboot bootloader'

Run 'fastboot oem unlock'. Then (Within 5 seconds run this to confirm): 'fastboot oem unlock_accept'.

Download this file -- http://www.bliny.net/downloads/nexusq-boot.img. It is a Nexus Q boot.img with ro.secure=0, allowing us to remount /system and root device.

Setup USB Debugging in Nexus Q via client app all over again (may require clearing data from client device Nexus Q app).

Run 'adb reboot bootloader'

Run 'fastboot boot nexusq-boot.img'. Your Nexus Q will now boot up unlocked, allowing:

Run 'adb remount'

Push 'su' and 'Superuser.apk' from a good source. I use nightly CM9 su/Superuser from my HTC Doubleshot. Put su in /system/xbin/, put Superuser in /system/app. chmod the su binary 06755. (There's many pages documenting how this is done).

*OPTIONAL BUT RECOMMENDED* -- adb push busybox binary from a known good source (I also use recent CM9 binary). Busybox will allow you to do things like remount /system and other necessary shell commands after the temporary ro.secure=0 boot up. This might also be a good time to push bash, or whatever linux utilities you'd like to have.

*OPTIONAL BUT RECOMMENDED* -- adb install the default Browser.apk from your good source, such as CM9. No browser is on the Q by default. Chrome will work, so will Firefox. Adobe Flash works (very well) with the CM9 Browser.apk in stock ICS on the Q.

*OPTIONAL* -- Install gapps, just like you would via clockworkmod. Hell CWM maybe out there for all I know. I did it manually, pushing the libs/apks/etc to the right places on /system. Gmail/Play/Youtube all work.

Sideload/Install a Launcher, I choose Trebuchet, also from nightly CM9 Doubleshot. adb install the apk, it will work.

*OPTIONAL* -- Sideload as many apks as you like for testing. I was lazy, and grabbed my apps from my Doubleshot /data/app directory. I then did a simple scripted command to install them all. 'for i in *.apk ; do adb install $i ; done'.

Profit.

How I profit:

From a PC or phone (I personally use ssh on my HTC Doubleshot), adb into the device again (I use adb connect network), and run:

'am start com.cyanogenmod.trebuchet/.Launcher'

This starts Trebuchet, and you now have a Launcher. Not everything works (wallpapers and home button mapping), but you have it up. If using USB keyboard like I am, ALT+TAB gets you around well.

Use a USB Micro USB dongle with USB wifi keyboard/mouse combination. I have two of them (adapters and keyboards), they all work. It makes navigation neato.

Install CIFS module: Grab android-omap-steelhead-3.0-ics-aah branch from https://android.googlesource.com/kernel/omap, and compile the CIFS and md4 modules. Push these to the Q via adb. Install them in /system optionally. Load them via insmod. I scripted it: 'for i in /system/lib/modules/* ; do insmod $i ; done'.

EDIT -- See Page 3 for instructions verbose on making a cifs module and loading it.

I map the IP in /etc/hosts on my PC, so "nexusq" is the network address, making adb connect simply 'adb connect nexusq:4321').

I know there's more. I love this thing. Highlights include Netflix and Youtube HQ, Vplayer playing 1080 mkvs of 17gb in size across CIFS, games working (Angry Birds, etc), Apollo music working, G+ is neat, etc.

And there's much more hacking to do, I did this with limited time.