Adding Luxury Charging Features To An Entry-Level EV

The Nissan Leaf is the best-selling electric car of all time so far, thanks largely to it being one of the first mass produced all-electric EVs. While getting into the market early was great for Nissan, they haven’t made a lot of upgrades that other EV manufacturers have made and are starting to lose customers as a result. One of those upgrades is charge limiting, which allows different charging rates to be set from within the car. With some CAN bus tinkering, though, this feature can be added to the Leaf.

Limiting the charging rate is useful when charging at unfamiliar or old power outlets which might not handle the default charge rate. In Europe, which has a 240V electrical distribution system, Leafs will draw around 3 kW from a wall outlet which is quite a bit of power. If the outlet looks like it won’t support that much power flow, it’s handy (and more safe) to be able to reduce that charge rate even if it might take longer to fully charge the vehicle. [Daniel Öster]’s modification requires the user to set the charge rate by manipulating the climate control, since the Leaf doesn’t have a comprehensive user interface.

The core of this project is performed over the CAN bus, which is a common communications scheme that is often used in vehicles and is well-documented and easy to take advantage of. Luckily, [Daniel] has made the code available on his GitHub page, so if you’re thinking about trading in a Leaf for something else because of its lack of features it may be time to reconsider.

Photo: Chuck Allen (chucka_nc) / CC BY-SA

