Commented the confusing Battery class
some refactoring