Closed fluppie closed 1 year ago
Hi,
regarding the exiConnector: Yes, this is a confusing error, which is in fact no error. I just pushed an improvement.
Regarding the closed connection, it is unclear which side closes the TCP connection, and why. Is it possible to create a network log with wireshark or tcpdump? (Edith) Maybe the car does not accept the protocol handshake response. May I ask what type of car this is?
Jup, exiConnector.py works now :) I can, is their a manual/instruction on how to do it? Or is this already happening in the background. 2022 BMW iX3
No, in EvseMode there is no script / service, which would run in background and do the logging. (This is in contrast to the PevMode, where we have the starter.sh, which starts the tcpdump and the pevNoGui script.) If you have a display and keyboard at your device and boot to the desktop, you can install wireshark using "sudo apt-get install wireshark", and then open the wireshark and select the appropriate interface for tracing. If you have only a command line, something like sudo tcpdump -i "eth0" -w "mydumpfile.pcap" & should do the job. This starts the tcpdump in the background (using the & at the end), and allows to call the python script afterwards.
I think I have something, hopefully it makes senses to you. I put the PWM 2 times to 5% for about 1 min. BMWiX3.zip
And some more BMWiX3_2.zip BMWiX3_ModemRequest.zip
The tracing worked perfectly. The traces show multiple times the issue with the broken connection, and the situation is always the same: After the TCP connection is correctly established, the iX3 announces the list of supported protocols, in this case the list contains one entry: DIN 70121 from 2012 (btw: This is surprising, this nearly brand-new car does not support ISO 15118, only the 10 year old DIN spec). The evse selects the first entry of the list, and the iX3 confirms this message with an TCP ACK. Afterwards it closes actively the TCP connection. It is not clear at the moment, why this is the case. The response of the evse is the same as also public chargers are using.
One idea: Maybe the car is confused about the lots of debug messages, which the evse sends as UDP broadcasts. I is worth a try to set udp_syslog_enable = No in pyPlc.ini.
Looks like it doesn't help :(. Yes, BMW announced plug & charge to be available mid 2023, but not for which models...
rpievse python3.9[12558]: [182010ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:34 rpievse python3.9[12558]: [184685ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:35 rpievse python3.9[12558]: [185335ms] received SLAC_PARAM.REQ
Jun 22 00:31:35 rpievse python3.9[12558]: [addressManager] pev has MAC EC:65:CC:B6:85:DC
Jun 22 00:31:35 rpievse python3.9[12558]: [185336ms] [EVSE] transmitting CM_SLAC_PARAM.CNF
Jun 22 00:31:35 rpievse python3.9[12558]: [185499ms] received SLAC_PARAM.REQ
Jun 22 00:31:35 rpievse python3.9[12558]: [addressManager] pev has MAC EC:65:CC:B6:85:DC
Jun 22 00:31:35 rpievse python3.9[12558]: [185500ms] [EVSE] transmitting CM_SLAC_PARAM.CNF
Jun 22 00:31:35 rpievse python3.9[12558]: [185745ms] received MNBC_SOUND.IND
Jun 22 00:31:35 rpievse python3.9[12558]: [185745ms] received MNBC_SOUND.IND
Jun 22 00:31:35 rpievse python3.9[12558]: [185827ms] received MNBC_SOUND.IND
Jun 22 00:31:35 rpievse python3.9[12558]: [185909ms] received MNBC_SOUND.IND
Jun 22 00:31:35 rpievse python3.9[12558]: [185991ms] received MNBC_SOUND.IND
Jun 22 00:31:35 rpievse python3.9[12558]: [185991ms] received MNBC_SOUND.IND
Jun 22 00:31:37 rpievse python3.9[12558]: [187369ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:37 rpievse python3.9[12558]: [187938ms] received SLAC_PARAM.REQ
Jun 22 00:31:37 rpievse python3.9[12558]: [addressManager] pev has MAC EC:65:CC:B6:85:DC
Jun 22 00:31:37 rpievse python3.9[12558]: [187938ms] [EVSE] transmitting CM_SLAC_PARAM.CNF
Jun 22 00:31:37 rpievse python3.9[12558]: [188183ms] received MNBC_SOUND.IND
Jun 22 00:31:37 rpievse python3.9[12558]: [188183ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188265ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188266ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188266ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188348ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188350ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188434ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188437ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188438ms] received MNBC_SOUND.IND
Jun 22 00:31:38 rpievse python3.9[12558]: [188439ms] [EVSE] transmitting ATTEN_CHAR.IND
Jun 22 00:31:39 rpievse python3.9[12558]: [189332ms] received SLAC_MATCH.REQ
Jun 22 00:31:39 rpievse python3.9[12558]: [189332ms] [EVSE] transmitting SLAC_MATCH.CNF
Jun 22 00:31:39 rpievse python3.9[12558]: [190063ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:42 rpievse python3.9[12558]: [addressManager] pev has IP fe80:0000:0000:0000:ee65:ccff:feb6:85dc
Jun 22 00:31:42 rpievse python3.9[12558]: V2GTP (10bytes) = 01 FE 90 00 00 00 00 02 10 00
Jun 22 00:31:42 rpievse python3.9[12558]: Ok, this was a valid SDP request. We are the SECC. Sending SDP response.
Jun 22 00:31:42 rpievse python3.9[12558]: SDP payload (20bytes) = FE 80 00 00 00 00 00 00 DA F2 AE 7A DB 60 D6 A9 3B 0E 10 00
Jun 22 00:31:42 rpievse python3.9[12558]: V2Gframe (28bytes) = 01 FE 90 01 00 00 00 14 FE 80 00 00 00 00 00 00 DA F2 AE 7A DB 60 D6 A9 3B 0E 10 00
Jun 22 00:31:42 rpievse python3.9[12558]: [192740ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:42 rpievse python3.9[12558]: [192743ms] Connection from ('fe80::ee65:ccff:feb6:85dc', 49155, 0, 4)
Jun 22 00:31:42 rpievse python3.9[12558]: [SNIFFER] EXI from 49155 to 15118 (34bytes) = 80 00 DB AB 93 71 D3 23 4B 71 D1 B9 81 89 91 89 D1 91 81 89 91 D2 6B 9B 3A 23 2B 30 02 00 00 00 00 40
Jun 22 00:31:42 rpievse python3.9[12558]: [192775ms] [EVSE] In state WaitForSupportedApplicationProtocolRequest, received (42bytes) = 01 FE 80 01 00 00 00 22 80 00 DB AB 93 71 D3 23 4B 71 D1 B9 81 89 91 89 D1 91 81 89 91 D2 6B 9B 3A 23 2B 30 02 00 00 00 00 40
Jun 22 00:31:42 rpievse python3.9[12558]: [192789ms] [EVSE] {
Jun 22 00:31:42 rpievse python3.9[12558]: "msgName": "supportedAppProtocolReq",
Jun 22 00:31:42 rpievse python3.9[12558]: "info": "34 bytes to convert",
Jun 22 00:31:42 rpievse python3.9[12558]: "error": "",
Jun 22 00:31:42 rpievse python3.9[12558]: "result": "Vehicle supports 1 protocols. ProtocolEntry#1 ProtocolNamespace=urn:din:70121:2012:MsgDef Version=2.0 SchemaID=0 Priority=1 ",
Jun 22 00:31:42 rpievse python3.9[12558]: "schema": "appHandshake",
Jun 22 00:31:42 rpievse python3.9[12558]: "debug": ""
Jun 22 00:31:42 rpievse python3.9[12558]: }
Jun 22 00:31:42 rpievse python3.9[12558]: [192789ms] [EVSE] Detected DIN
Jun 22 00:31:42 rpievse python3.9[12558]: [192803ms] [EVSE] responding (12bytes) = 01 FE 80 01 00 00 00 04 80 40 00 40
Jun 22 00:31:42 rpievse python3.9[12558]: [192804ms] [EVSE] from 0 entering 1
Jun 22 00:31:42 rpievse python3.9[12558]: [SNIFFER] EXI from 15118 to 49155 (4bytes) = 80 40 00 40
Jun 22 00:31:42 rpievse python3.9[12558]: [192855ms] connection closed
Jun 22 00:31:42 rpievse python3.9[12558]: [192855ms] [EVSE] re-initializing fsmEvse due to broken connection
Jun 22 00:31:42 rpievse python3.9[12558]: [192855ms] [EVSE] re-initializing fsmEvse
Jun 22 00:31:42 rpievse python3.9[12558]: [192855ms] Trying to reset the TCP socket
Jun 22 00:31:42 rpievse python3.9[12558]: [192856ms] pyPlcTcpSocket listening on port 15118
Jun 22 00:31:42 rpievse python3.9[12558]: [192857ms] The socket is linked the following IP addresses:
Jun 22 00:31:42 rpievse python3.9[12558]: [192857ms] ::1
Jun 22 00:31:42 rpievse python3.9[12558]: [192857ms] ::1
Jun 22 00:31:42 rpievse python3.9[12558]: [192857ms] ::1
Jun 22 00:31:45 rpievse python3.9[12558]: [195318ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Jun 22 00:31:47 rpievse python3.9[12558]: [197993ms] [CONNMGR] 9 0 0 0 0 0 0 --> 5
Does the same setup work with other car types?
On Sunday a friend with a Tesla Model 3 will come over, hopefully that will work, so we know if it's the iX3 or not.
I think I got the point: The iX3 uses SchemaID 0, but others (Tesla, Ioniq) use SchemaID 1. The pyPLC is hardwired to request Schema 1, which of course does not fit to the announcement of the iX3. Updates of the fsmEvse and the openV2Gx are necessary to be more flexible...
OK, and is this a complex thing to change? I have no clue what would be the difference between SchemaID 0 and SchemaID 1 :). Or can you just hardcode the SchemaID 0 where the 1 is mentioned?
P.S.: This is the log from the Tesla. pyPlc_logs_1day.txt Out of 9 "received SLAC_PARAM.REQ" I only have 2 "DC_EVStatus.EVRESSSOC"
The SchemaID is just a number. The car just gives a number to each entry in the list of supported protocols, and the charger picks one entry by telling "I want schemaID 1". In this response, the SchemaID is even optional, so the charger is formally allowed to say "I want", without telling a number. I have no idea, whether this works, but if you want to give a try you could search for aphsDoc.supportedAppProtocolRes.SchemaID = 1; in the openV2Gx, and change the number, or, more interesting, change the "isUsed" to 0 and test whether the car is happy with it.
The clean fix would be: Run through the list of announced protocols, extract the protocol and SchemaID of each entry, find the DIN entry, take the SchemaID of this entry, and send it to the car.
Since the topic mentioned in the title is solved, I created issues #9 and issue #10 for the remaining topics, and close this one.
Hi, I'm following along the manual at https://github.com/uhi22/pyPLC/blob/master/doc/installation_on_raspberry.md
I ignored it and continued steps, since this step worked for me:
seeing some data but seeing "[EVSE] re-initializing fsmEvse due to broken connection"
Any ideas about this? [21472ms] connection closed [21477ms] [EVSE] re-initializing fsmEvse due to broken connection [21477ms] [EVSE] re-initializing fsmEvse