uhi22 wrote: ↑Mon Dec 11, 2023 6:34 pm
The information I have leads to an other solution. Had a look to the Ioniq trace and to the specification. Added the analysis here:
https://github.com/uhi22/pyPLC#detaille ... ng-session
The summary:
- PowerDeliveryReq(Stop) is fired under full current.
- The charger needs 1.5s until it confirms with PowerDeliveryRes. Maybe already here, it turns-off the current.
- The car sets stateB, and this is the "fast trigger" to the charger to turn-off the current (I have read somewhere this should be in 20ms, but cannot find this information anymore).
- Here we can simply wait for half a second (conditionless), to give the current some time to fall.
- Open the contactors.
- Wait again 0.5s to give the contactors time to move.
- Send a WeldingDetection. Depending on the charger it will wait (in example 1s, according spec below 1.5s), measure the voltage and report it back in the WeldingDetectionResponse.
- We need to repeat the WeldingDetection loop, until the voltage is not dangerous anymore.
- Then unlocking the connector and send the SessionStop.
Since you cross referenced it in the pyPLC Thread I did a little digging in the IEC 61851-23 regarding the normal end of a charging session.
Heres what my understanding of it is and some comments (also relating to the github link):
[charging]
- EV reduces current request. Charger follows with time delay and reduces output current to less then 1A before disabling its output [so apparently its our job to make sure to reduce the current to less then 1A before continuing in the sequence. Which makes sense since the charger should follow our request and our side is coordinating the sequence]
- EV sends message to charger to disable power output. After current is below 1A the EV opens contactors (in the spec called "disconnecting device")
- Charger disables output & opens contactors
- Charger reports status "not ready" with message to indicate it disabled its output (DC_EVSEStatus.EVSEStatusCode = 2 EVSE_Shutdown) [comment to github: this does not contain voltage or current because the EVs HV should already be disconnected]
- After receiving the above message (or after timout) EV changes CP state to B. This is also where the EV may perform welded contactor check [I personally like the placement of the CP change, since we can (under normal circumstances) confirm that both sides have opened the contactors succesfully. The timout here is crucial to continue in the sequence so we dont stay locked in forever if the charger crashed. If I remember correctly this should be 2s. Welding checks are also defined (especially regarding time) but its mainly a loop until time limit is reached or weld detected. Comment to the 40s: Some OEMs e.g. BMW use multiple contactors for CCS and "cycle" which they use. So Welding checks sometime need that time

. If I understand it correctly it currently is not a priority on the ToDo List to implement welding checks. So we can ignore this for now and leave it as a todo for later? (I at least want to use it at some point in the future)]
- EV sends Session Stop Req, terminates PLC and unlocks connector after DC Output has dropped below 60V or energy is below 0,2J. [Till the end of this (with the exception of isolation monitoring during welding checks) the Isolation and lock monitoring is still active]
- Unplugging. CP state from B to A.
This is only my understanding and I am more then open for discussion but from my perspective this makes sense for "normal" operation.
Some questions that also came to my mind:
- It might be usefull to write down the whole cycle (not only the Power Down Sequence) in a structered way. At least what is implemented in Clara. Would have the additional benefit of lowering the entry barrier for new contributors to the project. With the permission of johannes and uhi I would like to make a wiki page for clara and fill it with this information. Maybe even with our own diagramms that we can reference to.
- We currently have no Emergeny Exit procedures implemented correct? Might be worth a point on the ToDo List for sometime down the road. With some mods on PyPLC we could also add tests to confirm they are working...
- Since a lot of people now know and see that Clara + Focci is able to initiate a charging session wouldnt it be usefull to add a Disclaimer to the github repo that this is still WIP and use is on own risk. I dont want to scare people away but at this point people should know that this is not a finished product and be handled with care or give them a realistic expectation (didnt finished watching Johannes newest yt video but from the first opening it seems like this is the same tenor. Congrats on the Ionity success btw

).
And lastly I want to thank Uhi. My Focci Board arrived today and I am excited to play with it over the christmas holidays
