Page 2 of 3

Re: Develop a QCA7000 board?

Posted: Tue Feb 20, 2024 6:33 pm
by uhi22
As soon as they see the 2k7 on the CP, yes. And special case Supercharger: as soon as it sees voltage on the PP and the 2k7 on CP, yes.
I even checked on some "out of service" chargers, which were powered, but showed in the display that they do not work. They have 12V on the CP, and connecting the 2k7 starts the PWM and even the SLAC.

[Edit] Well, "ALL" is a big word. I can only speak for the ones I have seen. But what else should they do? I've never seen a DC charger that needs authorization before activating 12V and PWM.

Re: Develop a QCA7000 board?

Posted: Tue Feb 20, 2024 6:41 pm
by johu
That sounds reasonable.

Only other issue I had with CP triggers was noise pickup. As in EMI from inverter while driving or something

EDIT: difference to PP trigger: I kept input impedance very high (100k or so) so it doesn't skew the PWM signal

Re: Develop a QCA7000 board?

Posted: Tue Feb 20, 2024 7:44 pm
by uhi22
Regarding noise pickup: I made an interesting observation in my Ioniq: They use a shielded CP line from the engine compartment (where the OBC sits), to the cabin (where the PLC modem sits under the driver seat) to the charge port above the rear left wheel. This avoids flooding the complete vehicle with PLC RF, and avoids picking up noise from the car to the CP. Quite an effort for a "cheap" car.

Re: Develop a QCA7000 board?

Posted: Tue Feb 20, 2024 7:57 pm
by asavage
uhi22 wrote: Tue Feb 20, 2024 7:44 pm I made an interesting observation in my Ioniq: They use a shielded CP line from the engine compartment (where the OBC sits), to the cabin (where the PLC modem sits under the driver seat) to the charge port above the rear left wheel.
On my 2014 RAV4 EV, I'm reasonably certain that my CP line is unshielded; only the AC power inputs have shielding.
Rav4 EV Charge Port: unshielded CP & PP
Rav4 EV Charge Port: unshielded CP & PP
Image

Re: Develop a QCA7000 board?

Posted: Tue Feb 20, 2024 8:45 pm
by muehlpower
CCS2.png
I think using 12V is a good idea. According to the Design_Guide_Combined_Charging_System, the CP line always has 12V / 1k at the beginning.

Re: Foccci wakeup/sleep discussions

Posted: Wed Feb 28, 2024 6:07 pm
by johu
Having second thoughts about CP wakeup. E.g. an unpowered EVSE (==unplugged granny lead) will not generate CP and thus there would be no driveaway protection since foccci doesn't even wake up.
I'll put some more though into using PP for both wakeup and cable capacity measurement.

Re: Foccci wakeup/sleep discussions

Posted: Wed Feb 28, 2024 6:58 pm
by uhi22
If the foccci would be woken up by CAN (or wakeup line) when the door is opened, or the interieur light is on, or even KL15, or something like this, it could detect the PP and communicate the driveaway protection. Okay, this would cost current during driving, also not nice.

Re: Foccci wakeup/sleep discussions

Posted: Wed Feb 28, 2024 7:19 pm
by tom91
Yes, have the Focci performance an OKAY to drive and not an DO NOT drive scenario. This way you cannot drive if the Focci is in an error state, not powered or waking up.

Waking up on PP is not needed, if you have it wake on kl15 or CAN when wanting to drive to have it give the okay.

On my builds the Charge Port Controllers are all woken with KL15 when driving and at all times they need to be happy and reporting no charge cable or errors. Sometimes this is as simple as a 12V relay that gets shut to allow the gear signal through.

Re: Foccci wakeup/sleep discussions

Posted: Thu Feb 29, 2024 5:11 pm
by celeron55
I think it would be perfectly fine to have foccci powered up while driving. Actually it would be preferable. This allows one to check from it whether something is plugged in any time one tries to drive (as mentioned by tom), but also it allows a dashboard display to read any stored errors from foccci, and possibly in the future some charging statistics and whatnot.

Re: Foccci wakeup/sleep discussions

Posted: Sat Mar 02, 2024 6:08 pm
by johu
As always, different opinions will just lead to more choice (aka solder jumpers and parameters) :D
I think it's easy to allow both PP and CP wakeup. I really like Touran setup where PP inherently disables drive with no other communication needed.
I'll try to get rid of the 12V/5V PP solder jumper and just deploy a little always-on 5V LDO for PP pull-up and consistent resistance readings.

Re: Foccci wakeup/sleep discussions

Posted: Tue Mar 05, 2024 9:59 pm
by johu
Ok, more woke design: (pun intended?)
grafik.png
We have 3 wake up sources
- 12V Wakeup
- CP
- PP

and actually 2 keep-awake sources
- Again Wakeup because it backfeeds
- KEEP_POWER_ON MCU signal

So quite simply an RC filtered CP will turn on the enable signal of the power converter. Likewise the 12V wakeup signal. PP on the other hand needs inversion, when PP goes low we turn power on. To not disturb resistance measurement with our 12V pull-up the latter is disabled once the MCU sets KEEP_POWER_ON.

