-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Packet Size EOF Bug / Problem #320
Comments
Okay so this is some very preliminary code. But this concept appears to resolve my issue. It is however not a very optimal solution in iso15118/shared/comm_session.py rcv_loop() message = await asyncio.wait_for(self.reader.read(7000), timeout)
message_len = len(message)
# Fragments are likely...
while (message_len > 1427): # TODO ENV MTU LIMIT, cap of 73 substracted from 1500 MTU for headers of packet
append_msg = await asyncio.wait_for(self.reader.read(7000 - message_len), timeout)
message = message + append_msg
message_len = len(append_msg) I would love to know, if I have just reinvented the wheel or if this is a new feature for this stack. Would it be worth it to create a pull request? Thank you. |
Hmm...does replacing self.reader.read(7000) with self.reader.read() help? |
Trying this solution did not go very well. After trying for some time make it work I could not get the stack to show normal function. It appears to keep reading indefinitely after receiving the first message. Anyone other ideas? |
Currently I am using the ISO15118 software stack in a system that has an ethernet interface which cannot exceed 1500 MTU (Maximum transmission unit).
This means the interface can only receive a maximum of around 1500 bytes per packet.
I have found that when testing ISO15118-20 and certificates are sent between the EVCC and SECC that the packet(s) containing the certificate get split into for example two packets because of the size of the packets.
Only the first packet is read by the software stack and then rightfully so the Java codec complains about an unexpected EOF.
TCPDUMP OUTPUT OF TWO PACKETS BEING SPLIT
I am wondering if this is the intended behavior or if there is a proper way for me to receive these two fragments to combine into one message. I have already dabbled with introducing a kind of "Number of fragments" addition to the code however I have been unsuccessful in its execution so far because of lack of knowledge.
Has anyone had issues similar to mine?
Thank you.
The text was updated successfully, but these errors were encountered: