Page 9 of 13

Re: Tesla Charger alternative firmware

Posted: Thu Mar 10, 2022 7:40 pm
by johu
I split off the ESP discussion: viewtopic.php?f=5&t=2299

Re: Tesla Charger alternative firmware

Posted: Thu Mar 10, 2022 11:53 pm
by Roadstercycle
johu wrote: Thu Mar 10, 2022 5:31 pmyes
Johu, That was it. Just bad connection on the D1 at the header. All's good in the hood.

Re: Tesla Charger alternative firmware

Posted: Tue Mar 15, 2022 11:03 am
by et0
HI all, I'm facing a Gen 2 charger which has a V5aB3 board fitted, and after reading this thread and the wiki I have a couple of questions if someone can help:

1) I want to have single phase 32A charging at home, and 3 phase 16A charging at public chargers - this is the norm in the UK. On previous builds I have used the V3 board and added an external relay and couple of lines of code to manage this (discussed in other threads). How can I do this with the V5 setup?

2) I will be using a commercial BMS to manage the charging, including the J1772 charging signals. So I need the charger to function as a "dumb charger" and not look for EVSE pilot signal feedback to operate - but only respond to CAN messages. Is that feasible?

Thank you

Re: Tesla Charger alternative firmware

Posted: Tue Mar 15, 2022 2:03 pm
by johu
1) You could just wire your single phase to 2 phases of your Type-2 outlet
2) Pilot signal can be ignored and instead a current setpoint can be received via CAN

Re: Tesla Charger alternative firmware

Posted: Tue Mar 15, 2022 10:57 pm
by et0
johu wrote: Tue Mar 15, 2022 2:03 pm 1) You could just wire your single phase to 2 phases of your Type-2 outlet
2) Pilot signal can be ignored and instead a current setpoint can be received via CAN
Hey Johu,

1) But it needs to operate with any random chargepoint, some 3-phase, some single-phase. We can't control how they are wired.
Here's an example of what I mean: viewtopic.php?f=10&t=761#p10912

2) Great!

Thanks

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 6:40 am
by EV_Builder
How is the difference communicated to the vehicle?
Cable limit?

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 8:10 am
by johu
That's what I meant by connecting L1 and L2 in the OUTLET, i.e. the cable in your garage. Not in the car! Not sure about your BMS but the Tesla charger software always interprets CP/PP current limit as per phase. So you'd still communicate a 16A limit.

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 9:43 am
by et0
johu wrote: Wed Mar 16, 2022 8:10 am That's what I meant by connecting L1 and L2 in the OUTLET, i.e. the cable in your garage. Not in the car! Not sure about your BMS but the Tesla charger software always interprets CP/PP current limit as per phase. So you'd still communicate a 16A limit.
Johannes, I understand what you mean and I agree, technically. But I want this car to charge at any 1-ph chargepoint found in the wild as well, not just one dedicated one with non-standard wiring. My Tesla can do it, my own conversion with a Gen 2 charger can do it..

Anyway, aren’t there risks with that workaround - if you charge with a 16A rated cable and the car is putting 32A through the neutral conductor, bad things could happen - no?

I’m just suggesting it as a feature, because it would be nice to use your well developed and supported software, and this is the only barrier.

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 6:19 pm
by johu
oh, now I get it!
Alright, that of course requires a relay. So it breaks the connection to L2 and makes the connection to L1 on the second module. One way to find out would be a 32A CP current limit but only AC voltage visible on the first charger module. I think there's an open collector output left.

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 6:19 pm
by EV_Builder
EV_Builder wrote: Wed Mar 16, 2022 6:40 am How is the difference communicated to the vehicle?
Cable limit?
@et0;
What about starting here? And educating all of us how the car can know with the current FW, or with change, how many phases there are connected to the socket it pulls from? as far as i know only amp ratings are communicated?