23 thoughts on “Adding Luxury Charging Features To An Entry-Level EV

  1. How long before someone changes a battery to a 10kw charging rate or makes it falsely report it’s charge level and cars start going up in flames like hover boards.
    When electric and self driving cars can get wireless updates, it’ll only be a matter of time. Doors lock, car heads for a hedge at 80mph. Cars steal themselves in the middle of the night. Exploding batteries are just another vulnerability to add to the list.

    1. If you can load malicious over-the-air updates, it doesn’t need to be an electric car to break stuff; the possibilities are endless. You could, for example, just turn on the fuel pump and injectors, flooding the cylinders, making fuel come out the intake and exhaust ports. If you keep one cylinder dry, you can use that one to ignite it, with a well-timed ignition just before the inlet or exhaust valves open.

      Or you could use the ABS system to completely disable the brakes, override the electronic throttle, and you can probably lock the steering column.

      Crappy software and over-the-air updates on cars are scary.

      https://xkcd.com/2030/

      1. using the ABS to disable brakes was actually demonstrated a year or so ago on a Jeep. By attacking the infotainment…

        also, forget locking the steering column, if you have parking assist – you can turn the steering wheel.
        So the guys demonstrated the ability to: yank the steering, disable the brakes AND hold you in the seat by activating the seat belt tensioners…

    1. Its certainly been a problem for some people trying to evacuate areas that only have one vehicle. I can say this though. In the area of northern California i am in. Its rare for people to have just one vehicle. Between weather and utility needs. Large percentages of people own both a hybrid and a diesel 4×4 truck. partly cause there is no way you are going to move soil and crops effectively with anything else.

      Thought I do get a special laugh at all the people who hate on me for owning a diesel truck. That have found themselves with no range when they need it the most. Who are now rapidly changing their stance.

      1. A car with not enough range to cross a highway between two cities should not even be sold as “highway capable”. In other words, it should be speed limited and sold as a “medium speed vehicle”.

        1. AKA the A is right, you also have to ask just how far you are talking about. In the UK for example you can easily bump into cities and towns multiple times in even an early EV’s very limited range, where many places in the world are so empty nothing crosses it with just its stock fuel tank of burning carbon…

          Modern EV’s driven sensibly have range rather comparable to most fuel tanks, much more tedious to refill of course, but range to cross between settled area’s isn’t much more of a problem for the new EV’s than a petrol/diesel assuming any stops have a charging capacity and you don’t mind the longer wait- and that last bit is probably the crux in most places globally – its relatively easy to find a tank full of hydrocarbons might be a little stale but it will burn. Finding somewhere with enough spare electric to charge the EV in the middle of nowhere is not so likely.

          1. In a winter test here, the range of a Nissan Leaf pretty much halved from the advertised, and in more severe weather with the heaters on it would run out after 40 miles with the original 24 kWh battery.

            That’s the problem. If you aren’t absolutely positively sure that you’re going to get a proper recharge at the end, you couldn’t trust it to go more than 20 miles out and back, and that was when the batteries were new. Now they aren’t, so you’re going even less distance.

      2. I have a diesel truck and a Prius, and if I can fit the load in the Prius I avoid using the truck.. You get some strange looks at Tractor Supply loading a bale of hay, a bale of alfalfa, and a roll of fencing in a Prius….

  2. it’s amazing they didn’t put this function in the car in the first place…But we often find that ie manufacturers don’t spend money (negligible amounts!) on software, that wouldn’t change the production cost at all, which would greatly improve the use of hardware..

    1. On a 2009 Prius I was surprised to find there’s no power seats and no automatic headlamps, and no option was available for them. The headlamps can be left on all the time and they’ll shut off when the car is turned off and the door opened, but on my olde 1997 Taurus they operate by a light sensor so they’re only on when it’s dark enough outside. The 1986 Cadillac Cimarron I had, had automatic headlamps.

      So I guess Toyota was shaving cost everywhere they could, while also spending more on some things people wouldn’t notice.

      Oh, and no rear disc brakes on the 2nd gen Prius for the USA! Why! Canada had them, but weren’t allowed the HID headlamps.

      1. Toyota is adhering to international laws where many countries require you to run headlights at daytime, so that they have to come on when the car starts. It’s a common feature in Toyotas – the lights are always on when the engine is running by default, and you have to switch them off.

        They do save money by making it the default in every country.

    2. They did. It’s called J1772.

      If they had brought back charge termination level (which Nissan apparently stupidly REMOVED from a vehicle already notorious for battery degradataion due to poor thermal management), it would make sense.

      But their issue was that they didn’t want to pull too much power from the outlet, using fugly CANbus hacks instead of doing it the way you’re supposed to do it which is to have the EVSE report appropriate current limits to the vehicle via J1772 PWM.

  3. This is great. It is unfortunate that manufactures have so much technology available in the car and battery pack but choose to limit how it is used or force you to purchase software or hardware to unlock the features. Tesla is an awesome example (software unlocks) I cant wait to see some software dongle to unlock the supercharging station for tesla’s that may have been blacklisted. It is an awesome amount of power and I understand their liability but not allowing recertification of batteries and cars to make use of the fast charging is unfortunate. Price point of the nissan’s is pretty compelling but they are very limited in miles. Being in a northeast state, I doubt I could make it to work and back in the winter without charging all day…

    1. People already do unlock their blacklisted Teslas to do high speed charging at non-Tesla charging sites with compatible plugs, or an adapter to the other charger.

      What’s especially nasty is that Tesla blacklisted the Model S cars they’d charged big bucks to recertify and ended their inspection and recertification program. I’d say that’s grounds for a lawsuit. Tesla certified those cars as safe to use their Supercharging stations. They shouldn’t be able to renege on that, not without a full refund of the costs for the inspection and recertification. The only acceptable outcome of such a suit should be un-blacklisting or full refund, no crap like discounts on another Tesla. Provide what the customer paid for or give the money back.

    2. If I’m not mistaken, Tesla cars communicate through the cellular network to authenticate to the supercharger network. I suspect trying to hack the superchargers is going to involve trying to spoof the identity of another Tesla, and given that they all have GPS it wouldn’t take Tesla long to figure it out and cut that car off too.

  4. It’s really the EVSE’s job to tell the car how much current it can draw. OpenEVSE in particular lets you set the current limit in it’s menu system.

    What drives me bonkers is Chevrolet EVs and hybrids don’t pay any attention to the EVSE pilot when fed with 120 volts and default to 8 amps – less than a kilowatt (with an option to use 12A, that you have to set *every time*). Never mind that it *is* possible that someone could set up and install a perfectly safe L1 EVSE on a 30A breaker (2.8 kW after derating) if their house only had single phase instead of split phase service.

    1. Yeah. Bolts limiting to 12A on 120v no matter what really pisses me off.

      I could see limiting to 16A because in the J1772 standard, anything greater at 120 is technically “undefined” even if the PWM duty-cycle-to-amperage map is the exact same below 16A, but 12A is even worse.

      I wish I could charge at 24A from a TT-30 when camping like I should be able to. Sites with a TT-30 tend to book up much more slowly than ones with 240v 14-50 outlets.

      If this person had used CAN hacking to stop charging above a certain BSOC percentage (which apparently was a feature that Nissan REMOVED, which is dumb for a vehicle notorious for battery degradation problems) it would have made sense, but here they just used some unreliable CAN hacks to compensate for using a bad/poorly designed EVSE.

      Also, the assertion that CAN is well documented and easy to work with is BS. The underlying PHY protocol is, indeed, well documented, but the message formats used for anything but OBD diagnostics (which isn’t able to do things like this) are universally proprietary and undocumented, requiring significant amounts of reverse engineering work and, if you actually want to alter vehicle behavior, frequently having to MITM the bus because things are designed to be resistant to message injection. (For example, many CAN messages going over a Bolt’s buses have rolling sequence numbers to prevent injection without MITMing the impersonated device off of the bus.)

Leave a Reply to Foldi-OneCancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.