added readout for total charge along with an alert to display readout in a popup