The PP wakeup will only work if there are no permanent pull-down resistors anywhere in the loop. So you can either have PP wakeup or the mystery 3k pull-down:
grafik.png
Like said, I've haven't had issues without mystery pull-down so far

If we want the button as a wakeup source it needs to pull up to 12V instead of pulling 3v3 down to ground. What was the reason for the analog button again?

Re: Foccci wakeup/sleep discussions

Posted: Wed Mar 06, 2024 8:09 am
by uhi22
Just two questions:
1. Is the 100k pulldown on the EN of TPS inside spec?
2. Is the CP filtering designed in a way that it (a) does not disturb the CP levels too much and (b) deliver sufficient current to the D17?
3. Could ESD on the wakeup line kill the TPS? Same for PP and Q2.

Re: Foccci wakeup/sleep discussions

Posted: Wed Mar 06, 2024 9:25 am
by johu
uhi22 wrote: Wed Mar 06, 2024 8:09 am 1. Is the 100k pulldown on the EN of TPS inside spec?
The internal pull-up current is about 1 uA if I interpret the data sheet correctly. The threshold voltage for disabling is about 1.2V. so 100k*1uA=0.1V -> good
uhi22 wrote: Wed Mar 06, 2024 8:09 am 2. Is the CP filtering designed in a way that it (a) does not disturb the CP levels too much and (b) deliver sufficient current to the D17?
Good question, made me realize I' forgotten D2. It does indeed skew the voltage a little, from 9V down to 8V at 5% duty cycle. At higher duty cycles or plain 12V the skew is less than 0.2V. Could be compensated for by making R26 slightly larger, like 3k3 to safely stay above 8V even at 5%. It shouldn't disturb HF because of the 3k3 resistor, so even if C1 is considered a short for HF there is still the resistor.
grafik.png
(100k parallel resistance configured for C1 represents R56)
uhi22 wrote: Wed Mar 06, 2024 8:09 am 3. Could ESD on the wakeup line kill the TPS? Same for PP and Q2.
Wakeup has a TVS. PP indeed doesn't have protection. Could add one of those double diodes to 12V and GND or just a 1uF cap to absorb ESD

Re: Foccci wakeup/sleep discussions

Posted: Thu Mar 07, 2024 7:53 am
by uhi22
johu wrote: Tue Mar 05, 2024 9:59 pm What was the reason for the analog button again?
Just flexibility. Maybe someone wants more than one button, so it would be possible to connect multiple resistor-coded buttons. Or connect the "fuel-flap-closed-switch" with a resistor. Maybe too much flexibility, and a simple 12V digital input for the button makes it easier, and use a spare pin for the more flexible analog input.

Re: Foccci wakeup/sleep discussions

Posted: Thu Mar 07, 2024 8:48 am
by johu
We could retain that. Either pull up to permanent 12V (I quite like that the button pulls to gnd as that is found everywhere in the car). Or 12V input

Re: Foccci wakeup/sleep discussions

Posted: Fri Mar 08, 2024 4:29 pm
by johu
Finalized the design today. CP and PP wakeup ar momentary now and the button has been added as a wakeup signal.
grafik.png
Button is now pulled up to permanent 12V and has a voltage divider:
grafik.png
grafik.png (3.23 KiB) Viewed 891 times

Re: Foccci wakeup/sleep discussions

Posted: Fri Mar 08, 2024 4:37 pm
by uhi22
C83 needs a parallel 1M(or Higher), otherwise the CP wakeup will work just once.

Re: Foccci wakeup/sleep discussions

Posted: Fri Mar 08, 2024 6:50 pm
by johu
First I thought so too, but in ltspice it didn't simulate that way. Upon your comment I built the whole thing up on a bread board

Input is a 5% 1kHz +/-5V square wave that runs for 6.6s and then turns off for 27s

Yellow is the low pass filtered CP signal and blue is the 5V converter enable signal.
cp enable wo discharge resistor.png
Without discharge resistor the enable pulse length (i.e. time the enable signal is > 1.2V) of the second enable cycle is 0.8s

Now I added a 2M7 discharge resistor across "C83"
cp enable w discharge resistor.png
This increases the enable pulse length to 0.95s on the second cycle.

Of course if you unplug and plug faster than that, say within 10s the second wakeup wouldn't go through. But that is easily solved by letting Foccci self-enable for 30s after each wakeup. Or rather after loosing CP or PP.

I think the explanation is that C82, C83 and R56 are all in series and each end is connected to GND. So once CP is gone, the series capacitor formed by C82 and C83 discharges via R56.

EDIT: now that I have the whole thing built up I also connected it to one of your Foccci boards and indeed duty cycle and PLC communication are not disturbed by it

Re: Foccci wakeup/sleep discussions

Posted: Fri Mar 08, 2024 10:06 pm
by uhi22
image.png
image.png (5.27 KiB) Viewed 855 times
The red point can only discharge, if there is a resistance to ground. E.g. the 10M of the scope input. Then it works. If no resistor is present, there is no path to turn the voltage down. Only leakage current, which is unpredictable. You could disconnect the scope while CP is at 12V, then disconnect CP, wait two minutes and re-connect the scope to the red point. The voltage starts at 12V and ramps down due the 10M of the scope.

