Closed hardbyte closed 8 years ago
Original comment by Joshua Villyard (Bitbucket: jvmotivps, GitHub: Unknown):
The issue should be fixed in pull request 15 on the Recv. There was no bug on the transmit. It just was not very clear how it functioned. Added documentation to explain why the code pads the data with additional zeros.
Original comment by Joshua Villyard (Bitbucket: jvmotivps, GitHub: Unknown):
The Recv function is where the issue is at. It adds extra zeros at the end when it is not supposed to be there. So when I sent from the PCAN the data 01020304 it gave 0102030400000000 on the USB2CAN. The transmit although sends 8 length with extra zeros to the interface, however when the length is different, say 4, only the first 4 data is sent on the network.
Here is a wireshark file of sending data of different lengths.
It is not overly obvious on the Transmit. The wireshark file when you look at the raw data only shows that the USB2CAB device sent the amount of data that was requested to send and no extra data.
Original comment by Tynan McAuley (Bitbucket: tymcauley, GitHub: tymcauley):
Hey @jvmotivps, correct me if I'm wrong, but this issue has been resolved, right? There was a comment here about this being a problem, but I'm pretty sure that's outdated. The code should be able to deal with any length messages.
Originally reported by: Brian Thorne (Bitbucket: hardbyte, GitHub: hardbyte)