Allow int amp values for charging speeds other than reduced and maximum
See original GitHub issueIs your feature request related to a problem? Please describe.
Hi I’ve a skoda citigo and I would like to select charging speed that I want but I’ve saw that currently it allow only “maximum” and “reduced” string values which map to 254 and 252, it would be nice to allaow also to take directly int values, infact I’ve tested by changing the code and if you pass a value from 5 to 32 (for skoda citigo) to the api it set directly the current to the correspond value
Describe the solution you’d like
Somethig like that:
async def set_current(call):
"""Prepare data and modify for data call."""
try:
current = call.data.get('current')
if current == "maximum":
current = 254
elif current == "reduced":
current = 252
_LOGGER.debug("Try to fetch object for VIN: %s" % call.data.get("vin", ""))
vin = call.data.get("vin")
car = connection.vehicle(vin)
_LOGGER.debug(f"Found car: {car.nickname}")
_LOGGER.debug(f"Set charger current to {call.data.get('current')} ({current})")
await car.set_charger_current(current)
async_dispatcher_send(hass, SIGNAL_STATE_UPDATED)
return
except Exception as error:
_LOGGER.warning(f"Couldn't execute, error: {error}")
async_dispatcher_send(hass, SIGNAL_STATE_UPDATED)
raise Exception(f"Service call failed")
SERVICE_SET_MAX_CURRENT_SCHEMA = vol.Schema(
{
vol.Required("vin"): cv.string,
vol.Required("current"): vol.Any(vol.In(range(5, 33)), vol.In([ "maximum", "reduced"])),
}
)
Issue Analytics
- State:
- Created 2 years ago
- Comments:13 (5 by maintainers)
Top Results From Across the Web
BU-409: Charging Lithium-ion - Battery University
Chargers made for operational readiness, or standby mode, often let the battery voltage drop to 4.00V/cell and recharge to only 4.05V/cell instead of...
Read more >USB Battery Charging Overview | Maxim Integrated
This paper describes how to interface a simple battery charger to a USB power source. This review of USB power bus characteristics includes...
Read more >A Designer's Guide to Lithium (Li-ion) Battery Charging - Digikey
This designer's guide helps you discover how you can safely and rapidly charge lithium (LI-ion) batteries to 20%-70% capacity in about 20-30 ...
Read more >FAQs - Ohme
Max charge will temporarily disable all Charge Schedules and simply charge your car at full power until it is full. It temporarily turns...
Read more >5 Things That Affect Your Charging Speed - EVgo
When you charge your electric vehicle (EV), you might notice that you don't always get the maximum charging speed advertised by either your ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I have tested and verified that integer values from 1 to 16 works for my Superb iV, it also correctly limits the maximum charging current to the correct value. For instance 8 ampere instead of being limited to reduced (6) and maximum (16). This will be integrated in upcoming release 1.0.43-RC3
Available in 1.0.48