Re: Foccci wakeup/sleep discussions

Posted: Sat Mar 09, 2024 12:55 pm
by johu
oh that's why - Schrödingers cat ;)

Well I guess a 1M resistor won't have unwanted effects.

EDIT: just realized that PP_WAKE will never work because it is being slowly pulled down by the voltage divider to the µC

Re: Foccci wakeup/sleep discussions

Posted: Mon Mar 18, 2024 7:28 pm
by johu
I have added the resistor and changed the PP wakeup back to permanent wakeup. So if you have a scenario where you expect the charge cable to be plugged in for many days you'd disable PP wakeup with the solder jumper and use CP wakeup instead.

So I think we can cover quite a few use cases now.
  1. The Tom91 way, AC and CCS charging, wakeup on drive for state reporting
    • Wakeup only with CP
    • Wakeup other devices via brief 12V pulse on wakeup pin - provided a charging session is actually established
    • Wakeup Foccci on vehicle start via wakeup input, Foccci goes to sleep after having sent some status messages
    • Drive lockout via explicit CAN state report
  2. The johu way - CCS charging only
    • Wakeup only via PP
    • Power supply other devices with permanent 12V output on wakeup pin
    • Foccci is not woken up when driving or AC charging (uses other socket)
    • Drive lockout implicit when wakeup pin from Foccci is low
Some things which we do not cover:
  • We don't have hassle free non-volatile memory to remember errors. We could permanently power V_bat with a separate LDO to be able to use the backup domain SRAM.
  • We can only combine Foccci with a charger that doesn't have its own CP and/or PP handling. We could make the 2k7 pull down and 5V pull-up switchable as well to free up the signals for chargers that do handle CP/PP

Re: Foccci wakeup/sleep discussions

Posted: Mon Mar 18, 2024 7:45 pm
by asavage
johu wrote: Mon Mar 18, 2024 7:28 pmWe can only combine Foccci with a charger that doesn't have its own CP and/or PP handling. We could make the 2k7 pull down and 5V pull-up switchable as well to free up the signals for chargers that do handle CP/PP
The above is my use case: adding DCFC to an OEM EV which has none, but its OBC expects to handle CP/PP for AC charging.

I have been planning to mechanically switch the CP & PP lines to/from FOCCI as needed. If FOCCI/clara can analyse incoming CP and determine that AC charging is presented by the EVSE, and then route CP/PP onward to the OBC, that would be a substantial improvement over a user-activated switch, but mine may be a niche case and not worth the dev effort.

Re: Foccci wakeup/sleep discussions

Posted: Mon Mar 18, 2024 8:45 pm
by johu
asavage wrote: Mon Mar 18, 2024 7:45 pm but mine may be a niche case and not worth the dev effort.
It may not be that niche. The MG/SAIC/DFSK chargers Damian us currently hacking expect an undistorted CP and PP signal, the popular Outlander charger expects an undistorted CP signal. And I'm guessing many others will expect that as well.

In fact Damian is deploying a change over relay to solve it for now but of course that is bulky.

Re: Foccci wakeup/sleep discussions

Posted: Mon Mar 18, 2024 9:23 pm
by MoonUnit
johu wrote: Mon Mar 18, 2024 7:28 pm We can only combine Foccci with a charger that doesn't have its own CP and/or PP handling. We could make the 2k7 pull down and 5V pull-up switchable as well to free up the signals for chargers that do handle CP/PP
and
asavage wrote: Mon Mar 18, 2024 7:45 pm The above is my use case: adding DCFC to an OEM EV which has none, but its OBC expects to handle CP/PP for AC charging.
Similar to my use case, in which I would be adding DCFC to (non OEM) onboard AC charging via J1772, using two charge ports as well.

As I understand it, in the Orion BMS2 which I use there is an option for using the Zero EV CCS config. If that is selected, the Zero EV CCS controller detects and sends the CP value to the Orion via CAN, effectively allowing the Orion to choose whether to command CCS limits or AC onboard charger limits, and both CP and PP lines are physically disconnected from the Orion. That, I assume, would mean the user only uses one charge port for both CCS and AC.

In my case, I would have two charge ports. The existing one for AC that has PP/CP connected, and a new CCS one for DC. If FOCCCI could wake up when CCS plugged in, and provide a 12V signal as well a CAN message then I expect I can use the 12V to wake up my BMS, disconnect the CP/PP lines and tell the BMS we are about to do DCFC.

Topic is here viewtopic.php?t=4746

Re: Foccci wakeup/sleep discussions

Posted: Tue Mar 19, 2024 7:08 pm
by celeron55
johu wrote: Mon Mar 18, 2024 8:45 pm the popular Outlander charger expects an undistorted CP signal
I have heard it doesn't really need an undistorted CP signal, it just needs 12V PWM with a current limiting resistor. Not even -12...12V, just 0...12V. So foccci could just replicate the CP PWM to a new 0...12V output, as far as the outlander charger is concerned.

I would prefer someone to confirm this who has actually tested it though. And I haven't heard of the other brands.