Also if the CanBus option on the charger communicates line voltages and the cable limit.
External hardware could decide to disconnect from L2 and L3 and connect those to L1 (in the car).
Then you have what you like correct? Maybe a reset to the charger should be needed for certain modules...

But that would be always after probing if L2 and L3 don't have tension....

The NEUTRAL wire in the car and house should always be upto the 11Kw amps that doesn't change on phases (at least if you want to use the maximum).

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 6:21 pm
by EV_Builder
johu wrote: Wed Mar 16, 2022 6:19 pm Alright, that of course requires a relay. So it breaks the connection to L2 and makes the connection to L1 on the second module. One way to find out would be a 32A CP current limit but only AC voltage visible on the first charger module. I think there's an open collector output left.
Yes; that's what i thought.

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 10:18 pm
by et0
johu wrote: Wed Mar 16, 2022 6:19 pm oh, now I get it!
Alright, that of course requires a relay. So it breaks the connection to L2 and makes the connection to L1 on the second module. One way to find out would be a 32A CP current limit but only AC voltage visible on the first charger module. I think there's an open collector output left.
There's a few different ways to do it! The simplest, I think, is to route L1 to all 3 modules by default (for single phase operation) - that can be done with a single DPDT relay. Then the charger works in single phase mode as normal, so CP current limit divided by 3 to each module.

This relay can be energised by the voltage between phase 1 and 2, now it sends L1, L2 L3 to module 1, 2, 3. This detection can also feed an *input* on the charger, and all that does is change the flag to 3 phase mode.

On that link is a nice schematic - I have done it slightly different because of the choice of relays available, but it's same idea.

If you implement it I will test it ;)

Re: Tesla Charger alternative firmware

Posted: Wed Mar 16, 2022 10:24 pm
by et0
EV_Builder wrote: Wed Mar 16, 2022 6:19 pm
EV_Builder wrote: Wed Mar 16, 2022 6:40 am How is the difference communicated to the vehicle?
Cable limit?
@et0;
What about starting here? And educating all of us how the car can know with the current FW, or with change, how many phases there are connected to the socket it pulls from? as far as i know only amp ratings are communicated?
A contact of the external relay informs the charger that 3 phase is present. See the explanation above.

Re: Tesla Charger alternative firmware

Posted: Wed Mar 23, 2022 1:51 pm
by janosch
Does increasing iaclim while charging break a GEN2 charger?

I was charging at ~16A DC @ 360V at a public charge point, ~29A AC.
Then I saw that iaclim was slightly lower than what the charge point could do and increased iaclim while charging from 29A to 32A.

The charge dropped off. Reconnected and I was able to charge for an hour after, but udc fluctuated*, then dropped out altogether, with only 1.5kW in 50mins delivered.

I think the DC wiring was fine, uaux is still showing at 12.62V, so DCDC was still on, and car drove home fine. Measured the cable from DC bus to charger today and had 0 Ohm resistance (under no load).

* = see video: https://youtu.be/6NOqiOUGcFc

Re: Tesla Charger alternative firmware

Posted: Wed Mar 23, 2022 4:43 pm
by EV_Builder
Mybe the conversion from 32A to the charger is slightly off so that it translates in a rolledover value bitwise..??

Maybe a check: can anyone else charge with 32A setting ...

Re: Tesla Charger alternative firmware

Posted: Thu Mar 24, 2022 9:45 am
by janosch
EV_Builder wrote: Wed Mar 23, 2022 4:43 pm Mybe the conversion from 32A to the charger is slightly off so that it translates in a rolledover value bitwise..??

Maybe a check: can anyone else charge with 32A setting ...
Good idea, but the limit is 45A, so I would be surprised if that is the case.

I just captured a CAN dump back to back with the now presumed broken charger and a working one on the bench.

hwaclim remains 0 for the presumed broken one.

