charging added and tested