Building a Mobile Javascript Powered Audio Player

This is really nicely done, great stuff:-)

But I wonder about the use-case for the battery sensing – under what circumstances would it be appropriate for a web-based player to give the user notifications about their battery state? Isn’t that up to the device?

Same thoughts for light sensing too – would it be appropriate to provide the user with more control over whether they actually want the view to adjust according to light conditions?