efficient music players remain elusive
First, we’ll try Spotify. Experimental results indicate this reduces battery life by as much as one hour, which isn’t great, and exceeds what one might expect even accounting for some occasional wifi activity. I think it’s well known that the Spotify player is kinda shit, but I wanted to see it for myself.
Next, we’ll try Groove, which is this week’s name for the built in media player. I figure this has a chance of working, since it’s developed by the same company that makes the hardware and operating system. The same company that writes blog posts bragging about battery life and even includes popup tips that warn you about the detrimental battery consequences of using the wrong browser. So there’s a chance they similarly care about the efficiency of their music player, though nothing is certain.
And indeed, not much luck here. After a few minutes of playing, Groove does something that causes the CPU speed to jump up to 3.5GHz and stay there, despite being mostly idle. Pausing playback sends the clockspeed back down to sub GHz speeds, and they stay low for a while after resuming, but inevitably pop back up within minutes. And there’s definitely an effect on power consumption. I first noticed something was amiss when the back of the device was considerably warmer than usual. Not hot, but warm enough you know something’s up. XTU confirms the CPU is consuming around 5W in this state, as opposed to 1W (not sure what the measurement floor is) when playing music at lower clocks. I’m not sure what’s happening. Some high frequency megamedia timer, perhaps? Regardless, efficient it is not. I can literally feel the wasted energy in my hand.
Time for an old standby? What’s Winamp up to these days? Oh, great, looks like more internet radio nonsense. And the website has the modern flat square design I’ve recognized as a harbinger of impending disaster. Sigh.
Let’s really dial things back. How about mpg123? MP3s may be dead, but mpg123 is still alive. “Not so much kicking, but humming along nicely.” as they say. After downloading hundreds upon hundreds of kilobytes of zip file, fire up a shell, run mpg123, and wowzers. It plays MP3s smoothly and efficiently. A remarkable feat of engineering, especially considering it’s all written in plain old C without leveraging the synergies of dozens of frameworks. One wonders how they managed.
On the surface (har har, puntastic), this doesn’t seem like such a difficult problem. I have a file which is a bitstream in a particular format. I want to read that file, apply some algorithmic operations to those bits, and then write the resulting bitstream out. For anyone not named George Sonos (har har, double pun), a $2000 computer makes for an expensive dedicated music player, and so we might logically conclude that the computer will be used to perform other tasks as well. In that context, I’d like for this bitstream transformation to be as efficient as possible, so as to minimize its interference with those other tasks.
There’s a certain amount of babble and chatter about certifying software. Like UL listing. Mostly this is brought up in the context of providing security assurances, which I think is probably a waste of time, because it’s attempting to measure a great many immeasurable attributes. Yeah, sure, there’s some checklists one can make, but to what extent will they improve the end product?
On the other hand, efficiency certification seems like a great idea. Readily quantifiable and easily measured. We can set some baselines for various software categories, and then you get a gold star for meeting them. A music player should be able to play a song using X CPU cycles. A browser should be able to render a static web page using X million system calls. An editor should be able to open a text file using only X GB RAM.
I think it’s obvious that consumers care a great deal about efficiency and battery life. Urban myths and hocus pocus tricks to squeeze out more runtime are everywhere. Mostly ineffective, but that doesn’t stop people from seeking out trashy battery extender apps and youtube videos and good grief, so much garbage out there. What if software actually came with stickers indicating how much power it used, like household appliances do? “Using this music player will reduce battery life by 10% and, over the course of one year, degrade battery capacity.” If users had to click through a warning like that, I think we’d see some rapid improvements in efficiency.