Untested cleanup of the GCM code into something we can share between TV/Mobile/Wear(?)