One of the best things about a Nexus device is the ability to build a fully functional ROM from the AOSP. Usually it is fully functional. This time Motorola have included some software into the shipped ROM that allows for the phone to be able to listen for the OK Google hotword(s) to start a Google search with the screen off. Unfortunately, this software has not made it into the AOSP and thus AOSP ROMs for the Nexus 6 do not have the Always Listening function.
The Nexus 6 has been out for over two months now and up until two days ago there wasn’t a single Nexus 6 ROM with Always Listening working. In fact not has this not been working but the whole “OK Google” from any screen has been sketchy at best. When training your voice for the action it often cannot record your voice and only a wiping of the data from the Google Search app would make it accept your “OK Googles” and then it would only last until the next reboot where you would have to clear the data from Google search yet again and retrain your voice. With there still being a few bugs in the current Google Nexus 6 ROM but have been fixed in AOSP it has been a tradeoff to decide which is more important.
Enter the clever developers of XDA, especially one who goes by the name of Sykopompos. He ran over the factory images from Google and has found that it was a number of things missing from AOSP. There were a couple of apps, TriggerEnroll and TriggerTrainingService, along with a couple of lib files. The final ingredient was a change in the Superuser policy allowing access to the apps which had been prevented by SELinux. Sounds complicated doesn’t it? It doesn’t have to be. By now many ROM developers are incorporating the fixes into their ROMs but if your favourite ROM does not include this fix then all you need to do is flash in recovery the zip file from XDA. I have tested this zip file and can confirm that it does work as advertised.
If you are lucky enough to have yourself a Nexus 6 you can now flash many different AOSP ROMs and enjoy all the functions that the factory ROM comes with. If you want to find out more head over to XDA and read away.