Returns the charging voltage, in volts, or 0.0 of not charging

def getChargingVoltage(self):
    """Returns the charging voltage, in volts, or 0.0 of not charging"""
    command = '$GG'
    currentAndVoltage = self.sendCommand(command)
    volts = float(currentAndVoltage[2])/1000
    return volts