Control of energy storage means for electrical energy