Started battery logging code for DM