according to this post:
Jack Bauer wrote: Tue Feb 02, 2021 6:25 pm 0x207 is the module 1 line status message. Available line current is in bits 32 to 40 as a 9 bit unsigned int with a scale of 0.06666. On the gen3 this will report as a little under 24A at power up and around 13 A on the gen 2 at power up.
0x207 32 to 40 (I hope I counted right):
working: C8 9C
broken: C8 00

Firmware:
working: 1.09R
broken: 1.10R

I suppose I have learnt my lesson to not change that param during charging, unless something else is afoot. I did change idcspnt before and that wasn't a problem, but maybe that was already wrong.

Any other thoughts?

Re: Tesla Charger alternative firmware

Posted: Sat Mar 26, 2022 5:55 am
by johu
Haven't found the time to look at CAN dumps yet.
What I can say is there is just one value set affects charger power: modaclim. Whichever limit you set elsewhere it will show up on modaclim. So I doubt CHANGING iaclim really caused this. Were you charging single phase?

Re: Tesla Charger alternative firmware

Posted: Sun Mar 27, 2022 10:49 am
by janosch
Thanks for checking.
Yes, single phase wired to all modules.

Wiring looked OK, connectors rated for 30A.

Interrupts from updating the value while charging making the firmware run out of time for another important operation?
Let me know if you need anything else.

I am now wondering if the "wet" charger died from the same cause (same vehicle). Cautious to put a new charger in before knowing what might have been the reason for this.

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 9:29 am
by janosch
Or asked another way: What could I try to narrow this down further?

Some ideas:
- take the connectors out, put them between a battery and a load and measure voltage drop to rule cabling out
- I can take a look at the CAN dumps, but what am I looking for? It's a shame I haven't got a log from the moment it broke/dropped out

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 9:42 am
by johu
From the other side I wonder how the firmware could contribute to failure. We're not controlling power electronics directly, so that's ruled out. I could only guess that I need to put a ramp on modaclim so that current is ramped up slowly instead of one step.

When you activate just the presumably broken charger I guess it does not charge at all

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 9:50 am
by janosch
Correct, seems bricked, I tried all individual modules in it, but hwaclim, aclim, udc remain 0 for chargerena {1,2,4}.

For the ramp: It was quite a small change though, it sat at 29.2A / ~ 6960W and I increased it to 32A / 7680W. Also, the EVSELimit was 29.9A or similar, so surely that limit would have kicked in. Not sure if a 720W change would need much ramping?

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 10:59 am
by EV_Builder
.
Also, the EVSELimit was 29.9A or similar, so surely that limit would have kicked in.
The EVSE can be a simple relay. It means that it has no clue about actual power drawn. The comms. Just tell the EV for what amperage the system is layed out. So I don't expect any limit from there.
Elaborate on it please, then I learn :)

If it's possible to brick the charger with wrong amperage commands we need to known what the first tell tale is. The charger communicates allot over canbus, about Vboost and many other stuff.

Which maybe the red-flag which we ignore while asking it to give more juice...

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 11:08 am
by EV_Builder
@johu;
Is the requested power by the user or the amount send to the charger capped by anything? What if the user makes a typo like 32.0 or 32,0 and 320 gets requested internally? For example are there HW device limits in place?

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 11:28 am
by janosch
For the limits my understanding is that the firmware takes MIN of all limits to determine what to do in the end?

Code: Select all

aclim = MIN(cablelim, iaclim, evselim, hwaclim)
dclim = MIN(idcspnt, idclim)
Pure speculation :)
EV_Builder wrote: Mon Mar 28, 2022 11:08 am ...What if the user makes a typo like 32.0 or 32,0 and 320 gets requested internally? ...
Yep, can't rule that out!

Re: Tesla Charger alternative firmware

Posted: Mon Mar 28, 2022 12:30 pm
by janosch
Ok, one more idea: I have the wet charger here that still charges on one module and that can be sacrificed.

I can set CAN up to be dumped continuously and then we can stress it and see if we can get it to break while capturing?